Skip to main content
Glama
joeblockchain

Jina AI MCP Server

fact_check

Verify statements for accuracy using Jina AI's grounding engine to identify factual claims and provide supporting evidence.

Instructions

Fact-check a statement using Jina AI's grounding engine

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
statementYes
deepdiveNo

Implementation Reference

  • index.ts:89-108 (handler)
    The groundStatement function executes the fact_check tool logic by querying Jina AI's grounding API with the provided statement and optional deepdive flag, parsing the response with GroundingResponseSchema.
    async function groundStatement(params: z.infer<typeof GroundingSchema>) {
      const headers: Record<string, string> = {
        'Authorization': `Bearer ${JINA_API_KEY}`,
        'Accept': 'application/json'
      };
    
      const statementQuery = encodeURIComponent(params.statement);
      const url = `https://g.jina.ai/${statementQuery}${params.deepdive ? '?deepdive=true' : ''}`;
    
      const response = await fetch(url, {
        method: 'GET',
        headers,
      });
    
      if (!response.ok) {
        throw new Error(`Jina AI Grounding API error: ${response.statusText}`);
      }
    
      return GroundingResponseSchema.parse(await response.json());
    }
  • Zod schema defining the input parameters for the fact_check tool: a required 'statement' string and optional 'deepdive' boolean.
    export const GroundingSchema = z.object({
      statement: z.string(),
      deepdive: z.boolean().optional().default(false)
    });
  • index.ts:123-127 (registration)
    Registers the fact_check tool in the ListTools response, specifying its name, description, and input schema.
    {
      name: "fact_check",
      description: "Fact-check a statement using Jina AI's grounding engine",
      inputSchema: zodToJsonSchema(GroundingSchema)
    }
  • Switch case in CallToolRequestSchema handler that parses arguments for fact_check, calls groundStatement, and formats the response as text content.
    case "fact_check": {
      const args = GroundingSchema.parse(request.params.arguments);
      const result = await groundStatement(args);
      return { content: [{ type: "text", text: JSON.stringify(result, null, 2) }] };
    }
  • Evaluation function (fact_checkEval) for testing the fact_check tool using mcp-evals framework.
    const fact_checkEval: EvalFunction = {
        name: 'fact_check Tool Evaluation',
        description: 'Evaluates the correctness of the fact-checking tool',
        run: async () => {
            const result = await grade(openai("gpt-4o"), "Is it true that the Great Wall of China is visible from space?");
            return JSON.parse(result);
        }
    };
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It mentions the engine ('Jina AI's grounding engine') but doesn't describe how it works, what sources it uses, accuracy limitations, rate limits, or response format. For a fact-checking tool with zero annotation coverage, this leaves critical behavioral traits unspecified.

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

Conciseness5/5

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

The description is a single, efficient sentence with zero waste. It front-loads the core purpose ('Fact-check a statement') and adds necessary context ('using Jina AI's grounding engine') without redundancy. Every word earns its place, making it appropriately sized for the tool's complexity.

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

Completeness2/5

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

Given the tool's complexity (fact-checking with an external engine), lack of annotations, no output schema, and 0% schema description coverage, the description is incomplete. It doesn't explain what the tool returns, how to interpret results, error conditions, or behavioral constraints. The agent lacks sufficient context to use this tool effectively.

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

Parameters2/5

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

Schema description coverage is 0%, so the schema provides no parameter descriptions. The description adds no information about the 'statement' parameter (e.g., format, length limits) or the 'deepdive' parameter (e.g., what it does, when to use it). It fails to compensate for the lack of schema documentation, leaving both parameters semantically unclear.

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 clearly states the action ('fact-check') and the resource ('a statement'), and specifies the method ('using Jina AI's grounding engine'). It distinguishes from sibling tools like 'read_webpage' and 'search_web' by focusing on verification rather than retrieval. However, it doesn't explicitly differentiate from hypothetical siblings like 'verify_claim' or 'check_fact', so it's not a perfect 5.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention when to prefer this over sibling tools like 'search_web' for fact-checking purposes, nor does it specify prerequisites or exclusions. The agent must infer usage from the tool name alone.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/joeblockchain/mcp-jina-ai'

If you have feedback or need assistance with the MCP directory API, please join our Discord server