<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                ThinkChat2.0新版上線,更智能更精彩,支持會話、畫圖、視頻、閱讀、搜索等,送10W Token,即刻開啟你的AI之旅 廣告
                # Synonym Graph Token Filter(Synonym Graph 詞元過濾器) **警告:**此功能是實驗性的,可能會在將來的版本中完全更改或刪除。 Elastic 將采取最大的努力來解決任何問題,但實驗功能不受SLA官方功能的支持。 **synonym_graph**?詞元過濾器允許在分析過程中輕松處理同義詞,包括多字同義詞。 為了正確處理多字同義詞,該詞元過濾器在處理過程中創建 “**graph token stream**”。 有關此主題及其各種復雜性的更多信息,請閱讀?**[Lucene’s TokenStreams are actually graphs](http://blog.mikemccandless.com/2012/04/lucenes-tokenstreams-are-actually.html)**?博客文章。 **提示:**該詞元過濾器被設計為僅用作搜索分析器的一部分。 如果要在索引期間應用同義詞,請使用標準?**[synonym token filter](http://www.apache.wiki/pages/viewpage.action?pageId=10028859)**。 同義詞使用配置文件配置。 這是一個例子: | `PUT /test_index` `{` `"settings"``: {` `"index"`?`: {` `"analysis"`?`: {` `"analyzer"`?`: {` `"search_synonyms"`?`: {` `"tokenizer"`?`:?``"whitespace"``,` `"filter"`?`: [``"graph_synonyms"``]` `}` `},` `"filter"`?`: {` `"graph_synonyms"`?`: {` `"type"`?`:?``"synonym_graph"``,` `"synonyms_path"`?`:?``"analysis/synonym.txt"` `}` `}` `}` `}` `}` `}` | 以上配置一個?**`search_synonyms`?**(同義詞)過濾器,其中包含一個路徑?**analysis/synonym.txt**(相對于?**config?**的位置)。 然后使用過濾器配置?**`search_synonyms`?**同義詞分析器。 其他設置有:**ignore_case**(默認為?**false**),和?**`expand`?**(默認為?**true**)。 **tokenizer**?參數控制將用于標記同義詞的分詞器,并且默認為?**`whitespace`**??分詞器。 支持兩種同義詞格式:**Solr,WordNet**。 #### **Solr synonyms** 以下是文件的示例格式: | `# Blank lines and lines starting with pound are comments.` `# Explicit mappings match any token sequence on the LHS of?``"=>"` `# and replace with all alternatives on the RHS.? These types of mappings` `# ignore the expand parameter in the schema.` `# Examples:` `i-pod, i pod => ipod,` `sea biscuit, sea biscit => seabiscuit` `# Equivalent synonyms may be separated with commas and give` `# no explicit mapping.? In?``this`?`case`?`the mapping behavior will` `# be taken from the expand parameter in the schema.? This allows` `# the same synonym file to be used in different synonym handling strategies.` `# Examples:` `ipod, i-pod, i pod` `foozball , foosball` `universe , cosmos` `lol, laughing out loud` `# If expand==``true``,?``"ipod, i-pod, i pod"`?`is equivalent` `# to the explicit mapping:` `ipod, i-pod, i pod => ipod, i-pod, i pod` `# If expand==``false``,?``"ipod, i-pod, i pod"`?`is equivalent` `# to the explicit mapping:` `ipod, i-pod, i pod => ipod` `# Multiple synonym mapping entries are merged.` `foo => foo bar` `foo => baz` `# is equivalent to` `foo => foo bar, baz` | 您也可以在配置文件中直接給過濾器定義同義詞(請注意使用?**synonyms?**而不是?**synonyms_path?**): | `PUT /test_index` `{` `"settings"``: {` `"index"`?`: {` `"analysis"`?`: {` `"filter"`?`: {` `"synonym"`?`: {` `"type"`?`:?``"synonym_graph"``,` `"synonyms"`?`: [` `"lol, laughing out loud"``,` `"universe, cosmos"` `]` `}` `}` `}` `}` `}` `}` | 但是,建議使用?**synonyms_path?**在文件中定義大型同義詞集,因為內聯指定會不必要地增加群集大小。 #### **WordNet synonyms** 基于 WordNet 格式的 同義詞 可以如下使用格式聲明: | `PUT /test_index` `{` `"settings"``: {` `"index"`?`: {` `"analysis"`?`: {` `"filter"`?`: {` `"synonym"`?`: {` `"type"`?`:?``"synonym_graph"``,` `"format"`?`:?``"wordnet"``,` `"synonyms"`?`: [` `"s(100000001,1,'abstain',v,1,0)."``,` `"s(100000001,2,'refrain',v,1,0)."``,` `"s(100000001,3,'desist',v,1,0)."` `]` `}` `}` `}` `}` `}` `}` | 同時支持使用?**`synonyms_path`??**在文本中定義?**WordNet synonyms**。
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看