cd /news/ai-agents/integrating-langgraph-with-maref-pro… · home topics ai-agents article
[ARTICLE · art-96333] src=maref.cc ↗ pub= topic=ai-agents verified=true sentiment=· neutral

Integrating LangGraph with MAREF — Protocol-Level Governance That Works Today

MAREF Engineering announced that its protocol-level governance integration with LangGraph, using MCP and A2A, is live and tested, while the native LangGraphAdapter remains on the roadmap. The MCPBridge wraps tool calls in a security gate, and the A2ABridge governs multi-agent task lifecycles, both providing audit logging and halt capabilities. The AutoGen adapter is already shipped, but the LangGraph native adapter is specified but not yet merged.

read3 min views1 publishedAug 14, 2026
Integrating LangGraph with MAREF — Protocol-Level Governance That Works Today
Image: Maref (auto-discovered)

By MAREF Engineering

If you're building production agents in 2026, there's a good chance they're a LangGraph state graph. Nodes, edges, conditional routing — elegant, testable, and — until you add a governance layer — completely unsupervised. This guide shows the two ways to govern a LangGraph app with MAREF, and it's honest about which is ready today.

TL;DR: the protocol-level path (MCP + A2A) is live and tested; the native LangGraphAdapter

documented in the quickstart is on the roadmap, with the AutoGen sidecar adapter already shipped.

The honest status, first #

MAREF's quickstart documents a sidecar.adapters.langgraph.LangGraphAdapter

with three methods — evaluate_node_safety

, observe_transition

, and inject_governance

. We want to be direct with you: that adapter is specified but not yet merged. The AutoGen adapter (sidecar.adapters.autogen.AutoGenAdapter

) is live; LangGraph's native adapter is being built to the same contract.

What that means for you: you should not block on the adapter. The protocol-level integration below uses only shipped, tested code paths and gives you the same governance guarantees today.

Path 1 — Govern tool calls inside a LangGraph node (MCP) #

LangGraph nodes call tools. Those tools are where the blast radius lives. Wrap them with MCPBridge

and every call from any node goes through the security gate — with the same event stream you can feed your audit log:

from langgraph.graph import StateGraph
from maref.integration.mcp_client import MCPClient, MCPServerConfig
from maref.integration.mcp_bridge import MCPBridge

client = MCPClient()
conn = client.register_server(MCPServerConfig(
    command=["npx", "-y", "@your/tool-server"],
    transport_type="stdio",
    server_name="tool-server",
))
bridge = MCPBridge(client)                      # wraps calls in the security gate

def tool_node(state):
    return bridge.invoke_tool(
        conn,
        tool_name=state["tool"],
        args=state["args"],
    )

graph = StateGraph(dict)
graph.add_node("tools", tool_node)
graph.add_edge("__start__", "tools")

A DENY verdict returns {"error": "Tool blocked by security gate", ...}

— the external server is never called, and the node's __error__

edge or fallback logic can route around it. Your LangGraph topology stays exactly as designed; MAREF just sits at every tool boundary.

Path 2 — Govern whole tasks across agents (A2A) #

For multi-agent LangGraph deployments — several graphs, maybe a supervisor — the A2ABridge

makes MAREF itself an A2A-governed agent that creates, delegates, and halts tasks across the federation:

from maref_lite.state_machine import GovernanceStateMachine
from maref.governance.audit import AuditLogger
from maref.integration.a2a_bridge import A2ABridge

bridge = A2ABridge(
    state_machine=GovernanceStateMachine(),
    audit_logger=AuditLogger(log_path="maref-audit.jsonl"),
    agent_name="langgraph-supervisor",
)

task_id = bridge.create_task("Summarize Q3 report")    # governed lifecycle
bridge.delegate_task(task_id, "https://other-agent.local:8000")

bridge.force_halt_task(task_id, reason="scope change")

Every create_task

, delegation, and state change is HMAC-signed into the audit log and runs through the same governance state machine — OBSERVE → ANALYZE → EVALUATE → DECIDE → ACT → VERIFY → STABILIZE → REPORT

, with HALT

reachable by any authorized human or the circuit breaker.

The result: your LangGraph graphs keep their orchestration logic, while MAREF owns the "is this safe?" decision at every boundary — tool calls, inter-agent handoffs, and task lifecycle.

Which path should you pick? #

Single graph, several tools→ Path 1 (MCP bridge on tool calls). Minimal change, immediate audit trail.** Multiple graphs / supervisor pattern→ Path 2 (A2A). You get task lifecycle governance, delegation, and a kill-switch across the whole fleet. Both**→ They compose. MAREF governs tool callsandtask orchestration simultaneously — that's the 8-layer architecture working as designed.

*🛡️ Sources: MAREF source — src/maref/integration/mcp_bridge.py (MCPBridge.invoke_tool), src/maref/integration/a2a_bridge.py (A2ABridge.create_task / delegate_task / force_halt_task), src/sidecar/adapters/autogen.py (shipped sidecar adapter). LangGraph adapter contract defined in docs/quickstart.md §3.3 (roadmap — AutoGen adapter shipped). *

Quickstart·

Integrations.

── more in #ai-agents 4 stories · sorted by recency
── more on @maref engineering 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
Live at https://your-agent.zahid.host
Get free account → Pricing
from €0/mo · no card required
LIVE [news/integrating-langgrap…] indexed:0 read:3min 2026-08-14 ·