Skip to content

hide-consumed: parseCallText fails on tag-prefixed compress call text, so live anchor args are never stubbed #230

Description

@ranxianglei

Found while investigating billion-context-pi #336 (PR #225, closed).

Bug: rewriteCompressText/parseCallText in src/hide-consumed.ts JSON.parse the compress tool-call text starting at index 0. When the adapter message carries a leading metadata tag (pi appends <acp ...>mNNNNN</acp> tags to message text), the parse fails, the call is treated as unparseable, and live compress anchors keep their full summary args forever — the summary text is duplicated in every request (measured 21.6K tokens of duplicated args in session 01a07b3c).

Fix: locate the JSON by scanning for the first { before parsing (as done in the closed PR #225). Independent of any reasoning feature — worth shipping on its own.

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