【问题标题】:Sinhala entity classifications僧伽罗实体分类
【发布时间】:2020-07-11 19:33:43
【问题描述】:

用户警告:消息“කමල්”中的实体注释未对齐,意图为“用户名”。确保训练数据中实体的开始和结束值与标记边界匹配(例如,实体不包含尾随空格或标点符号)。确保训练数据中实体的开始和结束值与标记边界匹配(例如,实体不要包含尾随空格或标点符号)。

我正在使用僧伽罗语,并且我正在使用 rasa 开源。

这是我的 nlu 部分

{

"text": "කමල්",

"intent": "username",

"entities": [

  {

    "start": 1,

    "end": 8,

    "value": "කමල්",

    "entity": "uname"

  }

]

},

Config.yml

# Configuration for Rasa NLU.
# https://rasa.com/docs/rasa/nlu/components/
language: en
pipeline:
  - name: WhitespaceTokenizer
  - name: RegexFeaturizer
  - name: LexicalSyntacticFeaturizer
  - name: CountVectorsFeaturizer
  - name: CountVectorsFeaturizer
    analyzer: "char_wb"
    min_ngram: 1
    max_ngram: 4
  - name: DIETClassifier
    epochs: 100
  - name: EntitySynonymMapper
  - name: ResponseSelector
    epochs: 100

    
# Configuration for Rasa Core.
# https://rasa.com/docs/rasa/core/policies/
policies:
  - name: MemoizationPolicy
  - name: TEDPolicy
    max_history: 5
    epochs: 100
  - name: MappingPolicy

【问题讨论】:

  • 你可以在这里添加你的config.yml 文件吗?可能是分词器在这里遇到了一些麻烦。
  • 好的,我更新我的问题。

标签: rasa-nlu rasa-core rasa


【解决方案1】:

您正在使用WhitespaceTokenizer,如果字符之间有空格,它将将文本拆分为标记。您提供的文本(抱歉,我不认识该语言)似乎没有使用空格拆分标记。这就是为什么整个文本被视为单个标记的原因。

看来您可能需要为您的语言寻找另一个标记器。我不知道哪个标记器可能适用。随时参与讨论here

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2011-10-03
    • 2013-07-08
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2015-07-18
    • 2016-03-03
    相关资源
    最近更新 更多