Agented
A stateful text editor designed for LLMs
Install & Use
Copy this prompt and send it to your AI assistant (Claude / Cursor / TRAE / Codex / WorkBuddy etc.) to auto-install:
Help me install this AI Skill: Agented. It is used for: A stateful text editor designed for LLMs Full Skill content: https://321skill.com/skills/agented-x-2/raw/index.md Read that page and install it.
The prompt includes a link to the full Skill content. You can also view the full content.
This Skill addresses the lack of state persistence, version history, and concurrency control when AI agents edit code or text. In real-world development, AI agents need to edit multiple files across multiple invocations, but standard tools like cat/grep/sed cannot retain context, leading to redundant work and risk of conflicts. Agented stores state in an SQLite workspace, with every edit recorded in an undo tree that supports branch navigation, ensuring no modification is lost.
Usage is simple: just open a file via ae open <path>. It returns a state_token, which must be included in all subsequent write operations (e.g., ae s for replace, ae i for insert). If the file is modified by another agent, the write operation is rejected (exit code 3) and returns the new content and token—simply retry. Supports multi-line content via pipe input, e.g., cat patch.txt | ae s foo.go -r 12:14 -i. Commands use short forms by default to save tokens, such as ae s foo.go -r 12:14 -w "..." -x ab12cd34.
It is ideal for AI agents and agent development teams that require safe, multi-step file editing, especially in scenarios involving frequent refactoring of legacy code, root cause debugging, or synchronizing project context. If you use tools like Claude or Cursor for complex coding tasks and want to preserve a complete edit history, Agented significantly reduces the manual overhead of version management.
We recommend using this tool consistently when you need edit history to persist across sessions. Note: it primarily targets text files and does not support binary files; it depends on the ae binary, installable via Homebrew (brew tap frane/tap && brew install agented); for simple one-off edits, using the platform's built-in editor is more efficient.
Key Features
Unlike sed or platform-native editors, Agented is a stateful editor that uses a state_token for concurrent conflict detection, supports undo tree branching, and provides cross-session persistence—capabilities ordinary editors lack for maintaining context across multiple invocations.
Limitations
Requires installation of the ae binary (via Homebrew), does not support binary files, relies on SQLite for state storage, and uses .agented/ as the workspace directory.
FAQ
How do I install Agented?
Run brew tap frane/tap && brew install agented, after which the ae command will be available.
What is the purpose of the state_token?
The state_token identifies the file version. Including it in write operations ensures the operation is rejected if the file has been modified by another agent, preventing conflicts.
Installation guide for AI assistants
If your AI coding assistant (Claude Code, Cursor, TRAE etc.) can see this page, send it this message to auto-install:
Visit https://321skill.com/skills/agented-x-2/raw/index.md to read the original Skill definition (Markdown format) for Agented, and install it according to the instructions.
Raw Markdown URL for AI: /skills/agented-x-2/raw/index.md