routeCall Chain Usage Guide

Feature Introduction

The call chain (also known as a “trace”) gives users insight into conversations, helping them understand the specific performance of the model, knowledge base, MCP, web search, and more during the conversation process. It is a OpenTelemetryarrow-up-right implemented observability tool that achieves visualization through end-side data collection, storage, and processing, providing quantitative evaluation basis for problem diagnosis and effect optimization.

Each conversation corresponds to one trace record. A trace consists of multiple spans, and each span corresponds to one program processing logic in Cherry Studio, such as model session calls, MCP calls, knowledge base calls, and web search calls. Traces are displayed in a tree structure, with spans as tree nodes. The main data includes duration and token usage. Of course, in the span details, you can also view its specific input and output.

Enable Trace

By default, after Cherry Studio is installed, Trace is hidden. You need to enable it in "Settings" - "General Settings" - "Developer Mode", as shown below:

And no Trace records will be generated for previous conversations; Trace records will only be generated after new questions and answers occur. The generated records are stored locally. If you need to completely clear Trace, you can do so via "Settings" - "Data Settings" - "Data Directory" - "Clear Cache", or by manually deleting the files under ~/.cherrystudio/trace, as shown below:

Scenario Introduction

View the full chain

In the Cherry Studio dialog, click Call Chain to view the full-chain data of the call chain. Whether a model, web search, knowledge base, or MCP is called during the conversation, you can view the full-chain call data in the call chain window.

View the model in the chain

If you want to view the details of the model in the call chain, you can click the model call node to view its input and output details.

View web search in the chain

If you want to view the details of web search in the call chain, you can click the web search call node to view its input and output details. In the details, you can see the question used to call web search and the results it returned.

View the knowledge base in the chain

If you want to view the details of the knowledge base in the call chain, you can click the knowledge base call node to view its input and output details. In the details, you can see the question used to query the knowledge base and the answer it returned.

View MCP calls in the chain

If you want to view the details of MCP in the call chain, you can click the MCP call node to view its input and output details. In the details, you can see the input parameters of the called MCP Server tool and the tool's return value.

Questions and suggestions

The current feature is provided by Alibaba Cloud EDASarrow-up-right team. If you have any questions or suggestions, please join the DingTalk group (group number: 21958624) to have in-depth communication with the developers.

\

Last updated

Was this helpful?