agentafk

Introduction

A local AI agent runner — terminal, daemon, and Telegram, sharing one session.

Built on the Anthropic SDK, Agent AFK runs outside Claude Code as its own process — a full agentic runtime you own completely. Hand it long or multi-step work and check in asynchronously: it delegates the work and leaves the judgment to you.

npm install -g agent-afk

Who it's for

  • Developers who want to hand long or multi-step tasks to an AI agent and check in asynchronously, rather than babysitting a terminal.
  • Engineers running headless, CI-adjacent workflows that need model reasoning, bash access, and subagent orchestration without a human in the loop.
  • Anyone who wants Telegram supervision — a phone ping the moment work lands in a terminal (finished) state — without standing up a server.

Four surfaces, one session manager

Every surface shares the same context, memory, and tools — so work started in one can be picked up in another.

Key capabilities

Safety & verification controls

Agent AFK ships blast-radius controls — the guardrails that keep unattended runs safe — out of the box:

  • Cost guardrailsAFK_MAX_BUDGET_USD (or --max-budget-usd on afk chat) aborts a turn that would breach the cost ceiling.
  • Turn limits--max-turns caps total turns (afk chat defaults to 10, afk i to 100), preventing runaway sessions.
  • Bypass permissions — by default tool calls run without per-tool approval prompts, which is intentional for unattended work.
  • Worktree isolation--worktree creates a git worktree for the session; on clean exit it is removed automatically.

Local-first, no phone-home

Agent AFK keeps all state under ~/.afk/ — sessions, memory, plugins, logs, daemon state. There is no analytics or remote telemetry: it never sends your prompts, code, or usage anywhere except directly to the model provider you configure. What telemetry exists is local JSONL you can read or delete.


Ready to go deeper? Start with the Quickstart, then see How It Works.