How abisheakp197/langchain-nti works
langchain-nti is a LangChain callback integration that applies NTI security checks around tool execution. The principal workflow is: an agent starts a tool, the callback submits the action for policy evaluation, and strict mode blocks a denied action; on completion, optional response-signature verification checks the tool output. The callback also exposes signing and voter registration. The README documents capability enforcement, BFT consensus, Merkle audit, and agent-mesh persistence as TrustEngine responsibilities. Those internals are not sampled, so their detail and wiring are shown only as documented capabilities.
Main entry points: callback.py Callback handler
Components 10
LangChain integration
- Callback handler
langchain_nti/callback.py - Output verification
langchain_nti/callback.py
NTI security
- TrustEngine
- Capability enforcement
- BFT consensus
- Merkle audit trail
- Agent mesh state
- PQC keypair
Other components
- LangChain agent
- LangChain tool
Connections 12
- LangChain agent → Callback handler: starts tool
README.md - Callback handler → TrustEngine: evaluates action
README.md - TrustEngine → Capability enforcement: enforces
README.md - TrustEngine → BFT consensus: handles
README.md - TrustEngine → Merkle audit trail: records
README.md - TrustEngine → Agent mesh state: persists state
README.md - Callback handler → PQC keypair: creates or accepts
langchain_nti/callback.py - Callback handler → PQC keypair: signs and verifies
langchain_nti/callback.py - Callback handler → TrustEngine: registers voter keys
langchain_nti/callback.py - Callback handler → LangChain tool: blocks denied action
README.md - LangChain tool → Callback handler: returns output
README.md - Callback handler → Output verification: optionally checks
langchain_nti/callback.py