agent-spec

agent-spec is a cursor rule for Cursor from mohitagw15856/pm-claude-skills. It costs 85 tokens per session (963 once invoked), scanned A, original, MIT.

A design document for an autonomous or tool-using AI agent. It defines the agent’s goal, available tools, permissions, operating loop, limits, and handoff rules.

In plain words
What is it for?
Use it to plan agents that read APIs, write data, execute code, spend money, send messages, or take other actions, with permissions and human approval gates.
Why use it?
It makes the agent’s authority explicit before implementation, reducing the risk of unwanted actions, unsafe decisions, and unclear success criteria.

Cursor rule for Cursor

Written for Cursor: a Cursor rule (.mdc).

Good fit Use it to plan agents that read APIs, write data, execute code, spend money, send messages, or take other actions, with permissions and human approval gates.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/mohitagw15856/pm-claude-skills/agent-spec
About the project

PM Skills is a collection of plain-Markdown instructions that teach AI assistants structured methods for handling professional, personal, and life-admin tasks. People use it with Claude, ChatGPT, Gemini, Cursor, Codex, and other supported agents for work such as writing product requirements, reviewing documents, or planning difficult situations.

mohitagw15856/pm-claude-skills · 1,345 stars · on GitHub · mohitagw15856.github.io

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.

Clone the repo
git clone --depth 1 https://github.com/mohitagw15856/pm-claude-skills

Made for: Cursor.

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 agent-spec

README.md
[![agentmods](https://agentmods.dev/badge/rules/mohitagw15856/pm-claude-skills/agent-spec/github.svg)](https://agentmods.dev/rules/mohitagw15856/pm-claude-skills/agent-spec)
Your own site
<a href="https://agentmods.dev/rules/mohitagw15856/pm-claude-skills/agent-spec"><img src="https://agentmods.dev/badge/rules/mohitagw15856/pm-claude-skills/agent-spec/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 agent-spec

Your own site · 80×15
<a href="https://agentmods.dev/rules/mohitagw15856/pm-claude-skills/agent-spec"><img src="https://agentmods.dev/badge/rules/mohitagw15856/pm-claude-skills/agent-spec.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 85 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 963 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.00085 $0.00963
Opus 5 $0.00043 $0.00481
Sonnet 5 $0.00017 $0.00193
Haiku 4.5 $0.00009 $0.00096

Measured 6d ago against content hash adc62f8f6327, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

agent-spec 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 6d 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.

exports/cursor/pm-ai/agent-spec/agent-spec.mdc · 68 lines

How it starts

The opening of the file, as written. The whole thing — 68 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Agent Spec Skill

An agent is a model plus tools plus a loop — and the danger lives in the tools and the loop, not the model. This skill specifies an agent so its authority is explicit: what it can do, what needs a human yes, and what happens when it's wrong. Scope and guardrails first; cleverness second.

Required Inputs

Ask for these only if they aren't already provided:

  • Job to be done — the outcome the agent owns, and the boundary of its authority.
  • Tools/actions — what it can call (read APIs, write actions, code execution), and which are irreversible.
  • Autonomy level — fully autonomous, propose-then-approve, or co-pilot.
  • Risk surface — what's the worst thing a wrong action could do (spend money, send a message, delete data)?
  • Success definition & escalation — how "done" is judged, and when it must hand off to a human.

Output Format

Agent Spec: [name]

1. Goal & scope — the job in one sentence; explicit non-goals and authority limits.

2. Tools / actions — a table; mark each action's reversibility and required permission.

Tool Purpose Reversible? Gate
search_kb read context yes none
send_email notify no human approval

3. Control loop — plan → act → observe → reflect; the stopping condition; and a hard max-steps / max-cost budget so it can't loop forever.

4. Guardrails & approval gates — which actions require a human yes (default: anything irreversible, outbound, or spending), input/output validation, and allow/deny lists. Pair irreversible actions with a dry-run preview (see action-runner).

5. Memory & state — what it remembers within a task vs. across tasks, and where (link a professional-brain for durable memory).

6. Escalation & handoff — the triggers that stop the agent and route to a human (low confidence, repeated failure, out-of-scope request, high-risk action).

Read the full file on GitHub · 68 lines

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. 6d ago First seen · 68 lines · 85 tokens per session scan A adc62f8f6327

Subscribe to this mod's changes

agent-spec is a cursor rule published in the GitHub repository mohitagw15856/pm-claude-skills (1,345 stars, last pushed 2d ago), licensed MIT. It adds 85 tokens to every session and 963 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-09-03.