Edictum
Guides

Install Extras

Edictum has zero required dependencies. Install only what you need with pip extras.

AI Assistance

Right page if: you need to decide which pip install edictum[...] extras to use, or want to understand what each extra installs. Wrong page if: you need framework-specific adapter setup -- see https://docs.edictum.ai/docs/adapters/overview. For getting started quickly, see https://docs.edictum.ai/docs/quickstart. Gotcha: the base install has zero dependencies and only supports Python contracts. Most users want edictum[yaml] at minimum. The Claude SDK and Nanobot adapters need no framework-specific extra -- edictum[yaml] is sufficient.

Edictum has zero required dependencies. The base install gives you the core pipeline and Python contract support. Everything else is opt-in through pip extras.


Quick Start

Most users want YAML contracts:

pip install edictum[yaml]

Need observability too? Combine extras with commas:

pip install edictum[yaml,otel]

Want everything:

pip install edictum[all]

All Extras

ExtraWhat It InstallsWhat It Enables
(base)NothingCore pipeline, Python contracts, Principal, Edictum class
yamlPyYAML, jsonschemaYAML contract files (Edictum.from_yaml())
otelopentelemetry-api, opentelemetry-sdk, opentelemetry-exporter-otlpOTel traces and metrics for every tool call
cliClick, Rich, plus edictum[yaml]The edictum command-line interface
serverhttpx, httpx-sseServer SDK for connecting agents to Edictum Console
langchainlangchain-coreLangChain adapter
crewaicrewaiCrewAI adapter
agnoagnoAgno adapter
semantic-kernelsemantic-kernelSemantic Kernel adapter
openai-agentsopenai-agentsOpenAI Agents SDK adapter
allEverything aboveFull install

Choosing Your Extras

Base Install (zero dependencies)

pip install edictum

Use this when you write contracts as Python functions and do not need YAML files. The core Edictum class, Principal, pipeline, and all contract types work without any dependencies.

from edictum import Edictum, Principal

guard = Edictum()

@guard.pre(tools=["read_file"])
def block_dotenv(tool_name, args, principal):
    if args.get("path", "").endswith(".env"):
        return "Sensitive file denied."

YAML Contracts

pip install edictum[yaml]

This is the most common install. Adds PyYAML for parsing contract files and jsonschema for validating them against the Edictum schema. Required for Edictum.from_yaml(), Edictum.from_yaml_string(), and the contract generator.

Observability

pip install edictum[yaml,otel]

Adds the OpenTelemetry SDK and OTLP exporter. Every tool call evaluation emits an edictum.evaluate span with attributes like edictum.tool, edictum.verdict, edictum.contract_id, and edictum.environment. See the telemetry reference for the full attribute list.

CLI

pip install edictum[cli]

Installs the edictum command with validate, check, test, diff, and replay subcommands. The cli extra automatically pulls in yaml (the CLI needs to parse YAML files). See the CLI reference for usage.

Server SDK (Console)

pip install edictum[server]

Adds httpx and httpx-sse for connecting agents to a running Edictum Console instance. This enables remote contract management, human-in-the-loop approvals, fleet monitoring, and centralized audit feeds.

Framework Adapters

Install the extra matching your AI framework:

pip install edictum[langchain]        # LangChain
pip install edictum[crewai]           # CrewAI
pip install edictum[agno]             # Agno
pip install edictum[semantic-kernel]  # Semantic Kernel
pip install edictum[openai-agents]    # OpenAI Agents SDK

Each extra installs only the framework's core library as a dependency. You still need the framework itself installed in your project. The extras ensure version compatibility.

Claude SDK and Nanobot

The Claude SDK and Nanobot adapters do not require framework-specific extras. They work with the base install (or edictum[yaml] if using YAML contracts).


Common Combinations

ScenarioInstall Command
YAML contracts, no frameworkpip install edictum[yaml]
LangChain agent with YAML contractspip install edictum[yaml,langchain]
CrewAI agent with observabilitypip install edictum[yaml,crewai,otel]
CI/CD contract validationpip install edictum[cli]
Agent connected to Consolepip install edictum[yaml,server]
Full development setuppip install edictum[all]
Python-only contracts, minimal footprintpip install edictum

Version Constraints

Each extra specifies minimum compatible versions:

ExtraMinimum Version
yamlPyYAML >= 6.0, jsonschema >= 4.20
otelopentelemetry-api/sdk/exporter >= 1.20.0
langchainlangchain-core >= 0.3
crewaicrewai >= 0.80
agnoagno >= 1.0
semantic-kernelsemantic-kernel >= 1.0
openai-agentsopenai-agents >= 0.1
serverhttpx >= 0.27, httpx-sse >= 0.4
cliClick >= 8.0, Rich >= 13.0

Next Steps

Last updated on

On this page