Ejemplo n.º 1
0
  @Override
  public void initialize(UimaContext aContext) throws ResourceInitializationException {
    super.initialize(aContext);

    posMappingProvider =
        MappingProviderFactory.createPosMappingProvider(
            posMappingLocation, posTagset, getLanguage());
  }
Ejemplo n.º 2
0
  @Override
  public void initialize(UimaContext aContext) throws ResourceInitializationException {
    super.initialize(aContext);

    posMappingProvider =
        MappingProviderFactory.createPosMappingProvider(
            posMappingLocation, posTagset, getLanguage());

    constituentMappingProvider =
        MappingProviderFactory.createConstituentMappingProvider(
            constituentMappingLocation, constituentTagset, getLanguage());

    converter = new PennTreeToJCasConverter(posMappingProvider, constituentMappingProvider);
    converter.setInternTags(internTags);
    converter.setWriteTracesToText(writeTracesToText);
    converter.setCreatePosTags(false); // We handle POS tags via the column already
    converter.setRootLabel("TOP");
  }