Skip to content

[Bug] DeepSeek DSML tool-call markers leak into assistant content and streamlit UI #804

Description

@ZhulongNT

Summary

When using DeepSeek with tool calls, raw DSML markers such as <‖DSML‖tool_calls> and <‖DSML‖invoke ...> are leaking into the assistant content field. Downstream consumers (UI/TUI) then display or speak these internal markers.

Suggested fix

  • Add DSML marker detection before emitting content.
  • Strip / normalize Unicode variants (, , etc.).
  • Keep tool-call data only in structured tool_calls.
  • Add regression tests with streaming chunks split across markers.

Reference

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions