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 instructions/tellahq/opensession/agents-mdgit clone --depth 1 https://github.com/tellahq/opensessionWhat 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.01965 | $0.01965 |
| Opus 5 | $0.00983 | $0.00983 |
| Sonnet 5 | $0.00393 | $0.00393 |
| Haiku 4.5 | $0.00197 | $0.00197 |
Grade B, and why
opensession AGENTS.md scanned grade B with 1 finding 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.
Asks for rootmediumPrivilege escalation
A mod that escalates privileges can change anything on the machine, not only the project.
- Use the full root deploy, `sudo deploy/deploy.sh <sha>`, instead when a change How it starts
The opening of the file, as written. The whole thing — 169 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Default to Bun instead of Node.js.
Keep instance-private operator instructions in an untracked AGENTS.local.md or
CLAUDE.local.md, never in this file.
Publishing to repositories
Repositories owned by your own organization are fair game, including public ones: commit, push, and open issues, comments, and pull requests there as part of normal work.
For any repository outside your organization, public or third-party, never publish without explicit user confirmation in the current conversation. Local investigation and commits are allowed; issues, comments, branches, forks, pushes, and pull requests are not.
Choose the client first
Open Session has five clients:
- Web UI:
packages/core/opensession-server/src/frontend/ - Phone web/PWA: the same web bundle at phone width
- Electron shell:
packages/clients/mac/ - Native Swift app:
packages/clients/ios/ - Chrome extension:
packages/clients/chrome/
Once a conversation names a client, keep working on that client unless the user
changes scope. Ask when the target is unclear. For web changes, build desktop
and phone together. For protocol, preference, or transcript changes, check the
native app and Chrome extension for matching wire models or behavior. Read the
nearest nested AGENTS.md before editing a client.
Shared checkout and deployment workflow
Sessions edit the shared main checkout, but the live services run from an
immutable release worktree selected by ~/.opensession/deploy/current. Other
sessions may edit and stage files in the shared checkout at the same time.
Uncommitted checkout edits never become live, including frontend edits.
- Start every task by pulling the latest remote history with
git fetch origin --pruneand checkinggit rev-list --left-right --count HEAD...origin/main. Do not start or continue edits from a stale or divergedmain. - Do not commit until your branch includes the latest
origin/main. Immediately before everygit commit, rungit fetch origin --prune. Then rungit merge-base --is-ancestor origin/main HEAD. If it fails, do not commit: rebase the local commits ontoorigin/mainand resolve every conflict first. Fetch again immediately before pushing; if the remote moved after your commit, rebase that commit onto the neworigin/mainbefore pushing. - Keep one session responsible for synchronizing the shared checkout at a time.
Preserve every staged, unstaged, and untracked change while rebasing. Never
use
git stash, autostash,git pull --rebase --autostash, reset, clean, force-push, or an ordinary pull that creates a merge commit in this checkout. After pushing, fetch once more and verifygit rev-list --left-right --count HEAD...origin/mainreports0 0before continuing. - Never reset, revert, switch branches, or discard unrelated work.
- Stage only your files. Use
git add -pfor shared high-traffic files. - Inspect
git diff --cached --name-onlyandgit diff --cachedbefore every commit. Commit with a pathspec when the index contains other work. - Commit and push promptly. Never use
git add -A. - Do not use an ad-hoc
systemctl restart. It only restarts the already pinned release and can violate the gateway/kernel rollout order. - Commit and push before deploying. Deployment may be autonomous when the task calls for making the change live, but it is a shared operation, not a per-session completion ritual. Concurrent main-line requests queue and coalesce to the newest fast-forward commit; targets already covered become successful no-ops. Do not manually retry a queued request.
- Treat a successful deploy as fully settled. Success already means the target release is active and its required health checks passed; the rollback safety window is protection, not a cooldown. Continue immediately with the next promotion or verification. Do not wait for a shared deploy to "settle", add an arbitrary delay, or wait out the safety window. If a lifecycle operation still owns the deploy lock, submit the normal deploy request and let it queue and coalesce instead of polling or sleeping.
- Use
deploy_selffor ordinary frontend, backend, protocol, and dependency changes. It classifies the complete diff from the running backend pin. A strictly frontend-only diff is built in its immutable target release and promoted without restarting any service; everything else uses the standard health-gated executor, session-kernel, and gateway restart. The deploy controller collapses overlapping main-line requests instead of producing a restart train. - Use the full root deploy,
sudo deploy/deploy.sh <sha>, instead when a change affects live deployment machinery or an artifact that script installs:deploy/{deploy,self-deploy,release-checkout}.sh, the fouropensession*.servicetemplates, credential installers, the fixed run-host helper/installer, or root-deploy-managed systemd units and drop-ins. The full deploy refreshes those privileged artifacts before switching the same immutable release. Other operator-managed artifacts, such as watchdog units and sandbox images, follow their own documented rollout. When unsure, inspectdeploy/deploy.shrather than assuming a restart applies the change. - A docs-only change needs no live deploy. A frontend-only change still needs
deploy_self: the production watcher and/api/rebuild-frontenduse the active immutable release, not the shared WIP checkout.deploy_selfautomatically takes the restart-free frontend promotion path when the whole diff is safe; do not claim a shared-checkout edit is live before that succeeds.
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 · 169 lines · 1,965 tokens per session scan B d1988bb35d62
opensession AGENTS.md is an instructions file published in the GitHub repository tellahq/opensession (327 stars, last pushed 2d ago), licensed MIT. It adds 1,965 tokens to every session, about $0.0098 per session on Opus 5. A static security scan graded it B with 1 finding (asks for root). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other instructions, from other repositories
taiwan-ecommerce-toolkit CLAUDE.md
Instructions for Moksa1123/taiwan-ecommerce-toolkit, covering claude.md, project overview, available scripts, test api connectivity and validate invoice data.
sparrowhawk AGENTS.md
Instructions for bacpop/sparrowhawk, covering agents.md — sparrowhawk, what this is, getting a working checkout, two facts that will otherwise cost you an hour and layout.
ship-it AGENTS.md
Instructions for LunkiBR/ship-it, covering agents.md, project context, repository layout, terminology and key components.
ScalaSemantic AGENTS.md
Instructions for MercurieVV/ScalaSemantic, covering agents.md instructions and quick start.
agentdir AGENTS.md
Instructions for jstxn/agentdir: Use AgentDir as the local flight recorder for coding-agent work in this repository.
zola-mcp CLAUDE.md
Instructions for chrischall/zola-mcp, covering zola-mcp, commands, architecture, environment and auth resolution (four-path).