Borrowing it
Nothing to install: this file belongs to tig/mcec. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/tig/mcec/develop/AGENTS.mdgit clone --depth 1 https://github.com/tig/mcecWrote 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/instructions/tig/mcec/agents-md)<a href="https://agentmods.dev/instructions/tig/mcec/agents-md"><img src="https://agentmods.dev/badge/instructions/tig/mcec/agents-md/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/instructions/tig/mcec/agents-md"><img src="https://agentmods.dev/badge/instructions/tig/mcec/agents-md.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.04279 | $0.04279 |
| Opus 5.5 | $0.01712 | $0.01712 |
| Sonnet 5.5 | $0.00856 | $0.00856 |
| Haiku 4.5 | $0.00428 | $0.00428 |
Grade A, and why
mcec AGENTS.md 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 2mo 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 — 217 lines — stays where its author put it; the contents beside it link to each section on GitHub.
AGENTS.md: driving (and testing) MCEC with an agent
MCEC 3.0 (the Model Context Environment Controller) gives an AI agent eyes, hands, and a safe
front door on Windows (Windows computer use, in the sense Claude, Codex, and similar agents use the
term). This file is the self-reinforcing guidance loop: the canonical guidance an
agent needs, plus the recipe to dogfood it (drive MCEC through its own MCP server) so the guidance
stays honest. Each time MCEC changes, re-run the dogfood and refine the guidance below and in
AgentServer.Instructions.
The built-in guidance (single source of truth)
The connect-time guidance an MCP client shows the model is authored in
src/Agent/AgentInstructions.md. It is embedded into the exe at build
time and returned in the MCP initialize response (result.instructions) via AgentServer.Instructions,
which loads the embedded file and collapses each blank-line-separated paragraph to one line.
Work the loop observe → target → act → observe.
- Target a window by
window(title substring),process(name without.exe),className, orforeground:true. At least one is required; a call with no target fails by design.- Observe:
querydumps the UI Automation tree (controlType, name, automationId, bounds, state, value; bounded bymaxDepthandmaxNodes);capturereturns a PNG (renders composited WinUI/WPF surfaces correctly). Check results before trusting them: acapturewitherrorCategory: capture-blankis a black/empty frame (minimized/cloaked/occluded/locked session); restore or foreground the window and retry, don't trust the image; acapture-fallbackwarning means PrintWindow was refused and the picture may be wrong; aquerywithtruncated:true(atree-truncatedwarning) hit the node cap; raisemaxNodesor target a deeper window.warningsare non-fatal;errorCategorytells you how to recover. (Shape:docs/agent_control.mdandagent-tool-result.schema.json.)- Act: prefer
invoke(byname/automationId/classname;actioninvoke|toggle|setvalue| setfocus|expand|collapse|select) over coordinate clicks.invokefast-fails if the control isn't present (it does not wait), sofind/wait-forthe control first; aninvokethat returnsno-targetmeans it hasn't appeared yet;wait-forit rather than retrying blindly. Useselectfor TabItem/ListItem/RadioButton. To drag (resize a window by its sizing border, move one by its title bar, or drag a slider/handle; noinvokefor these), use thedragtool: give afromandto, each an element{ by, value }or an absolute screen pixel{ x, y }, plus optionalpathwaypoints; the whole press-move-release is dispatched atomically (prefer it over hand-rollingmouse:lbd/mouse:mt/mouse:lbu, which can interleave with other input). To click a pointinvokecan't reach (a custom-drawn cell, a canvas/map coordinate, a bare pixel), use theclicktool. Before firing an app's own keyboard shortcut at a specific surface (e.g. a MAUI GraphicsView),focusit first; keystrokes only reach the foreground window's focused control.send_commandis the raw escape hatch for any other MCEC command (keystrokes, a single mouse action, launch). Re-queryafter acting; bounds have moved.- Verify with another
query/capture.Compose creatively. Many tasks have no single dedicated tool; build them from primitives. Launch an app with the
launchtool (preferred). Useinvokeaction:select for tabs/list/radios. Drag/resize/move with thedragtool; switch a tab byinvokeselect orclick; record a window by passing itsquery'd bounds as therecordregion; wait on window state with thewindowstool + atimeoutand acondition(appears/disappears/foreground). A capable agent uses the full command set; reach for a rawsend_commandbefore concluding something can't be done.
There is exactly one copy: edit that file. It is the observe → target → act → observe playbook
(targeting; observation with query/capture/record/displays; invoke, drag, click, focus and
send_command; the result
envelope; creative composition of primitives; the on-screen overlay; and the security gates). Nothing here
to keep in sync.
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.
- 2mo ago First seen · 217 lines · 4,279 tokens per session scan A b9aae5acb188
mcec AGENTS.md is an instructions file published in the GitHub repository tig/mcec (105 stars, last pushed 2mo ago), licensed MIT. It adds 4,279 tokens to every session, about $0.0171 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-08-30.
mcec AGENTS.md compared with instructions from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| mcec AGENTS.mdtig/mcec | Instructions file | 105 | 2mo ago | MIT | A | 4,279 | Codex, OpenCode |
| vscode buildNext.instructions.mdmicrosoft/vscode | Instructions file | 195k | yesterday | MIT | A | 9,719 | GitHub Copilot |
| next.js AGENTS.mdvercel/next.js | Instructions file | 143k | today | MIT | A | 7,461 | Codex, OpenCode |
| langchain AGENTS.mdlangchain-ai/langchain | Instructions file | 149k | yesterday | MIT | A | 4,680 | Codex, OpenCode |
| vscode oss-third-party-notices.instructions.mdmicrosoft/vscode | Instructions file | 195k | yesterday | MIT | A | 5,516 | GitHub Copilot |
| vscode copilot-instructions.mdmicrosoft/vscode | Instructions file | 195k | yesterday | MIT | A | 3,093 | GitHub Copilot |
| deepseek-harness AGENTS.mddeepseek-ai/deepseek-harness | Instructions file | 274k | 2d ago | MIT | A | 4,313 | Codex, OpenCode |