git clone --depth 1 https://github.com/jeremylongshore/tons-of-skills-marketplace /tmp/background && cp -r /tmp/background/plugins/ai-agency/hyperflow/skills/background ~/.claude/skills/backgroundSKILL.md
# Background Read-only-by-default management interface for background agents fired by other hyperflow skills (dispatch quality gates, deploy CI watcher, scaffold analysis refresh, cache compact, scope speculative prefetch). Reads from `.hyperflow/background/registry.json` + per-agent output buffers. Full doctrine: [background-agents.md](../hyperflow/background-agents.md). ## Subcommands | Subcommand | Description | |---|---| | `list` | Print the registry: in-flight · completed-uncollected · stalled · errored | | `show <id>` | Print one agent's output buffer (`.hyperflow/background/<id>.md`) | | `cancel <id>` | Cancel one specific in-flight agent | | `cancel --all` | Cancel every in-flight agent (use before closing a session) | | `prune` | Delete completed `.hyperflow/background/<id>.md` files older than 7 days | Default subcommand when none provided: `list`. ## Subcommand Details ### `list` Read `.hyperflow/background/registry.json`. Group entries by status and print a compact table: ```markdown ## In flight (N) | ID | Purpose | Fired | Timeout | Blocks | |-----------------------------------|--------------------------------------|------------|---------|---------| | `bg-1718049600-quality-gates-b2` | Layer 5 gates Batch 2 | 17:30 | 18:00 | step3 | | `bg-1718049820-ci-watcher` | GitHub Actions watch for v4.7.0 | 17:33 | 18:33 | — | ## Completed (uncollected, N) | ID | Purpose | Completed | Duration | Output | |-----------------------------------|--------------------------------------|------------|----------|--------| | `bg-1718045400-scaffold-refresh` | Refresh .hyperflow/architecture.md | 16:42 | 2m 18s | 1.4kb | ## Stalled / Errored (N) | ID | Purpose | Status | Reason | |-----------------------------------|--------------------------------------|-------------------|-------------------| | `bg-1717980000-cache-compact` | Compact learnings.md | STALLED | timeout (30m) | ``` Print one trailing line: `<count> in flight · <count> uncollected · <count> needs attention`. If registry is empty, print `No background agents.` and stop. ### `show <id>` Read `.hyperflow/background/<id>.md` and print it verbatim. If the agent is still running, print the registry entry first then `Output buffer not yet written.` and stop. ### `cancel <id>` 1. Read registry, find the entry. 2. If `status: running`, signal cancellation per the provider's mechanism (Claude Code: use the runtime's cancellation API for that subagent ID; if unavailable, mark the entry `status: cancelled` and leave the agent to time out on its own — the foreground orchestrator will drop the result on collection). 3. Update registry entry: `status: cancelled`, `cancelled_at: <now>`. 4. Print `Cancelled <id> — <purpose>`. If the agent already completed, print `Agent <id> already <status> — nothing to cancel.` ### `cancel --all` For every entry with `status: running`, run the `cancel` flow. Print summary: `Cancelled N agents.` ### `prune` `find .hyperflow/background/ -name "bg-*.md" -mtime +7 -delete` plus remove their entries from `registry.json` (only entries with `status: complete | error | stalled | cancelled` older than 7 days are pruned). Print: `Pruned N output buffers · N registry entries`. ## Flow 1. Parse subcommand from invocation (default: `list`). 2. Read `.hyperflow/background/registry.json` (if absent, treat as empty). 3. Execute subcommand. 4. Print result. ## Overview `/hyperflow:background` is the user-facing read/manage interface for background agents. The orchestrator itself maintains the registry as a side-effect of `run_in_background: true` Agent dispatches in other skills — this skill never *fires* a background agent, it only reads/manages the registry. ## Prerequisites - `.hyperflow/background/registry.json` exists (created on first background dispatch by any other skill — if absent, all subcommands degrade gracefully). - `.hyperflow/` initialized (run `/hyperflow:scaffold` if missing — though this skill works even without scaffold, since the registry is created on demand). ## Instructions See [Subcommands](#subcommands) and [Subcommand Details](#subcommand-details). Summary: 1. Parse the subcommand (default `list` when none given). 2. Read the registry from `.hyperflow/background/registry.json`. 3. Execute the subcommand against the registry + per-agent output buffers. 4. Print compact result; do not modify any source code. ## Output - `list` — table of in-flight / completed-uncollected / stalled+errored, with one trailing summary line. - `show <id>` — file contents of `.hyperflow/background/<id>.md`. - `cancel <id>` / `cancel --all` — one-line confirmation per cancelled agent + total. - `prune` — count of pruned buffers + registry entries. ## Error Handling | Failure | Behavior | |---|---| | Registry file missing | Treat as empty — `list` prints `No background agents.`; other subcommands print `No registry — fire a background agent first.` and stop. | | Registry JSON malformed | Print `Registry malformed — back up to .hyperflow/background/registry.json.bak and re-create empty.` Move file, write empty registry, continue. | | `show <id>` for unknown id | List 3 closest IDs by Levenshtein distance. | | `cancel <id>` for already-completed agent | Print `Agent <id> already <status> — nothing to cancel.` | | Provider cancellation API unavailable | Mark entry `status: cancelled` in registry; the foreground orchestrator drops the result on collection. Print `Marked <id> as cancelled (provider has no live cancellation API — agent will run to completion or timeout, but result will be discarded).` | | Prune called with no eligible entries | Print `Nothing to prune — no completed buffers older tha
Guard the beads execution record: enforce the write-flush-verify discipline that defeats the bd rapid-write race, audit epic dependency graphs for cycles and orphans, catch closures whose title overstates what shipped, flag open beads carrying no disposition or a disproven premise, and reconcile bd against its GitHub and Plane projections. Owns RECORD INTEGRITY; delegates graph analysis to bead-dependency-mapper and epic-closure drift to bead-epic-auditor rather than duplicating them. Use before closing an epic, after any batch of bd writes, when a bead premise looks stale, or when auditing whether the record matches reality. Trigger with "audit beads", "check the bead DAG", "did that close actually land", "bead hygiene".
Verify every factual assertion in a diff, PR body, commit message, bead note, or governing doc against the actual repository, and fail anything that cannot be substantiated by a command. Use before merging any PR that makes claims about counts, coverage, consumers, enforcement, provenance, or certification, and when auditing standing docs for rot. Trigger with "verify claims", "check this PR body", "is this claim true", "claim audit".
Design and build Omarchy (Quickshell/QML) bar-widget, panel, and service plugins that actually work on a stock install. Knows the hard runtime constraint (no node on the graphical session PATH), the first-party contracts (BarWidget, Panel, KeyboardPanel, PanelKeyCatcher, Service), the curl-from-QML data pattern, FileView persistence, and the marketplace submission bar. Use when starting a new Omarchy plugin, porting a plugin off an external runtime, wiring a service to a bar widget, or deciding how a widget should fetch and persist. Trigger with "build an omarchy plugin", "omarchy widget", "quickshell plugin", "port this plugin to QML".
Audit an Omarchy plugin before it reaches the marketplace: prove it installs and runs on a stock box (no node/python on the session PATH), run the omarchy-submit gate lane, validate on the rig with omarchy-plugin-validate and qmllint, and check the QML security invariants and first-party idiom contracts. Read-only: it reports and blocks, it does not rewrite the plugin. Use before submitting an entry, after any data-layer change, or when a plugin works on the dev box and you need to know whether it works for a real user. Trigger with "audit this omarchy plugin", "is this plugin submission ready", "will this plugin work when installed".
Audit and fix Claude Code SKILL.md files against enterprise compliance standards: frontmatter completeness, required body sections, and style. Use when validating or repairing skills in a plugin directory. Trigger with "audit skill", "fix skill compliance".
Learn how SKILL.md files work in Claude Code plugins, then build a production-quality agent skill from scratch. Covers frontmatter schema, body structure, testing, and iteration.
Step-by-step guide to writing a SKILL.md file for Claude Code. Learn how to plan, structure, and test auto-activating skills with proper frontmatter, allowed-tools, dynamic context injection, and supporting files.
|