Skip to main content
Glama

rag-embedding-poisoning-escrow-auditor

audit_rag_embeddings_escrow

Idempotent

[Private] Audit RAG chunks and vector embeddings in RAM for dimension mismatch, NaN/zero L2 norms, duplicates and indirect prompt injection. Call with {} for preview. Example: {"expectedDimension":4,"minChunks":5}.

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": "audit_rag_embeddings_escrow"
  }
}

Input Schema

NameRequiredDescriptionDefault
chunksNoRAG chunks with text & embedding.
minChunksNoMin required chunks.
expectedDimensionNoExpected vector length.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changed
    • changedInput schema / properties / chunks / description
      Previous value: -"Array of RAG objects containing text and numeric embedding arrays."New value: +"RAG chunks with text & embedding."
    • changedInput schema / properties / expectedDimension / description
      Previous value: -"Expected vector length for every embedding."New value: +"Expected vector length."
    • addedInput schema / properties / expectedDimension / examples
      Added value: +[
      +  4
      +]
    • changedInput schema / properties / minChunks / description
      Previous value: -"Minimum required number of valid knowledge chunks."New value: +"Min required chunks."
  2. Changed1 schema field changed
    • changedInput schema / required
      Previous value: -[
      -  "chunks"
      -]New value: +[]
  3. Changed4 schema fields changed
    • addedInput schema / properties / chunks / description
      Added value: +"Array of RAG objects containing text and numeric embedding arrays."
    • addedInput schema / properties / chunks / items
      Added value: +{
      +  "type": "object"
      +}
    • addedInput schema / properties / expectedDimension / description
      Added value: +"Expected vector length for every embedding."
    • addedInput schema / properties / minChunks / description
      Added value: +"Minimum required number of valid knowledge chunks."
  4. First observed

TDQS

B3.4/5.0
Behavior3/5

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

Annotations declare readOnlyHint=false but destructiveHint=false and idempotentHint=true, meaning the tool is non-destructive yet not purely a read; the description says only that it audits "in RAM" and never explains the non-read-only aspect or any side effect. On the positive side, it does disclose the in-memory scope and the preview behavior, which are not in the annotations. It omits what happens on a failed check (exception vs. report) and any auth or rate-limit context.

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?

Two compact sentences: the audit scope is front-loaded and the preview/example invocation follows immediately, with no filler. The embedded JSON example is dense and earns its place, though it partially duplicates parameter meaning already carried by the schema.

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

Completeness3/5

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

With three optional parameters and no output schema, the description carries the burden of describing what an audit returns, and it does not: an agent cannot tell whether failures raise an error or appear in a structured report, nor what the preview returns. The scope and failure-mode enumeration are strong, but the result contract is missing for a tool whose whole value is its findings.

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 description coverage is 100%, so each of the three parameters is already documented in the schema and the baseline is 3. The inline example {"expectedDimension":4,"minChunks":5} usefully shows realistic values and confirms both are optional, but the description adds no semantics for the chunks parameter or for how minChunks and expectedDimension interact with the duplicate/injection checks.

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 names a concrete verb (audit) and resource (RAG chunks and vector embeddings) and enumerates the specific failure modes checked: dimension mismatch, NaN/zero L2 norms, duplicates, indirect prompt injection. That is far more specific than the other audit_*_escrow siblings, whose domains are all different. It stops short of explicitly naming a sibling it should be preferred over, which keeps it at 4 rather than 5.

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

Usage Guidelines3/5

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

"Call with {} for preview" gives one concrete invocation mode, and the example shows a configured run, so the agent can infer the preview-then-configure pattern. However, there is no statement of when this audit should be run versus the other escrow audit tools, no prerequisites, and no guidance on when a full audit is required instead of the empty-payload preview.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.