AgentKit
ReferenceCLI commands

CLI commands

ak run

Run a skill via the configured agent adapter

ak run

Run a skill via the configured agent adapter

Synopsis

What it does: Resolve <kit>/<skill> against the kits directory and dispatch the invocation to the configured AgentAdapter. Streams stdout/stderr in pretty or NDJSON form. Honors SIGINT for clean cancellation and --timeout for hard caps.

Who it's for: Power devs scripting agent invocations; non-technical users via the matching dashboard surface.

When to use it: When you want to actually run a skill end-to-end. Use after ak kit list-kits to confirm the target exists; pair with --json for scripted consumers (CI, dashboards).

Examples: ak run engineer/scout # default adapter, pretty output ak run engineer/scout --json | jq . # scripted consumption ak run engineer/scout --timeout 30s # hard timeout ak run engineer/scout --target codex # route through Codex CLI Stream

What changes on disk: Read-only on the kit content; the underlying adapter may write to its own working directory (e.g. .agentkit/cache/). The run command itself does not mutate.

Output modes: pretty default on TTY (colors, ASCII markers) plain auto when stdout piped or --no-interactive json --json (single-object envelope, NDJSON-safe)

Exit codes: 0 success 1 runtime error 2 invalid flags 3 user-cancel (SIGINT, prompt-cancel) 4 unmet dependency (missing skill env or backend binary) 5 kit or skill not found

ak run <kit>/<skill> [args...] [flags]

Options

  -h, --help               help for run
      --json               Emit machine-readable JSON (implies --no-interactive)
      --kits-dir string    Kits directory (default: ./kits or $AGENTKIT_KITS_DIR)
      --no-interactive     Disable interactive prompts (CI-safe)
  -q, --quiet              Suppress non-error output on stderr
      --target string      Adapter to dispatch to: claude-code | codex (default "claude-code")
      --timeout duration   Per-invocation timeout (e.g. 30s, 2m). Zero disables timeout.
  -V, --verbose            Extra diagnostic output on stderr (loses to --quiet)
  -y, --yes                Assume yes for all prompts

SEE ALSO

  • ak - AgentKit CLI

On this page