Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add commands/agentis-tools/ctx/self-updategit clone --depth 1 https://github.com/agentis-tools/ctxWhat it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00000 | $0.01482 |
| Opus 5 | $0.00000 | $0.00741 |
| Sonnet 5 | $0.00000 | $0.00296 |
| Haiku 4.5 | $0.00000 | $0.00148 |
Grade A, and why
self-update scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 125 lines — stays where its author put it; the contents beside it link to each section on GitHub.
ctx self-update
Update the ctx binary from GitHub releases — explicitly, never automatically.
Synopsis
ctx self-update [--version <X.Y.Z>] [--json]
ctx --version --check
Description
ctx self-update queries the GitHub Releases API for agentis-tools/ctx, downloads the artifact for the current platform, verifies it, and atomically replaces the running executable:
- Fetch the latest release (or the release pinned with
--version X.Y.Z). - Pick the artifact matching this binary's compile-time target (
ctx-v<version>-<target>.tar.gz,.zipon Windows). - Download the release's aggregated
SHA256SUMSfile and the artifact, and verify the artifact's sha256 against it. On mismatch the update aborts with exit code 2 and the installed binary is untouched. - Extract the
ctxbinary, write it to a temp file in the same directory as the current executable, set executable permissions, andrenameit over the current binary (atomic on the same filesystem).
If nothing newer exists, it prints ctx <version> is already up to date and exits 0. On success it prints the transition:
ctx 0.2.1 → 0.3.0
--version X.Y.Z installs that exact release — including downgrades — instead of the latest.
Before any network work, ctx checks whether the executable belongs to a package manager and verifies
that a direct-download install location is writable. Cargo, Homebrew, Arch, Debian, RPM, and Scoop
installations are never overwritten: ctx exits 2 and prints the appropriate package-manager update
command. Path detection covers Cargo, Homebrew, and Scoop layouts; on Linux, read-only queries to
the local pacman, dpkg, and RPM package databases identify owned files.
Use ctx self-update only for direct GitHub binary installations. Upgrade managed installations
with cargo install agentis-ctx, brew upgrade ctx, yay -Syu ctx-bin, scoop update ctx, or by
installing a newer .deb/.rpm through the corresponding system package manager.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2d ago First seen · 125 lines · 0 tokens per session scan A c3222d27e47e
self-update is a command published in the GitHub repository agentis-tools/ctx (11 stars, last pushed 15d ago), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 1,482 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other commands, from other repositories
coograph-review
Review the changes in scope for spec compliance, convention violations, logic bugs, and architectural issues. You review — you do not author. Never edit files.
coograph-verify
Verify that the described work is complete and correct. Provide evidence for every claim. You verify — you do not implement or fix style.
api-gen
Generate REST API endpoints with routes, validation, error handling, and tests.
component-gen
Generate React or Vue components with prop types, styling, accessibility, and tests.
code-review
Review staged git changes for bugs, security issues, and style violations.
pr-description
Generate a PR title and description from the current branch diff against main.