Skip to content
Agentmart
Submit a tool

swarm_query

Read-only cross-project state aggregation for L1 visibility.

Skill by ollieb89

IndexedMIT
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/ollieb89-swarm-query

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Read-only cross-project state aggregation for L1 visibility. Enables ClawdiaPrime to query project status, detect bottlenecks, and monitor swarm health without modifying state.

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found
Runs as
Python package

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/swarm-query

What's inside

Skill name
swarm_query
Description
Read-only cross-project state aggregation for L1 visibility. Enables ClawdiaPrime to query project status, detect bottlenecks, and monitor swarm health without modifying state.
License
MIT
Instructions
67 lines in SKILL.md · view on GitHub

Before installing

  • Ships executable scripts

Agent Skills spec issues

  • name: only lowercase letters, digits and single hyphens allowed

Files (6)

  • SKILL.md
  • __init__.py
  • __main__.py
  • query.py
  • __init__.py · tests/
  • test_query.py · tests/

SKILL.md (first lines)

# SKILL: Swarm Query

## Purpose
Provide ClawdiaPrime (L1) with read-only visibility into the entire swarm's operational state across all managed projects.

## Capabilities

### Queries

1. **get_swarm_overview()** - Aggregate status across all projects
   - Total active/queued/completed/failed tasks
   - Project health scores
   - Bottleneck detection

2. **get_project_status(project_id)** - Detailed single project view
   - Active task count and list
   - Recent activity timeline
   - L3 container status

3. **find_stalled_tasks(threshold_minutes)** - Detect stuck work
   - Tasks with no activity for N minutes
   - Potential recovery candidates

4. **get_health_score(project_id)** - Compute project health (0.0-1.0)
   - 1.0 = healthy, 0.0 = critical
   - Based on load, backlog, failures, staleness

## Safety

- **Read-only**: Uses `LOCK_SH` (shared lock) — never blocks L2/L3 writes
- **Cache**: 5-second TTL prevents state file thrashing
- **Graceful degradation**: Returns partial results if projects are unreachable

## Usage

### Python API
```python
from agents.clawdia_prime.skills.swarm_query import SwarmQuery

query = SwarmQuery()
overview = query.get_swarm_overview()
print(f"Total active: {overview.total_active}")
print(f"Bottlenecks: {overview.bottleneck_projects}")
```

### CLI
```bash
python -m agents.clawdia_prime.skills.swarm_query overview
python -m agents.clawdia_prime.skills.swarm_query status --project main
python -m agents.clawdia_prime.skills.swarm_query stalled --threshold 30
```

### Natural Language
When ClawdiaPrime receives queries like:
- "What's the status of all projects?"
- "Which projects need attention?"
- "Show me stalled tasks"

...the skill aggregates and formats the response.

## Dependencies

- `openclaw.state_engine:JarvisState` - for state file reading
- `openclaw.config:get_state_path` - for project state path resolution
- `openclaw.project_config:get_project_config` - for project registry

From ollieb89/openrepo, MIT.

More from ollieb89/openrepo

Signals

Stars
0
Forks
1
Open issues
0
Last commit (this folder)
Mar 2, 2026 (8 months ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from ollieb89

Cite this page

swarm_query skill. Agent Mart. https://agentmart.dev/skills/ollieb89-swarm-query (last updated 2026-10-24)