xiaozhi-esp32-server/main/xiaozhi-server/core/providers/llm
Brad Shannon d46a4f6006 fix(llm/openai): strip <think> tags against the original chunk
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.
2026-06-18 11:01:04 -04:00
..
AliBL feat: 统一LLM错误处理并添加系统错误回复配置 2026-01-25 16:48:01 +08:00
coze update:优化空密钥的提示提示方式 2025-06-12 23:11:42 +08:00
dify feat: 统一LLM错误处理并添加系统错误回复配置 2026-01-25 16:48:01 +08:00
fastgpt feat: 统一LLM错误处理并添加系统错误回复配置 2026-01-25 16:48:01 +08:00
gemini update:给LLM性能测试工具增加系统提示词,更符合本项目的实际效果 2025-08-17 09:35:06 +08:00
homeassistant fix: 修复频繁打断下生成器不会清理 2026-04-22 11:24:43 +08:00
ollama fix: 修复频繁打断下生成器不会清理 2026-04-22 11:24:43 +08:00
openai fix(llm/openai): strip <think> tags against the original chunk 2026-06-18 11:01:04 -04:00
xinference fix: 修复频繁打断下生成器不会清理 2026-04-22 11:24:43 +08:00
base.py feat: 统一LLM错误处理并添加系统错误回复配置 2026-01-25 16:48:01 +08:00
system_prompt.py 修改提示词,增强tool调用约束 2025-04-17 10:00:13 +08:00