swarm
Search across multiple projects in your organization's swarm. Use when you need cross-project patterns, org-level conventions, shared decisions, or want to know how other projects solved a problem. Complements the oak (team) skill which covers single-project knowledge. Also use when the user mentions swarm_search, swarm_fetch, swarm_nodes, swarm_status, or asks about what other teams/projects have done, cross-project dependencies, org-wide patterns, or collective knowledge across the organization.
Best use case
swarm is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Search across multiple projects in your organization's swarm. Use when you need cross-project patterns, org-level conventions, shared decisions, or want to know how other projects solved a problem. Complements the oak (team) skill which covers single-project knowledge. Also use when the user mentions swarm_search, swarm_fetch, swarm_nodes, swarm_status, or asks about what other teams/projects have done, cross-project dependencies, org-wide patterns, or collective knowledge across the organization.
Teams using swarm should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/swarm/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How swarm Compares
| Feature / Agent | swarm | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Search across multiple projects in your organization's swarm. Use when you need cross-project patterns, org-level conventions, shared decisions, or want to know how other projects solved a problem. Complements the oak (team) skill which covers single-project knowledge. Also use when the user mentions swarm_search, swarm_fetch, swarm_nodes, swarm_status, or asks about what other teams/projects have done, cross-project dependencies, org-wide patterns, or collective knowledge across the organization.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
# Swarm
The swarm is a federation of teams across your organization. Each team is a
project with its own machine and developer nodes — its own memories, sessions,
plans, and codebase knowledge. The swarm connects these teams so you can search
and retrieve knowledge from all of them at once.
Use MCP tools (`swarm_search`, `swarm_fetch`, `swarm_nodes`, `swarm_status`)
to access collective knowledge. If MCP tools are not available, fall back to
the CLI commands shown below.
## Architecture at a Glance
```
Organization Swarm
├── Team A (this project)
│ ├── Node: developer laptop
│ └── Node: CI server
├── Team B (api-service)
│ └── Node: developer laptop
└── Team C (mobile-app)
├── Node: developer laptop
└── Node: staging server
```
- **Swarm** = organization-level federation of teams
- **Team** = a single project (has its own `.oak/ci/activities.db`)
- **Node** = a machine running the team daemon within a project
The swarm aggregates knowledge across teams. The team federates tool calls
across nodes within one project. This skill is for the swarm layer.
## When to Use Swarm vs Team
| Question | Use Team (`oak`) | Use Swarm |
|----------|------------------|-----------|
| How does auth work in *this* project? | `oak_search` | |
| How do we handle auth *across* projects? | | `swarm_search` |
| What patterns exist org-wide for error handling? | | `swarm_search` |
| What was decided about *our* API design? | `oak_search` | |
| What API conventions do other teams follow? | | `swarm_search` |
| What depends on this module locally? | `oak_context` | |
| Which other projects depend on our shared library? | | `swarm_search` |
**Rule of thumb:** Team = "this project", Swarm = "the organization".
## Quick Start
### Search then Fetch (primary workflow)
The two-step pattern keeps responses focused — search returns summaries with
IDs, fetch returns full content for the items you care about.
```
# 1. Search across all connected teams
swarm_search(query="retry with exponential backoff", search_type="memory")
# 2. Get full details for specific results
swarm_fetch(ids=["chunk-id-from-search"], project_slug="api-service")
```
### Discover connected teams
```
swarm_nodes()
```
Returns each team's project slug, connection status, and capabilities.
### Check connectivity
```
swarm_status()
```
Returns whether this node is connected to the swarm, the swarm ID, and
peer count.
## Tool Reference
| MCP Tool | Purpose | Key Args |
|----------|---------|----------|
| `swarm_search` | Search memories, sessions, plans across all teams | `query`, `search_type` (`all`/`memory`/`sessions`/`plans`), `limit` |
| `swarm_fetch` | Get full details for search result IDs | `ids` (list of chunk IDs), `project_slug` |
| `swarm_nodes` | List connected teams and their capabilities | (none) |
| `swarm_status` | Check swarm connection health | (none) |
### Search Types
- `all` — everything (default, good starting point)
- `memory` — observations, decisions, gotchas, discoveries across teams
- `sessions` — session summaries from other projects
- `plans` — planning documents and architectural decisions
Code search is NOT available via swarm. Use `oak_search` (team skill) for
code search within the current project.
### CLI Fallback
If MCP tools are unavailable, use the CLI:
```bash
# Search across the swarm
oak-dev swarm search "retry with exponential backoff" --type memory
# List connected teams
oak-dev swarm nodes
# Check connectivity
oak-dev swarm status
```
## Common Patterns
### Find how other teams solved a problem
```
swarm_search(query="database migration strategy", search_type="all")
# Review results, then fetch the most relevant
swarm_fetch(ids=["<id>"], project_slug="<project>")
```
### Discover org-wide conventions
```
swarm_search(query="error handling conventions", search_type="memory")
```
### Check cross-project impact before a breaking change
```
swarm_search(query="shared authentication service", search_type="memory")
```
### Find decisions made by other teams
```
swarm_search(query="chose PostgreSQL over MongoDB", search_type="memory")
```
### Understand what a team has been working on
```
swarm_search(query="recent refactoring", search_type="sessions")
```
## Tips
- **Start broad, narrow down.** Use `search_type="all"` first. If results
are noisy, switch to `memory` or `sessions`.
- **Use project_slug from results.** Search results include the originating
project — pass it to `swarm_fetch` to get full details.
- **Check nodes first if search returns nothing.** Run `swarm_nodes()` to
verify teams are connected. If the list is empty, the swarm may not be
configured or the daemon may be offline.
- **Combine with team skill.** Use swarm to find cross-project patterns, then
use `oak_search` to find the local implementation of that pattern.Related Skills
swarm-report
Generate a cross-project comparative report from your organization's swarm. Use when you need an overview of all connected projects, want to compare activity levels, find shared patterns, or identify collaboration opportunities across teams. Also use when the user asks for a "swarm report", "cross-project analysis", "org overview", or wants to understand how projects relate to each other. Requires an active swarm connection.
playwright-cli
Automates browser interactions for web testing, form filling, screenshots, and data extraction. Use when the user needs to navigate websites, interact with web pages, fill forms, take screenshots, test web applications, or extract information from web pages.
project-governance
Create and maintain project constitutions and agent instruction files. Use when establishing coding standards, adding project rules, creating agent guidance files, syncing rules across agents, or improving AI agent consistency. Also supports RFC/ADR documents for formalizing technical decisions that feed into the constitution.
pattern-finder
Find recurring code patterns, architectural decisions, and shared conventions across projects in your organization's swarm. Use when you want to discover what patterns other teams use, find candidates for shared libraries, or standardize approaches across the org. Also use when the user asks to "find patterns across projects", "what conventions do other teams follow", "shared code opportunities", or anything about org-wide code reuse. Requires an active swarm connection.
oak
Find out what happened, what was decided, and what depends on what in your codebase. Use this skill whenever you need to: recall past decisions or discussions ("what did we decide about X?"), check what might break before refactoring ("what depends on this module?"), find conceptually similar code that grep would miss ("all the retry/backoff logic"), look up past bugs, gotchas, or learnings, query session history or agent run costs, store observations about the codebase, or understand how components connect end-to-end. Powered by semantic search, memory lookup, and direct SQL against the Oak CI database (.oak/ci/activities.db). Also use when the user mentions oak_search, oak_context, oak_remember, oak_resolve_memory, or asks to run queries against activities.db or oak.
dependency-audit
Audit dependencies across projects in your organization's swarm. Use when you need to find version conflicts, outdated packages, or security risks across teams. Also use when the user asks for a "dependency audit", "version check across projects", "package alignment", or wants to standardize dependencies org-wide. Requires an active swarm connection.
context-engineering
Design effective prompts and optimize context for AI models and agents. Covers prompt engineering foundations (clarity, examples, chain of thought, XML structure), the four context engineering strategies (Write, Select, Compress, Isolate), agent memory and session patterns, and before/after examples showing measurable improvement. Use when writing system prompts, designing agent workflows, optimizing context windows, building prompt templates, structuring few-shot examples, reducing context rot, or improving AI output quality.
deft-directive-swarm
Parallel local agent orchestration. Use when running multiple agents on vBRIEF stories simultaneously — to scan active/ for allocatable work, set up isolated worktrees, launch agents with proven prompts, monitor progress, handle stalled review cycles, and close out PRs cleanly.
swarm
N coordinated agents on shared task list with SQLite-based atomic claiming
code-review-swarm
Deploy specialized AI agents to perform comprehensive, intelligent code reviews that go beyond traditional static analysis
coordinate-swarm
Apply collective intelligence coordination patterns — stigmergy, local rules, and quorum sensing — to organize distributed systems, teams, or workflows without centralized control. Covers signal design, agent autonomy boundaries, emergent behavior cultivation, and feedback loop tuning. Use when designing distributed systems without a coordination bottleneck, organizing teams that must self-coordinate, building event-driven architectures with shared state communication, or replacing fragile centralized orchestration with resilient emergent coordination.
swarm-status
Display comprehensive status dashboard for a swarm team