I'm working on providing advanced searching for annotated Medical Documents (using UIMA). In the context of an annotated document, I identify relevant medical terms, as well as the negation of certain terms. Following what I've read and seen in Lucene examples, I've been able to provide a search that takes into account the metadata contained in the payload. Although very primitive, I've implemented a search which returns the payloads (using PayloadSpanUtil), and then excludes those terms where the payload doesn't meet the criteria.
Is the use of payloads I've described appropriate? Can I exclude/filter the matching terms based on the payload within a query itself ? Are there any examples that do this? Cheers, Kyley