Package com.ikanow.infinit.e.harvest.enrichment.custom

Examples of com.ikanow.infinit.e.harvest.enrichment.custom.UnstructuredAnalysisHarvester


    }//(only only)
  }//TESTED (fullText_docMetaTests.json, import_lookups_test_uahSah)
 
  protected void requiresUnstructuredAnalysis() {
    if (null == _uah) {
      _uah = new UnstructuredAnalysisHarvester();
      _uah.setContext(_hc);
     
      if (null != _sah) {
        _sah.addUnstructuredHandler(_uah);
      }
View Full Code Here


          }//TOTEST
          else if (null != searchDoc.getMetadata()){
            savedMeta = searchDoc.getMetadata().remove("searchEngineSubsystem");
              // (this is normally null)
          }//TOTEST
          UnstructuredAnalysisHarvester dummyUAH = new UnstructuredAnalysisHarvester();
          boolean bMoreDocs = (nPage < nMaxPages - 1);
          Object[] searchResults = null;
          try {
            dummyUAH.executeHarvest(context, src, searchDoc, false, bMoreDocs);
              // (the leading false means that we never sleep *before* the query, only after)
            searchResults = searchDoc.getMetaData().get("searchEngineSubsystem");
          }
          finally {
            if (null != savedMeta) { // (this is really obscure but handle the case where someone has created this meta field already)
View Full Code Here

  //

  private void enrichSource(SourcePojo source, List<DocumentPojo> toAdd, List<DocumentPojo> toUpdate, List<DocumentPojo> toRemove)
  {
    StructuredAnalysisHarvester sah = null;
    UnstructuredAnalysisHarvester usah = null;

    // Create metadata from the text using regex (also calculate header/footer information if desired)
    if (source.getUnstructuredAnalysisConfig() != null)
    {
      usah = new UnstructuredAnalysisHarvester();

      // If performing structured analysis also then need to mux them
      // since the UAH will run on the body/description potentially created by the SAH
      // and the SAH will take the metadata generated by UAH to create entities and events
      if (source.getStructuredAnalysisConfig() != null) {
        sah = new StructuredAnalysisHarvester();
        sah.addUnstructuredHandler(usah);
      }
      else {
        toAdd = usah.executeHarvest(this, source, toAdd);
      }
    }

    // For sources that generate structured data, we can turn that into entities and events
    // and fill in document fields from the metadata (that can be used by entity extraction)
View Full Code Here

TOP

Related Classes of com.ikanow.infinit.e.harvest.enrichment.custom.UnstructuredAnalysisHarvester

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.