Login


en | de

API Documentation

TXT Werk - the Neofonie text mining API - analyzes text according to semantic criteria. Various methods of natural language technology are used. The API takes text as input and classifies them to topics, it extracts keywords which can be used as tags. If a text contains dates or date ranges, they will be annotated. Mentions of names (Named Entities) of places, persons, organizations, and concepts are recognized and annotated. If the entity can be found in the Wikidata ontology, an URI will be provided.

Authentication

The authentication is done by providing the API Key in the header "X-Api-Key".

Example Request

Details of the parameters and a detailed description of the return format can be found in the Request- or Response- documentation.

Request

curl "https://api.neofonie.de/rest/txt/analyzer" \
    -H "X-Api-Key: ..." \
    --data-urlencode text='Angela Merkel wurde am 17. Juli 1954 in Hamburg als Angela Dorothea Kasner geboren.' \
    -d services='categories,entities,tags,dates'

Response

  • {
    • text: "Angela Merkel wurde am 17. Juli 1954 in Hamburg als Angela Dorothea Kasner geboren.",
    • language: "de",
    • entities: [
      • {
        • confidence: 47.150089263916016,
        • end: 13,
        • label: "Angela Merkel",
        • start: 0,
        • surface: "Angela Merkel",
        • type: "PERSON",
        • uri: "https://www.wikidata.org/wiki/Q567"
      • },
      • {
        • confidence: 46.01070785522461,
        • end: 47,
        • label: "Hamburg",
        • start: 40,
        • surface: "Hamburg",
        • type: "PLACE",
        • uri: "https://www.wikidata.org/wiki/Q1055"
      • },
      • {
        • confidence: 75.0,
        • end: 74,
        • label: null,
        • start: 52,
        • surface: "Angela Dorothea Kasner",
        • type: "PERSON",
        • uri: null
      • }
    • ]
    • tags: [
      • {
        • confidence: 0.9967904107197822,
        • term: "Angela Merkel"
      • },
      • {
        • confidence: 0.9927268430144784,
        • term: "Juli"
      • },
      • {
        • confidence: 0.9751561498425574,
        • term: "Hamburg"
      • },
      • {
        • confidence: 0.7406453816287002,
        • term: "Angela Dorothea Kasner"
      • }
    • ]
    • dates: [
      • {
        • dateEnd:
          • {
            • bc: false,
            • day: 17,
            • month: 7,
            • year: 1954
          • }
        • dateStart:
          • {
            • bc: false,
            • day: 17,
            • month: 7,
            • year: 1954
          • }
        • end: 36,
        • start: 23,
        • surface: "17. Juli 1954"
      • }
    • ]
    • categories: [
      • {
        • confidence: 0.9840945695370302,
        • label: "politik"
      • },
      • {
        • confidence: 0.010815793425103136,
        • label: "wirtschaft"
      • },
      • {
        • confidence: 0.005075348628913112,
        • label: "kultur"
      • },
      • {
        • confidence: 1.09702999767795e-05,
        • label: "sport"
      • },
      • {
        • confidence: 1.8793566199359706e-06,
        • label: "reisen"
      • },
      • {
        • confidence: 8.05313821392574e-07,
        • label: "wissenschaft"
      • },
      • {
        • confidence: 6.26958551045314e-07,
        • label: "internet"
      • },
      • {
        • confidence: 6.479984358403916e-09,
        • label: "auto+technik"
      • }
    • ]
  • }