antigravity-swarm
Deploys autonomous sub-agents to perform tasks in the Antigravity IDE. Supports both manual dispatch and dynamic "Auto-Hiring" of agent teams.
- License 许可
- MIT
- 最近更新
- 2026-10-14
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- antigravity-swarm
- description
- Deploys autonomous sub-agents to perform tasks in the Antigravity IDE. Supports both manual dispatch and dynamic "Auto-Hiring" of agent teams.
02 资源文件 27
- 参考文档.gemini-extension-install.json81 B
- 其他.gitignore662 B
- 参考文档GEMINI_example.md455 B
- 参考文档gemini-extension.json210 B
- 许可证LICENSE1.0 KB
- 参考文档package.json360 B
- 参考文档README_KO.md22.4 KB
- 参考文档README.md20.7 KB
- 参考文档requirements.txt25 B
- 脚本scripts/compactor.py2.8 KB
- 脚本scripts/core/__init__.py57 B
- 脚本scripts/core/audit.py4.4 KB
- 脚本scripts/core/backends/__init__.py603 B
- 脚本scripts/core/backends/base.py1023 B
- 脚本scripts/core/backends/thread_backend.py2.3 KB
- 脚本scripts/core/backends/tmux_backend.py6.8 KB
- 脚本scripts/core/config.py3.3 KB
- 脚本scripts/core/mailbox.py7.3 KB
- 脚本scripts/core/mission.py3.0 KB
- 脚本scripts/core/types.py2.6 KB
- 脚本scripts/dispatch_agent.py25.0 KB
- 脚本scripts/mock_gemini_timeout.sh55 B
- 脚本scripts/orchestrator.py51.8 KB
- 脚本scripts/planner.py17.5 KB
- 脚本scripts/reporter.py3.3 KB
- 脚本scripts/ultrawork_loop.py3.0 KB
- 参考文档swarm-config.yaml1.3 KB
03 SKILL.md 正文
Antigravity Subagents Skill
This skill allows you to dispatch autonomous sub-agents to perform tasks.
It features a Manager layer (planner.py) that can automatically design a team of agents for a complex mission, and an Orchestrator (orchestrator.py) to run them visually.
Both scripts include a Plan Mode (confirmation step) by default to prevent accidental usage limits consumption.
[!WARNING] Do NOT modify files in this directory while the Orchestrator is running. The system actively reads and writes to
task_plan.md,findings.md, andsubagents.yaml. Manual edits during execution may cause race conditions or inconsistent agent behavior.
🛠 Tools
dispatch_subagent
Runs a sub-agent with a specific task.
Usage: Use this when you have a parallelizable task or need to offload a specific job (e.g., "Write a test file", "Analyze this directory").
Arguments:
task: A clear, self-contained description of what the sub-agent should do.
Implementation Details:
The sub-agent is powered by the gemini CLI. A Python wrapper intercepts specific output patterns to perform file system operations and command executions.
Syntax used by Sub-Agent (Handled Automatically):
<<WRITE_FILE path="...">>...<<END_WRITE>><<RUN_COMMAND>>...<<END_COMMAND>>
run_mission (Dynamic Orchestration)
Analyzes a high-level goal, hires a custom team of sub-agents, and creates a configuration for them.
Usage: Use this for complex, multi-step projects where you don't want to manually define every sub-agent.
Arguments:
mission: A description of the overall project (e.g., "Create a Snake game in Python").
How it works:
- Calls
scripts/planner.pyto generatesubagents.yaml. (Will prompt for confirmation unless--yesis used). - (Optional) You can then run
scripts/orchestrator.pyto execute the team. (Will prompt for confirmation unless--yesis used).
Usage Modes
Mode 1: CLI User (Terminal Visualization)
Run the Python orchestrator in your terminal to see a TUI.
python scripts/orchestrator.py
Mode 2: IDE Agent (Chat Visualization)
As an Agent, you act as the Orchestrator.
- Spawn: Use
run_commandto launch sub-agents in the background. Use--format jsonfor logs.python scripts/dispatch_agent.py "Task A" --log-file logs/agent_a.json --format json & python scripts/dispatch_agent.py "Task B" --log-file logs/agent_b.json --format json & - Monitor: Poll the JSON log files to check for
{"type": "status", "content": "completed"}. - Visualize: Render a Markdown dashboard in your chat response to the user.
🚀 Examples
1. Manual Dispatch (Single Agent)
run_command("python3 scripts/dispatch_agent.py 'Create a file named hello.py that prints Hello World'")
2. Auto-Hire a Team (Mission Mode)
# 1. Generate the team
run_command("python3 scripts/planner.py 'Create a fully functional Todo List app in HTML/JS'")
# 2. Run the team
run_command("python3 scripts/orchestrator.py")
[!WARNING] You must use
gemini-3-proorgemini-3-flash. Deprecated or older models may not support the file shim protocol correctly.
❓ FAQ & Philosophy
Why Sub-agents?
- Context Isolation: Prevents "Context Contamination." A UI Specialist doesn't need to see specific Database Migration code. Separation ensures higher accuracy.
- Scalability: While loop-based agents process sequentially, Sub-agents are architected to run in parallel threads.
- Fault Tolerance: If one sub-agent fails (e.g., Syntax Error), it doesn't crash the entire mission; the Orchestrator can retry just that agent.
Is this truly parallel?
Yes. orchestrator.py uses Python's threading.Thread to spawn separate OS processes for each agent.
Note: You may perceive sequential behavior if the underlying gemini CLI tool enforces a global lock or if you hit API Rate Limits.
Planning with Files (Manus Protocol)
This skill adheres to the "Manus" state management philosophy. All agents operate on a shared set of "Memory Files" in the root of the workspace:
task_plan.md: The Source of Truth for the mission checklist.findings.md: A shared scratchpad for discoveries and research.progress.md: A log of completed steps and current status.
04 同仓库更多 Skills
blocked-page-recovery
Use when a fetch fails: 403/429, paywall, WAF, bot wall.
gemini-vision-fallback
Vision fallback: Gemini REST API if vision_analyze blocked.
twitter-cli
Use twitter-cli for ALL Twitter/X operations — reading tweets, posting, replying, quoting, liking, retweeting, following, searching, user lookups. Invoke whenever user requests any Twitter interaction.
prism-scan
Structural analysis through dynamically generated cognitive lenses. Generates the optimal analytical lens for the specific code/artifact, then executes it. Finds conservation laws, structural invariants, and concrete bugs that vanilla analysis misses. Use on any code file, system design, or text artifact.
prism-reflect
Constraint transparency: analyzes an artifact structurally, then analyzes what its own analysis concealed. Produces a conservation law AND a constraint report showing what was maximized, what was sacrificed, and what to investigate next. The only AI skill that knows what it can't see.
prism-full
Full Prism: multi-pass structural analysis with mandatory adversarial self-correction. Designs custom analytical passes, executes them with chaining, then attacks its own findings before synthesizing. Use for maximum depth on important code or artifacts.