Borrowing it
Nothing to install: this file belongs to last9/last9-mcp-server. 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/last9/last9-mcp-server/main/AGENTS.mdgit clone --depth 1 https://github.com/last9/last9-mcp-serverWrote 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/last9/last9-mcp-server/agents-md)<a href="https://agentmods.dev/instructions/last9/last9-mcp-server/agents-md"><img src="https://agentmods.dev/badge/instructions/last9/last9-mcp-server/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/last9/last9-mcp-server/agents-md"><img src="https://agentmods.dev/badge/instructions/last9/last9-mcp-server/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.05611 | $0.05611 |
| Opus 5.5 | $0.02244 | $0.02244 |
| Sonnet 5.5 | $0.01122 | $0.01122 |
| Haiku 4.5 | $0.00561 | $0.00561 |
Grade A, and why
last9-mcp-server 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 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.
How it starts
The opening of the file, as written. The whole thing — 470 lines — stays where its author put it; the contents beside it link to each section on GitHub.
last9-mcp-server — agent instructions
Canonical agent guidance for this repo. CLAUDE.md is a compatibility shim that includes
this file — edit here, not there.
This is a public repo. Never put internal backend paths, handler or route names, customer names, or infrastructure identifiers in code, comments, docs, commits, or PRs.
Orientation
An MCP server in Go (module last9-mcp) that exposes Last9 observability as tools,
prompts, and resources.
Root files
| file | role |
|---|---|
main.go |
startup, config, subcommands, stdio/HTTP transport |
tools.go |
every tool registration |
resources.go |
reference resources (last9://reference/...) |
dump.go |
dump-tools / dump-prompts — builds a server without credentials |
http_server.go |
--http mode |
internal/
| package | role |
|---|---|
last9api |
the single door for HTTP calls to the Last9 API |
apm, alerting, dashboards, telemetry, change_events, suggest |
tool handlers |
prompts |
embedded tool descriptions and reference manuals |
workflows |
MCP prompts |
toolsets |
which tools belong to which --toolsets domain |
models, constants, utils, auth, deeplink, otelids |
shared plumbing |
Commands
go build .
go test -race ./... # integration tests skip without TEST_REFRESH_TOKEN
go run . dump-tools # served tools/list, name-sorted, plus instructions; no credentials
go run . dump-prompts # served prompts/list
./scripts/start-local.sh # run against a local .env
./scripts/eval-r10.sh # eval suites against a fresh build of this checkout
Adding a tool, end to end
- New API endpoint? Add
internal/last9api/<area>/<endpoint>.go— see Calling the Last9 API. Skip if the endpoint already exists. - Description — write
internal/prompts/descriptions/<tool_name>.mdand embed it ininternal/prompts/prompts.goas<Tool>Description— see Tool descriptions. - Tool — create
<package>/<tool_name>.gowith itsArgsstruct, itsNew<Tool>Handler, and its private helpers — see Go conventions. - Register — add to
tools.goviaregisterIfAllowed(registerWriteToolfor a tool that changes state), and add the tool name to its domain ininternal/toolsets/toolsets.go— see Registration. - Test —
<tool_name>_test.gousinghttptest.NewServer; rungo test -race ./.... - Verify —
go run . dump-toolsshows the tool with the intended description and schema. - CHANGELOG — one bullet at the top of its section in
[Unreleased].
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.
- 4d ago Changed · +11 lines · +131 tokens per session f70e27770aea
- 5d ago Changed · +4 lines · +62 tokens per session 5faf70e48ade
- 6d ago Changed · +2 lines · +29 tokens per session 035554a71785
- 11d ago Changed · +7 lines · +67 tokens per session 147eeff8f2d5
- 16d ago Changed · +2 lines · +22 tokens per session 59a428befb3b
- 18d ago Changed · +6 lines · +99 tokens per session c68db6acf1e7
- 19d ago Changed · +9 lines · +175 tokens per session eb80d676902a
- 20d ago Changed · +38 lines · +672 tokens per session 4a3227297f5d
- 21d ago Changed · +14 lines · +213 tokens per session 167185c67014
- 1mo ago First seen · 377 lines · 4,141 tokens per session scan A 8ed4084af6dc
last9-mcp-server AGENTS.md is an instructions file published in the GitHub repository last9/last9-mcp-server (63 stars, last pushed yesterday), licensed Apache-2.0. It adds 5,611 tokens to every session, about $0.0224 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.
last9-mcp-server AGENTS.md compared with instructions from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| last9-mcp-server AGENTS.mdlast9/last9-mcp-server | Instructions file | 63 | yesterday | Apache-2.0 | A | 5,611 | Codex, OpenCode |
| vscode buildNext.instructions.mdmicrosoft/vscode | Instructions file | 195k | today | MIT | A | 9,719 | GitHub Copilot |
| vscode oss-third-party-notices.instructions.mdmicrosoft/vscode | Instructions file | 195k | today | MIT | A | 5,516 | GitHub Copilot |
| next.js AGENTS.mdvercel/next.js | Instructions file | 143k | yesterday | MIT | A | 7,461 | Codex, OpenCode |
| 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 |
| vscode model-prompts.instructions.mdmicrosoft/vscode | Instructions file | 195k | today | MIT | A | 2,022 | GitHub Copilot |