shield_analyze
One-call safety gate for an LLM response: grounding (with source), prompt injection on the response AND the prompt (checks.injection / checks.injection_prompt), toxicity, PII, guardrail rules, quality, plus an LLM review on Groq (server key; model "none" skips it and sends nothing out). Returns PASS/FIX/BLOCK, a 0-100 safety score, per-check results and fixes. PII gates the verdict: SSN or card → BLOCK, email → FIX, phone/IP flagged only.
Example tool call
This call uses example arguments supplied in the tool’s input schema.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"model": "none",
"prompt": "When will my order arrive?",
"response": "Your order #1234 will arrive tomorrow."
},
"name": "shield_analyze"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| model | No | LLM review model: openai/gpt-oss-20b, openai/gpt-oss-120b, qwen/qwen3.8-27b (default openai/gpt-oss-20b), or "none". | |
| rules | No | Same format as guardrail_test. | |
| prompt | No | The original prompt — also scanned for injection; pass it whenever you have it. | |
| source | No | Reference text for the grounding check. | |
| response | Yes | The LLM response to check. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| flags | No | ||
| grade | No | ||
| score | No | ||
| checks | No | ||
| verdict | No |