Yes, I have read that part of the documentation and implemented the image feature into untterances.
Additionally, I investigated in which form the image is transmitted to the client using the /respond endpoint.
The following structure is received by the client:
[
{
"recipient_id": "default",
"text": "some text..."
},
{
"recipient_id": "default",
"text": "Image: https://dictionary.cambridge.org/de/images/full/cat_noun_001_02368.jpg"
}
]
However, I want the second response to use a different tag than ‘Image’.
I would like to be able to set a different tag like ‘Data’ or ‘Url’, such that my client can distinguish regular text messages that should be displayed in chat log from data that need a different formatting.
The workaround I found is setting the tag by myself using an regular utterance with text:
utter_data: - text: "Data: {dataslot}"
However, this is not stored as an attachement in the event history in the tracker as it is for Image tags (since it is only a text utterance).
Using my workaround stores the data as text message:
{'data': None, 'event': 'bot', 'text': 'Data: .. some data', 'timestamp': 1535967934.8861153}
In comparison Image tag is recognized as data and thus it is marked as attachement in the tracker event history:
{'data': {'attachment': 'https://dictionary....02368.jpg'}, 'event': 'bot', 'text': None, 'timestamp': 1535966845.3623219}
To be able to distinguish data slots from regular text messages i want to set different tags than Image when defining utterances, e.g. in the domain.yml
How can this be achieved?