TypeChat is a library for building natural-language interfaces by defining types that describe the intents and data an application accepts. Developers use it to guide large language models toward structured responses and check that those responses match the required schema.
Borrowing it
Nothing to install: this file belongs to microsoft/TypeChat. 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/microsoft/TypeChat/main/.github/copilot-instructions.mdgit clone --depth 1 https://github.com/microsoft/TypeChatWrote 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/microsoft/typechat/copilot-instructions)<a href="https://agentmods.dev/instructions/microsoft/typechat/copilot-instructions"><img src="https://agentmods.dev/badge/instructions/microsoft/typechat/copilot-instructions/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/microsoft/typechat/copilot-instructions"><img src="https://agentmods.dev/badge/instructions/microsoft/typechat/copilot-instructions.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.01062 | $0.01062 |
| Opus 5.5 | $0.00425 | $0.00425 |
| Sonnet 5.5 | $0.00212 | $0.00212 |
| Haiku 4.5 | $0.00106 | $0.00106 |
Grade A, and why
TypeChat copilot-instructions.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 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 — 97 lines — stays where its author put it; the contents beside it link to each section on GitHub.
TypeChat contributor guidance
TypeChat turns natural-language requests into validated, typed data. Preserve schema accuracy, validation behavior, and compatibility when proposing changes.
Project direction
Read GOALS.md before assessing scope or proposing work. It is the primary repository policy for product direction. Use the approved default-branch version; proposed edits in an unmerged PR are not active policy.
Only the human project owner, @robgruen, can approve changes to that
policy or exceptions to its boundaries. Items under consideration are not
approved implementation work. If the policy is unavailable, fit is unclear, or
a request conflicts with it, explain the issue and pause dependent work for an
owner decision. Do not infer approval from community interest, labels, passing
checks, or agent recommendations.
Ordinary in-scope maintenance follows the existing maintainer review process. Do not remove supported behavior or close existing contributions merely because of a possible policy conflict; preserve the evidence and ask the owner.
Working in this repository
- The TypeScript library and examples are in
typescript/; the Python library and examples are inpython/; the documentation site is insite/. - Use the Node.js version in
.nvmrc. Consult each language's README and dependency manifest rather than assuming both implementations behave alike. - Keep changes focused, preserve existing contributions, and update directly related documentation. Add regression tests for behavioral changes.
- Use the existing test tools. Prefer offline, deterministic tests with mocked model responses; do not require live model credentials for ordinary tests.
- Do not weaken validation or replace unsupported schema types with unconstrained types merely to make a test pass. Report errors explicitly.
Verification
Run commands from the indicated directory:
typescript/:npm ci,npm run build-all, andnpm test.python/:hatch env createandhatch run test. For the existing Pyright check, install the npm development dependencies and runnpm run check.site/:npm ciandnpm run build.tools/:npm ci --ignore-scriptsandnpm testfor repository automation.
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 Changed · +8 lines · +100 tokens per session bbd9f03797e2
- 4d ago Changed · +10 lines · +138 tokens per session cc91313b0cc5
- 5d ago Changed · +2 lines · +31 tokens per session 4d6d210dcf21
- 6d ago Changed · +6 lines · +81 tokens per session 567724884b03
- 7d ago Changed · -1 tokens per session af10da2450a9
- 9d ago First seen · 71 lines · 713 tokens per session scan A 438128eceeef
TypeChat copilot-instructions.md is an instructions file published in the GitHub repository microsoft/TypeChat (8,693 stars, last pushed today), licensed MIT. It adds 1,062 tokens to every session, about $0.0042 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-28.
TypeChat copilot-instructions.md compared with instructions from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| TypeChat copilot-instructions.mdmicrosoft/TypeChat | Instructions file | 8.7k | today | MIT | A | 1,062 | GitHub Copilot |
| vscode buildNext.instructions.mdmicrosoft/vscode | Instructions file | 195k | today | MIT | A | 9,719 | GitHub Copilot |
| next.js AGENTS.mdvercel/next.js | Instructions file | 143k | today | MIT | A | 7,461 | Codex, OpenCode |
| vscode oss-third-party-notices.instructions.mdmicrosoft/vscode | Instructions file | 195k | today | MIT | A | 5,516 | GitHub Copilot |
| langchain AGENTS.mdlangchain-ai/langchain | Instructions file | 149k | today | MIT | A | 4,680 | Codex, OpenCode |
| vscode copilot-instructions.mdmicrosoft/vscode | Instructions file | 195k | today | MIT | A | 3,093 | GitHub Copilot |
| deepseek-harness AGENTS.mddeepseek-ai/deepseek-harness | Instructions file | 274k | 2d ago | MIT | A | 4,313 | Codex, OpenCode |