Skip to main content

verificate-langchain

A veto gate for AI-written code in LangChain / LangGraph. Your agent writes code; Verificate runs it through 17 deterministic reality gates (mock/placeholder veto, invented-API checks, false-completion detection) plus a frontier-model review, and can veto. An agent that ships confident-but-wrong code loses its user's trust — this is the safety net that keeps it shipping.

pip install verificate-langchain

25 free validations per machine — no signup, no token. After that, pass a token (30-day trial, no card: https://verificate.ai/auth/signup).

One-shot check

from verificate_langchain import validate

v = await validate("def refund(order_id, amount):\n    pass  # TODO real refund")
print(v.approved)     # False — the mock refund path is vetoed
print(v.findings)     # ['[code_reality_gate] Placeholder detected ...', ...]

Verdict is truthy iff approved, so if await validate(code): ship(code) reads naturally.

As a LangGraph guardrail node

from verificate_langchain import VerificateGuardrail
from langgraph.graph import StateGraph, START, END

gate = VerificateGuardrail(max_attempts=3)           # optional token=...

g = StateGraph(dict)
g.add_node("write", write_code)                       # your codegen node, sets state["code"]
g.add_node("gate", gate.node)                         # sets state["verdict"] / ["findings"]
g.add_edge(START, "write")
g.add_edge("write", "gate")
g.add_conditional_edges("gate", gate.route, {"fix": "write", "done": END, "give_up": END})
app = g.compile()

The output must pass through the gate node — the veto is structural, not an optional tool call the agent can skip under pressure.

Load the raw tools

from verificate_langchain import load_verificate_tools

tools = await load_verificate_tools()   # validate_ai_output, validate_plan, analyze_code, generate_code
agent = create_react_agent(model, tools + your_other_tools)

What it catches (real, verbatim)

"N+1 synchronous API calls … 100 sequential HTTP roundtrips … will trigger Stripe rate limiting" · "stripe.Inventory is not a valid Stripe SDK resource" · "Stripe API requires integer cents"

Read-only: code is analyzed, never executed, never trained on. https://verificate.ai/privacy

Uses the official langchain-mcp-adapters against the hosted Verificate MCP server. All clients + one-click installs: https://github.com/Verificate-Dev/verificate-mcp-quickstart

Metadata

Release files for verificate-langchain 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for verificate-langchain 0.1.0
File Size Uploaded
verificate_langchain-0.1.0.tar.gz 5.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for verificate-langchain 0.1.0
File Interpreter ABI Platform
verificate_langchain-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 10.8 kB

Release files / verificate_langchain-0.1.0.tar.gz

Download URL verificate_langchain-0.1.0.tar.gz
Size 5.1 kB
Tags Source
SHA-256 checksum
How to use checksums
bdb861e30fda504600ece25d3d4ec2b6fe329145ce920cffb84008bd49b6d2d7
BLAKE2b-256 checksum
How to use checksums
11a8beea526e6b5f3182f44c57477e4334bffe4ac4229d4f06ed06330b484f9b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.10

Release files / verificate_langchain-0.1.0-py3-none-any.whl

Download URL verificate_langchain-0.1.0-py3-none-any.whl
Size 5.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
88d7fb2979f607a105abb784c864cf77f7bd01d340c9e5da26d395aef621f085
BLAKE2b-256 checksum
How to use checksums
5760062c753229e24d825a34d06acb99301cd39effa3c48a9fd9c207d3649d15
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.10

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page