RasaHQ/rasa rasa chatbot duckling implementation issue

I’m currently working on rasa chatbot , I can install duckling but can not implement it in for time and date entity so pls help me if any one had already use it. thank you

Hi @IKhushi - I’m afraid I’ll need a bit more information to help you. What have you tried so far? What are the steps you are following, and what is the error you encounter?

I’ve added time entity in my data and train it. after that when I test it with message of time in my API it return empty entity. ########## nlu.md

intent:block_unblock

########### config.py pipeline: supervised_embeddings

-name: ner_duckling_http

when I’ll test the api it will give warning :

rasa.nlu.extractors.crf_entity_extractor - extracted in crf_entity extarctor

the problem is with your config.py - since you provide the value supervised_embeddings, this specifies a whole pipeline. Try removing that so it’s just:

pipeline:
- name: ner_duckling_http
  - url: http://localhost:8000
  - dimensions: ["time", "day"]
  - locale: en_US
  - timezone: Europe/Berlin

and then add back the other pieces you need,

- name: "CountVectorsFeaturizer"
- name: "EmbeddingIntentClassifier"
- name: "ner_duckling_http"
...

I’ve tried

pipeline:

  • name: ner_duckling_http

in config file but gives error :

The config file ‘config.yml’ is missing mandatory parameters: ‘pipeline’. Add missing parameters to config file and try again.

after modification in config file

{ “intent”: { “name”: “block_unblock”, “confidence”: 0.9578648806 }, “entities”: [ { “start”: 0, “end”: 5, “value”: “block”, “entity”: “blockType”, “confidence”: 0.9478110737, “extractor”: “CRFEntityExtractor” }, { “start”: 6, “end”: 14, “value”: “tommorow”, “entity”: “targetTime”, “confidence”: 0.8920832596, “extractor”: “CRFEntityExtractor” }, { “start”: 6, “end”: 14, “text”: “tommorow”, “value”: “2019-08-13T00:00:00.000-07:00”, “confidence”: 1, “additional_info”: { “values”: [ { “value”: “2019-08-13T00:00:00.000-07:00”, “grain”: “day”, “type”: “value” } ], “value”: “2019-08-13T00:00:00.000-07:00”, “grain”: “day”, “type”: “value” }, “entity”: “time”, “extractor”: “DucklingHTTPExtractor” } ], “intent_ranking”: [ { “name”: “block_unblock”, “confidence”: 0.9578648806 } }

but duckling returns entity name as time instead of targetTime of that value from trained data.So, now what should I do to get entity value from duckling?

duckling is a static tool, so it doesn’t look at your training data at all. You can map the time to targetTime using an entity synonym. You'll have to addner_synonyms` to your pipeline as well

1 Like

Alan, thank you so much for your support and guidance.