Sign In

@pharmatools/opengate-mcp

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@pharmatools/opengate-mcp

MCP server for OpenGATE — let an AI agent check whether its answers are grounded in the provided context. Deterministic, no LLM judge.

latest
Source
npmnpm
Version
0.1.4
Version published
Weekly downloads
33
-43.1%
Maintainers
1
Weekly downloads
 
Created
Source

@pharmatools/opengate-mcp

An MCP server that lets an AI agent check whether its own answers are grounded in the context it was given — before returning them.

It exposes one tool, check_grounding, backed by OpenGATE's deterministic grounding check. No LLM-as-judge: the verdict is reproducible and gold-anchored.

Why

An agent doing RAG or document QA can hallucinate a figure, drop a required fact, or answer confidently when the context doesn't actually contain the answer. check_grounding catches all three, deterministically:

  • Required facts you name must appear in the answer.
  • Every number in the answer must trace to the context (or the question).
  • Unanswerable questions must be declined, not fabricated.

Add it to your MCP client

Claude Desktop (claude_desktop_config.json):

{
  "mcpServers": {
    "opengate": {
      "command": "npx",
      "args": ["-y", "@pharmatools/opengate-mcp"]
    }
  }
}

Then, in a conversation, the agent can self-check:

Before you answer, use check_grounding with your draft answer and the retrieved passages.

The tool

check_grounding

ArgumentTypeMeaning
answerstringThe answer to check.
contextstring | string[]The retrieved context it must be grounded in.
questionstring (optional)The original question (lets its numbers count as grounded).
expected_factsstring[] (optional)Facts a correct answer must contain.
allowed_new_numbersstring[] (optional)Numbers the answer may introduce that aren't in the context.
must_abstainboolean (optional)Set true when the context can't answer — the answer must then decline.

Returns a GROUNDED / NOT GROUNDED verdict with named issues, plus structured output (grounded, issues, anchorsMissed, ungroundedNumbers, abstained).

Privacy

Runs entirely on your machine. check_grounding is a deterministic, local text comparison — the answer and context you pass are processed in memory and never transmitted or stored. No accounts, no analytics, no external network calls, no third-party model. Full policy: https://www.pharmatools.ai/privacy

MIT licensed.

Keywords

mcp

FAQs

Package last updated on 06 Jul 2026

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts