add smart constructor to DocDesc type
add smart constructor to document table
adjust test