DSH Web Search Usage Audit: Tokens, Models & Cost

Author
DeepSeekAgent.io Editorial Team
Published
Updated

The main conversation model and the Web Search provider in DSH can use separate request paths. Looking only at the model label or token total shown on the Session can miss search-model tokens, a separate API key, and the provider invoice.

An October 2026 community case used DSH 0.2.1-rc.2 with MiniMax as the main model. Because only one search provider was available, DSH selected dsh-web-search-deepseek. The user later reconciled archives and the provider console: 2,717 searches from September 22 to October 21, including 2,470 on October 21, and 28,769,009 deepseek-flash tokens costing ¥68.30. These are records from one workflow, not a standard price for DSH search; they expose an accounting boundary.

Why search usage is separate from the main model

The DeepSeek Web Search provider issues a separate Messages request and, when configured that way, uses DEEPSEEK_API_KEY. A typical flow is:

main model decides to search
  → Web Search provider calls its search model
  → search results return
  → main model reads results and continues

There are at least two usage events: the search model processes the query and results, while the main model processes the tool result and answer. They may use different vendors, or use DeepSeek for both while remaining distinct requests.

Why Session usage may be incomplete

The community report says Session events retained the search request without its usage record. The main-model token display therefore could not reconstruct the total cost. An audit needs four sources:

SourceQuestion answered
Session trajectoryWho triggered search and when
Web Search configurationProvider, model, and key source
Provider consoleRequest count, tokens, price, and peaks
Task artifactsWhether searches produced useful evidence

The provider total is also insufficient by itself because it rarely explains which Session, schedule, or Subagent caused the peak.

Set a search budget

Cap searches per task

Replace “search until satisfied” with a concrete limit, such as three query rounds with five results each. When more coverage is needed, the Agent should identify the missing evidence before the user approves continuation.

Separate discovery from reading

Use Search to find candidate URLs and Fetch to read a small selected set. Rephrasing nearly identical queries or repeatedly fetching the same result set compounds cost without adding equivalent evidence.

Separate keys for automation

Where the provider supports it, assign different keys or projects to interactive Sessions, schedules, and batch research. Each source can receive its own limit, and an abnormal workflow can be stopped without disabling all search.

Retain correlatable usage records

An ideal event contains Session ID, parent task, Subagent, query summary, provider, model, request ID, input/output tokens, and pricing version. If the provider omits usage, record that it is missing rather than treating it as zero.

Investigating a usage spike

  1. pause schedules and recursive tasks so the spike stops growing;
  2. inspect provider requests and tokens by hour;
  3. align Web Search events with Session and Subagent creation times;
  4. check whether a single available provider caused automatic selection;
  5. find duplicate queries, failed retries, validation loops, and repeated searches across children;
  6. restore one task behind hard limits and observe it before reopening the rest.

For API configuration, query operators, and limits, use the DeepSeek Search and Fetch API guide. If concurrent children amplify the bill, continue with the DSH Subagent token billing audit.

References