Skip to content
Phronesis v0.1.0 alpha is availableRead the announcement
Phronesis

Open source · Apache 2.0 · Python 3.11+

Practical wisdom for AI agent systems.

Phronesis (φρόνησις): for Aristotle, practical wisdom — the capacity to deliberate well and act with judgment in concrete situations. An LLM has episteme (knowledge). An agent needs phronesis.

hello_phronesis.py
from phronesis import Agent, anthropic

researcher = Agent(
    name="researcher",
    model=anthropic("claude-opus-4-7"),
    system_prompt="You investigate questions thoroughly and cite sources.",
)

answer = await researcher.run("What is phronesis in Aristotelian ethics?")

Why Phronesis

An agent is not a chatbot with tools.

LLMs know things — that is episteme. But agents must decide and act with judgment in concrete situations. That is phronesis. Most agent frameworks treat agents as enhanced chatbots glued to a tool-use loop. Phronesis treats them as deliberating systems with explicit contracts: typed inputs, declared effects, bounded memory, named execution patterns.

Existing frameworks force a choice. On one side, you write arbitrary control flow as code: maximal expressiveness, and a multi-agent system that nobody can debug six months later. On the other, everything is described in YAML or graph-builders: legible at a glance, impossible the moment you need something non-trivial. Phronesis separates declarative specification from runtime execution. Agents, tools, memory, pipelines are typed, immutable, JSON-serializable specs. Execution patterns come from a closed, well-defined catalog — expressiveness without chaos.

Every run is observable through OpenTelemetry, every spec is versionable, every contract is a runtime check, not a comment in a prompt. This is the difference between a framework that produces demos and one that produces systems you can operate.

Code tour

The API in four snippets.

Real Python. Real shape. The framework you see below is in early alpha — the surface area will grow, but the design will stay this lean.

An agent binds a model, tools, and memory under a single declarative spec.

agent.py
from phronesis import Agent, anthropic
from phronesis.memory import SemanticMemory

agent = Agent(
    name="assistant",
    model=anthropic("claude-opus-4-7"),
    tools=[search_web, read_file],
    memory=SemanticMemory(scope="session"),
    system_prompt="You are a careful research assistant.",
)

Patterns

Designed for the agent shapes that recur.

These are patterns the framework supports today. They are not case studies — we have no production users to claim yet, and we will not pretend otherwise.
  • Research agents

    Agents that gather information, reason over it, and synthesize answers with citations.

  • Document agents

    Agents that read, structure, and act on documents with explicit memory of what they have seen.

  • Multi-agent pipelines

    Pipelines composing specialized agents through handoffs, debate, or consensus.

  • Tool-using assistants

    Agents that invoke typed tools and MCP servers under explicit safety contracts.

Principles

Six choices, applied everywhere.

  • Composition over inheritance

    Agents are configured from parts — model, tools, memory, prompts — not subclassed. You assemble; you don't override.

  • Async-first

    Streaming, concurrency, and cancellation are baseline assumptions. There is no synchronous shadow API to maintain.

  • Strongly typed

    Pydantic v2 throughout. Types are not documentation — they are runtime contracts the framework enforces.

  • Immutable specs, mutable runs

    Definitions are JSON-serializable and reproducible. Execution state lives apart, observable and queryable.

  • Observability built in

    OpenTelemetry spans for every agent run, tool call, and pipeline stage — from the first commit, not bolted on.

  • Closed catalog of execution patterns

    Sequence, Parallel, ReActLoop, Consensus, Debate, Handoff. Named modes you can reason about — not arbitrary control flow.

What's inside

A small, principled surface.

The framework is intentionally narrow. Each layer earns its place by either making a system safer to operate or making the code simpler to read six months later.

Core

The primitives every agent is built from.

  • Agents
  • Tools
  • MCP integration
  • Prompts
  • Capabilities

State and context

How agents remember and what they share.

  • Memory (episodic, semantic, working, shared)
  • Context management
  • Sessions

Orchestration

How agents compose into systems.

  • Pipelines
  • Execution modes
  • Inter-agent communication
  • Policies
  • Observability

Install

One command. Python 3.11 or newer.

$pip install phronesis-framework

Project status

Phronesis is in early alpha.

The API will change. We are working in public to build a framework that takes agent systems seriously — typed, composable, observable. No production claims, no fabricated case studies, no enterprise gates. Just the code, and an honest commitment to its design.

Feedback, ideas, and contributions are welcome through GitHub Discussions and Issues. The roadmap, the rough edges, and the open questions are all in the repository.