InitRunner

Quickstart

Get your first AI agent running in under five minutes.

Prerequisites

  • Python 3.11+ (Linux, macOS, or WSL — see Installation for Windows details)
  • An API key from a supported provider (OpenAI, Anthropic, Google, Groq, Mistral, Cohere, Bedrock, or xAI) — or a local Ollama instance

Install

curl -fsSL https://initrunner.ai/install.sh | sh

Or install directly with a package manager:

uv tool install "initrunner[recommended]"
pipx install "initrunner[recommended]"
pip install "initrunner[recommended]"

Note: On modern Linux (Python 3.11+), bare pip install outside a virtual environment will fail due to PEP 668. Use uv, pipx, or create a venv first.

Tip: [recommended] includes search, ingestion, and the dashboard so common workflows just work. Use [all] for every provider and feature. See Installation for the full list.

Or run with Docker (no Python required):

docker run --rm -e OPENAI_API_KEY vladkesler/initrunner:latest --version

Setup

Run the setup wizard to configure your provider and API key:

initrunner setup

The wizard walks you through the essentials: choose your LLM provider and model, validate your API key, and generate a ready-to-run role.yaml. See Setup Wizard for all options.

Shortcut: Already have an API key? Skip the wizard — just export it and go:

export OPENAI_API_KEY="sk-..."

Using Ollama? Make sure ollama serve is running. No API key needed — just run initrunner setup --provider ollama.

Verify Your Setup

Confirm everything works with a single command:

initrunner doctor --quickstart

You should see a provider status table followed by a smoke test result:

╭───────────────────────────── Quickstart Result ──────────────────────────────╮
│ Smoke test passed!                                                           │
│                                                                              │
│ Response: Hello!                                                             │
│ Tokens: 97 | Duration: 2229ms                                                │
╰──────────────────────────────────────────────────────────────────────────────╯

If the smoke test can't find your API key, initrunner run asks for one inline and saves it to ~/.initrunner/.env (mode 0600) so the next run picks it up automatically. That only works in an interactive terminal. In CI or piped scripts it still exits with an error, so set the variable explicitly there:

export OPENAI_API_KEY=sk-...

See Troubleshooting for other common issues, or run initrunner doctor --fix to auto-repair detected problems.

Your First Agent

The fastest way to chat, no YAML file needed:

initrunner run -p "What is the capital of France?"

InitRunner auto-detects your provider and returns a single response:

The capital of France is Paris.

Try a Starter Agent

You don't need to write any YAML yet. InitRunner ships with 18 ready-to-run starters (one-word names like helpdesk, scout, reviewer, writer) you can try right now:

initrunner run --list

Here are a few to start with:

StarterKindWhat it does
helpdeskAgent (RAG)Drop your docs in, get an AI helpdesk with citations and memory
scoutAgentSearch the web and produce structured briefings
reviewerTeamMulti-perspective review: architect, security, maintainer
writerFlowResearcher, writer, editor/fact-checker pipeline
telegramAgent (Daemon)Telegram bot with memory and web search
watcherAgent (Daemon)Heartbeat-driven health checks on a schedule

Run initrunner run --list to see the full set.

Pick one and go:

# Run a starter directly
initrunner run helpdesk -i

# Save locally to read and customize the YAML
initrunner run helpdesk --save ./my-helpdesk/
cd my-helpdesk && cat role.yaml

With --save, you get a local copy of the role.yaml that you can open and edit. It's the fastest way to see what a real agent config looks like before writing your own.

See Examples for 60+ more runnable agents.

Create Your Own Agent

The easiest way to create a custom agent is initrunner new. Describe what you want in plain English and it generates the full config for you:

initrunner new "a code review bot that reads git diffs and suggests improvements"

The builder generates a role.yaml and shows it to you. You can refine it in a back-and-forth loop, or press Enter to save:

+-- code-reviewer -------------------- VALID --+
| apiVersion: initrunner/v1                     |
| kind: Agent                                   |
| ...                                           |
+-----------------------------------------------+

Refine (empty to save, "quit" to discard):
> add memory so it remembers past reviews

Once saved, run your agent:

initrunner run role.yaml -p "Review the last commit"

Or skip the two-command dance by passing --run to initrunner new. It opens the refinement loop first, then fires off a run with your prompt as soon as you save:

initrunner new "a code review bot that reads git diffs and suggests improvements" \
  --run "Review the last commit"

You can also start from a template (initrunner new --template rag) or a blank slate (initrunner new --blank). See Role Creation for all the options.

Understanding Your role.yaml

The generated file defines everything about your agent: its model, system prompt, tools, and safety limits. Here's what a basic one looks like:

apiVersion: initrunner/v1          # always this value
kind: Agent                         # single agent (also: Team, Flow)
metadata:
  name: my-first-agent              # lowercase, hyphens only
  description: A helpful assistant
spec:
  role: |                           # the system prompt, tells the agent what to do
    You are a helpful assistant. You answer questions
    clearly and concisely.
  model:
    provider: openai                # or: anthropic, google, groq, ollama, etc.
    name: gpt-5-mini
  guardrails:
    max_tokens_per_run: 10000       # cost safety net
    max_tool_calls: 5
    timeout_seconds: 60

You can write this by hand too, or edit the one initrunner new generated. Validate it anytime with:

initrunner validate role.yaml

Tip: initrunner setup also generates a role.yaml for you as part of the setup wizard.

Note: YAML is indentation-sensitive. Use spaces, not tabs. If you get a validation error, check your indentation first.

Add Tools

Without tools, your agent can only chat from its training data. Tools let it interact with files, the web, and more. Add a tools section to your role.yaml under spec:

spec:
  role: |
    You are a helpful assistant. You answer questions
    clearly and concisely.
  model:
    provider: openai
    name: gpt-5-mini
  tools:
    - type: datetime                # get current time
    - type: web_reader              # fetch and read web pages
      timeout_seconds: 15
    - type: filesystem              # read local files
      root_path: .
      read_only: true
  guardrails:
    max_tokens_per_run: 10000
    max_tool_calls: 5
    timeout_seconds: 60

Run the agent with a prompt that requires a tool:

initrunner run role.yaml -p "What time is it right now?"

The agent uses the datetime tool and returns the current time. You can see which tools the agent calls in the output.

InitRunner has 27 built-in tool types, from filesystem, HTTP, shell, Python, git, MCP, and SQL to more specialized ones. See Tools for the full list.

Interactive Mode

So far you have used single-shot mode (-p "...") where the agent responds once and exits. Interactive mode starts a multi-turn conversation:

initrunner run role.yaml -i
You: What files are in the current directory?
Agent: I found the following files: role.yaml, README.md, src/...
You: Summarize README.md for me
Agent: The README describes...
You: quit

The agent keeps context within the session — it remembers what you discussed earlier. Type quit, exit, or press Ctrl+D to end the session.

To pick up where you left off in a future session:

initrunner run role.yaml -i --resume

Autonomous mode: For multi-step tasks where the agent works independently — planning, executing, and iterating without you prompting each step — use autonomous mode:

initrunner run role.yaml -a -p "Read all Python files in ./src and write a summary report"

See Autonomous Mode for budget controls and reasoning strategies.

What's Next

Pick your path based on what you want to build:

  • Build a complete agent step by stepTutorial walks you through initrunner new, the dashboard, memory, RAG, autonomy, triggers, teams, and flows
  • Add document search (RAG)RAG in 5 Minutes adds vector search over your files
  • Add persistent memoryMemory in 5 Minutes lets your agent remember across sessions
  • Explore all tool typesTools covers 27 built-in tools (HTTP, shell, Python, git, MCP, and more)
  • Full YAML schemaConfiguration is the complete reference for every role.yaml field
  • Run on a schedule or webhookTriggers for cron, file watch, and webhook-driven agents
  • Telegram or Discord botTelegram and Discord setup guides with access control
  • API serverAPI Server exposes any agent as an OpenAI-compatible endpoint
  • Web dashboardDashboard for visual agent management and monitoring
  • Browse community agentsInitHub marketplace for pre-built agents

On this page