[bug] Tool response token leakage (#17 reopen) #56

Closed
opened 2026-05-14 23:29:42 +02:00 by sleepy · 2 comments
Owner

Issue #17 was about tool response tokens leaking into output. Check if this is still reproducible on current main, especially with MTP enabled (which generates tokens in pairs and may miss multi-token stop sequences).

Acceptance criteria:

  • Tool response tokens never appear in streamed output
  • Works correctly with both standard batching and MTP paths
Issue #17 was about tool response tokens leaking into output. Check if this is still reproducible on current main, especially with MTP enabled (which generates tokens in pairs and may miss multi-token stop sequences). Acceptance criteria: - Tool response tokens never appear in streamed output - Works correctly with both standard batching and MTP paths
Author
Owner

PR #60 (issue #54) fixes the <|im_end|> leak. The structural token leak (user markers) from MTP heads is a separate issue. Needs server-level testing with tool calling to reproduce and fix. The 4B mxfp4 test model is broken (produces token 0). Cannot verify without a working MTP model at smaller size.

PR #60 (issue #54) fixes the <|im_end|> leak. The structural token leak (user markers) from MTP heads is a separate issue. Needs server-level testing with tool calling to reproduce and fix. The 4B mxfp4 test model is broken (produces token 0). Cannot verify without a working MTP model at smaller size.
Author
Owner

Merged via squash (PR #63). Root cause: _mtp_step bypassed _get_output_parser_session(), so Harmony models had no channel-aware token filtering during MTP generation. Fix: route all MTP token emission through parser session with 3 extracted helpers. 81/82 scheduler tests pass (1 pre-existing failure on boundary snapshots).

Merged via squash (PR #63). Root cause: `_mtp_step` bypassed `_get_output_parser_session()`, so Harmony models had no channel-aware token filtering during MTP generation. Fix: route all MTP token emission through parser session with 3 extracted helpers. 81/82 scheduler tests pass (1 pre-existing failure on boundary snapshots).
Sign in to join this conversation.
No labels
bug
feature
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
sleepy/omlx#56
No description provided.