agentleFS
ryanmacleanryanmaclean/skills/preflight/SKILL.md

preflight

Skill1 starsChanged 2 months agoMITView on GitHub

Pre-dispatch quota check showing live utilization across providers (Codex, Auto-Claude, others), recommending the backend with the most headroom — warns above 70%, blocks above 90%. Use before delegating tasks, dispatching agents, or when asked what has capacity.

56 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use perf, repo-audit and 9 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • MicrosoftSkill

    perf

    Speed and memory performance rules for Rust crates, the Node addon, webui-framework, and webui-delivery.

    Also in 3 projects that use this

  • brandonsimpsonSkill

    repo-audit

    Use when asked to audit a repository's health, assess technical debt, evaluate codebase quality end-to-end, or produce a prioritized improvement plan — including "how bad is this code", new-team-takeover or pre-acquisition reviews, and periodic engineering health checks. Analysis-only; never modifies code.

    Also in 3 projects that use this

  • asterkinSkill

    adr

    Create Architecture Decision Records (ADRs) following project standards. Guides template usage, process, and best practices for documenting architecturally significant decisions.

    Also in 4 projects that use this

  • BerryKuipersSkill

    scaffold

    Detect project stack, apply architecture patterns, wire quality gates, and scaffold features. Use when bootstrapping a project, adding a vertical slice, wiring CI/CD, adding Docker compose, or setting up quality gates.

    Also in 3 projects that use this

  • nicepkgSkill

    team

    根据任务快速组建临时 AI Agent 团队协作。自动从 .claude/agents/ 中选择最合适的成员组队。

    Also in 3 projects that use this

  • dirienSkill

    decide

    Three-agent adversarial debate protocol for strategic decisions. Two advocates steelman opposing positions while a moderator identifies risks and synthesizes a binding consensus. Use when choosing between alternatives, evaluating tradeoffs, or making high-stakes decisions.

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

8 rules. 0 are common, 7 are distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 50 edited versions we read keep these.

  • 7

    Distinctive

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Run this before delegating batches of tasks to Codex, Auto-Claude, or any agent backend.

    line 17
  2. Distinctive:

    If any critical provider is >90%, warns before proceeding

    line 33
  3. Distinctive:

    Claude 5h >80%: Avoid spawning more Claude Code subagents.

    line 46
  4. Distinctive:

    Both constrained: Do small tasks directly; defer large batches

    line 47
  5. Distinctive:

    When this skill is invoked:

    line 52
  6. Very specific:

    Run nu ~/.claude/skills/providers/providers.nu --json via Bash tool

    line 54
  7. Distinctive:

    If the user mentioned a task count (e.g.

    line 59
  8. Distinctive:

    Do NOT just print raw numbers — give an actionable recommendation

    line 61

“Common” is measured: kept by at least 6 in 10 of the 50 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

preflight — Pre-Dispatch Quota Check

Run this before delegating batches of tasks to Codex, Auto-Claude, or any agent backend. Shows live utilization and recommends the best backend for the planned work.

Usage

/preflight
/preflight 5          # planning to dispatch 5 specs
/preflight 10 codex   # planning 10 codex tasks specifically

What it does

  1. Reads live quota from ~/.claude/skills/providers/providers.nu --json
  2. Evaluates each provider against thresholds (green <70%, yellow 70-90%, red >90%)
  3. Recommends backend routing based on remaining capacity
  4. If any critical provider is >90%, warns before proceeding

Thresholds

LevelUsageAction
Green<70%Proceed freely
Yellow70-90%Prefer cheaper model (Haiku over Sonnet, Haiku over Codex)
Red>90%Do task directly or use Ollama; avoid spawning agents

Backend routing rules

  • Codex session >80%: Switch to Auto-Claude (Haiku) for simple tasks
  • Claude 5h >80%: Avoid spawning more Claude Code subagents; use Codex or Ollama
  • Both constrained: Do small tasks directly; defer large batches
  • All green: Proceed with planned dispatch

Instructions for Claude

When this skill is invoked:

  1. Run nu ~/.claude/skills/providers/providers.nu --json via Bash tool
  2. Parse the JSON and evaluate thresholds
  3. Print a concise summary table with color-coded status
  4. State clearly: which providers are constrained, which are free
  5. Recommend: what backend to use for the planned work
  6. If the user mentioned a task count (e.g. "/preflight 5"), estimate whether quota covers it and at what cost (Codex session burns faster than weekly)
  7. Do NOT just print raw numbers — give an actionable recommendation

Example output

Provider         Usage    Status   Reset
──────────────────────────────────────────
Claude 5h        44%      ✓ green  2h 47m
Claude 7d        61%      ✓ green  127h
Claude 7d sonnet 70%      ⚠ yellow 129h
Codex session    21%      ✓ green  12m
Codex weekly     32%      ✓ green  95h

Recommendation: All green. Codex session resets in 12m — if dispatching >3 specs,
wait 12 minutes to start with a fresh session budget. Proceed freely otherwise.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.