Skip to content

[Bug]AstrBot4.10.2-Deepseek3.2无法正常使用函数工具 #4207

@RC7rabbit

Description

@RC7rabbit

What happened / 发生了什么

在用到使用函数工具的地方,会直接输出<function_calls>


</function_calls>

Image Image

Reproduce / 如何复现?

调用任意插件的工具使用就会出现

AstrBot version, deployment method (e.g., Windows Docker Desktop deployment), provider used, and messaging platform used. / AstrBot 版本、部署方式(如 Windows Docker Desktop 部署)、使用的提供商、使用的消息平台适配器

4.10.2,阿里云linux直接部署,供应商Deepseek,QQ

OS

Windows

Logs / 报错日志

日志里并没有报错

Image

[调皮指令官/16:55:44]: [At: copyrabbit] 群里有多少人, conversation_id=4334c2f4-7cb4-4c08-b47d-c634b53c5f11,
[16:55:44] [Core] [DBUG] [runners.base:64]: Agent state transition: AgentState.IDLE -> AgentState.RUNNING
[16:55:53] [Core] [DBUG] [sources.openai_source:152]: completion: ChatCompletion(id='73e892e58bbe433eb18e421ab16a97d0', choices=[Choice(finish_reason='stop', index=0, logprobs=None, message=ChatCompletionMessage(content='\n\n<function_calls>\n\n\n\n</function_calls>', refusal=None, role='assistant', annotations=None, audio=None, function_call=None, tool_calls=None, reasoning_content=None), matched_stop=1)], created=1766739353, model='deepseek-ai/deepseek-v3.2', object='chat.completion', service_tier=None, system_fingerprint=None, usage=CompletionUsage(completion_tokens=31, prompt_tokens=10901, total_tokens=10932, completion_tokens_details=None, prompt_tokens_details=None, reasoning_tokens=0), metadata={'weight_version': 'default'})
[16:55:53] [Core] [DBUG] [runners.base:64]: Agent state transition: AgentState.RUNNING -> AgentState.DONE
[16:55:53] [Core] [DBUG] [pipeline.context_utils:95]: hook(OnLLMResponseEvent) -> astrbot - inject_reasoning
[16:55:53] [Plug] [DBUG] [astrbot.long_term_memory:180]: Recorded AI response: rcrabbit:GroupMessage:1017902891 | [You/16:55:53]: <function_calls>

[16:55:53] [Core] [DBUG] [result_decorate.stage:162]: hook(on_decorating_result) -> astrbot_plugin_wakepro - on_message [16:55:53] [Core] [DBUG] [result_decorate.stage:162]: hook(on_decorating_result) -> astrbot_plugin_outputpro - on_decorating_result [16:55:53] [Core] [INFO] [respond.stage:168]: Prepare to send - 调皮指令官/2998226719: [16:55:56] [Core] [DBUG] [pipeline.context_utils:95]: hook(OnAfterMessageSentEvent) -> astrbot - after_message_sent [16:55:56] [Core] [DBUG] [pipeline.scheduler:88]: pipeline 执行完毕。 [16:56:27] [Core] [DBUG] [aiocqhttp.aiocqhttp_platform_adapter:112]: [aiocqhttp] RawMessage

Are you willing to submit a PR? / 你愿意提交 PR 吗?

  • Yes!

Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:providerThe bug / feature is about AI Provider, Models, LLM Agent, LLM Agent Runner.bugSomething isn't workingfeature:pluginThe bug / feature is about AstrBot plugin system.plugin-cate:toolingIntegrate external tools, services, APIs, or systems into the bot.(only startswith [Plugin])priority: p0will fix asap

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions