
Host File Editing
Guide safe use of text_editor_remote for reading, writing, and patching files on the...
Install
npx skills add agent0ai/agent-zero --skill host-file-editing -g -a claude-code -y- Repository
- agent0ai/agent-zero19.6k
- Category
- DevOps
- Updated
- 3d ago
- License
- See repository
- Context cost
- Lightabout 646 tokens
- Runs scripts
- No, instructions only
What it does
Guide safe use of text_editor_remote for reading, writing, and patching files on the connected A0 CLI host. Use when the user asks to inspect or edit files on their computer, local files, CLI host files, or files that are explicitly not Docker/server files.
Host File Editing
Boundary
Use text_editor_remote only for file work on the machine where A0 CLI is running. These paths and files belong to the CLI host, not the Agent Zero server or Docker container.
If the task belongs inside Agent Zero's own runtime, use the normal server-side file tools instead.
Access Modes
- Read&Write: reads, writes, and patches may modify the CLI host. Keep changes narrow and intentional.
- Read only: inspect files only. If writes are blocked, tell the user to switch local file access to Read&Write with F3.
Editing Flow
- Start with
readwhen inspecting a file or preparing line-based edits. - Use
writeonly when replacing or creating the whole file is truly the right operation. - Prefer
patchwithold_textandnew_textfor simple exact replacements. - Use
patch_textfor context-anchored edits, especially after inserts/deletes or when line numbers may have shifted. - Use
patchwitheditsonly for small line-range edits based on the latest remote read. - If freshness-aware line patching rejects an edit as stale, reread the file and retry with updated ranges.
- Treat reads as bounded text previews (2,000 lines / 256 KiB). Follow
next_linefor another small slice; use the authenticated HTTP transfer path for complete large files and binary data. - Keep each write or patch payload within 256 KiB. Do not split a binary file into text-editor calls.

