airyhq / airy

💬 Open Source App Framework to build streaming apps with real-time data - 💎 Build real-time data pipelines and make real-time data universally accessible - 🤖 Join historical and real-time data in the stream to create smarter ML and AI applications. - ⚡ Standardize complex data ingestion and stream data to apps with pre-built connectors
https://airy.co/docs/core
Apache License 2.0
369 stars 44 forks source link

Render Suggested Replies #677

Closed lizhutter closed 3 years ago

lizhutter commented 3 years ago

Summary

The following criteria must be met for each suggested reply to be eligible to be rendered:

Requirements

If a question is received by a system user on Airy Core, it should be possible to view suggested replies. If a system user clicks the suggested reply modal, we should offer the option of one or several reply options. Once the system user selects a suggested reply to send, it should auto-fill the input bar and the system user should be able to send this message.

02 0 Suggested Replies one option@2x 02 1 Suggested Replies one option@2x 02 2 Suggested Replies one option@2x 01 0 Suggested Replies – many options@2x 01 1 0 Suggested Replies – many options@2x 01 1 1 Suggested Replies – many options@2x 01 2 Suggested Replies@2x 01 3 Suggested Replies@2x

We need to be able to render different types of templates regardless of whether they are composed of text, media, or buttons.

03 0 Suggested Replies – Templates@2x 03 1 Suggested Replies – Templates@2x 03 2 Suggested Replies – Templates@2x

We should be able to render templates composed of long messages. We should be able to display a cropped view of these replies and furthermore, system users should be able to send these messages in full.

04 0 Long message crop@2x

It should be possible for system users to be prompted with more than 1 intent. The system user should be able to choose from these replies and send the message.

05 0 Suggested Replies – more than one intent@2x

Design Note

When creating this feature, we should only include the template button within the input bar. Do not include the template button next to the suggested replies.

lucapette commented 3 years ago

As I understand it, @steffh suggested (and we agreed) that the suggested replies are message specific. The UI seems designed in a way that you can suggest replies to a conversation. It's technically not that different for the backend (but still needs to be clarified). It's surely very different in the UI?

lizhutter commented 3 years ago

In order for suggested replies to work: