The ecosystem design philosophy of DeepSeek Harness (DSH) is “everything is a plugin.” In agent development, it is often necessary to allow the model to directly access backend logs for troubleshooting. Manually integrating an Elasticsearch client can result in a cumbersome configuration process. The following introduces the dsh-client-ui-elasticsearch plugin, which solves this connection and querying problem by adding a settings panel and built-in tools.

Plugin Positioning

dsh-client-ui-elasticsearch is a DeepSeek Harness plugin maintained by SaitoAsuka1121. It mainly does two things: first, it adds an Elasticsearch configuration section to the DSH settings interface; second, it provides the es_query_logs model tool. Its core value lies in encapsulating Elasticsearch connection configuration and log-query capabilities into the DSH runtime environment, allowing Agents to directly query logs using natural language or a Trace ID.

Core Features

  1. Settings Panel Integration
    The plugin adds an Elasticsearch section to DSH settings. Developers can configure the server connection addresses (uris), username, and password there. These settings are stored in DSH’s shared settings document and can be reused across different sessions.

  2. es_query_logs Tool
    The plugin provides a model tool named es_query_logs. This tool supports two query modes:

    • trace_id query: Enter a Trace ID for exact matching.
    • Natural-language query: Enter keywords (such as “connection refused”) to match text fields such as message and exception.
      The tool also supports log filtering and result limiting through the fields, index, and size parameters.
  3. Automatic Guidance
    The plugin includes an automatic guidance system prompt. When a user asks about a trace_id or log content in a conversation, the tool automatically prompts the Agent to use es_query_logs, without requiring additional dedicated Agent presets.

Installation and Enabling

Before installation, ensure that pnpm is available in your system PATH and that the DeepSeek Harness runtime is correctly installed.

Run the following command to install the plugin:

dsh plugin --profile web add @asuka1121/dsh-client-ui-elasticsearch@latest

After installation, restart the deployment. The plugin declares dsh.bundle.patch, so the installation command automatically registers it as a Web-specific Profile Bundle.

Typical Usage

  1. Configure the Connection
    After logging in to DSH, open the settings page and find the Elasticsearch configuration section. Enter uris line by line, then fill in username and password.

  2. Query Logs
    In the conversation, the Agent automatically recognizes log-query intent.

    • Trace ID query: Provide a Trace ID directly, and the Agent performs exact matching.
    • Natural-language query: Describe the issue, such as “Help me check if there has been a NullPointerException recently.”

    The Agent calls the es_query_logs tool and searches using the configured index and size parameters.

Use Cases and Considerations

This plugin is suitable for scenarios that require direct retrieval of Elasticsearch logs within the DSH context, such as development debugging or exception troubleshooting.

Note: The plugin runs with the permissions of the current DSH process. Before installing and using it, developers are advised to review the plugin source code and license (MIT). In addition, the plugin depends on the @deepseek-ai/* runtime dependencies installed with DSH; ensure the environment dependencies are complete.

Summary

dsh-client-ui-elasticsearch simplifies integration between DSH and Elasticsearch by encapsulating configuration items and model tools. It uses an automatic guidance mechanism to lower the barrier to entry, making it suitable for developers who want to improve the efficiency of log troubleshooting.