[英]how to match concept values in chatscript
If i use a ~concept, how would I know what the user typed?如果我使用 ~concept,我怎么知道用户输入了什么? this is like an entity in typical NLP frameworks.
这就像典型的 NLP 框架中的实体。 eg
例如
u: (I am from ~country )
^keep() ^repeat()
you come from _0?
If the user types I am from FRANCE
there seems no way to extract the value FRANCE
for ~country
to echo back to the user or to use it later with perhaps $country=_0
如果用户
I am from FRANCE
,似乎无法提取FRANCE
的值~country
以回显给用户或稍后使用$country=_0
I thought the _0
might help with that, but no workie我认为
_0
可能会对此有所帮助,但没有工作
This will work but doesn't use concepts just wildcards这将起作用,但不使用通配符的概念
u: (I was born [in near close by] _* )
^keep() ^repeat()
you were born in _0?
ref docs https://github.com/ChatScript/ChatScript/blob/master/WIKI/OVERVIEWS-AND-TUTORIALS/ChatScript-Tutorial.md#short-term-memory--_参考文档https://github.com/ChatScript/ChatScript/blob/master/WIKI/OVERVIEWS-AND-TUTORIALS/ChatScript-Tutorial.md#short-term-memory--_
seems _
before the ~concept
will allow capturing:似乎
_
在~concept
之前将允许捕获:
u: (I am from _~country )
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.