langchain-sidclaw
SidClaw governance integration for LangChain — policy evaluation, human approval, and audit trails for AI agent tools.
What it does
Wraps your LangChain tools with governance. Before any tool executes:
- Allowed actions run immediately
- High-risk actions require human approval (reviewer gets a notification)
- Prohibited actions are blocked before execution
- Every decision is logged with a tamper-proof audit trail
Installation
pip install langchain-sidclaw
Quick Start
Option 1: Enforce policies (recommended)
from langchain_sidclaw import govern_tools
from sidclaw import SidClaw
client = SidClaw(
api_key="ai_...",
base_url="https://api.sidclaw.com",
agent_id="your-agent-id",
)
# Wrap your existing tools — no changes to tool code
governed = govern_tools(my_tools, client=client, data_classification="confidential")
# Use governed tools in your agent
agent = create_tool_calling_agent(llm, governed, prompt)
Option 2: Monitor only (audit without blocking)
from langchain_sidclaw import GovernanceCallbackHandler
handler = GovernanceCallbackHandler(client=client)
agent = create_tool_calling_agent(llm, tools, prompt, callbacks=[handler])
# Every tool call is logged to SidClaw, but nothing is blocked
Configure policies
Create policies in the SidClaw dashboard or via API. Example policy effects:
| Policy Effect | Behavior |
|---|---|
allow |
Tool executes immediately |
approval_required |
Blocks until a human approves in the dashboard |
deny |
Raises ActionDeniedError, tool never executes |
Links
Release files for langchain-sidclaw 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| langchain_sidclaw-0.1.1.tar.gz | 8.0 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| langchain_sidclaw-0.1.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 16.1 kB
Release files / langchain_sidclaw-0.1.1.tar.gz
| Download URL | langchain_sidclaw-0.1.1.tar.gz |
|---|---|
| Size | 8.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
c0c596dfe457461bacec0c99aae43e7fa6583c91f9a0364355f3e09d83b9de22
|
|
BLAKE2b-256 checksum How to use checksums |
0b4731eb1855b2d0e78111fb34bb63fd855bccc2f6a05ec25c2d53aab803c63b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.5
|
Release files / langchain_sidclaw-0.1.1-py3-none-any.whl
| Download URL | langchain_sidclaw-0.1.1-py3-none-any.whl |
|---|---|
| Size | 8.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e70530a7cc5c06198759e42cfe0cf943ceba33d3c65291bd7b3ee3fbf30ce2b5
|
|
BLAKE2b-256 checksum How to use checksums |
061153e9888c8f0bdbc230ee7e92c5a51a9e23a63573203395d6c7b398122fd0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.5
|