kord-aios 3.3.1 → 3.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. package/README.md +334 -308
  2. package/dist/agents/analyst.d.ts +1 -13
  3. package/dist/agents/builder/index.d.ts +2 -0
  4. package/dist/agents/index.d.ts +1 -1
  5. package/dist/agents/kord.d.ts +2 -1
  6. package/dist/agents/plan-analyzer.d.ts +1 -7
  7. package/dist/agents/plan-reviewer.d.ts +1 -1
  8. package/dist/agents/qa.d.ts +1 -1
  9. package/dist/agents/utils.d.ts +2 -1
  10. package/dist/cli/extract.d.ts +11 -0
  11. package/dist/cli/index.js +253 -32
  12. package/dist/config/schema.d.ts +2 -2
  13. package/dist/features/builtin-agents/prompts.d.ts +32 -0
  14. package/dist/features/opencode-agent-loader/index.d.ts +2 -0
  15. package/dist/features/opencode-agent-loader/loader.d.ts +18 -0
  16. package/dist/features/opencode-agent-loader/types.d.ts +49 -0
  17. package/dist/features/squad/chief-template.d.ts +9 -0
  18. package/dist/features/squad/factory.d.ts +13 -2
  19. package/dist/features/squad/schema.d.ts +10 -0
  20. package/dist/index.js +2039 -1150
  21. package/dist/shared/agent-capabilities.d.ts +81 -0
  22. package/dist/shared/agent-frontmatter-capabilities-store.d.ts +9 -0
  23. package/dist/shared/index.d.ts +2 -0
  24. package/dist/shared/squad-fallback-store.d.ts +18 -0
  25. package/dist/test-utils/tsls_guard.d.ts +2 -0
  26. package/package.json +8 -8
  27. /package/dist/agents/{plan → planner}/behavioral-summary.d.ts +0 -0
  28. /package/dist/agents/{plan → planner}/high-accuracy-mode.d.ts +0 -0
  29. /package/dist/agents/{plan → planner}/identity-constraints.d.ts +0 -0
  30. /package/dist/agents/{plan → planner}/index.d.ts +0 -0
  31. /package/dist/agents/{plan → planner}/interview-mode.d.ts +0 -0
  32. /package/dist/agents/{plan → planner}/plan-generation.d.ts +0 -0
  33. /package/dist/agents/{plan → planner}/plan-template.d.ts +0 -0
package/README.md CHANGED
@@ -1,308 +1,334 @@
1
- > [!TIP]
2
- >
3
- > **Kord AIOS** — multi-model agent orchestration meets story-driven development methodology.
4
- > Built on [Oh-My-Opencode](https://github.com/code-yeongyu/oh-my-opencode) + [Synkra AIOS](https://github.com/SynkraAI/aios-core).
5
- > 20+ specialized agents, squads, 149 skills, background tasks, LSP/AST tooling.
6
- > npm package: `kord-aios`.
7
- >
8
- > ✅ Official repository: https://github.com/GDSDN/kord-aios
9
-
10
- ## Contents
11
-
12
- - [What is Kord AIOS?](#what-is-kord-aios)
13
- - [Quick Start](#quick-start)
14
- - [Installation](#installation)
15
- - [Architecture](#architecture)
16
- - [Agents](#agents-20)
17
- - [Squads](#squads)
18
- - [Skills](#skills-149)
19
- - [Background Agents](#background-agents)
20
- - [Features](#features)
21
- - [Commands](#commands)
22
- - [Hooks](#hooks-40)
23
- - [Tools](#tools)
24
- - [MCPs](#mcps-built-in)
25
- - [Context Injection](#context-injection)
26
- - [Claude Code Compatibility](#claude-code-compatibility)
27
- - [Configuration](#configuration)
28
- - [Uninstallation](#uninstallation)
29
- - [Origin Story](#origin-story)
30
- - [Contributing](#contributing)
31
-
32
- ## What is Kord AIOS?
33
-
34
- **Kord AIOS** is a version of [Synkra AIOS](https://github.com/SynkraAI/aios-core) built on top of [Oh-My-Opencode](https://github.com/code-yeongyu/oh-my-opencode) — combining the best of both worlds: Synkra's proven agent methodology with Oh-My-Opencode's powerful plugin runtime.
35
-
36
- Kord transforms your terminal into a full AI development team. Instead of one agent doing everything, Kord orchestrates 20+ specialized agents — each with the right model for the right job — working in parallel on your codebase.
37
-
38
- Kord AIOS combines:
39
- - **Engine**: OpenCode-native plugin runtime with background agents, parallel execution, LSP/AST tooling, Claude Code compatibility.
40
- - **Methodology**: Story-driven execution, squads, quality gates, and battle-tested development skills.
41
-
42
- > **Naming**: The project is **Kord AIOS**. The npm package is `kord-aios`. The config file is `kord-aios.json`.
43
-
44
- ## Quick Start
45
-
46
- Include `ultrawork` (or just `ulw`) in your prompt. That's it.
47
-
48
- Parallel agents, background tasks, deep exploration, and relentless execution activate automatically. The agent figures out the rest.
49
-
50
- ## Installation
51
-
52
- ### For Humans
53
-
54
- Read the [Installation Guide](docs/guide/installation.md) or paste it to your LLM agent and let it handle the setup.
55
-
56
- ### For LLM Agents
57
-
58
- Read and follow [docs/guide/installation.md](docs/guide/installation.md).
59
-
60
- > **Note**: Use `bunx kord-aios init` for setting up new projects if you have already installed Kord AIOS globally.
61
-
62
- ## Architecture
63
-
64
- ### Agents (20+)
65
-
66
- Kord AIOS ships a full development team. All agents are customizable — override models, temperatures, prompts, and permissions in `kord-aios.json`.
67
-
68
- **Orchestration Layer**
69
-
70
- | Agent | Model | Role |
71
- |-------|-------|------|
72
- | **Kord** | Claude Opus 4.6 | Master orchestrator — delegates, plans, reviews |
73
- | **Dev** | GPT 5.3 Codex | Autonomous deep worker — goal-oriented, explores before acting |
74
- | **Plan** | Claude Opus 4.6 | Strategic planner with interview and high-accuracy modes |
75
- | **Plan Reviewer** | GPT 5.2 | Validates plan feasibility |
76
- | **Plan Analyzer** | Claude Opus 4.6 | Pre-planning analysis |
77
-
78
- **Specialist Layer**
79
-
80
- | Agent | Model | Role |
81
- |-------|-------|------|
82
- | **Architect** | GPT 5.2 | System design, debugging, strategic consultation |
83
- | **Librarian** | GLM 4.7 | Documentation search, open-source code exploration |
84
- | **Explore** | Grok Code Fast 1 | Blazing fast codebase grep |
85
- | **UX Design Expert** | Gemini 3 Pro | Frontend development and design |
86
- | **Vision** | Gemini 3 Flash | Image/screenshot/PDF analysis |
87
- | **Data Engineer** | | Data pipeline methodology |
88
- | **DevOps** | | Infrastructure and CI/CD |
89
-
90
- **Methodology Layer**
91
-
92
- | Agent | Role |
93
- |-------|------|
94
- | **PM** | Project Manager — epic structuring, wave planning |
95
- | **PO** | Product Owner — quality gate before dev execution |
96
- | **QA** | Quality assurance and test strategy |
97
- | **SM** | Scrum Master — sprint coordination, stateless Dev awareness |
98
- | **Analyst** | Strategic analysis and research |
99
- | **Squad Creator** | Creates new SQUAD.yaml manifests |
100
-
101
- ### Squads
102
-
103
- Define domain-specific agent teams via `SQUAD.yaml` manifests. Each squad declares its agents, categories for task routing, and skill dependencies. The built-in `dev` squad provides the default development team.
104
-
105
- ```yaml
106
- # .opencode/squads/my-squad/SQUAD.yaml
107
- name: my-squad
108
- description: My custom agent team
109
- agents:
110
- specialist:
111
- description: "Domain expert"
112
- model: anthropic/claude-sonnet-4-5
113
- prompt: "You are a domain specialist..."
114
- categories:
115
- my-domain:
116
- description: "Domain-specific tasks"
117
- ```
118
-
119
- ### Skills (149)
120
-
121
- Battle-tested development methodologies encoded as `SKILL.md` files with YAML frontmatter. Each skill is a step-by-step instruction set for a specific development domain — from Git workflows to API design to testing strategies.
122
-
123
- Skills are loaded from:
124
- - `src/features/builtin-skills/skills/` — shipped with the plugin
125
- - `.opencode/skills/` — project-specific
126
- - `~/.config/opencode/skills/` — user-global
127
- - `.claude/skills/` — Claude Code compatible
128
-
129
- ### Background Agents
130
-
131
- Run multiple agents in parallel with per-provider and per-model concurrency management. Kord fires off exploration tasks to cheaper, faster models while the main agent focuses on implementation.
132
-
133
- ```json
134
- {
135
- "background_task": {
136
- "defaultConcurrency": 5,
137
- "providerConcurrency": { "anthropic": 3, "openai": 5 },
138
- "modelConcurrency": { "anthropic/claude-opus-4-6": 2 }
139
- }
140
- }
141
- ```
142
-
143
- ## Features
144
-
145
- Full documentation: [docs/guide/features.md](docs/guide/features.md) | Configuration: [docs/guide/configurations.md](docs/guide/configurations.md)
146
-
147
- **Summary:**
148
- - **20+ Specialized Agents** — right model for the right task, full dev team
149
- - **Squad System** SQUAD.yaml v2 manifests for domain-specific agent teams
150
- - **149 Skills** — battle-tested development workflows (5 hardcoded + 144 methodology)
151
- - **Background Agents** — parallel async execution with concurrency limits
152
- - **LSP & AST Tools** — structural refactoring, rename, diagnostics, AST-aware search
153
- - **40+ Lifecycle Hooks** — context injection, productivity automation, quality gates, recovery
154
- - **12 Slash Commands** — init-deep, ralph-loop, ulw-loop, refactor, start-work, checkpoint, status, squad, and more
155
- - **Built-in MCPs** web search (Exa), documentation (Context7), GitHub code search (Grep.app)
156
- - **Context Injection** — auto-inject AGENTS.md, README, conditional rules per directory
157
- - **Claude Code Compatibility** — full compat layer for commands, skills, agents, MCPs, hooks
158
- - **Todo Enforcer** — forces completion, no half-finished work
159
- - **Comment Checker** — prevents AI comment bloat, keeps code human-like
160
- - **Tmux Integration** — visual multi-agent dashboard, watch agents work in parallel
161
- - **Story-Driven Pipeline** — wave/story execution with persistent state
162
- - **CLI Installer** — interactive setup with project maturity detection and doctor checks
163
-
164
- ### Commands
165
-
166
- | Command | Description |
167
- |---------|-------------|
168
- | `/init-deep` | Generate hierarchical AGENTS.md files throughout your project |
169
- | `/ralph-loop` | Self-referential dev loop runs until task is 100% complete |
170
- | `/ulw-loop` | Ultrawork loopralph-loop with max parallel intensity |
171
- | `/cancel-ralph` | Cancel active loop |
172
- | `/refactor` | Intelligent refactoring with LSP, AST-grep, TDD verification |
173
- | `/start-work` | Start Build agent execution from a Plan-generated plan |
174
- | `/stop-continuation` | Stop continuation mechanisms for the current session |
175
- | `/checkpoint` | Trigger a PO checkpoint decision on current execution |
176
- | `/status` | Show current plan progress, wave, and pending items |
177
- | `/squad` | Switch active squad context |
178
- | `/squad-create` | Create a specialized squad for a domain |
179
- | `/modelconfig` | View and configure model routing per agent |
180
-
181
- Custom commands: `.opencode/commands/*.md` or `.claude/commands/*.md`
182
-
183
- ### Hooks (40+)
184
-
185
- Hooks intercept agent lifecycle events: PreToolUse, PostToolUse, UserPromptSubmit, Stop.
186
-
187
- | Category | Hooks | Purpose |
188
- |----------|-------|--------|
189
- | **Context** | directory-agents-injector, readme-injector, rules-injector, compaction-context-injector | Auto-inject AGENTS.md, README, rules when reading files |
190
- | **Productivity** | keyword-detector, think-mode, ralph-loop, auto-slash-command | Activate modes (`ultrawork`/`ulw`), think deeply, loop execution |
191
- | **Quality** | comment-checker, thinking-block-validator, edit-error-recovery | Prevent comment bloat, validate blocks, recover from failures |
192
- | **Recovery** | session-recovery, context-window-limit-recovery, background-compaction | Handle errors, context limits, auto-compact |
193
- | **Truncation** | grep-output-truncator, tool-output-truncator | Dynamically truncate output to keep context lean |
194
- | **Notifications** | auto-update-checker, background-notification, session-notification | Version checks, task completion, OS notifications |
195
-
196
- Disable specific hooks: `"disabled_hooks": ["comment-checker"]` in config.
197
-
198
- ### Tools
199
-
200
- **LSP (IDE Features for Agents)**
201
-
202
- | Tool | Description |
203
- |------|-------------|
204
- | `lsp_diagnostics` | Errors/warnings before build |
205
- | `lsp_rename` | Rename symbol across workspace |
206
- | `lsp_goto_definition` | Jump to definition |
207
- | `lsp_find_references` | Find all usages |
208
- | `lsp_symbols` | File outline or workspace search |
209
-
210
- **AST-Grep** `ast_grep_search` and `ast_grep_replace` for pattern search/replace across 25 languages.
211
-
212
- **Delegation** `task` (category-based routing: visual, business-logic, custom), `call_kord_agent` (direct spawn with `run_in_background`), `background_output` / `background_cancel`.
213
-
214
- **Session** `session_list`, `session_read`, `session_search`, `session_info` for browsing agent session history.
215
-
216
- **Interactive Terminal** — `interactive_bash` for tmux-based TUI apps (vim, htop, pudb).
217
-
218
- ### MCPs (Built-in)
219
-
220
- | MCP | Purpose |
221
- |-----|--------|
222
- | **websearch** | Real-time web search (Exa AI) |
223
- | **context7** | Official documentation lookup for any library/framework |
224
- | **grep_app** | Code search across public GitHub repos |
225
-
226
- Skills can embed their own MCP servers via YAML frontmatter, including OAuth-protected remote MCPs with full RFC compliance.
227
-
228
- ### Context Injection
229
-
230
- - **AGENTS.md** — auto-injected when reading files (walks file directory project root, collecting all AGENTS.md)
231
- - **README.md** — directory context injection
232
- - **Conditional rules** — `.claude/rules/*.md` with glob patterns and `alwaysApply`
233
-
234
- ### Claude Code Compatibility
235
-
236
- Full compatibility layer for Claude Code configurations:
237
-
238
- | Type | Locations |
239
- |------|----------|
240
- | **Commands** | `~/.claude/commands/`, `.claude/commands/` |
241
- | **Skills** | `~/.claude/skills/*/SKILL.md`, `.claude/skills/*/SKILL.md` |
242
- | **Agents** | `~/.claude/agents/*.md`, `.claude/agents/*.md` |
243
- | **MCPs** | `~/.claude/.mcp.json`, `.mcp.json` (with `${VAR}` expansion) |
244
- | **Hooks** | `settings.json` hook execution |
245
-
246
- Toggle features: `"claude_code": { "mcp": false, "commands": false, ... }` in config.
247
-
248
- ## Configuration
249
-
250
- Config file: `.opencode/kord-aios.json` (project) or `~/.config/opencode/kord-aios.json` (user).
251
-
252
- JSONC supported comments and trailing commas work.
253
-
254
- **What you can configure:**
255
- - Agent models, temperatures, prompts, and tool permissions
256
- - Background task concurrency per provider/model
257
- - Disabled hooks, skills, agents
258
- - Category-based task delegation routing
259
- - Built-in MCPs (websearch, context7, grep_app)
260
- - LSP and experimental features
261
-
262
- See the full [Configuration Documentation](docs/configurations.md) for details.
263
-
264
- ## Uninstallation
265
-
266
- To remove Kord AIOS:
267
-
268
- 1. **Remove the plugin from your OpenCode config**
269
-
270
- Edit `~/.config/opencode/opencode.json` (or `opencode.jsonc`) and remove `"kord-aios"` from the `plugin` array:
271
-
272
- ```bash
273
- jq '.plugin = [.plugin[] | select(. != "kord-aios")]' \
274
- ~/.config/opencode/opencode.json > /tmp/oc.json && \
275
- mv /tmp/oc.json ~/.config/opencode/opencode.json
276
- ```
277
-
278
- 2. **Remove configuration files (optional)**
279
-
280
- ```bash
281
- rm -f ~/.config/opencode/kord-aios.json
282
- rm -f .opencode/kord-aios.json
283
- ```
284
-
285
- 3. **Verify removal**
286
-
287
- ```bash
288
- opencode --version
289
- # Kord AIOS should no longer be loaded
290
- ```
291
-
292
- ## Origin Story
293
-
294
- I wanted a disciplined way to run AI development workflows without giving up control of models and runtime behavior.
295
-
296
- OpenCode provided the open, multi-model engine. Kord AIOS adds the orchestration and methodology layer on top: squads, story-driven execution, quality gates, and specialized agents.
297
-
298
- **Kord AIOS is the result:** structured execution with full control over models, prompts, tools, skills, and squads.
299
-
300
- ## Contributing
301
-
302
- See [CONTRIBUTING.md](CONTRIBUTING.md) for development setup, code conventions, and PR guidelines.
303
-
304
- ## Warnings
305
-
306
- - Requires OpenCode >= 1.0.150.
307
- - If you're on [1.0.132](https://github.com/sst/opencode/releases/tag/v1.0.132) or older, an OpenCode bug may break config.
308
- - [The fix](https://github.com/sst/opencode/pull/5040) was merged after 1.0.132 — use a newer version.
1
+ > [!TIP]
2
+ >
3
+ > **Kord AIOS** — multi-model agent orchestration meets story-driven development methodology.
4
+ > Built on [Oh-My-Opencode](https://github.com/code-yeongyu/oh-my-opencode) + [Synkra AIOS](https://github.com/SynkraAI/aios-core).
5
+ > 20+ specialized agents, squads, 149 skills, background tasks, LSP/AST tooling.
6
+ > npm package: `kord-aios`.
7
+ >
8
+ > ✅ Official repository: https://github.com/GDSDN/kord-aios
9
+
10
+ > [!NOTE]
11
+ >
12
+ > **Versioning**: Kord AIOS may reset public semver to `1.x` even if earlier npm versions exist from upstream history. Always install via the npm `latest` tag unless you intentionally pin an older version.
13
+
14
+ ## Contents
15
+
16
+ - [What is Kord AIOS?](#what-is-kord-aios)
17
+ - [Quick Start](#quick-start)
18
+ - [Installation](#installation)
19
+ - [Architecture](#architecture)
20
+ - [Agents](#agents-20)
21
+ - [Squads](#squads)
22
+ - [Skills](#skills-149)
23
+ - [Background Agents](#background-agents)
24
+ - [Features](#features)
25
+ - [Commands](#commands)
26
+ - [Hooks](#hooks-40)
27
+ - [Tools](#tools)
28
+ - [MCPs](#mcps-built-in)
29
+ - [Context Injection](#context-injection)
30
+ - [Claude Code Compatibility](#claude-code-compatibility)
31
+ - [Configuration](#configuration)
32
+ - [Uninstallation](#uninstallation)
33
+ - [Origin Story](#origin-story)
34
+ - [Contributing](#contributing)
35
+
36
+ ## What is Kord AIOS?
37
+
38
+ **Kord AIOS** is a version of [Synkra AIOS](https://github.com/SynkraAI/aios-core) built on top of [Oh-My-Opencode](https://github.com/code-yeongyu/oh-my-opencode) — combining the best of both worlds: Synkra's proven agent methodology with Oh-My-Opencode's powerful plugin runtime.
39
+
40
+ Kord transforms your terminal into a full AI development team. Instead of one agent doing everything, Kord orchestrates 20+ specialized agents — each with the right model for the right job — working in parallel on your codebase.
41
+
42
+ Kord AIOS combines:
43
+ - **Engine**: OpenCode-native plugin runtime with background agents, parallel execution, LSP/AST tooling, Claude Code compatibility.
44
+ - **Methodology**: Story-driven execution, squads, quality gates, and battle-tested development skills.
45
+
46
+ > **Naming**: The project is **Kord AIOS**. The npm package is `kord-aios`. The config file is `kord-aios.json`.
47
+
48
+ ## Quick Start
49
+
50
+ Include `ultrawork` (or just `ulw`) in your prompt. That's it.
51
+
52
+ Parallel agents, background tasks, deep exploration, and relentless execution activate automatically. The agent figures out the rest.
53
+
54
+ ## Installation
55
+
56
+ ### For Humans
57
+
58
+ Read the [Installation Guide](docs/guide/installation.md) or paste it to your LLM agent and let it handle the setup.
59
+
60
+ ### For LLM Agents
61
+
62
+ Read and follow [docs/guide/installation.md](docs/guide/installation.md).
63
+
64
+ > **Note**: Use `bunx kord-aios init` for setting up new projects if you have already installed Kord AIOS globally.
65
+
66
+ ## Architecture
67
+
68
+ ### Agents (20+)
69
+
70
+ Kord AIOS ships a full development team. All agents are customizable — override models, temperatures, prompts, and permissions in `kord-aios.json`.
71
+
72
+ **Orchestration Layer**
73
+
74
+ | Agent | Model | Role |
75
+ |-------|-------|------|
76
+ | **Kord** | Claude Opus 4.6 | Master orchestrator — delegates, plans, reviews |
77
+ | **Dev** | GPT 5.3 Codex | Autonomous deep worker — goal-oriented, explores before acting |
78
+ | **Plan** | Claude Opus 4.6 | Strategic planner with interview and high-accuracy modes |
79
+ | **Plan Reviewer** | GPT 5.2 | Validates plan feasibility |
80
+ | **Plan Analyzer** | Claude Opus 4.6 | Pre-planning analysis |
81
+
82
+ **Specialist Layer**
83
+
84
+ | Agent | Model | Role |
85
+ |-------|-------|------|
86
+ | **Architect** | GPT 5.2 | System design, debugging, strategic consultation |
87
+ | **Librarian** | GLM 4.7 | Documentation search, open-source code exploration |
88
+ | **Explore** | Grok Code Fast 1 | Blazing fast codebase grep |
89
+ | **UX Design Expert** | Gemini 3 Pro | Frontend development and design |
90
+ | **Vision** | Gemini 3 Flash | Image/screenshot/PDF analysis |
91
+ | **Data Engineer** | — | Data pipeline methodology |
92
+ | **DevOps** | | Infrastructure and CI/CD |
93
+
94
+ **Methodology Layer**
95
+
96
+ | Agent | Role |
97
+ |-------|------|
98
+ | **PM** | Project Manager epic structuring, wave planning |
99
+ | **PO** | Product Owner quality gate before dev execution |
100
+ | **QA** | Quality assurance and test strategy |
101
+ | **SM** | Scrum Master — sprint coordination, stateless Dev awareness |
102
+ | **Analyst** | Strategic analysis and research |
103
+ | **Squad Creator** | Creates new SQUAD.yaml manifests |
104
+
105
+ ### Squads
106
+
107
+ Define domain-specific agent teams via `SQUAD.yaml` manifests. Each squad declares its agents, categories for task routing, and skill dependencies. The built-in default is `code` (`src/features/builtin-squads/code/SQUAD.yaml`).
108
+
109
+ **Chief + Worker Model:** Squads support L2 (chief) and L1 (worker) agent hierarchy. Chiefs have `is_chief: true` with auto-generated Squad Awareness and coordination protocol. Workers are standard subagents.
110
+
111
+ **Naming Convention:** Squad agents are registered with prefixed names (`squad-{squadName}-{yamlKey}`) to prevent collisions across squads.
112
+
113
+ **Agent Fields:** `fallback` (per-agent fallback chain) and `write_paths` (extra write authority paths) are supported in `SQUAD.yaml`. `write_paths` is validated (relative only, no `..`, no root `**`, no `docs/kord/` prefix).
114
+
115
+ **Chief Permissions:** Chiefs auto-enable `permission.task = "allow"` unless `tools` explicitly overrides `task`.
116
+
117
+ ```yaml
118
+ # .opencode/squads/my-squad/SQUAD.yaml
119
+ name: my-squad
120
+ description: My custom agent team
121
+
122
+ agents:
123
+ chief:
124
+ description: "Squad leader"
125
+ is_chief: true
126
+ mode: all
127
+ specialist:
128
+ description: "Domain expert"
129
+ model: anthropic/claude-sonnet-4-5
130
+ prompt: "You are a domain specialist..."
131
+
132
+ categories:
133
+ my-domain:
134
+ description: "Domain-specific tasks"
135
+ ```
136
+
137
+ ### Skills (149)
138
+
139
+ Battle-tested development methodologies encoded as `SKILL.md` files with YAML frontmatter. Each skill is a step-by-step instruction set for a specific development domain — from Git workflows to API design to testing strategies.
140
+
141
+ Skills are loaded from:
142
+ - `src/features/builtin-skills/skills/` — shipped with the plugin
143
+ - `.opencode/skills/` — project-specific
144
+ - `~/.config/opencode/skills/` — user-global
145
+ - `.claude/skills/` Claude Code compatible
146
+
147
+ ### Background Agents
148
+
149
+ Run multiple agents in parallel with per-provider and per-model concurrency management. Kord fires off exploration tasks to cheaper, faster models while the main agent focuses on implementation.
150
+
151
+ ```json
152
+ {
153
+ "background_task": {
154
+ "defaultConcurrency": 5,
155
+ "providerConcurrency": { "anthropic": 3, "openai": 5 },
156
+ "modelConcurrency": { "anthropic/claude-opus-4-6": 2 }
157
+ }
158
+ }
159
+ ```
160
+
161
+ ## Features
162
+
163
+ Full documentation: [docs/guide/features.md](docs/guide/features.md) | Configuration: [docs/guide/configurations.md](docs/guide/configurations.md)
164
+
165
+ **Summary:**
166
+ - **20+ Specialized Agents** — right model for the right task, full dev team
167
+ - **Squad System** — SQUAD.yaml v2 manifests for domain-specific agent teams
168
+ - **149 Skills** battle-tested development workflows (5 hardcoded + 144 methodology)
169
+ - **Background Agents**parallel async execution with concurrency limits
170
+ - **LSP & AST Tools** structural refactoring, rename, diagnostics, AST-aware search
171
+ - **40+ Lifecycle Hooks** context injection, productivity automation, quality gates, recovery
172
+ - **12 Slash Commands** init-deep, ralph-loop, ulw-loop, refactor, start-work, checkpoint, status, squad, and more
173
+ - **Built-in MCPs** web search (Exa), documentation (Context7), GitHub code search (Grep.app)
174
+ - **Context Injection** auto-inject AGENTS.md, README, conditional rules per directory
175
+ - **Claude Code Compatibility** full compat layer for commands, skills, agents, MCPs, hooks
176
+ - **Todo Enforcer** forces completion, no half-finished work
177
+ - **Comment Checker** prevents AI comment bloat, keeps code human-like
178
+ - **Tmux Integration** visual multi-agent dashboard, watch agents work in parallel
179
+ - **Story-Driven Pipeline** wave/story execution with persistent state
180
+ - **CLI Installer** — interactive setup with project maturity detection and doctor checks
181
+
182
+ ### Commands
183
+
184
+ | Command | Description |
185
+ |---------|-------------|
186
+ | `/init-deep` | Generate hierarchical AGENTS.md files throughout your project |
187
+ | `/ralph-loop` | Self-referential dev loop — runs until task is 100% complete |
188
+ | `/ulw-loop` | Ultrawork loop — ralph-loop with max parallel intensity |
189
+ | `/cancel-ralph` | Cancel active loop |
190
+ | `/refactor` | Intelligent refactoring with LSP, AST-grep, TDD verification |
191
+ | `/start-work` | Start Build agent execution from a Plan-generated plan |
192
+ | `/stop-continuation` | Stop continuation mechanisms for the current session |
193
+ | `/checkpoint` | Trigger a PO checkpoint decision on current execution |
194
+ | `/status` | Show current plan progress, wave, and pending items |
195
+ | `/squad` | Switch active squad context |
196
+ | `/squad-create` | Create a specialized squad for a domain |
197
+ | `/modelconfig` | View and configure model routing per agent |
198
+
199
+ Custom commands: `.opencode/commands/*.md` or `.claude/commands/*.md`
200
+
201
+ ### Hooks (40+)
202
+
203
+ Hooks intercept agent lifecycle events: PreToolUse, PostToolUse, UserPromptSubmit, Stop.
204
+
205
+ | Category | Hooks | Purpose |
206
+ |----------|-------|--------|
207
+ | **Context** | directory-agents-injector, readme-injector, rules-injector, compaction-context-injector | Auto-inject AGENTS.md, README, rules when reading files |
208
+ | **Productivity** | keyword-detector, think-mode, ralph-loop, auto-slash-command | Activate modes (`ultrawork`/`ulw`), think deeply, loop execution |
209
+ | **Quality** | comment-checker, thinking-block-validator, edit-error-recovery | Prevent comment bloat, validate blocks, recover from failures |
210
+ | **Recovery** | session-recovery, context-window-limit-recovery, background-compaction | Handle errors, context limits, auto-compact |
211
+ | **Truncation** | grep-output-truncator, tool-output-truncator | Dynamically truncate output to keep context lean |
212
+ | **Notifications** | auto-update-checker, background-notification, session-notification | Version checks, task completion, OS notifications |
213
+
214
+ Disable specific hooks: `"disabled_hooks": ["comment-checker"]` in config.
215
+
216
+ ### Tools
217
+
218
+ **LSP (IDE Features for Agents)**
219
+
220
+ | Tool | Description |
221
+ |------|-------------|
222
+ | `lsp_diagnostics` | Errors/warnings before build |
223
+ | `lsp_rename` | Rename symbol across workspace |
224
+ | `lsp_goto_definition` | Jump to definition |
225
+ | `lsp_find_references` | Find all usages |
226
+ | `lsp_symbols` | File outline or workspace search |
227
+
228
+ **AST-Grep** `ast_grep_search` and `ast_grep_replace` for pattern search/replace across 25 languages.
229
+
230
+ **Delegation** — `task` (category-based routing: visual, business-logic, custom), `call_kord_agent` (direct spawn with `run_in_background`), `background_output` / `background_cancel`.
231
+
232
+ **Session** — `session_list`, `session_read`, `session_search`, `session_info` for browsing agent session history.
233
+
234
+ **Interactive Terminal** `interactive_bash` for tmux-based TUI apps (vim, htop, pudb).
235
+
236
+ ### MCPs (Built-in)
237
+
238
+ | MCP | Purpose |
239
+ |-----|--------|
240
+ | **websearch** | Real-time web search (Exa AI) |
241
+ | **context7** | Official documentation lookup for any library/framework |
242
+ | **grep_app** | Code search across public GitHub repos |
243
+
244
+ Skills can embed their own MCP servers via YAML frontmatter, including OAuth-protected remote MCPs with full RFC compliance.
245
+
246
+ ### Context Injection
247
+
248
+ - **AGENTS.md** — auto-injected when reading files (walks file directory → project root, collecting all AGENTS.md)
249
+ - **README.md** — directory context injection
250
+ - **Conditional rules** — `.claude/rules/*.md` with glob patterns and `alwaysApply`
251
+
252
+ ### Claude Code Compatibility
253
+
254
+ Full compatibility layer for Claude Code configurations:
255
+
256
+ | Type | Locations |
257
+ |------|----------|
258
+ | **Commands** | `~/.claude/commands/`, `.claude/commands/` |
259
+ | **Skills** | `~/.claude/skills/*/SKILL.md`, `.claude/skills/*/SKILL.md` |
260
+ | **Agents** | `~/.claude/agents/*.md`, `.claude/agents/*.md` |
261
+ | **MCPs** | `~/.claude/.mcp.json`, `.mcp.json` (with `${VAR}` expansion) |
262
+ | **Hooks** | `settings.json` hook execution |
263
+
264
+ Toggle features: `"claude_code": { "mcp": false, "commands": false, ... }` in config.
265
+
266
+ ## Configuration
267
+
268
+ Config file: `.opencode/kord-aios.json` (project) or `~/.config/opencode/kord-aios.json` (user).
269
+
270
+ JSONC supported comments and trailing commas work.
271
+
272
+ **What you can configure:**
273
+ - Agent models, temperatures, prompts, and tool permissions
274
+ - Background task concurrency per provider/model
275
+ - Disabled hooks, skills, agents
276
+ - Category-based task delegation routing
277
+ - Built-in MCPs (websearch, context7, grep_app)
278
+ - LSP and experimental features
279
+
280
+ ### OpenCode Agent Overrides
281
+
282
+ You can override methodology agents from disk with `.opencode/agents/*.md` and `~/.config/opencode/agents/*.md`.
283
+
284
+ - Agent keys are derived from filename (`course-creator.md` -> `course-creator`).
285
+ - Frontmatter `write_paths` is enforced by `agent-authority` to gate file writes.
286
+ - T0 agents (`kord`, `dev`, `builder`, `planner`) are protected and cannot be overridden from OpenCode agent files.
287
+
288
+ See the full [Configuration Documentation](docs/configurations.md) for details.
289
+
290
+ ## Uninstallation
291
+
292
+ To remove Kord AIOS:
293
+
294
+ 1. **Remove the plugin from your OpenCode config**
295
+
296
+ Edit `~/.config/opencode/opencode.json` (or `opencode.jsonc`) and remove `"kord-aios"` from the `plugin` array:
297
+
298
+ ```bash
299
+ jq '.plugin = [.plugin[] | select(. != "kord-aios")]' \
300
+ ~/.config/opencode/opencode.json > /tmp/oc.json && \
301
+ mv /tmp/oc.json ~/.config/opencode/opencode.json
302
+ ```
303
+
304
+ 2. **Remove configuration files (optional)**
305
+
306
+ ```bash
307
+ rm -f ~/.config/opencode/kord-aios.json
308
+ rm -f .opencode/kord-aios.json
309
+ ```
310
+
311
+ 3. **Verify removal**
312
+
313
+ ```bash
314
+ opencode --version
315
+ # Kord AIOS should no longer be loaded
316
+ ```
317
+
318
+ ## Origin Story
319
+
320
+ I wanted a disciplined way to run AI development workflows without giving up control of models and runtime behavior.
321
+
322
+ OpenCode provided the open, multi-model engine. Kord AIOS adds the orchestration and methodology layer on top: squads, story-driven execution, quality gates, and specialized agents.
323
+
324
+ **Kord AIOS is the result:** structured execution with full control over models, prompts, tools, skills, and squads.
325
+
326
+ ## Contributing
327
+
328
+ See [CONTRIBUTING.md](CONTRIBUTING.md) for development setup, code conventions, and PR guidelines.
329
+
330
+ ## Warnings
331
+
332
+ - Requires OpenCode >= 1.0.150.
333
+ - If you're on [1.0.132](https://github.com/sst/opencode/releases/tag/v1.0.132) or older, an OpenCode bug may break config.
334
+ - [The fix](https://github.com/sst/opencode/pull/5040) was merged after 1.0.132 — use a newer version.