Ao spawn gate

From jleechanorg/claude-commands · View interactive version

Ao spawn gate is an AI agent skill from the GitHub repository jleechanorg/claude-commands. Pre-spawn checklist for Agent Orchestrator worker dispatch.

How to use this skill

Skill file

ao-spawn-gate

Pre-spawn checklist for AO worker dispatch. Run this before approving any new worker spawn.

Required checks (in order)

  1. GitHub rate limits, when the task needs GitHub API calls
gh api rate_limit
  1. Active AO worker count
ao session ls
  1. Available context check (avoid spawning if there is no actionable context)
# Verify there is a concrete task / PR / issue context
ao status --project "$AO_PROJECT"
ao session ls

Thresholds / gate rules

does not block a spawn or unrelated work; choose REST only for an operation

it supports and when its own bucket is available.

in ~/.claude/skills/github-cli-reference/SKILL.md where the operation

permits it. A REST fallback applies only to the specific operation; it does

not authorize write operations or retry uncertain mutations.

~/.claude/skills/ao-spawn-safety/SKILL.md. Count workers from `ao session

ls`, not tmux. At the cap, defer only the new AO spawn; do not run cleanup,

kill sessions, or raise the cap automatically. Continue independent work.

report the missing context as the dependency.

REST fallback commands

# Create PR — only when the current task explicitly authorizes PR creation.
# Resolve existing state before retrying an uncertain mutation.
gh api "repos/${AO_GITHUB_REPO:?set AO_GITHUB_REPO=owner/repo}/pulls" --method POST \
  -f title='[agento] ...' -f head='branch-name' -f base='main' -f body='...'

# Comment on PR — only when the current task explicitly authorizes sending it.
gh api "repos/${AO_GITHUB_REPO:?set AO_GITHUB_REPO=owner/repo}/issues/<PR_NUMBER>/comments" --method POST \
  -f body='...'

# Get PR details
gh api "repos/${AO_GITHUB_REPO:?set AO_GITHUB_REPO=owner/repo}/pulls/<PR_NUMBER>"

Approval output format

When reporting a spawn decision, include:

If blocked, include the exact blocker and retry trigger.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.