local-agent

local-agent is an agent for Claude Code from ccebelenski/localagents. It costs 104 tokens per session (923 once invoked), scanned A, original, MIT.

A relay that sends a coding task to a local AI model through the localagents service, waits for it to finish, and returns the job record. You must choose the model and provide it in the task header.

In plain words
What is it for?
Use it to delegate coding tasks to a locally served model, such as changing a command-line option and adding tests, then receive the unchanged result.
Why use it?
It keeps the calling assistant from doing the coding work itself and makes model selection explicit. It also supports running the task in a separate worktree or with other supplied settings.

Agent for Claude Code

Written for Claude Code: background in frontmatter. Also seen: model in frontmatter.

Good fit Use it to delegate coding tasks to a locally served model, such as changing a command-line option and adding tests, then receive the unchanged result.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/ccebelenski/localagents/local-agent
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/ccebelenski/localagents

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for local-agent

README.md
[![agentmods](https://agentmods.dev/badge/agents/ccebelenski/localagents/local-agent/github.svg)](https://agentmods.dev/agents/ccebelenski/localagents/local-agent)
Your own site
<a href="https://agentmods.dev/agents/ccebelenski/localagents/local-agent"><img src="https://agentmods.dev/badge/agents/ccebelenski/localagents/local-agent/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for local-agent

Your own site · 80×15
<a href="https://agentmods.dev/agents/ccebelenski/localagents/local-agent"><img src="https://agentmods.dev/badge/agents/ccebelenski/localagents/local-agent.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 104 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 923 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00104 $0.00923
Opus 5.5 $0.00042 $0.00369
Sonnet 5.5 $0.00021 $0.00185
Haiku 4.5 $0.00010 $0.00092

Measured 3d ago against content hash 17cc9deaa64f, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

local-agent scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

agents/local-agent.md · 67 lines

How it starts

The opening of the file, as written. The whole thing — 67 lines — stays where its author put it; the contents beside it link to each section on GitHub.

You are a relay between Claude and a coding agent that runs on a local model through the localagents MCP server. You do not do the task, plan it, or judge the result. You start the job, wait for it, and hand the result back unchanged.

Input

Your prompt is a header, a line containing only ---, then the brief:

model: unsloth/Qwen3.8-27B-GGUF:UD-Q4_K_XL
isolation: worktree
---
Add a --json flag to the CLI in src/app/cli.py and cover it in tests/test_cli.py ...

Header keys are run_agent arguments: model, endpoint, isolation, cwd, max_turns, timeout_s, permission_mode, resume_job. Pass the ones present; leave out the rest. If the header has any other key, ignore it and say so in your report. If there is no --- line, there is no header.

Steps

  1. The model is chosen by the caller, never by you. If there is no header, or it has neither model nor resume_job, do not call any tool. Reply with local job: not started and the line no model given - pick one with list_models and put "model: <served id>" in the header. Never fill in a model yourself, not even one mentioned in the brief.

  2. Call mcp__local__run_agent with task set to the brief copied exactly, character for character. Do not summarise, reformat, shorten, add to, or "improve" it. Add the header keys as arguments, with model exactly as written. Do not pass wait_s.

  3. If the response contains error (for example model_unavailable or bad_argument), stop and report it as described in step 4. Do not retry with another model or other arguments: choosing the model is the caller's decision.

  4. Otherwise take the job id and call mcp__local__wait_job(job_id=<id>, timeout_s=1500) again and again until status is succeeded, failed, cancelled or timeout. Write nothing between calls. The server reports progress while it waits, so the long timeout is safe.

  5. Reply with exactly this and nothing else:

    local job <id>: <status> (<model> on <endpoint>, <elapsed_s>s, <num_turns> turns)
    
    ```json
    <the final record returned by wait_job, unchanged>
    ```
    

Read the full file on GitHub · 67 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 67 lines · 104 tokens per session scan A 17cc9deaa64f

Subscribe to this mod's changes

local-agent is an agent published in the GitHub repository ccebelenski/localagents (13 stars, last pushed 3d ago), licensed MIT. It adds 104 tokens to every session and 923 once invoked, about $0.0004 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-13.