7.6.3. remove-dic オプション

利用しない地名解析辞書を指定します。

set-dic オプション と併用した場合、 まず set-dic を評価して利用する辞書を決定し、 そこから remove-dic で指定された辞書を除外します。

set-dic が指定されていない場合、データベースに 登録されている全ての辞書から remove-dic で 指定された辞書を除外します。

パラメータ

remove-dic : str, list of str

  • 文字列が指定された場合、正規表現として解釈し、 パターンを含む identifier を持つ 辞書を除外します

  • 文字列のリストが指定された場合、 利用する辞書 identifier のリストと解釈し、 リストに含まれる identifier 持つ辞書を除外します

7.6.3.1. リクエストの例

identifier に 'station' を含む辞書 ( geonlp:ksj-station-N02-2019 ) を利用しないように指定します。 駅名は検索されなくなります。

{
  "method": "geonlp.parse",
  "params": {
    "sentence": "和歌山市は晴れ。",
    "options": {
      "remove-dic": "station"
    }
  },
  "id": "test_parse_remove_dic"
}

7.6.3.2. レスポンスの例

{
  "features": [
    {
      "geometry": {
        "coordinates": [
          135.170808,
          34.230514
        ],
        "type": "Point"
      },
      "properties": {
        "geoword_properties": {
          "address": "和歌山県和歌山市",
          "body": "和歌山",
          "body_variants": "和歌山",
          "code": {},
          "countyname": "",
          "countyname_variants": "",
          "dictionary_id": 1,
          "dictionary_identifier": "geonlp:geoshape-city",
          "entry_id": "30201A1968",
          "geolod_id": "lQccqK",
          "hypernym": [
            "和歌山県"
          ],
          "latitude": "34.23051400",
          "longitude": "135.17080800",
          "ne_class": "市区町村",
          "prefname": "和歌山県",
          "prefname_variants": "和歌山県",
          "source": "1/和歌山市役所/和歌山市七番丁23/P34-14_30.xml",
          "suffix": [
            "市"
          ],
          "valid_from": "1889-04-01",
          "valid_to": ""
        },
        "morphemes": {
          "conjugated_form": "*",
          "conjugation_type": "*",
          "original_form": "和歌山市",
          "pos": "名詞",
          "prononciation": "",
          "subclass1": "固有名詞",
          "subclass2": "地名語",
          "subclass3": "lQccqK:和歌山市",
          "surface": "和歌山市",
          "yomi": ""
        },
        "node_type": "GEOWORD",
        "surface": "和歌山市"
      },
      "type": "Feature"
    },
    {
      "geometry": null,
      "properties": {
        "morphemes": {
          "conjugated_form": "*",
          "conjugation_type": "*",
          "original_form": "は",
          "pos": "助詞",
          "prononciation": "ワ",
          "subclass1": "係助詞",
          "subclass2": "*",
          "subclass3": "*",
          "surface": "は",
          "yomi": "ハ"
        },
        "node_type": "NORMAL",
        "surface": "は"
      },
      "type": "Feature"
    },
    {
      "geometry": null,
      "properties": {
        "morphemes": {
          "conjugated_form": "*",
          "conjugation_type": "*",
          "original_form": "晴れ",
          "pos": "名詞",
          "prononciation": "ハレ",
          "subclass1": "一般",
          "subclass2": "*",
          "subclass3": "*",
          "surface": "晴れ",
          "yomi": "ハレ"
        },
        "node_type": "NORMAL",
        "surface": "晴れ"
      },
      "type": "Feature"
    },
    {
      "geometry": null,
      "properties": {
        "morphemes": {
          "conjugated_form": "*",
          "conjugation_type": "*",
          "original_form": "。",
          "pos": "記号",
          "prononciation": "。",
          "subclass1": "句点",
          "subclass2": "*",
          "subclass3": "*",
          "surface": "。",
          "yomi": "。"
        },
        "node_type": "NORMAL",
        "surface": "。"
      },
      "type": "Feature"
    }
  ],
  "type": "FeatureCollection"
}