FortSignal DeepAgents
Deep Agents with FortSignal enforcement — every risky tool call cryptographically authorized before execution.
Every risky operation (file write, edit, execute, sub-task) is intercepted and routed through FortSignal's challenge/verify flow — only cryptographically signed intents reach your machine.
Free dev account
500 governed verifications/month, no card. Sign up at fortsignal.com/signup — API key in two minutes, passkey-only.
Before you start
- API key — Sign up at fortsignal.com/signup → Dashboard → API Keys. Your key starts with
fs_live_. - Register your agent — In the dashboard, create an agent and generate an Ed25519 keypair. Download the private key as
agent-key.json. - Create a policy — In the dashboard, create a policy defining what the agent may do (see Policy Setup for a coding-agent example). You select this policy when delegating in step 4.
- Approve a delegation — In the dashboard, approve a delegation with your passkey. Agent calls return
delegation_invaliduntil this is done.
Install
pip install fortsignal-deepagents
Quick Start
Agent mode (autonomous — Ed25519 signs each challenge automatically):
export FORTSIGNAL_API_KEY="fs_live_..."
export FORTSIGNAL_AGENT_ID="your-agent-id"
export FORTSIGNAL_AGENT_KEY="/path/to/agent-key.json"
fortsignal-deepagents --model "openai:gpt-4o"
Human mode (passkey approval required per risky action):
export FORTSIGNAL_API_KEY="fs_live_..."
export FORTSIGNAL_USER_ID="your-user-id"
fortsignal-deepagents --model "openai:gpt-4o"
One-shot prompt:
fortsignal-deepagents --model "openai:gpt-4o" --message "create hello.py with a greeting"
Agent key file
FORTSIGNAL_AGENT_KEY points to a JSON file with your Ed25519 private key:
{ "privateKey": "<base64url-encoded Ed25519 private key>" }
Generate from the dashboard (recommended), or create it manually:
from cryptography.hazmat.primitives.asymmetric.ed25519 import Ed25519PrivateKey
import base64, json
key = Ed25519PrivateKey.generate()
priv = base64.urlsafe_b64encode(key.private_bytes_raw()).rstrip(b"=").decode()
pub = base64.urlsafe_b64encode(key.public_key().public_bytes_raw()).rstrip(b"=").decode()
with open("agent-key.json", "w") as f:
json.dump({"privateKey": priv}, f)
print("Public key to register:", pub)
Register the public key in the dashboard, then approve a delegation before running.
How it works
- Agent calls a risky tool → FortSignalMiddleware intercepts it
/challenge/start— challenge bound to exact action + target- Agent signs with Ed25519 (autonomous) or human signs with passkey (human-in-the-loop)
/challenge/verify— only verified intents execute
Risky tools intercepted: write_file, edit_file, execute, eval, task, write_todos
Read-only tools pass through without any verification check.
Execution artifacts
Every allow from /challenge/verify returns an artifact — an Ed25519-signed JWT receipt bound to the exact action parameters (action, recipient, amount, source, metadata). Denies never carry one: absence of an artifact IS the deny. The middleware attaches signalId + artifact to every approved tool call's additional_kwargs["fortsignal"] — persist it with your run logs; it is cryptographic proof of what was authorized, verifiable offline against FortSignal's public JWKS (https://api.fortsignal.com/.well-known/fs-keys.json).
Python API
from fortsignal_deepagents import create_fortsignal_deep_agent
agent = create_fortsignal_deep_agent(
model="openai:gpt-4o",
agent_id="my-agent-id",
agent_key_path="/path/to/agent-key.json",
)
Or use the middleware directly:
from fortsignal_deepagents import FortSignalMiddleware
from deepagents import create_deep_agent
middleware = FortSignalMiddleware(
agent_id="my-agent-id",
agent_key_path="/path/to/agent-key.json",
)
agent = create_deep_agent(model="openai:gpt-4o", middleware=[middleware])
Environment variables
| Variable | Required | Description |
|---|---|---|
FORTSIGNAL_API_KEY |
Yes | Your fs_live_... API key |
FORTSIGNAL_AGENT_ID |
Agent mode | Your registered agent ID |
FORTSIGNAL_AGENT_KEY |
Agent mode | Path to agent-key.json |
FORTSIGNAL_USER_ID |
Human mode | Your userId for passkey approval |
FORTSIGNAL_BASE_URL |
No | Override API base (default: https://api.fortsignal.com) |
FORTSIGNAL_SOURCE |
No | Source context binding for allowedFromSources policies (e.g. production-cluster) |
FORTSIGNAL_LOG_LEVEL |
No | Log verbosity (default: WARNING) |
Development
git clone https://github.com/fortsignal/fortsignal-deepagents.git
cd fortsignal-deepagents
uv sync
uv run pytest
Full detail → api.fortsignal.com/docs
Tests
73 tests — all mock (middleware logic), no API key required.
Mock tests run offline and cover config, safe-tool passthrough, risky-tool interception, challenge/verify flow (agent + passkey modes), retry logic, API error handling, and middleware injection.
uv run pytest tests/ -v
Policy Setup
After creating an Agent Passport, create a policy in the FortSignal dashboard to define what the agent can do. Two rules to know: leave Allowed actions empty and every action is permitted — list any and only those pass. Same for recipients: empty means any target, listed patterns gate each call. A tool call that doesn't match the policy is denied and never executes.
Example for a coding agent:
| Setting | Value |
|---|---|
| Actions | edit_file, file_write, execute, write_file, task, write_todos |
Action recipients — execute |
cmd:git *, cmd:python*, cmd:uv *, cmd:pip *, cmd:pytest *, cmd:npm *, cmd:npx * |
Action recipients — task |
task:* |
The cmd: prefix is added automatically by the middleware to execute
commands so they match the per-action policy overrides. The task: prefix
is added similarly for task descriptions.
Execution budgets and human escalation (optional):
Max actions(actionBudget) — e.g. 50 actions/hour per delegation; over the cap denies withaction_budget_exceededTotal amount budget(amountBudget) — cumulative amount cap per fixed window; denies withamount_budget_exceededAlways require human approval(requiresHuman) — listed actions (or*) always deny for agents withrequires_human; the middleware will tell you to rerun in human mode (FORTSIGNAL_USER_ID) to approve
Multi-sig: delegations can require M-of-N passkey approval (dashboard → Team card to invite co-signers; approval links arrive by email; the agent can't act until the threshold activates the delegation).
License
MIT © FortSignal
Metadata
Release files for fortsignal-deepagents 0.1.14
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| fortsignal_deepagents-0.1.14.tar.gz | 12.8 kB | Without provenance | Details for fortsignal_deepagents-0.1.14.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| fortsignal_deepagents-0.1.14-py3-none-any.whl | Python 3 | none | any | Details for fortsignal_deepagents-0.1.14-py3-none-any.whl |
Total release size: 27.9 kB
Release files / fortsignal_deepagents-0.1.14.tar.gz
| Download URL | fortsignal_deepagents-0.1.14.tar.gz |
|---|---|
| Size | 12.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
cad35839c206553f05e5c7621bd1a6633ff5ca6e0f25628e413c6412aaadfd18
|
|
BLAKE2b-256 checksum How to use checksums |
540a04270c7ee4cd5c20be13efd69b6c5d6d4ebde9f36403e5ef7572446aba7b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.11 {"installer":{"name":"uv","version":"0.11.11","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Fedora Linux","version":"43","id":"","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / fortsignal_deepagents-0.1.14-py3-none-any.whl
| Download URL | fortsignal_deepagents-0.1.14-py3-none-any.whl |
|---|---|
| Size | 15.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
281d5f9a6ec478508c2bed065d981ffb47a0ad8335d9476e21c23a1e312f22fc
|
|
BLAKE2b-256 checksum How to use checksums |
819c9731c9e21d867dfbde08caac39323a784040957db7518daae69902a66ec9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.11 {"installer":{"name":"uv","version":"0.11.11","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Fedora Linux","version":"43","id":"","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Security for fortsignal-deepagents 0.1.14
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.