Skip to content

docs(agents): add gator launch skill#2203

Open
johntmyers wants to merge 5 commits into
mainfrom
feat/launch-openshell-gator-skill
Open

docs(agents): add gator launch skill#2203
johntmyers wants to merge 5 commits into
mainfrom
feat/launch-openshell-gator-skill

Conversation

@johntmyers

Copy link
Copy Markdown
Collaborator

Summary

Add a main repository skill for launching and supervising OpenShell gator agents through scripts/agents/run.sh.

Related Issue

N/A

Changes

  • Added .agents/skills/launch-openshell-gator/SKILL.md with preflight, launch, monitoring, restart, and troubleshooting workflows.
  • Documented the skill in the CONTRIBUTING.md agent skills inventory.

Testing

  • git diff --check passes
  • mise run pre-commit passes
  • Unit tests added/updated (not applicable)
  • E2E tests added/updated (not applicable)

Checklist

  • Follows Conventional Commits
  • Commits are signed off (DCO)

Signed-off-by: John Myers <johntmyers@users.noreply.github.com>
pimlock
pimlock previously approved these changes Jul 9, 2026

@pimlock pimlock left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚢

Couple of nits, around how this skill would be included in the context.

Comment thread .agents/skills/launch-openshell-gator/SKILL.md Outdated
Comment thread .agents/skills/launch-openshell-gator/SKILL.md Outdated
Signed-off-by: John Myers <johntmyers@users.noreply.github.com>
pimlock
pimlock previously approved these changes Jul 9, 2026
Signed-off-by: John Myers <johntmyers@users.noreply.github.com>
pimlock
pimlock previously approved these changes Jul 10, 2026
@drew drew added gator:in-review Gator is reviewing or awaiting PR review feedback and removed gator:in-review Gator is reviewing or awaiting PR review feedback labels Jul 10, 2026
drew
drew previously approved these changes Jul 10, 2026

@drew drew left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Image

@drew drew added the gator:in-review Gator is reviewing or awaiting PR review feedback label Jul 10, 2026
@drew

drew commented Jul 10, 2026

Copy link
Copy Markdown
Collaborator

gator-agent

PR Review Status

Validation: This is a concentrated repository documentation/agent-skill update for launching supervised OpenShell gator agents, so it is project-valid.
Head SHA: 5427f87a50ed877049a44e6b28d24936dd107925

Thanks @pimlock, I checked the trigger-scope and intro concerns you raised. The latest commits removed the broad gateway/model trigger wording and trimmed the extra intro, so that feedback appears addressed.

Review findings:

  • .agents/skills/launch-openshell-gator/SKILL.md:108 and .agents/skills/launch-openshell-gator/SKILL.md:233: the skill shows commands where agents substitute PR/issue/sandbox placeholders directly into shell arguments. Please add an explicit guardrail to normalize PR/issue IDs to digits only and sandbox names to a safe character set such as [A-Za-z0-9_.-]+, and to avoid pasting raw operator text into --name, --from, or numeric placeholders. This avoids command/argument injection risk in the operator workflow.
  • .agents/skills/launch-openshell-gator/SKILL.md:173 and .agents/skills/launch-openshell-gator/SKILL.md:183: the model/image experiment example uses a hard-coded host-specific temp path. Please switch this to a portable generated temp directory, for example tmp_context="$(mktemp -d "${TMPDIR:-/tmp}/gator-codex-XXXXXX")", and pass that path to --from.

Docs: No Fern docs navigation update is needed because this does not change user-facing CLI/API behavior.

Next state: gator:in-review

Signed-off-by: John Myers <johntmyers@users.noreply.github.com>
@johntmyers johntmyers dismissed stale reviews from drew and pimlock via 12ecf38 July 10, 2026 15:46

- Keep normal gator launches supervised: use `--watch --background` and let the in-sandbox supervisor own sleeping and relaunching bounded cycles.
- Do not add passive `sleep` loops in the operator session to watch gator. Check logs or status once, then report the current state or launch a proper watcher outside the model session only when explicitly asked.
- Do not use `--keep` for normal supervised gators. The launcher already keeps watch-mode sandboxes alive through the supervisor.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: I thought that --keep was deprecated / the default. Does that mean that one needs to specify --no-keep explicitly?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, it was deprecated a while ago and just got removed (#2126).

If the intention is for the sandbox to be deleted when the command exits, the --no-keep should be used.

- Do not change the default gator model in `scripts/agents/gator/agent.yaml` for experiments. Use `CODEX_MODEL=...` and, if needed, a temporary `--from` Docker context or `--codex-bin` override.
- Do not push to contributor branches, approve, merge, post `/ok to test`, or broaden gator scope unless the operator explicitly authorized that action.
- Scope each launch prompt to the requested issue/PR set. Avoid repo-wide gator scans unless the operator asked for repo-wide processing.
- Treat `/etc/openshell/agent-payload` as immutable once a sandbox is created. After prompt/skill/runtime/image changes, delete and relaunch the affected gator instead of trying to patch files in-place.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this something that can be enforced through a policy?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we even need this statement. I've been able to adjust a running agent by just pushing updated skills, etc if I want to update it while it's running. I don't think there's a reason for it to treat it as immutable.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK. If we don't think there's a reason to enforce it, then let's drop it.


### Step 5: Verify Gateway Is Registered And Alive

Use the target gateway, usually `docker-dev` for local gators.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note: If the user is using an installed openshell, I think this is openshell and not docker-dev.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good call. removing all the hard coded docker-dev refs so it can be dynamic

openshell --gateway docker-dev sandbox list
```

Look for names like `gator-pr-<number>-supervised`. If one exists, inspect its log before deleting or relaunching.

@elezar elezar Jul 10, 2026

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When I was using this, my gator sandboxes were something like gator-<TIMESTAMP. There was no PR reference. How do we handle those "conflicts"?

Later in this skill we have issue-specific sandbox names. Should those be checked for conflicts too?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would imagine you could steer that w/ the local agent using the skill right and it's going to depend on how the local agent names sandboxes or if you want to direct it to a different naming convention. Nothing in a skill is authoritative.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe as a follow up: What's the "worst" that can happen if multiple agents are looking at the same PR/issue? Their per-sha state is local, correct.

```bash
issue_number="<digits-only>"
[[ "$issue_number" =~ ^[0-9]+$ ]] || { echo "invalid issue number" >&2; exit 1; }
sandbox_name="gator-issue-${issue_number}-supervised"

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are we concerned about conflicts for these too?

--from "$tmp_context" \
--watch \
--background \
"Review and monitor PR #${pr_number} through the gator-gate workflow. Scope this invocation only to PR #${pr_number}."

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Question: Should the "scope this invocation only to PR ... " be the default?

Signed-off-by: John Myers <johntmyers@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

gator:in-review Gator is reviewing or awaiting PR review feedback

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants