Skip to main content

The Python Governance Platform for AI Agents — compliance middleware for LangGraph, CrewAI, AutoGen

Project description

Drako SDK

The Trust Layer for AI Agents — Scan for governance gaps offline. Enforce policies in production via the Drako platform.

PyPI Python License


Quick Start

1. Install

pip install drako

With framework-specific extras:

pip install drako[crewai]      # CrewAI support
pip install drako[langgraph]   # LangGraph support
pip install drako[autogen]     # AutoGen support
pip install drako[all]         # All frameworks

2. Scan Your Project (free, offline, no account needed)

drako scan .
# → Governance Score: 35/100 | 8 findings | Agent BOM: 3 agents, 12 tools
# → Run `drako auth login` to enable runtime governance

3. Connect to Platform (optional, enables runtime governance)

drako init

This will:

  • Validate your API key
  • Generate .drako.yaml config
  • Create a framework-specific middleware file
  • Enable runtime policy enforcement

4. Integrate Runtime Middleware

CrewAI

from drako import with_compliance
from my_crew import MyCrew

crew = with_compliance(MyCrew())
result = crew.kickoff()

LangGraph

from drako import with_langgraph_compliance

graph = with_langgraph_compliance(my_graph.compile())
result = graph.invoke(input)

AutoGen

from drako import with_autogen_compliance

chat = with_autogen_compliance(my_group_chat)

Direct Client

from drako import DrakoClient

client = DrakoClient.from_env()
result = client.verify_agent_identity_sync("my-agent", "researcher")

CLI Commands

Command Description Requires Account
drako scan . Scan project for governance gaps No
drako init Initialize runtime SDK in your project Yes
drako status Check connection and quota status Yes
drako verify Verify audit hash chain integrity Yes
drako serve Start a local MCP compliance server Yes

Configuration

.drako.yaml:

version: "1.0"
tenant_id: your_tenant_id
api_key_env: DRAKO_API_KEY
endpoint: https://api.getdrako.com
framework: crewai

tools:
  audit_log_action: true
  verify_agent_identity: true
  evaluate_policy: true

guardrails:
  prompt_injection_detection: true
  dlp_scanning: false

trust:
  enabled: true
  decay_half_life_hours: 168
  circuit_breaker_threshold: 3

Capabilities

Scan CLI (free, offline)

Capability Status Details
Governance Score ✅ Built-in 25 rules, 4 categories, deterministic evaluation
Agent BOM ✅ Built-in AST-based discovery, 6 frameworks
EU AI Act Gap Detection ✅ Built-in Art. 9, 11, 12, 14 mapping with fix snippets
SARIF 2.1.0 ✅ Built-in GitHub Code Scanning compatible
SVG Badge ✅ Built-in Embeddable governance badge

Runtime Platform (requires account)

Capability Status Details
Policy Enforcement ✅ Production Real-time evaluation on tool calls
DLP/PII Detection ✅ Production Presidio-based, 8+ entity types, anonymization
Circuit Breaker ✅ Production State machine + EigenTrust scoring
Audit Trail ✅ Production SHA-256/BLAKE3 hash chain + digital signatures
Trust Score ✅ Production 0-100 dynamic score per agent
OTEL Export 🔜 Next Sprint OpenTelemetry semantic conventions

Environment Variables

Variable Description Required
DRAKO_API_KEY Your API key (for runtime features) For platform
DRAKO_ENDPOINT Custom backend URL No
DRAKO_TENANT_ID Override tenant ID No

Development

git clone https://github.com/angelnicolasc/drako.git
cd drako
pip install -e ".[dev]"
pytest

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

drako-2.4.3.tar.gz (330.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

drako-2.4.3-py3-none-any.whl (263.3 kB view details)

Uploaded Python 3

File details

Details for the file drako-2.4.3.tar.gz.

File metadata

  • Download URL: drako-2.4.3.tar.gz
  • Upload date:
  • Size: 330.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.9

File hashes

Hashes for drako-2.4.3.tar.gz
Algorithm Hash digest
SHA256 ba8cc80854626e6f3bb3ed5e800d10db7761758c30ac5a7ab1ba9fc3406b8bb4
MD5 570c337733910b672c1bab507f3fd317
BLAKE2b-256 b0a3fc49104d9ca996f4766a7ce7dd1a768026eefa93a3dead1cf48c7b152232

See more details on using hashes here.

File details

Details for the file drako-2.4.3-py3-none-any.whl.

File metadata

  • Download URL: drako-2.4.3-py3-none-any.whl
  • Upload date:
  • Size: 263.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.9

File hashes

Hashes for drako-2.4.3-py3-none-any.whl
Algorithm Hash digest
SHA256 2afa2db751192072297e45860bbf911e7ca9f63794438bcbd913f1e58788b6b2
MD5 8799a54a908a02ddc3d1e0d4a324fdce
BLAKE2b-256 cf2bfd03be6024af4bf43ffc65e23a7b25363f18f8ace25ff8ddcd7b6919fdea

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page