Agent 24
An autonomous AI coding & technical assistant for Android — a terminal-based agent that reads, writes, edits and runs code, browses the web, and completes multi-step tasks on its own.
Agents
Build, plan, explore, scout and system agents — each with its own permission profile.
Tools
31 tools: shell, files, search, web, git, documents, vision, device sensors and more.
Permissions
Allow / ask / deny gates on every tool, per agent — full control over what runs.
Providers
13 pre-configured model providers with auto-fallback and retry logic.
Quick start
- Connect a provider —
/connect - Pick a model —
/model - Start a task: just type what you want built.
Getting Started
Three minutes from install to your first completed task.
1. Install & open
Install Agent 24, open it, and grant the accessibility permission when prompted (required for screen understanding and UI dumping).
2. Connect a provider
Run /connect and pick from 13 pre-configured providers — OpenCode Zen, Pollinations (free), OpenAI, Anthropic, Google, Groq, DeepSeek, Mistral, xAI, Together, OpenRouter, HuggingFace, GitHub Models. Free options work with zero setup.
3. Choose a model
/model lists every model of the connected provider with capability flags: supportsTools, supportsImages, supportsReasoning, supportsStreaming.
4. Start working
Just type the task in natural language:
> build a calculator app with history > find every TODO in src/ and summarize > refactor utils.js and run the tests
Keyboard
| Key | Action |
|---|---|
/ | Focus search / command palette |
Ctrl/Cmd + K | Command palette |
Esc | Close overlay / cancel |
Agents
Primary/sub agents you select, plus system agents that trigger automatically.
| Agent | Mode | Permissions | Description |
|---|---|---|---|
| build | primary | *: allow | Default agent, full access |
| plan | primary | edit: ask, bash: ask | Read-only analysis |
| general | subagent | *: allow | General multi-step tasks |
| explore | subagent | read-only set | Fast codebase exploration |
| scout | subagent | read/web only | External docs & research |
System agents
| Agent | Trigger | Purpose |
|---|---|---|
| compaction | Tokens > 80% | Context summarization |
| title | First message | Session title (3–5 words) |
| summary | Session switch | Conversation summary |
Permission matrix
| Tool | build | plan | general | explore | scout |
|---|---|---|---|---|---|
| read | allow | allow | allow | allow | allow |
| edit / write | allow | ask | allow | deny | deny |
| bash | allow | ask | allow | allow | allow |
| grep / glob / list | allow | allow | allow | allow | allow |
| webfetch / websearch | allow | allow | allow | allow | allow |
| todowrite | allow | allow | deny | deny | deny |
| task / question | allow | allow | allow | deny | deny |
allow = run silently · ask = confirm popup · deny = blocked
Tools
31 built-in tools. Every tool takes a JSON parameter map.
| # | Tool | Class | Description |
|---|---|---|---|
| 1 | bash | BashTool | Execute shell commands |
| 2 | shell | ShellTool | Persistent shell sessions |
| 3 | read | ReadTool | Read file contents |
| 4 | write | WriteTool | Create / overwrite files |
| 5 | edit | EditTool | Find & replace edits |
| 6 | grep | GrepTool | Regex content search |
| 7 | glob | GlobTool | Find files by pattern |
| 8 | list | ListTool | List directory contents |
| 9 | diff | DiffTool | Unified diff preview |
| 10 | apply_patch | ApplyPatchTool | Apply unified patches |
| 11 | webfetch | WebfetchTool | Fetch URL content |
| 12 | websearch | WebsearchTool | Search the web |
| 13 | task | TaskTool | Delegate to subagents |
| 14 | skill | SkillTool | Load specialized skills |
| 15 | question | QuestionTool | Interactive user prompts |
| 16 | todowrite | TodoWriteTool | Task list management |
| 17 | todoread | TodoReadTool | Read todo state |
| 18 | git | GitTool | Git status/diff/commit/… |
| 19 | archive | ArchiveTool | Zip / tar create & extract |
| 20 | cv_maker | CvMakerTool | Generate a CV as PDF |
| 21 | docx_maker | DocxMakerTool | Generate Word documents |
| 22 | image_analyze | ImageAnalyzeTool | OCR & structure analysis |
| 23 | image_describe | ImageDescribeTool | Describe images for the model |
| 24 | memory | MemoryTool | Long-term memory across sessions |
| 25 | pdf | PdfTool | Read / extract PDF text |
| 26 | pdf_edit | PdfEditTool | Edit existing PDFs |
| 27 | pdf_maker | PdfMakerTool | Generate PDF documents |
| 28 | schedule | ScheduleTool | Timed commands via alarms |
| 29 | screenshot | ScreenshotTool | Capture device screenshots |
| 30 | ui_dump | UiDumpTool | Dump the UI hierarchy |
| 31 | sensor | SensorTool | Read sensors & control hardware (torch, vibrate, brightness, wifi…), root when needed |
Execution flow
user action → check permission rules → deny → blocked immediately → ask → confirmation popup → wait for user → allow → action runs
Example calls
bash { "command": "ls -la" }
read { "path": "/path/to/file" }
edit { "path": "...", "oldString": "find", "newString": "replace" }
grep { "pattern": "regex", "path": "/dir", "include": "*.md" }
task { "description": "...", "prompt": "...", "subagent_type": "explore" }Commands
25+ slash commands for session and workflow control.
| Command | Description |
|---|---|
/new | Start new session |
/clear | Clear chat messages |
/sessions | Show session list |
/model | Change AI model |
/connect | Connect a provider |
/build /plan | Switch agent mode |
/init | Initialize project |
/diff | Show real git diff |
/undo /redo | Undo / redo last tracked file change |
/fork | Duplicate session into a copy |
/review | Code review |
/component | Create component |
/compact | Summarize context (chat history stays) |
/share | Share via Android share sheet |
/skills | List skills |
/agents | List agents |
/theme | Change theme (picker dialog) |
/export /import | Export / import session |
/help | Show help |
Permissions
Every tool call passes through the permission layer before executing.
Permission keys
| Key | Gates |
|---|---|
read | read |
edit | write, edit, apply_patch |
bash | bash, shell |
glob / grep / list | respective tools |
task | task |
external_directory | any tool outside workspace |
todowrite | todowrite, todoread |
webfetch / websearch | web tools |
skill / question | skill, question |
doom_loop | stuck-agent recovery |
Values
| Value | Behavior |
|---|---|
| allow | Execute without asking |
| ask | Show popup, wait for user decision |
| deny | Block execution entirely |
Evaluation order
- Check agent-specific permission for the tool name
- Check wildcard (
*) permission - Default: allow (build) / ask (plan)
Providers
13 pre-configured providers with capability flags and auto-fallback.
| Provider | Base URL | Models |
|---|---|---|
| OpenCode Zen | https://opencodezen.ai | mimo-v2.5-free, gpt-5, claude-sonnet-4 |
| Pollinations | https://text.pollinations.ai/openai | openai-fast, gpt-oss-20b |
| OpenAI | https://api.openai.com/v1 | gpt-4o, gpt-4o-mini, o1 |
| Anthropic | https://api.anthropic.com/v1 | claude-sonnet-4, claude-haiku |
https://generativelanguage.googleapis.com/v1beta | gemini-2.0-flash, gemini-1.5-pro | |
| Groq | https://api.groq.com/openai/v1 | llama-3.3-70b, mixtral-8x7b |
| DeepSeek | https://api.deepseek.com/v1 | deepseek-chat, deepseek-coder |
| Mistral | https://api.mistral.ai/v1 | mistral-large, codestral |
| xAI | https://api.x.ai/v1 | grok-2, grok-2-mini |
| Together | https://api.together.xyz/v1 | llama-3.3-70b, codellama |
| OpenRouter | https://openrouter.ai/api/v1 | multi-provider |
| HuggingFace | https://api-inference.huggingface.co/v1 | various |
| GitHub Models | https://models.inference.ai.azure.com | gpt-4o, codestral |
Model capabilities
| Flag | Description |
|---|---|
supportsTools | Tool calling |
supportsImages | Image processing |
supportsReasoning | Thinking / reasoning display |
supportsStreaming | SSE streaming |
Error handling
| HTTP | Type | User message |
|---|---|---|
| 401 | Authentication | Invalid API key. Check Settings > Models. |
| 402 | Payment | Quota exhausted. Add credits or switch provider. |
| 403 | Access denied | No permission for this model. |
| 404 | Not found | Model not available. Try another. |
| 429 | Rate limit | Too many requests. Wait and retry. |
| 5xx | Server error | Provider unavailable. Retrying… |
Retry: max 3 attempts, exponential backoff 2s → 4s → 8s (429: 5s → 10s → 15s), auto-fallback to Pollinations on 4xx/5xx.
Settings
Runtime configuration lives in ~/.config/agent24/.
| Path | Purpose |
|---|---|
agent24.json | Main config file |
AGENTS.md | Base system prompt |
agents/ | Agent prompt files |
skills/ | Skill definitions |
commands/ | Custom slash commands |
prompts/ | Custom prompts |
Useful toggles
show_reasoning— thinking card visibilityauto_summarize— auto-summary on session switchcompaction_threshold— token % that triggers compaction (default 80)- Theme — change with
/theme(picker dialog)
Skills
Markdown instruction files loaded into the system prompt on demand.
Location
~/.config/agent24/skills/<name>.md
Usage
Load with the skill tool or ask the agent directly — it pulls the file into context:
{ "tool": "skill", "params": { "name": "settings-customization" } }Structure
- One markdown file per skill
- Loaded skills are listed at the bottom of the system prompt
- Related assets can sit next to the file
- List everything with
/skills
Example
# settings-customization How to modify agent24.json safely: keys, defaults, restart behavior and rollback steps.
MCP
Model Context Protocol — connect external tool servers.
Registering a server
{
"server": "my-server",
"instructions": "shown to the model in the system prompt",
"tools": [ { "name": "create_issue", "inputSchema": { ... } } ]
}
Calling any of these tools routes the result back to the model.Naming
MCP tools are prefixed with mcp_{serverName}_{toolName} so they never collide with built-ins.
mcp_github_create_issue mcp_slack_send_message
Flow
- Server registers tools & instructions
- Instructions join the system prompt
- Tool definitions join the API tool list
- Model calls
mcp_*→ routed to the server
Hooks
Deterministic actions that run on lifecycle events — no model involved.
| Hook | When |
|---|---|
| session.created | New session starts |
| session.loaded | Existing session opened |
| session.deleted | Session removed |
| session.renamed | Title changed |
| message.before_send | User message leaves the input |
| message.after_response | Agent response completed |
| tool.before_execute | Before a tool runs (can block) |
| tool.after_execute | After a tool returns |
| permission.requested | Permission popup shown |
Event system
session.created(sessionId) session.loaded(sessionId) session.deleted(sessionId) session.renamed(sessionId, newTitle)
Typical uses: telemetry, auto-backup before edits, audit logging, custom notifications.
Sessions
Every conversation is an isolated session with its own database.
Lifecycle
startNewSession() → id "session_" + timestamp → metadata → session database → event loadSession(id) → set current → load messages → update timestamp → event deleteSession(id) → drop database + folders + metadata → clear memory → event
Storage
| Database | Path |
|---|---|
| Session DB | ~/.local/share/agent24/sessions/{id}/session.db |
| Global DB | ~/.local/share/agent24/databases/agent24_global.db |
Message senders
| Value | Name | Description |
|---|---|---|
| 0 | USER | User message |
| 1 | AGENT | AI response |
| 2 | SYSTEM | System message |
| 3 | COMMAND | Command output |
| 4 | ERROR | Error message |
| 5 | PERMISSION | Permission request |
| 6 | THINKING | Reasoning / thinking |
| 7 | TODO | Todo update |
Auto features
| Feature | Trigger |
|---|---|
| Auto-title | First user message → 3–5 word title |
| Auto-summary | Session switch → conversation summary |
| Auto-compaction | Tokens > 80% → summarize & compact |
| Auto-queue | Session busy → queue, then drain |
Queue
If the session is busy, messages go into a ConcurrentLinkedQueue and show Queued (N pending) — they run right after the current task completes.
Troubleshooting
| Symptom | Fix |
|---|---|
| 401 errors | Re-enter API key: Settings > Models, or /connect |
| 429 rate limit | Wait — auto backoff 5s/10s/15s; or switch provider |
| Model not responding | Try another model with /model; free fallback is Pollinations |
| Agent stuck in a loop | Permission key doom_loop triggers recovery |
| Context too long | Run /compact — chat history stays |
| UI dump fails | Enable accessibility service, then retry ui_dump |
| Command not found | /help lists commands; custom ones live in ~/.config/agent24/commands/ |
| Session feels slow | Check the queue; switch to a faster model (e.g. openai-fast) |
Still stuck?
Open a session and ask — the agent can read its own logs via bash and the global database at ~/.local/share/agent24/databases/.