AgentModule + Engine + Trace. You define the strategy; the Engine owns the loop. This guide walks through that path using the minimal coding agent from examples/quickstart/minimal_agent.py.
Prerequisites
- Python 3.10+
- An API key for any OpenAI-compatible endpoint
Define state around a coding task
Every minimal QitOS coding agent still starts from a typed The key mindset is that the task, scratchpad, and verification contract all live in state, not in hidden runtime glue.
StateSchema:Attach a real model and a real coding toolset
The minimal example is intentionally model-backed. It uses an OpenAI-compatible model plus the canonical coding tool preset:
Seed a workspace and run the agent
The minimal example creates one tiny buggy file, then asks the agent to fix it:
Complete example
The full minimal coding-agent example lives here: You can also run the packaged version directly:Common mistakes
| Mistake | Symptom | Fix |
|---|---|---|
Forget return state in reduce | StateValidationError or None state | Always end reduce with return state |
| Skip provider config | OPENAI_API_KEY / QITOS_API_KEY error before the run starts | Export the API key and base URL before running the demo |
| Never run verification | The agent edits code but finishes without proof | Keep a concrete test_command in state and treat passing it as success |
| Wrong prompt-parser pairing | Parse errors every step | Match your system prompt format to ReActTextParser or another explicit parser |
| Toolset too broad for the task | The run wanders through unnecessary tools | Start with the minimal coding preset and add tools only when the task really needs them |
Next steps
Tutorial track
Continue with the four-lesson research path: ReAct, PlanAct, Claude Code-style, and code security audit.
Agent patterns
Compare the high-level tradeoffs between QitOS pattern families before choosing one.
Observability
Inspect every run with qita board, replay, and export.
Kit reference
Look up the parsers, planners, toolsets, and helpers used in the lessons.
