14.5.14. crate_anon.nlp_manager.constants

crate_anon/nlp_manager/constants.py


Copyright (C) 2015, University of Cambridge, Department of Psychiatry. Created by Rudolf Cardinal (rnc1001@cam.ac.uk).

This file is part of CRATE.

CRATE is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

CRATE is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with CRATE. If not, see <https://www.gnu.org/licenses/>.


Constants for CRATE NLP, including a demo config file.

class crate_anon.nlp_manager.constants.CloudNlpConfigKeys[source]

Config file keys for cloud NLP.

class crate_anon.nlp_manager.constants.DatabaseConfigKeys[source]

Config file keys for database definitions.

class crate_anon.nlp_manager.constants.GateApiKeys[source]

Dictionary keys for the direct API to GATE.

See https://cloud.gate.ac.uk/info/help/online-api.html for format of response from processor. The GATE JSON format is:

{
  "text":"The text of the document",
  "entities":{
    "SampleAnnotationType1":[
      {
        "indices":[0,3],
        "feature1":"value1",
        "feature2":"value2"
      }
    ],
    "SampleAnnotationType2":[
      {
        "indices":[12,15],
        "feature3":"value3"
      }
    ]
  }
}
class crate_anon.nlp_manager.constants.GateFieldNames[source]

Field (column) names for results from GATE. These match KEY_* strings in CrateGatePipeline.java.

class crate_anon.nlp_manager.constants.GateResultKeys[source]

Dictionary keys to represent GATE results in our NLPRP server.

class crate_anon.nlp_manager.constants.InputFieldConfigKeys[source]

Config file keys for input database fields (columns).

class crate_anon.nlp_manager.constants.NlpConfigPrefixes[source]

Section name prefixes for the NLP config file.

class crate_anon.nlp_manager.constants.NlpDefConfigKeys[source]

Config file keys for NLP definitions.

class crate_anon.nlp_manager.constants.NlpDefValues[source]

Config file values for NLP definitions

class crate_anon.nlp_manager.constants.NlpOutputConfigKeys[source]

Config file keys for output tables from GATE or Cloud NLP processors.

class crate_anon.nlp_manager.constants.ProcessorConfigKeys[source]

Config file keys for NLP processors.