From fc4080c58a4deef04e49d5ead4ccffc5d7170a68 Mon Sep 17 00:00:00 2001 From: teknium1 Date: Mon, 16 Mar 2026 07:34:29 -0700 Subject: [PATCH] fix(cli): add to streaming tag suppression list Anthropic native models emit tags in text content (separate from the SDK's thinking_delta events). Without suppression, these tags leak into the streamed CLI output. Found during live provider testing. --- cli.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cli.py b/cli.py index b7203e9063..2aa181797a 100755 --- a/cli.py +++ b/cli.py @@ -1431,8 +1431,8 @@ class HermesCLI: # These tags are model-generated (system prompt tells the model # to use them) and get stripped from final_response. We must # suppress them during streaming too. - _OPEN_TAGS = ("", "", "") - _CLOSE_TAGS = ("", "", "") + _OPEN_TAGS = ("", "", "", "") + _CLOSE_TAGS = ("", "", "", "") # Append to a pre-filter buffer first self._stream_prefilt = getattr(self, "_stream_prefilt", "") + text