Build LLM agents the lazy way.
LazyBridge is a zero-boilerplate, multi-provider Python framework. One
Agent class, swappable engines, and one tool contract —
everything is a tool.
from lazybridge import Agent, LLMEngine agent = Agent( engine=LLMEngine("claude-opus-4-7"), ) result = agent("hello") print(result.text())
That's the whole surface when you start — it grows only when your problem grows. Parallelism is automatic when the engine emits multiple tool calls in a turn; deterministic when you declare it.
API is intentionally fluid pre-1.0. Pin a minor (lazybridge>=0.7,<0.8) in production until 1.0.
The mental model
Every Agent is the composition Engine + Tools + State.
The same shape supports a one-shot helper, a hierarchical multi-agent system,
and a checkpointed production pipeline — only the engine=
argument changes.
- Engine. What decides next.
LLMEngineis the common case; swap forPlan(deterministic DAG),HumanEngine(approval gate), orSupervisorEngine(REPL). - Tools. Anything the agent can invoke. Functions, other
Agents,Plan-backed pipelines, MCP servers, and provider-native tools live in the sametools=[…]list. - State.
Memory(in-prompt history),Store(durable blackboard),Session(event bus and observability).
Pick your tier
Every tier is additive. Lift the lid only when the problem requires it.
One-shot, tool-calling agents
Agent · LLMEngine · Tool · NativeTool · Envelope
Real apps with state & control
Memory · Store · Session · Guard* · verify= · MCP
Production pipelines
Plan · Step · sentinels · SupervisorEngine · checkpoint
Extend the framework
BaseProvider · custom engines · OpenTelemetry · Visualizer
Function becomes a tool
No decorators. No hand-written JSON schemas. Type hints and the docstring become the tool's LLM-facing schema automatically.
from lazybridge import Agent, LLMEngine, Tool def get_weather(city: str) -> str: """Return current temperature and conditions for ``city``.""" return f"{city}: 22°C, sunny" agent = Agent( engine=LLMEngine("claude-opus-4-7"), tools=[Tool.wrap(get_weather, name="get_weather")], ) result = agent("what's the weather in Rome and Paris?") print(result.text())
Core primitives
| Symbol | What it is |
|---|---|
LLMEngine | An LLM call loop. Tool-aware, optionally streaming, retries on transient errors. |
Plan | Deterministic DAG of Steps. Validates at construction, resumes on crash. |
Tool.wrap(fn) | Lift any Python callable into a tool. Schema inferred from type hints. |
MCP.stdio / MCP.http | Mount an MCP server as a tool catalogue. Deny-by-default since 0.7.9. |
Memory · Store · Session | In-prompt history, durable blackboard, and event bus + observability. |