Fixes to Section extraction code, tree model