agy-native
Run a supplied task in headless AGY (Antigravity, Gemini) and collect its result. Use when: AGY, Antigravity or Gemini is requested by name; never a fallback.
- License 许可
- Apache-2.0
- 最近更新
- 2026-11-11
- Stars
- ★ 1.6k
- Forks
- 474
01 前言 Front Matter
- name
- agy-native
- consumes
- [ "explicit-packet" ]
- metadata
- { "tier": "cross-vendor", "effects": [ "start_agy_session" ], "disposition": "keep_optional_adapter", "capabilities": [ "dispatch_explicit_packet", "provide_fresh_context" ], "dependencies": [], "canonical_status": "canonical" }
- produces
- [ "agy-run-evidence" ]
- practices
- [ "team-topologies", "design-by-contract" ]
- context_rel
- [ { "kind": "separate-ways", "with": "codex-exec" } ]
- description
- Run a supplied task in headless AGY (Antigravity, Gemini) and collect its result. Use when: AGY, Antigravity or Gemini is requested by name; never a fallback.
- hexagonal_role
- driving-adapter
- user-invocable
- true
- output_contract
- AGY runtime evidence
- skill_api_version
- 1
03 SKILL.md 正文
AGY Native
Run a supplied packet in AGY (Antigravity) only when the caller explicitly
selects that runtime. Scope the run to the supplied workspace and packet,
return runtime evidence, and stop. It worked when the command passes an
explicit --print-timeout, the posture is disclosed, and the result says
whether the turn finished instead of reading exit 0 as proof.
Before launch
- Read the live surface. The CLI changes faster than skill text.
Re-checked on 2026-10-25 against AGY 1.4.7.
Run
agy --helpfor flags,agy changelogfor behavior the help omits, andagy modelsfor ids. That list includes Claude and GPT-OSS: a Gemini or cross-family run needs agemini-*id. - Absent means stop. If
agyis missing or its help cannot be read, report the absence and stop. Never fall back silently to Codex, Claude or any other runtime. A fallback the caller named, in advance or after that report, runs only after it, through claude-exec or codex-exec with its own bound, labelled "not an AGY result". Nothing routes work to AGY on its own either. - Set an explicit bound. Print mode (
agy -p/--print) is the headless path, and it has no built-in limit:--print-timeoutdefaults to0, which waits until the turn completes. Pass--print-timeoutfrom the caller's remaining deadline and hold the same bound outside the process. A run stopped at the bound is a timeout, not a result. - Keep author and validator apart. A validator is a new run in a new
conversation, never
-c/--continueor--conversation <author-id>, so its judgment stays fresh. Validators stay read-only and hand judgment to Validate; they never write the core verdict.
Permission posture (disclose it; never assume it)
Name the posture before launch: the flags plus the user and project
settings.json permissions, which headless runs honor (disclose those or say
not inspected). No flag makes file access read-only.
- No posture flag: workspace reads are granted; other actions needing approval
are denied and listed in the JSON
denied_actions. With settings that allow no writes, this is the validator posture. --sandboxrestricts terminal commands only.--mode accept-editsapproves edits and--mode autoedits and safe commands;--mode planis not documented as read-only, and headless runs pass plan review on their own.--dangerously-skip-permissionsapproves every tool call. It and the approving modes need declared effects and caller authorization covering that blast radius.
Before and after the run, take git status --porcelain and
git diff HEAD | shasum in $WORKSPACE, and list the packet directory
$PKT after; a validator's write is out of authority. These miss edits
inside untracked or ignored files and under other --add-dir paths: report
those unchecked.
Command
In an AgentOps source checkout, review runs use REVIEWER=agy (the id in
REVIEWER_MODEL) with codex_exec_guarded from scripts/lib/codex-exec.sh
(call shape in codex-exec). It adds echo,
stall and output-cap handling. Its posture, to disclose, is
--sandbox --dangerously-skip-permissions with --add-dir on its own
private mktemp -d packet directory: every tool call is approved over the
workspace and that directory, so it is not read-only. An installed skill
lacks that library; use this block.
The caller supplies $MODEL, $POSTURE, DEADLINE_EPOCH and absolute
$WORKSPACE, $PROMPT_FILE, $OUT and $ERR paths, the last three outside
$WORKSPACE.
This block passes the packet by path, not inline: a short -p pointer plus
--add-dir on the packet's own directory only, because a large inline prompt
can be dropped while the run still looks scoped. That drop is an earlier-run
observation, not in the 1.4.7 help or changelog. Would verify: a run with an
inline -p prompt over ~100 KB that asks for a marker from its end.
TO=$(command -v timeout || command -v gtimeout) || { echo "no timeout: not launching" >&2; exit 2; }
[ -n "$MODEL" ] || { echo "MODEL unset: pick an id from agy models" >&2; exit 2; }
# DEADLINE_EPOCH: absolute Unix time fixed once by the caller; a later run gets what is left.
case "$DEADLINE_EPOCH" in ''|*[!0-9]*) echo "no deadline: not launching" >&2; exit 2;; esac
for p in "$WORKSPACE" "$PROMPT_FILE" "$OUT" "$ERR"; do case "$p" in /*) ;; *) echo "not absolute: '$p'" >&2; exit 2;; esac; done
remaining=$(( DEADLINE_EPOCH - $(date +%s) ))
pt=$(( remaining - 15 )) # AGY's bound fires first; 0 would mean no limit
[ "$pt" -gt 0 ] || { echo "deadline too close; not launched" >&2; exit 124; }
PKT=$(mktemp -d) && cp "$PROMPT_FILE" "$PKT/packet.md" || exit 2 # not $TMPDIR itself
cd "$WORKSPACE" || exit 2
# POSTURE: Bash array of the flags chosen above; empty is the default posture.
set -o pipefail # bash and zsh: $? is the failing stage, not head's
start=$(date +%s)
"$TO" -k 10 "$remaining" \
agy --print-timeout "${pt}s" --model "$MODEL" --output-format json \
"${POSTURE[@]}" --add-dir "$PKT" \
-p "Read the task packet at $PKT/packet.md and do what it describes." \
</dev/null 2>"$ERR" | head -c 10485760 >"$OUT"
rc=$?; elapsed=$(( $(date +%s) - start )); echo "exit=$rc elapsed=${elapsed}s pt=${pt}s"
Flags after -p <prompt> are parsed (1.4.7: a bad value there exits 2).
--print-timeout needs a unit such as 300s; a bare number or an
unknown flag exits 2. If the host shell tool's cap is under
remaining plus 10 s, handle it as claude-exec does.
Did it finish? Exit 0 is not proof: an expired --print-timeout returns
partial output, exits 0 and warns on stderr. The 1.4.11 changelog adds a JSON
finished_reason (print_timeout, interrupted or error; omitted for a
finished turn); 1.4.7 lacks it. There, exit 0 with elapsed under pt was
not cut by that bound; at pt or later it is that timeout or a finished turn
whose background tasks held the run to the bound, so read $ERR. Judge a
finished turn by the expected artifact and the workspace snapshots, else say
unknown. Exit 3 with an AGY_ERROR: line is a model or agent error; other
non-zero is a failed run; 124, or 137 after the grace, is the outer bound.
Output repeating the packet or pointer is an echo. An $OUT of exactly
10 MiB was cut; its status is the closed pipe.
Return
command: exact argv (prompt by reference)
posture: flags used; settings permissions, or "settings not inspected"
model: requested id; observed model if AGY reported one, else unknown
conversation: id AGY reported, else unknown
bound: --print-timeout value, the outer deadline and elapsed seconds
outcome: exit status; finished | timed out (which bound) | echo | unknown | not run
denied_actions: list from the JSON output, else none reported
artifacts: output path, bytes, truncated yes|no; changed-file paths
Installation, plugin mutation and recurring scheduling need separate explicit authorization.
04 同仓库更多 Skills
migrate-to-e2e
Moves an existing Playwright, Cypress, Selenium, Appium, Detox, Maestro, or TesterArmy suite to e2e one slice at a time, with the old suite running beside the new one until each ported test is proven. Keeps a MIGRATION.md progress file so any later session resumes where the last stopped. Optionally plants a defect to show both suites catch it. Use for /migrate-to-e2e, "migrate our tests to e2e", "port these Maestro flows", "move our TesterArmy tests", or when a project has an e2e config and an older suite still running.
e2e
Writes, runs, and debugs end-to-end tests for web and mobile apps with e2e, the agentic test runner, which mixes agent.act goals with exact locator assertions on a Playwright browser or an iOS or Android device. Also drives a project's running app live over the e2e MCP server to look at a screen, check a UI change, take a screenshot or record a video, and try a locator; and runs bug bashes, parallel e2e explore runs with each bug proven by a repro test. Use when a project depends on e2e or has an e2e.config.ts, when asked for end-to-end, browser, mobile, or agentic UI tests, to check a change in the running app, to QA or bug bash an app or branch, or when an e2e run fails.
create-verification-skill
Generate a project-local verify-<app> skill on top of e2e, so any coding agent can launch the app, check it is worth driving, exercise a feature the way a user does, keep evidence, and bug bash it. Writes the skill, a feature map with one explore charter per feature, and proves it once. Use for /create-verification-skill, "make a verification skill for this repo", or when a project has no scripted way to prove UI behavior.
deja-search
deja-vu memory — search the user's past AI coding sessions with the deja CLI. Holds what they already settled and never wrote into the repo (naming rules, banned or already-tried tools, required checks before merge, preferred values, who owns what). Use before your first edit in a task, before you call a change done or ready to merge, before you recommend a tool, library, design or reviewer, before re-debugging an error that may already be solved, when they say 'didn't we fix this before', 'what did we decide about X' or 'I already have that', and before telling them something on this machine does not exist.
deja-reflect
End-of-session reflection and memory curation with deja-vu. Review what was decided, what commands broke and what repaired them, and record durable project rules or decisions with deja remember so the next session starts with them.
revid
Make, edit, export and post AI videos with Revid (revid.ai) through the Revid MCP server. Use whenever the user wants a short-form or long-form video made (from an idea, a script, a URL, an article, a PDF, a tweet, a product page, their own clips, or a song), wants to find what is going viral on TikTok, YouTube, Instagram or X before making something, wants to edit or re-export an existing Revid project, generate a standalone AI image or clip, make a series episode, or publish and schedule a finished video to connected social accounts. Covers setup (hosted MCP with OAuth, or an API key), the 36 tools, credits, polling and the rules for publishing. Routes to the more specific revid-* skills when one fits.