I built a watson conversation service and I connected it to Slack using the provided wizard in Bluemix. This is not connected to an application yet (such as Java, etc), it was built using the bluemix dialog tool. My question is: How can I show images or pdf files as a response?
相关问题
- How to disable okhttp3.internal.platform.Platform
- Watson Conversation supports nested Intents?
- How to extract current date in watson conversation
- Watson Conversation: What is lost when restoring a
- Reminder codings in Watson Conversation Service
相关文章
- IBM沃森助手:聊天机器人实体混淆了正则表达式(IBM Watson Assistant: Chat
- 从对话走向对话:如何做 做?(From Dialog to Conversation: how
- IBM Watson Knowledge Studio 2.0 - deploying a rule
- How to print the answer returned by IBM Watson Ass
- Recognize undefined Entities in Watson Conversatio
- IBM Conversation API - What should be a endpoint U
- Api Watson : Conversation, internal error
- Unknown pattern character 'X' Exception oc
You could provide the response as a URL link to the pdf or image. For example you could save your image in a storage place such as google drive and for the response you could provide the link to the image/pdf.
Within the dialog tool itself you will not be able to view any other type of media other than text. The output in the test panel will simply show the output from the node.
When deployed to an application such as a web application the output node would look something like this containing HTML markup:
In this case to display an image you would simply replace the link tag with that of an HTML image etc.
An example starter kit can be found here https://github.com/watson-developer-cloud/conversation-simple
You will need an orchestration layer to handle the encoding to the desired platform format e.g FB messenger requires an object to be passed such as
An example orchestration layer such as Botmaster can be used alongside its extension fulfill that will allow you to creatr these objects and in the Watson dialog simply just add custom XML tags. E.g www.google.com this will then be passed to the orchestration layer which will send the relevant object. A code example using this method can be found here with some other Facebook actions.
Conversation is text only. So you would return the markup, or a context variable. The UI / application layer would then handle the loading and rendering of the PDF.