Harness integrations
Orchestration frameworks (LangGraph, Inspect AI, eval runners, shell agents) integrate with Attestack via callback adapters or session wrappers. Editor agents (Cursor, Claude Code) should use Agent setup and MCP instead.
Callback adapter (LangGraph)
Section titled “Callback adapter (LangGraph)”LangGraph and LangChain emit tool and model lifecycle events through BaseCallbackHandler. The reference handler hashes payloads and appends Attestack ai.* events via the CLI.
from attestack_callback import AttestackCallbackHandler, attestack_session
handler = AttestackCallbackHandler()
with attestack_session("my graph run"): graph.invoke( {"messages": [("user", "…")]}, config={"callbacks": [handler]}, )Example: examples/harnesses/langgraph/
| LangChain callback | Attestack event |
|---|---|
| Tool end | ai.tool_call (input + output hashes) |
| Model start / end | ai.prompt + ai.response hashes |
record_decision() | ai.decision |
Run the demo (no API key):
cd examples/harnesses/langgraph./run_demo.shattestack verify .attestack/bundles/*.attestack.zip --strictCallback adapter (Inspect AI)
Section titled “Callback adapter (Inspect AI)”Inspect AI hooks (on_sample_event, on_run_start, on_run_end) map completed tool/model events to Attestack. Uses mockllm/model in the demo — no API key.
Example: examples/harnesses/inspect-ai/
cd examples/harnesses/inspect-ai./run_demo.shImport your hooks module from the task file so @hooks registers before inspect eval runs.
Session wrapper (OpenHands, Aider, eval runners)
Section titled “Session wrapper (OpenHands, Aider, eval runners)”Any harness that runs shell commands can wrap a session without code changes to Attestack:
| Harness | Example |
|---|---|
| OpenHands | examples/harnesses/openhands/ |
| Aider | examples/harnesses/aider/ |
| Generic | scripts/agent-session.sh |
./scripts/agent-session.sh start "eval run"attestack run -- npm test # optional: record subprocess steps./scripts/agent-session.sh finish # stop + bundle create + verifyOpenHands and Aider include run-with-evidence.sh wrappers you can copy or call from your project root.
Production use in your repo
Section titled “Production use in your repo”Merge Attestack MCP into an existing Cursor config (keeps your other MCP servers):
/path/to/attestack/scripts/dogfood-agent.sh --merge cursorAdd project scripts for daily use — see Kiket’s evidence-session.sh and pnpm evidence:* wrappers as a reference implementation.
CI entrypoints
Section titled “CI entrypoints”GitHub Actions, Dagger, Earthly, and Nix: see CI integration and examples/github-actions/.
Pull requests on GitHub get an automated evidence summary comment when the CI evidence workflow runs.
Verify
Section titled “Verify”Every integration should produce a bundle that passes:
attestack verify .attestack/bundles/*.attestack.zip --strictRaw prompts and tool I/O are not stored by default — only SHA-256 hashes.