AIP identity and delegation for AI agent frameworks
Project description
aip-agents
AIP identity and delegation for AI agent frameworks. Add cryptographic identity, scoped delegation chains, and audit-ready token flows to your agents in 5 lines of code.
Supports CrewAI, Google ADK, and LangChain.
Install
pip install aip-agents[crewai] # CrewAI
pip install aip-agents[adk] # Google ADK
pip install aip-agents[langchain] # LangChain
pip install aip-agents[all] # All frameworks
Quick Start: CrewAI
from crewai import Crew, Agent, Task
from aip_agents.adapters.crewai import AIPCrewPlugin
plugin = AIPCrewPlugin()
researcher = Agent(role="researcher", ...)
writer = Agent(role="writer", ...)
crew = Crew(agents=[researcher, writer], tasks=[...])
plugin.register(crew) # Each agent gets an AIP identity + delegation token
crew.kickoff()
Quick Start: Google ADK
from google.adk import Agent, Runner
from aip_agents.adapters.adk import AIPAdkPlugin
plugin = AIPAdkPlugin()
agent = Agent(name="coordinator", sub_agents=[worker1, worker2], ...)
runner = Runner(agent=agent)
plugin.register(runner) # Walks agent tree, creates delegation chains
runner.run("task")
Quick Start: LangChain
from langchain.agents import AgentExecutor, create_tool_calling_agent
from aip_agents.adapters.langchain import AIPLangChainPlugin
plugin = AIPLangChainPlugin()
# Register single agent
plugin.register(agent_executor, name="researcher")
# Or register multiple agents (supervisor pattern)
plugin.register_agents({
"researcher": researcher_executor,
"writer": writer_executor,
})
# Get headers for tool calls
headers = plugin.get_tool_call_headers("researcher")
# {"X-AIP-Token": "eyJ..."}
What You Get
When you register a plugin, every agent gets:
- Cryptographic identity - An Ed25519 keypair and AIP identifier (
aip:key:ed25519:z...) - Delegation chain - When a parent agent delegates to a sub-agent, a Biscuit token chain records the delegation with attenuated scope
- Tool call headers -
X-AIP-Tokenheaders ready to attach to outgoing tool/MCP calls
Enable logging to see it in action:
from aip_agents import AIPConfig
plugin = AIPCrewPlugin(AIPConfig(log_tokens=True))
Output:
[AIP] Identity created: researcher -> aip:key:ed25519:z6Fk3...
[AIP] Delegation: manager -> researcher [scope: web_search] [chain depth: 2]
[AIP] Tool call: researcher -> web_search [chain depth: 3, verified]
Configuration
AIPConfig(
app_name="my-app", # Root identity label
auto_identity=True, # Auto-assign identity to every agent
auto_delegation=True, # Auto-create delegation chains
persist_keys=False, # Save keys to ~/.aip/keys/
log_tokens=False, # Log token operations
default_scope=None, # Default scope for root token
)
How It Works
- Identity: Each agent gets an Ed25519 keypair. The public key becomes the agent's AIP identifier.
- Tokens: Authority tokens use Biscuit - an append-only cryptographic token that enforces scope can only narrow, never widen.
- Delegation: When Agent A delegates to Agent B, a new block is appended to A's token with B's identity and attenuated scope. The chain is cryptographically verifiable.
- Tool calls: Tokens are attached via
X-AIP-Tokenheader, compatible with AIP MCP middleware for end-to-end verification.
Links
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file aip_agents-0.2.2.tar.gz.
File metadata
- Download URL: aip_agents-0.2.2.tar.gz
- Upload date:
- Size: 8.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5452761a42095158ac20016340ef4723cf25ec0dcd078603bcf1a8470188f132
|
|
| MD5 |
e615cad63e4083608e403df05f2e31d3
|
|
| BLAKE2b-256 |
e981d344138e7c806e2a69d9ea0b6bcad70a324b723777dee74c289c47496a37
|
Provenance
The following attestation bundles were made for aip_agents-0.2.2.tar.gz:
Publisher:
publish-aip-agents.yml on sunilp/aip
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
aip_agents-0.2.2.tar.gz -
Subject digest:
5452761a42095158ac20016340ef4723cf25ec0dcd078603bcf1a8470188f132 - Sigstore transparency entry: 1467809209
- Sigstore integration time:
-
Permalink:
sunilp/aip@6948b4a8b2cf7765cbbd2d924f40d663bab06163 -
Branch / Tag:
refs/tags/aip-agents-v0.2.2 - Owner: https://github.com/sunilp
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-aip-agents.yml@6948b4a8b2cf7765cbbd2d924f40d663bab06163 -
Trigger Event:
push
-
Statement type:
File details
Details for the file aip_agents-0.2.2-py3-none-any.whl.
File metadata
- Download URL: aip_agents-0.2.2-py3-none-any.whl
- Upload date:
- Size: 14.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d715aeca97505ebbb1bf3cecf58760ae550a7cb86129f2634e70cda85577b055
|
|
| MD5 |
dc211aa57dd654a8aa798a0b652a8b8d
|
|
| BLAKE2b-256 |
17bf66b6101cd1364d07f93bedf478a1b0fcea9bc7d310a0361d7898f39c5c91
|
Provenance
The following attestation bundles were made for aip_agents-0.2.2-py3-none-any.whl:
Publisher:
publish-aip-agents.yml on sunilp/aip
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
aip_agents-0.2.2-py3-none-any.whl -
Subject digest:
d715aeca97505ebbb1bf3cecf58760ae550a7cb86129f2634e70cda85577b055 - Sigstore transparency entry: 1467809394
- Sigstore integration time:
-
Permalink:
sunilp/aip@6948b4a8b2cf7765cbbd2d924f40d663bab06163 -
Branch / Tag:
refs/tags/aip-agents-v0.2.2 - Owner: https://github.com/sunilp
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-aip-agents.yml@6948b4a8b2cf7765cbbd2d924f40d663bab06163 -
Trigger Event:
push
-
Statement type: