mirror of
https://github.com/hansjone/oclaw.git
synced 2026-10-11 04:10:44 +08:00
将文件/命令/Git/检索能力统一迁入 public,去除重复工具与 local_ 命名前缀,并重命名底层路径守卫模块为 path_guard 以提升语义清晰度。 Made-with: Cursor
41 lines
976 B
Markdown
41 lines
976 B
Markdown
# Local Public Tools
|
|
|
|
This project exposes local atomic capabilities as shared `public` tools for all agents.
|
|
|
|
## Included P0 tools
|
|
|
|
- `run_command`
|
|
- `read_file`
|
|
- `write_file`
|
|
- `edit_file`
|
|
|
|
## Included P1/P2/P3 tools
|
|
|
|
- `list_directory`
|
|
- `move_file`
|
|
- `delete_file`
|
|
- `mkdir`
|
|
- `search_files`
|
|
- `get_cwd`
|
|
- `cd`
|
|
- `get_env`
|
|
- `set_env`
|
|
- `list_processes`
|
|
- `kill_process`
|
|
|
|
## Loading path
|
|
|
|
- Files live under `runtime/tools/public/`.
|
|
- They are auto-discovered by `runtime/tools/public_registry.py` (`*_tool` factory naming).
|
|
- Final exposure is controlled in `runtime/tools/catalog.py`.
|
|
|
|
## Risk gating
|
|
|
|
- `read_file` is `risk_level=low` and visible by default.
|
|
- `run_command`, `write_file`, `edit_file` are `risk_level=high`.
|
|
- High-risk public tools are hidden unless `AIA_PUBLIC_TOOLS_ALLOW_HIGH=1`.
|
|
|
|
## Local backend adapter
|
|
|
|
- Adapter path: `runtime/tools/local_sdk/adapter.py`.
|
|
- Uses a self-implemented local backend (cross-platform) with a stable tool contract.
|