mirror of
https://github.com/xinnan-tech/xiaozhi-esp32-server.git
synced 2026-11-28 04:59:52 +01:00
Reasoning models often emit both <think> and </think> in a single streamed chunk. The previous code truncated `content` at <think> first, then tested the already-truncated string for </think>. The closing tag was gone, so `is_active` was never restored to True and the entire post-</think> answer was dropped — the user received silence. Snapshot the chunk as `original_content` and test both tags against the snapshot so the closing tag is still detectable after truncation. |
||
|---|---|---|
| .. | ||
| config | ||
| core | ||
| models | ||
| music | ||
| performance_tester | ||
| plugins_func | ||
| agent-base-prompt.txt | ||
| app.py | ||
| config.yaml | ||
| config_from_api.yaml | ||
| docker-compose.yml | ||
| docker-compose_all.yml | ||
| mcp_server_settings.json | ||
| performance_tester.py | ||
| requirements.txt | ||