M

How to Build an Agentic OS Using Kimi K3 ( Builder's Guide )

4 min readView source ↗

Cover image

Here's the truth nobody tells AI builders: you don't need to train a model to build an "OS" for agents

You need three things - a loop, a memory layer, and a router. Kimi K3 just made all three cheap enough to run 24/7

Bookmark this. Full breakdown below

Why Kimi K3, specifically

Article image

> 2.8T parameters, Mixture of-Experts, fully open ( weights land July 27 ) 1M token context window flat pricing across the whole window, no long-context tax $3 / $15 per million tokens ( in/out ) - Sonnet-tier pricing, near-Fable-tier output Agent Swarm

> coordinates up to 300 sub-agents in parallel out of the box Beats Opus 4.8 and GPT-5.6 on most benchmarks, trails only Fable 5 and GPT-5.6 Sol Max

This is the first open-weight model where the "OS" doesn't feel like a compromise. Swarm coordination is native, not bolted on

What "Agentic OS" actually means

Article image

Not a product A pattern: a persistent process that

  1. Gathers context - pulls only what the next step needs, not everything
  2. Takes action - calls tools, writes code, hits APIs
  3. Verifies - a separate pass checks the work against a rubric
  4. Repeats - on a schedule, a trigger, or a goal condition - without you in the room

"OS" part is the scheduler + memory + router sitting around that loop, so it survives your laptop closing.

The architecture, piece by piece

Article image

  1. THE KERLEN - one system prompt, one state file

Every agent reads and writes to a single AGENT.md file. This is your kernel config: goals, constraints, current task queue, and what "done" looks like. Kimi K3's 1M context means you can keep the entire project history in here without chunking.

  1. THE SCHEDULER

A cron-like process (a simple systemd timer or a hosted cloud routine) wakes the swarm on an interval or an event. It pulls the top item off the task queue defined in the kernel file.

  1. THE ROUDER

Not every task needs the full 2.8T model. Route by complexity:

> Cheap/fast subtasks → smaller model or K3 at low reasoning effort Long-horizon planning, codegen, verification → full K3 at max reasoning

  1. THE SWARM

K3's Agent Swarm spins up to 300 parallel sub agents

Use this for fan-out work testing multiple approaches, scraping multiple sources, generating multiple variants

then have a single verifier agent grade and merge results.

  1. The Verifier - the rule that decides if it converges or spirals

The maker agent never grades its own work. A fresh-context verifier subagent checks the artifact against the rubric only - it never sees the maker's reasoning trail. This single design choice is what separates a loop that improves over time from one that just repeats its own mistakes.

  1. MEMORY

Not a vector database by default - start with files

memory/ folder the kernel writes learnings to after every cycle

Only reach for embeddings once file search stops being fast enough

Build it - step by step

  1. PROJECT SKELETON

Article image

  1. KERNEL FILE

this is what every agent reads first

Article image

  1. SCHEDULER

runs the loop every 15 minutes, unattended

Article image

Where this breaks (read before you ship it)

> K3 always reasons - no low-effort mode yet, so every cycle costs more than you'd expect Full open weights aren't out until July 27 - until then you're API-only, not self-hosted Token usage runs higher than closed models for equivalent tasks - budget accordingly The maker/verifier split only works if the verifier genuinely can't see the maker's reasoning - leaking context between them defeats the whole design

The one sentence to remember

A prompt is a request. A loop is a policy. Requests need you present. Policies run at 3am, survive your laptop closing, and get better every cycle because they write down what they learned.

Save this before you rebuild and leave a comment saying “KIMI” to get a complete step-by-step guide it from scratch in three weeks 📬

Related articles