Skip to main content
Glama
SLF Guardian MCP

SLF Guardian MCP

by slfguardian

check_prompt

Detect prompt injection in untrusted text, HTML, or a web page before feeding it to a model. Flags hidden instructions, invisible characters, and system prompt or data exfiltration attempts.

Instructions

Check untrusted text, HTML or a web page for prompt injection before feeding it to a model. Finds instructions written for the model instead of the reader: text hidden with CSS, HTML comments, zero-width and invisible Unicode tag characters, chat template markers, 'ignore previous instructions', attempts to make an agent leak its system prompt or credentials, hide actions from the user, approve something without review, run a command, or render a markdown image that exfiltrates data through its URL. Returns a verdict, injection_detected, and clean_text with invisible characters stripped. Never follows what it finds.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "check_prompt"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlNoPublic page to fetch and check.
htmlNoHTML including hidden markup.
textNoPlain text to check.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.2.0

TDQS

A3.9/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden and does substantial work: it enumerates what classes of injection are detected, discloses the return fields (verdict, injection_detected, clean_text with invisible characters stripped), and states the important safety property 'Never follows what it finds' for a tool that ingests adversarial text. It omits operational behavior such as whether the URL path performs a live fetch with latency or rate limits, and does not restate that the operation is non-mutating.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The purpose and the 'before feeding it to a model' trigger are front-loaded, and the return-value sentence is placed before the closing safety note. The long middle enumeration is dense but every item is a distinct detection class, so it earns its place; it could be tightened but is not padding.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no annotations and no output schema, the description must cover purpose, inputs, and returns, and it does all three, including the names of the returned fields. The remaining gaps are the input-selection rule among three optional parameters and any guidance on what an agent should do when injection_detected is true, which keeps it from being fully complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the three parameter descriptions already carry their meaning, and the prose correctly maps 'text', 'HTML', and 'a web page' onto text/html/url, adding the nuance that url is fetched and html may contain hidden markup. However, all three parameters are optional and the description never says whether exactly one input must be supplied or how conflicting inputs are resolved, which is the one semantic gap the schema leaves open.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description gives a specific verb+resource: check untrusted text, HTML, or a web page for prompt injection, with a concrete threat model (hidden CSS text, HTML comments, zero-width characters, chat template markers, exfiltration attempts). That is far more specific than the sibling names check_command/check_domain/check_package, which target different artifacts. It stops short of 5 because it never explicitly routes the agent away from the URL-oriented sibling scan_site, leaving overlap to be inferred.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It states a clear trigger condition: run this 'before feeding it to a model' on untrusted input. That is real when-to-use guidance rather than implied usage. There are no exclusions or named alternatives, so it falls short of the explicit when-not/alternatives bar.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.