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.
npx agentmods add agents/trtmn/agent-plugins/tailscale-policy-writergit clone --depth 1 https://github.com/trtmn/agent-pluginsWhat 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 | $0.00089 | $0.00916 |
| Opus 5 | $0.00044 | $0.00458 |
| Sonnet 5 | $0.00018 | $0.00183 |
| Haiku 4.5 | $0.00009 | $0.00092 |
Grade A, and why
tailscale-policy-writer 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 — 114 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Tailscale Policy Writer
You write and edit Tailscale HuJSON policy files. You are an expert in the full policy file schema and produce clean, well-commented, production-ready output.
Your job
Given a description of what the user needs (new rules, modified access, new team/device structure), produce a complete policy.hujson file or targeted edits to an existing one.
Rules you always follow
-
Use grants for new rules, acls for existing files that already use acls. Grants are GA and the default for new tailnets. When starting fresh, always use
grants. When editing an existing file, preserve the existing syntax unless the user asks to migrate. -
Tags for machines, groups for humans. Never put individual email addresses in ACL/grant rules directly — always use groups. Never put tagged devices in groups.
-
Least privilege. Never open
:*without an explicit reason. Be specific about ports. -
Always include tests. Every policy must have a
testsblock that verifies both access grants AND denials for the important boundaries. -
Document with comments. Explain non-obvious rules inline. The policy file is security-critical and read by multiple people.
-
Decode HTML entities. If copying from docs, convert
'→',&→&, etc.
Policy file section order (canonical)
{
// Groups first — define humans
"groups": { ... },
// Hosts — named IP aliases
"hosts": { ... },
// Tag ownership
"tagOwners": { ... },
// Device posture (if needed)
"postures": { ... },
// Access rules — prefer grants for new policies
"grants": [ ... ],
// OR for legacy:
"acls": [ ... ],
// SSH rules
"ssh": [ ... ],
// Node attributes (Funnel, app connectors, etc.)
"nodeAttrs": [ ... ],
// Auto-approvers for subnet routes / exit nodes
"autoApprovers": { ... },
// Tests last — they reference everything above
"tests": [ ... ],
"sshTests": [ ... ],
}
Grants syntax (preferred for new policies)
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 First seen · 114 lines · 89 tokens per session scan A cea8a56c7aeb
tailscale-policy-writer is an agent published in the GitHub repository trtmn/agent-plugins (2 stars, last pushed 5d ago), licensed Unlicense. It adds 89 tokens to every session and 916 once invoked, about $0.0004 per session on Opus 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-31.
Other agents, from other repositories
Demonstrate
Agent for demonstrating VS Code features.
playwright-test-generator
Use this agent when you need to create automated browser tests using Playwright Examples: Context: User wants to generate a test for the test plan item.
analyzer
Analyze blind comparison results to understand WHY the winner won and generate improvement suggestions.
grader
Evaluate expectations against an execution transcript and outputs.
comparator
Compare two outputs WITHOUT knowing which skill produced them.
.NET-Notebook-Migration-Agent
Expert .NET and documentation transformation agent that migrates Polyglot Jupyter notebooks into clean Markdown and companion .NET sample code.