workspace-agent-modes

workspace-agent-modes is a skill for Claude Code, Codex from BrentFarris/echo. It costs 30 tokens per session (409 once invoked), scanned A, original, MIT.

A technical guide to storing, serving, and using workspace-specific modes for coding agents.

In plain words
What is it for?
Use it when implementing or debugging workspace agent modes and the default mode selected for new chat tabs.
Why use it?
It documents the file format, API endpoints, defaults, validation, deletion behavior, and frontend consumers so changes remain compatible.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it when implementing or debugging workspace agent modes and the default mode selected for new chat tabs.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/brentfarris/echo/workspace-agent-modes
Install

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.

Any agent
npx skills add BrentFarris/echo --skill workspace-agent-modes
Clone the repo
git clone --depth 1 https://github.com/BrentFarris/echo

Made for: Claude Code, Codex.

Wrote 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.

agentmods badge for workspace-agent-modes

README.md
[![agentmods](https://agentmods.dev/badge/skills/brentfarris/echo/workspace-agent-modes/github.svg)](https://agentmods.dev/skills/brentfarris/echo/workspace-agent-modes)
Your own site
<a href="https://agentmods.dev/skills/brentfarris/echo/workspace-agent-modes"><img src="https://agentmods.dev/badge/skills/brentfarris/echo/workspace-agent-modes/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.

agentmods 80×15 button for workspace-agent-modes

Your own site · 80×15
<a href="https://agentmods.dev/skills/brentfarris/echo/workspace-agent-modes"><img src="https://agentmods.dev/badge/skills/brentfarris/echo/workspace-agent-modes.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 30 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 409 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00030 $0.00409
Opus 5.5 $0.00012 $0.00164
Sonnet 5.5 $0.00006 $0.00082
Haiku 4.5 $0.00003 $0.00041

Measured 4d ago against content hash f8bfecf80c85, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

workspace-agent-modes 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 4d 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.

.echo/skills/workspace-agent-modes/SKILL.md · 17 lines

What it actually says

Workspace agent modes

  • Storage: per-workspace .echo/agent-modes.json (via internal/agentmodes). The on-disk shape is {"defaultModeId": "...", "modes": [...]} (agentmodes.store). defaultModeId is optional/omitted when unset; load() also migrates the legacy bare-JSON-array format in memory, so never assume the file is an array when reading it.
  • defaultModeId is the workspace-scoped default agent mode for new chat tabs. Unset/invalid values resolve to general (agentmodes.GeneralID). Manager.SetDefault validates the ID against built-ins + custom modes; explicitly choosing General stores an empty value (setting omitted). Manager.Delete clears the default if it pointed at the deleted mode.
  • API: GET /api/agent-modes?workspaceId= returns {workspaceId, modes, tools, defaultModeId}. PUT /api/agent-modes/default with {workspaceId, modeId} sets the default (registered as a literal path in server.go so it does not collide with PUT /api/agent-modes/{id}).
  • Frontend consumers: web/js/views/home.js (defaultAgentModeId module var; used by restoreCurrentComposer for new tabs and as fallback for invalid carry-overs) and web/src/chatSurface.ts (preselects data.defaultModeId on the mode select; saved drafts still win via restoreDraft). Settings UI lives in renderAgentModes in web/js/views/settings.js (data-default-mode select).
Changes

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.

  1. 4d ago First seen · 17 lines · 30 tokens per session scan A f8bfecf80c85

Subscribe to this mod's changes

workspace-agent-modes is a skill published in the GitHub repository BrentFarris/echo (11 stars, last pushed today), licensed MIT. It adds 30 tokens to every session and 409 once invoked, about $0.0001 per session on Opus 5.5. 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-10-12.