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.
git clone --depth 1 https://github.com/dork-labs/dorkosWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/commands/dork-labs/dorkos/session-switch-test)<a href="https://agentmods.dev/commands/dork-labs/dorkos/session-switch-test"><img src="https://agentmods.dev/badge/commands/dork-labs/dorkos/session-switch-test/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/commands/dork-labs/dorkos/session-switch-test"><img src="https://agentmods.dev/badge/commands/dork-labs/dorkos/session-switch-test.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What 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.1 | $0.00054 | $0.05457 |
| Opus 5.5 | $0.00022 | $0.02183 |
| Sonnet 5.5 | $0.00011 | $0.01091 |
| Haiku 4.5 | $0.00005 | $0.00546 |
Grade E, and why
session-switch-test scanned grade E with 3 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 12d 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.
Downloads and executes remote codehighSupply chain
curl | sh runs whatever the server returns today, which is not necessarily what it returned when this was reviewed.
curl -s "http://localhost:$API_PORT/api/models" | python3 -c "import sys,json;[print(m['value']) for m in json.load(sys.stdin)['models']]" Recursive force deletehighDestructive command
rm -rf with a variable or a broad path is one typo away from removing the wrong tree.
dotenv -- sh -c 'rm -rf /tmp/dorkos-test-mode-4243 && turbo run build --filter=@dorkos/server && pnpm --filter @dorkos/server exec tsx src/index.ts' Makes network callslowCapability
Not a fault in itself. Listed so you know the mod talks to something, and to what.
curl -sf -X PATCH http://localhost:4248/api/config -H 'content-type: application/json' \ How it starts
The opening of the file, as written. The whole thing — 262 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Self-test the DorkOS chat UI under the hardest real-world condition: two sessions of the same agent doing long, tool-heavy work at the same time, while the operator toggles between them in the sidebar. This is the flow where session-scoped live state (streaming, pending permission prompts, queued messages, running subagents, todos) tends to leak or get lost. The command drives the browser, cross-checks the on-disk JSONL transcripts and the server API, and writes an evidence-based report.
This complements /chat:self-test (which exercises a single session in depth). Use this one whenever you touch session switching, the SSE stream lifecycle, useSessionId, the session-chat store, tool-approval rendering, or message queueing.
Argument Parsing
Parse $ARGUMENTS:
- URL — any arg starting with
http. Default (expand$HOMEto the actual home directory;mkdir -pthe dir if missing):http://localhost:6241/session?dir=$HOME/Keep/temp/empty(Extract thedirquery param asTEST_DIRfor JSONL resolution. The empty temp dir keeps file side-effects isolated.) topics:a,b— two unambiguous, distinct topics for sessions A and B. Default:lakes,fruit. Pick concrete nouns (cars, fruit, lakes, clothes) so A and B content is trivially distinguishable on disk and on screen.perm:<mode>— permission mode for both sessions. Default:default.default— prompts on tool use. Use this to reproduce/regress the permission-prompt-on-switch bug (checks #6). The downstream checks (#2–#4) will be blocked if that bug is present, because the agents stall at the first tool gate.bypassPermissions/acceptEdits— no blocking gate. Use this to exercise subagents, queued messages, and file ops end-to-end (checks #2–#4).- Run both variants for full coverage.
model:<id>— defaultclaude-haiku-4-5(fastest, cheapest; this tests UI plumbing, not model capability). Ignored undermode:sandbox, where no model answers.mode:sandbox|live— which stack the run drives (contributing/capabilities/chat.md§11).mode:sandbox— the test-mode runtime: throwaway data dir, deterministic, no model spend. Verifies UI plumbing: switching, queueing, stream lifecycle.mode:live— the dev stack with a real runtime. Verifies streaming feel, real tool loops, timing, and permission gates as they actually behave.- If the invocation does not state a mode, ASK the user before spending anything (
AskUserQuestion, offering both, with the cost of each). Never assumelive.
Store as TEST_URL, TOPIC_A, TOPIC_B, PERM_MODE, MODEL, MODE.
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.
- 12d ago Changed dfa15e23cf3b
- 14d ago Changed 54f5f5dc781e
- 1mo ago First seen · 262 lines · 54 tokens per session scan E 3bcd81d096f9
session-switch-test is a command published in the GitHub repository dork-labs/dorkos (12 stars, last pushed today), licensed MIT. It adds 54 tokens to every session and 5,457 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it E with 3 findings (downloads and executes remote code, recursive force delete, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other commands, from other repositories
e2e
Generate and run end-to-end tests with Playwright. Creates test journeys, runs tests, captures screenshots/videos/traces.
e2e
Generate and run E2E tests with Playwright.
test-browser
Run browser tests on pages affected by current PR or branch.
test-suite
Run comprehensive test suite with coverage analysis.
health-check
Perform a comprehensive, read-only end-to-end review of any portfolio app across three layers — Frontend (E2E), Database integrity, and Audit Log & User Activity — and produce a structured, observations-only report. Optionally, on explicit opt-in, generate (never apply) the infrastructure provisions needed so future…
web-checklist
A checklist command for testing a website after a Git merge. It records checklist items in a file so progress can be viewed and individual checks can be marked complete.