问题描述
根据 README 的示例,当用户输入 what files are here? 时,预期行为是:
- AI 会调用
glob 工具(如 Glob(**/*.py))列出文件
- AI 返回类似 "There's one Python file: nanocode.py" 的结果
实际表现
实际运行时,AI 没有调用任何工具,而是直接返回:
I don't have direct access to your file system to see what files are in your current directory. You can list the files in your current directory by running the command:
ls
If you want to see more details, use:
ls -l
Let me know if you need help with a specific file or further commands!
预期 vs 实际
| 预期(README 示例) |
实际 |
调用 Glob(**/*.py) 工具 |
未调用任何工具 |
| 返回 "There's one Python file: nanocode.py" |
返回 "I don't have direct access..." 并建议用户执行 ls |
环境信息
- 运行方式: 通过 LiteLLM proxy 运行
- LiteLLM 启动命令:
python start_litellm.py --config config.litellm.yaml --port 12051
- 模型:
claude-sonnet-4-5-20250929(通过 config.litellm.yaml 配置的 api.n1n.ai 转发)
- 系统 prompt:
Concise coding assistant. cwd: {工作目录}
- Python 版本: 3.10+
复现步骤
- 使用
config.litellm.yaml 配置 LiteLLM,指向 claude-sonnet-4-5-20250929(如通过 n1n.ai)
- 启动 LiteLLM proxy:
python start_litellm.py --config config.litellm.yaml --port 12051
- 设置
LITELLM_BASE_URL=http://localhost:12051 并运行 python nanocode.py
- 在提示符下输入:
what files are here?
- 观察:模型未调用
glob 工具,而是返回无法访问文件系统的说明
问题描述
根据 README 的示例,当用户输入
what files are here?时,预期行为是:glob工具(如Glob(**/*.py))列出文件实际表现
实际运行时,AI 没有调用任何工具,而是直接返回:
预期 vs 实际
Glob(**/*.py)工具ls环境信息
python start_litellm.py --config config.litellm.yaml --port 12051claude-sonnet-4-5-20250929(通过 config.litellm.yaml 配置的api.n1n.ai转发)Concise coding assistant. cwd: {工作目录}复现步骤
config.litellm.yaml配置 LiteLLM,指向claude-sonnet-4-5-20250929(如通过 n1n.ai)python start_litellm.py --config config.litellm.yaml --port 12051LITELLM_BASE_URL=http://localhost:12051并运行python nanocode.pywhat files are here?glob工具,而是返回无法访问文件系统的说明