You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 9 Next »

Create custom pipelines to extract more information than is available through the Default Clinical Pipeline. Special Analysis Engines are in various cTAKES modules. Analysis Engines can be removed or added to pipelines to obtain desired results.

There are four methods available to create custom pipelines.

  1. XML Descriptor files are the original method used to create pipelines in Apache UIMA™.  Though self-descriptive, they are verbose and error prone.
  2. uimaFIT™ enables creation of pipelines through Java code.  This greatly simplifies unit testing and experimentation.
  3. The PipelineBuilder class in ctakes-core is a facade for uimaFIT™ factories and objects.

  4. Piper files are a modern equivalent of the XML descriptor files.  Piper files list basic commands and parameters in a flat format.
CommandParameter 1Parameters 2-nDescription
packagepackage path 

Add to known packages. Shortens load and add specifications.

loadPiper file path Load external piper file.
setname=value<name=value ...>Add global parameter values.
cliname=char<name=char ...>

Add global parameter values based upon command-line character option values.

readerCR name<name=value ...>Set the collection reader for pipeline input data.
readFilesinput directory Set the collection reader for pipeline input data to the files in directory tree reader.
addAE or CC name<name=value ...>Add AE/CC to pipeline.
addDescriptionAE or CC name<value ...>

Add AE/CC to pipeline using its .createDescription method.

addLoggedAE or CC name<name=value ...>Add AE/CC to pipeline with Start/Finish logging.
addLastAE or CC name<name=value ...>Add AE/CC to the end of pipeline. Useful if the pipeline is meant to be extended.
writeXmisoutput directory Add XMI writer to the pipeline.
// or # or !comment text Line Comment.

Table 1.  Standard Piper commands.
A complete pipeline can be created using a reader (or readFiles) and add commands.

Step-by-step guide

  1. Create an empty text file.  The standard file extension for piper files is .piper .
  2. If applicable, start with a load of an available piper file.  See Table 2 for standard piper files in cTAKES.

 

Piper fileModuleDescriptionContains
DefaultTokenizerPipeline.pipercoreComplete Tokenizer pipeline.SimpleSegmentAnnotator SentenceDetector TokenizerAnnotatorPTB
ChunkerSubPipe.piperchunkerChunker partial pipeline.Chunker ChunkAdjuster (NP,NP 1) ChunkAdjuster (NP,NP,NP 2)
AssertionSubPipe.piperassertionEntity attribute partial pipeline.ClearNLPDependencyParserAE ClearNLPSemanticRoleLabelerAE ConceptConverterAnalysisEngine AssertionAnalysisEngineFit GenericAttributeAnalysisEngine SubjectAttributeAnalysisEngine
AttributeCleartkSubPipe.piperassertionEntity attribute partial pipeline.ClearNLPDependencyParserAE ClearNLPSemanticRoleLabelerAE PolarityCleartkAnalysisEngine UncertaintyCleartkAnalysisEngine HistoryCleartkAnalysisEngine ConditionalCleartkAnalysisEngine GenericCleartkAnalysisEngine SubjectCleartkAnalysisEngine
DefaultFastPipeline.piperclinical-pipelineComplete Clinical pipeline.DefaultTokenizerPipeline.piper ContextDependentTokenizerAnnotator POSTagger ChunkerSubPipe.piper DefaultJCasTermAnnotator AttributeCleartkSubPipe.piper

Table 2.  Available standard piper files in cTAKES.

 

 

DefaultFastPipeline.piper

Diagram 1.  Piper files used in the cTAKES default Clinical Pipeline.  Upper left is DefaultFastPipeline.piper

 

 

 

  • No labels