gate - How to get the name of the document, the pipeline is currently working on? -


let's say, corpus have 1k docs, , processed pipeline.
@ point, pipeline stucks, throws exception or have funny behavior. these document-relevant.
it'd nice know document being processed in pipeline. example, print out doc name in jape transducer.

to document processing can write simple jape rule like:

phase:  docname input: token options: control = once  rule:docname (  {token} ) --> {   system.out.println(doc.getname()); } 

put rule first rule in pipeline. hope have least 1 token in document.


Comments

Popular posts from this blog

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -

Trying to import CSV file to a SQL Server database using asp.net and c# - can't find what I'm missing -