// Assumes a single test dataset description in the assembler file.
Dataset ds = TextDatasetFactory.create(file) ;
if (ds == null)
throw new CmdException("No dataset description found") ;
// get index.
dataset = (DatasetGraphText)(ds.asDatasetGraph()) ;
textIndex = dataset.getTextIndex() ;
if (textIndex == null)
throw new CmdException("Dataset has no text index") ;
entityDefinition = textIndex.getDocDef() ;
}