Agent Prompt Linter
A static quality lint for an agent's system prompt: missing structure, tool-list mismatches, unbounded loops, undelimited external content, and contradictions. Runs in your browser — no model call, nothing uploaded.
Matching is regex based: a prompt can satisfy a check in wording this linter doesn't recognise, and passing every check doesn't mean the prompt works. Treat findings as review prompts.
- Structure: Issues (3)
- Tool consistency: Issues (4)
- Loop bounds & escalation: Issues (3)
- Untrusted-data delimiting: Issues (1)
- Clarity & contradictions: Issues (3)
- Hygiene: Pass
- No constraintsWarning
No "must", "never", "only" or "do not" language. The agent's limits are whatever the model assumes.
Fix — State what the agent must never do and what it is limited to, in its own short section.
- No output formatWarning
The prompt never says what a response should look like (format, length, schema).
Fix — Specify the response shape, e.g. "Respond with JSON matching this schema" or "Reply in at most 5 bullets".
- No stop conditionWarning
Nothing defines when the task is finished.
Fix — Add "You are done when …" and what the final message must contain.
- Prompt references `delete_account`, which is not in the tool listWarning
The model will try to call a tool it does not have, or invent arguments for a look-alike.
Fix — Rename the reference to a declared tool, add the tool, or remove the instruction.
Line 1
- Tool `lookup_customer` is never mentioned in the promptNote
The model only has the tool description to decide when to use it. If the prompt has rules about this tool, they are missing.
Fix — Say when to use it, when not to, and what to do with its output.
- Tool `search_kb` is never mentioned in the promptNote
The model only has the tool description to decide when to use it. If the prompt has rules about this tool, they are missing.
Fix — Say when to use it, when not to, and what to do with its output.
- Tool `refund_order` is never mentioned in the promptNote
The model only has the tool description to decide when to use it. If the prompt has rules about this tool, they are missing.
Fix — Say when to use it, when not to, and what to do with its output.
- No step, retry or budget limitWarning
"keep trying" invites an open-ended loop and nothing caps it.
Fix — Add a ceiling, e.g. "Make at most 10 tool calls; if the answer is not found by then, say so."
Line 1
- No path to a humanWarning
The prompt never says when to stop and ask. An agent with no way out guesses.
Fix — Name the situations that need a person (ambiguous request, destructive action, low confidence) and what to ask.
- No failure behaviourWarning
Nothing says what to do when a tool errors or the agent cannot complete the task.
Fix — Add "If a tool fails twice or you are unsure, stop and report what you tried" — or whatever the right fallback is.
- Untrusted content is mentioned but never delimitedWarning
The prompt refers to "web pages" but has no tags, fences or markers separating that content from instructions.
Fix — Wrap external content in tags such as <document>…</document> and have the harness insert it there.
Line 3
- Vague directive: "Be careful"Note
Careful about what? Name the failure to avoid.
Line 1
- Vague directive: "use your best judgment"Note
Give the criteria the judgment should use.
Line 1
- Possible length conflict: "Be concise" and "thorough"Note
Both appear in the prompt. If they apply to different outputs, say which; otherwise pick one.
Line 1
About this tool
Agent Prompt Linter
This checks whether an agent prompt is well-formed, not whether it is hardened. It reads the prompt you paste, and optionally the names of the tools the agent is given, and flags the gaps that make agents loop, guess or call things that do not exist. It never calls a model.
Six groups of checks: structure (role, constraints, output format, stop condition); tool consistency (the prompt names a tool that is not declared, or a declared tool is never mentioned); loop bounds and escalation (a step limit, a path to a human, what to do on failure); untrusted-data delimiting (external content wrapped in tags and labelled as data); clarity (vague directives, "always X" against "never X"); and hygiene (hard-coded dates and model names, very long prompts).
Every check is regex-based, so a prompt can meet one in wording the linter does not recognise, and a clean result does not mean the prompt works. Contradiction detection is deliberately narrow because anything broader needs a model. Use the output as a review checklist, then test the agent.
When to use it
Before shipping an agent
Paste the prompt and the tool names. Fix the warnings, in particular missing step limits and escalation, which are the usual cause of runaway agents.
After changing the tool set
Re-paste the prompt with the new tool list to catch instructions that still point at tools you removed or renamed.
Pair with the injection tester
This tool checks prompt quality. The Prompt Injection Tester checks injection resistance. A prompt can pass one and fail the other.
Questions
How is this different from the Prompt Injection Tester?
The Prompt Injection Tester asks whether the prompt contains guardrails against six injection techniques. This linter asks whether the prompt is complete and consistent for an agent: does it say when to stop, when to ask a human, which tools exist, and how external content is separated from instructions. The one overlap is data delimiting, and here it is a structural check.
Does it call an LLM or upload my prompt?
No. The lint runs in your browser. Nothing is sent to a model or a server.
Why is the tool list optional?
The tool-consistency check compares the prompt to the tools the agent actually has, so it needs that list. Paste tool names one per line, a JSON array of names, or your tool definitions (an array of objects with a name). Without it, that check is skipped.
Why did it flag something my prompt does cover?
Matching is keyword based. If your prompt expresses a limit or an escalation path in unusual wording, the linter will miss it. Treat a finding as a question to answer, not a verdict.
Can it tell me whether my prompt is good?
No. It finds structural gaps and obvious inconsistencies. Whether the agent behaves well is only answered by running it against real tasks.