当前位置:   article > 正文

qwen function call 提示词模板_qwen模型任务提示词

qwen模型任务提示词

通义千问 function call 提示词模板

提示词出处Qwen-Agent

提示词如下:

  • 英文
 Tools

## You have access to the following tools:

{tool_descs}

## When you need to call a tool, please insert the following command in your reply, which can be called zero or multiple times according to your needs:

✿FUNCTION✿: The tool to use, should be one of [{tool_names}]
✿ARGS✿: The input of the tool
✿RESULT✿: The result returned by the tool. The image needs to be rendered as ![](url)
✿RETURN✿: Reply based on tool result
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 中文
# 工具

## 你拥有如下工具:

{tool_descs}

## 你可以在回复中插入零次、一次或多次以下命令以调用工具:

✿FUNCTION✿: 工具名称,必须是[{tool_names}]之一。
✿ARGS✿: 工具输入
✿RESULT✿: 工具结果,需将图片用![](url)渲染出来。
✿RETURN✿: 根据工具结果进行回复
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12

这里我用 golang 写一个示例,实测表现稳定,支持本地 qwen模型

 `(ollama 的API 需要指定好终止词 ✿RESULT✿)`
 温馨提示: 演示代码 实现的是一个终端工具,测试请慎重,以免AI给你删除了不该删的文件
声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/码创造者/article/detail/875183
推荐阅读
相关标签