diff --git a/_config.yml b/_config.yml index 8614b723..2762f6fe 100644 --- a/_config.yml +++ b/_config.yml @@ -115,6 +115,9 @@ collections: automating-workflows: permalink: /:collection/:path/ output: true + dashboards-assistant: + permalink: /:collection/:path/ + output: true opensearch_collection: # Define the collections used in the theme @@ -169,6 +172,9 @@ opensearch_collection: ml-commons-plugin: name: Machine learning nav_fold: true + dashboards-assistant: + name: Dashboards assistant + nav_fold: true automating-workflows: name: Automating workflows nav_fold: true diff --git a/_dashboards/dashboards-assistant/index.md b/_dashboards/dashboards-assistant/index.md new file mode 100644 index 00000000..ff835ee8 --- /dev/null +++ b/_dashboards/dashboards-assistant/index.md @@ -0,0 +1,127 @@ +--- +layout: default +title: OpenSearch Assistant for OpenSearch Dashboards +nav_order: 3 +has_children: false +has_toc: false +--- + +This is an experimental feature and is not recommended for use in a production environment. For updates on the feature's progress or to leave feedback, go to the [`dashboards-assistant` repository](https://github.com/opensearch-project/dashboards-assistant) on GitHub or the associated [OpenSearch forum thread](https://forum.opensearch.org/t/feedback-opensearch-assistant/16741). +{: .warning} + +For more information about ways to enable experimental features, see [Experimental feature flags]({{site.url}}{{site.baseurl}}/install-and-configure/configuring-opensearch/experimental/). +{: .note} + +# OpenSearch Assistant for OpenSearch Dashboards +Introduced 2.12 +{: .label .label-purple } + +The OpenSearch Assistant toolkit helps you create AI-powered assistants for OpenSearch Dashboards without requiring you to have specialized query tools or skills. + +## Enabling OpenSearch Assistant + +To enable **OpenSearch Assistant** in OpenSearch Dashboards, locate your copy of the `opensearch_dashboards.yml` file and set the following option: + +``` +assistant.chat.enabled: true +``` +{% include copy-curl.html %} + +Then configure the root `agent_id` through the following API: + +``` +PUT .plugins-ml-config/_doc/os_chat +{ + "type":"os_chat_root_agent", + "configuration":{ + "agent_id": "your root agent id" + } +} +``` +{% include copy-curl.html %} + +This example shows a system index. In security-enabled domains, only super admins have permission to execute this code. For information about making super admin calls, see the [System indexes]({{site.url}}{{site.baseurl}}/security/configuration/system-indices/) guide. For access permission, contact your IT administrator. +{: .warning} + +Next, restart the OpenSearch Dashboards server. Following a successful restart, **OpenSearch Assistant** appears in the OpenSearch Dashboards interface. + +A screenshot of the interface is shown in the following image. + +OpenSearch Assistant interface + +## Configuring OpenSearch Assistant + +You can use the OpenSearch Dashboards interface to configure OpenSearch Assistant. Go to the [Getting started guide](https://github.com/opensearch-project/dashboards-assistant/blob/main/GETTING_STARTED_GUIDE.md) for step-by-step instructions. For the chatbot template, go to the [Flow Framework plugin](https://github.com/opensearch-project/flow-framework) documentation. You can modify this template to use your own model and customize the chatbot tools. + +For information about configuring OpenSearch Assistant through the REST API, see OpenSearch Assistant toolkit. + +## Using OpenSearch Assistant in OpenSearch Dashboards + +The following tutorials guide you through using OpenSearch Assistant in OpenSearch Dashboards. OpenSearch Assistant can be viewed full frame or in the right sidebar. The default is sidebar. To view full frame, select the frame icon {::nomarkdown}frame icon{:/} in the toolbar. + +### Start a conversation + +Start a conversation by entering a prompt in the **Ask a question** search box or by using the shortcut `ctrl + /`. Select **Go** to initiate the conversation. A response is generated. + +The following screenshot shows an example prompt and response. + +Prompt and response using OpenSearch Assistant in OpenSearch Dashboards + +### Regenerate a response + +Beneath the response, select the regenerate icon to generate an alternative answer to your original question. The new answer will replace the previous one, appearing in both the interface and the chat history. A regenerated example is shown in the following image. + +Regenerated response + +### Suggested prompts + +OpenSearch Assistant suggests prompts to help you get started, build upon your existing prompts, or explore other queries you may not have considered, among other reasons. Select a suggested prompt listed beneath the response field. A screenshot is shown in the following image. + +Suggested prompts + +### Rate a response + +To rate a response, select the thumbs up or thumbs down icon. A screenshot of the interface is shown in the following image. The feedback is stored in the `additional_info` field of the message index. + +### Response generation + +Learn how a response is generated by selecting the **How was this generated?** option. This option is included within the available suggestions to help you understand which tools were involved in creating the response. If multiple tools were involved, each step will display the tool name and its input and output. This feature can be useful for troubleshooting. A screenshot is shown in the following image. + +Response generation details + +### Resume previous conversations + +To view a previous conversation, select the clock icon to open the conversation history panel and display the chat history. The conversation history can also be searched by conversation name. A screenshot is shown in the following image. + +Conversation history + +#### Edit and delete previous conversations + +Select the pencil icon to edit a conversation name and rename it. Select the **Confirm name** button to save the new name. A screenshot is shown in the following image. + +Editing a conversation name + +Select the trash can icon to delete a conversation. Once the confirmation dialog appears, select **Delete conversation**. The conversation is now deleted from your chat history. A screenshot is shown in the following image. + +Deleting a conversation + +### Share a conversation through Notebooks + +You can use [Notebooks]({{site.url}}{{site.baseurl}}/observing-your-data/notebooks/) to save your conversations. To use this option, select **Save to notebook** from the dropdown menu to the right of **OpenSearch Assistant**. Enter a name for the notebook, then select **Save**. A pop-up message in the lower-right corner confirms the conversation has been saved. + +All conversations (prompts and responses/questions and answers) between you and the large language model (LLM) will be saved to this notebook. + +To open the saved notebook or view a list of other notebooks, select **Observability** > **Notebooks** from the OpenSeach Dashboards navigation menu. + +A screenshot of the Notebooks interface with a list of saved conversations is shown in the following image. + +Notebooks interface with saved OpenSearch Assistant conversations + +The following screenshot shows a saved conversation, along with actions you can take for the saved conversation. + +Notebooks interface with saved OpenSearch Assistant conversations + +## Related articles + +- [Getting started guide for OpenSearch Assistant in OpenSearch Dashboards](https://github.com/opensearch-project/dashboards-assistant/blob/main/GETTING_STARTED_GUIDE.md) +- OpenSearch Assistant configuration through the REST API diff --git a/images/dashboards-assistant/conversation-history-entry.png b/images/dashboards-assistant/conversation-history-entry.png new file mode 100644 index 00000000..2ac35ce0 Binary files /dev/null and b/images/dashboards-assistant/conversation-history-entry.png differ diff --git a/images/dashboards-assistant/conversation-history-list.png b/images/dashboards-assistant/conversation-history-list.png new file mode 100644 index 00000000..e1208975 Binary files /dev/null and b/images/dashboards-assistant/conversation-history-list.png differ diff --git a/images/dashboards-assistant/conversation-in-notebook.png b/images/dashboards-assistant/conversation-in-notebook.png new file mode 100644 index 00000000..2ee9a701 Binary files /dev/null and b/images/dashboards-assistant/conversation-in-notebook.png differ diff --git a/images/dashboards-assistant/delete-conversation.png b/images/dashboards-assistant/delete-conversation.png new file mode 100644 index 00000000..b5ac7cfd Binary files /dev/null and b/images/dashboards-assistant/delete-conversation.png differ diff --git a/images/dashboards-assistant/edit-conversation-title.png b/images/dashboards-assistant/edit-conversation-title.png new file mode 100644 index 00000000..0f35babc Binary files /dev/null and b/images/dashboards-assistant/edit-conversation-title.png differ diff --git a/images/dashboards-assistant/entry.png b/images/dashboards-assistant/entry.png new file mode 100644 index 00000000..b645389f Binary files /dev/null and b/images/dashboards-assistant/entry.png differ diff --git a/images/dashboards-assistant/rate.png b/images/dashboards-assistant/rate.png new file mode 100644 index 00000000..efc741c7 Binary files /dev/null and b/images/dashboards-assistant/rate.png differ diff --git a/images/dashboards-assistant/response.png b/images/dashboards-assistant/response.png new file mode 100644 index 00000000..3bb920e6 Binary files /dev/null and b/images/dashboards-assistant/response.png differ diff --git a/images/dashboards-assistant/save-conversation-to-notebook.png b/images/dashboards-assistant/save-conversation-to-notebook.png new file mode 100644 index 00000000..a02f0070 Binary files /dev/null and b/images/dashboards-assistant/save-conversation-to-notebook.png differ diff --git a/images/dashboards-assistant/start-conversation.png b/images/dashboards-assistant/start-conversation.png new file mode 100644 index 00000000..f61ac663 Binary files /dev/null and b/images/dashboards-assistant/start-conversation.png differ diff --git a/images/dashboards-assistant/suggestions.png b/images/dashboards-assistant/suggestions.png new file mode 100644 index 00000000..a7cb0ea6 Binary files /dev/null and b/images/dashboards-assistant/suggestions.png differ diff --git a/images/dashboards-assistant/traces.png b/images/dashboards-assistant/traces.png new file mode 100644 index 00000000..ee5ad8c6 Binary files /dev/null and b/images/dashboards-assistant/traces.png differ diff --git a/images/dashboards/opensearch-assistant-QandA.png b/images/dashboards/opensearch-assistant-QandA.png new file mode 100644 index 00000000..e35e097a Binary files /dev/null and b/images/dashboards/opensearch-assistant-QandA.png differ diff --git a/images/dashboards/opensearch-assistant-conversation-history.png b/images/dashboards/opensearch-assistant-conversation-history.png new file mode 100644 index 00000000..8b4eb96b Binary files /dev/null and b/images/dashboards/opensearch-assistant-conversation-history.png differ diff --git a/images/dashboards/opensearch-assistant-delete-convo.png b/images/dashboards/opensearch-assistant-delete-convo.png new file mode 100644 index 00000000..c0d90833 Binary files /dev/null and b/images/dashboards/opensearch-assistant-delete-convo.png differ diff --git a/images/dashboards/opensearch-assistant-edit-convo.png b/images/dashboards/opensearch-assistant-edit-convo.png new file mode 100644 index 00000000..bd57487b Binary files /dev/null and b/images/dashboards/opensearch-assistant-edit-convo.png differ diff --git a/images/dashboards/opensearch-assistant-full-frame.png b/images/dashboards/opensearch-assistant-full-frame.png new file mode 100644 index 00000000..b98a2331 Binary files /dev/null and b/images/dashboards/opensearch-assistant-full-frame.png differ diff --git a/images/dashboards/opensearch-assistant-how-generated.png b/images/dashboards/opensearch-assistant-how-generated.png new file mode 100644 index 00000000..33a9b673 Binary files /dev/null and b/images/dashboards/opensearch-assistant-how-generated.png differ diff --git a/images/dashboards/opensearch-assistant-notebooks.png b/images/dashboards/opensearch-assistant-notebooks.png new file mode 100644 index 00000000..74283c13 Binary files /dev/null and b/images/dashboards/opensearch-assistant-notebooks.png differ diff --git a/images/dashboards/opensearch-assistant-regenerate.png b/images/dashboards/opensearch-assistant-regenerate.png new file mode 100644 index 00000000..d547ac18 Binary files /dev/null and b/images/dashboards/opensearch-assistant-regenerate.png differ diff --git a/images/dashboards/opensearch-assistant-save-notebook.png b/images/dashboards/opensearch-assistant-save-notebook.png new file mode 100644 index 00000000..ed0cbff2 Binary files /dev/null and b/images/dashboards/opensearch-assistant-save-notebook.png differ diff --git a/images/dashboards/opensearch-assistant-suggestions.png b/images/dashboards/opensearch-assistant-suggestions.png new file mode 100644 index 00000000..3a819242 Binary files /dev/null and b/images/dashboards/opensearch-assistant-suggestions.png differ diff --git a/images/icons/frame-icon.png b/images/icons/frame-icon.png new file mode 100644 index 00000000..994c67d3 Binary files /dev/null and b/images/icons/frame-icon.png differ