SuperAPI AI 工具集

call-cursor-agent

智能体与模型

查看项目

更新于 10-15 15:09

技能介绍

用途

该技能用于把一个任务请求转交给 cursor-agent 执行。技能本身以“调用 cursor-agent 完成任务”为目的,不包含额外逻辑说明。

主要能力

  • 检查 cursor-agent 是否已安装。
  • 在已安装的情况下,向 cursor-agent 发起任务请求,并传入任务描述。
  • 支持指定模型;若未指定,则使用默认模型 composer-1。

使用方式

检查 cursor-agent 是否存在

通过 which 命令判断安装情况:退出码 0 表示成功(已安装),1 表示失败(未安装)。如果未安装,则跳过该技能的后续步骤。

which cursor-agent
if [ $? -ne 0 ]; then
  echo "cursor-agent is not installed"
fi

向 cursor-agent 请求任务

如果未指定模型,默认模型为 composer-1。通过 here-doc 将任务描述传给 cursor-agent:

model=composer-1
cursor-agent --model=$model <<EOT
{task_description}
EOT

适用场景

适用于已安装 cursor-agent、且希望把某个任务交给 cursor-agent 处理的环境。

限制

  • 依赖 cursor-agent 已安装;未安装时应跳过后续步骤。
  • 资料未提供该技能的收费、价格、平台支持范围、执行效果等更多信息。