Skip to main content

NobelAgentic (Python)

Agents that get out of your way. One kernel, three APIs, any model.

from nobelagentic import Agent, tool

@tool
def get_weather(city: str) -> str:
    """Current weather for a city."""
    return f"{city}: 31°C, humid"

agent = Agent("You help plan trips", tools=[get_weather, "web", "time"])
print(agent.run("What's the weather in Lagos right now?"))

No model named → nobelagentic picks one from whatever API key is in your environment. No schemas written → type hints and the docstring are the schema. Errors tell you what to do, not just what broke.

Install

pip install -e ".[all,dev]"      # everything
pip install -e ".[anthropic]"    # or just one provider

Set ANTHROPIC_API_KEY, OPENAI_API_KEY, GEMINI_API_KEY — or run Ollama locally and use model="ollama:llama3.1".

The three levels

Level You write Who it's for
Agent one line 90% of use cases — a model, instructions, tools
Crew (v0.3) agents + tasks + process multi-agent, role-based teams
Graph (v0.2) nodes + edges + state full control, cycles, human-in-the-loop

All three compile to the same runtime, so streaming, tracing and checkpoints behave identically everywhere.

Tools

Agent(tools=[
    my_function,          # any function — sync or async
    "web", "files",       # built-in packs
])

Built-in packs (nobelagentic tools list): web files shell time math data. Packs are lazy-loaded; shell is opt-in only.

MCP

Agent(mcp=["github", "postgres"])                       # registry names
Agent(mcp=["https://my-server.example.com/mcp"])        # remote
Agent(mcp=[{"command": "npx", "args": ["-y", "some-mcp-server"]}])

nobelagentic mcp add myserver "npx -y some-mcp-server" registers one for every project.

Handoffs

spanish = Agent("You only speak Spanish", name="spanish")
triage  = Agent("Route by language", handoffs=[spanish])
triage.run("Hola!")   # → spanish answers

Orchestration

A handoff transfers the conversation. An orchestrator keeps control — sub-agents become tools it can call, combine and build on:

researcher = Agent("You find facts.", name="researcher", tools=["web"])
writer     = Agent("You write crisp prose.", name="writer")

boss = Agent("Produce short reports. Delegate, then combine.",
             tools=[researcher.as_tool(), writer.as_tool()])
boss.run("One paragraph on African fintech")

Streaming and events

async for ev in agent.stream("..."):
    match ev:
        case TextDelta(text):        print(text, end="")
        case ToolCallStart(call):    print("calling", call.name)
        case RunEnd(output, usage):  print(usage)

Models

Agent(model="claude-opus-5-5")          # prefix → provider
Agent(model="openai:gpt-5")             # explicit
Agent(model="groq:llama-3.3-70b")       # any OpenAI-compatible host
Agent(model=MyProvider())               # bring your own

CLI

nobelagentic run "What is 15% of 240?"
nobelagentic chat --tools web,files --mcp github
nobelagentic tools list
nobelagentic mcp list | add

Roadmap

  • v0.1 ✅ provider layer · @tool · ReAct loop · streaming · packs · MCP client · handoffs · CLI
  • v0.2 graph kernel (nodes, typed state, checkpoints, resume) · Agent re-based on it
  • v0.3 Crew API · memory · guardrails · OpenTelemetry tracing · cost tracking
  • v0.4 TypeScript port from the shared spec · MCP server mode (nobelagentic serve --mcp) · tool registry (nobelagentic add tool/weather)

Layout

nobelagentic/
  agent.py        the ReAct loop + handoffs
  tools.py        @tool → JSON schema
  types.py        provider-neutral messages & events
  providers/      anthropic.py, openai_compat.py (OpenAI, Gemini, Ollama, Groq, OpenRouter, Together)
  packs/          built-in tool packs
  mcp.py          MCP client + registry
  cli.py
tests/            runs offline with a scripted FakeProvider
examples/

Run tests

pytest

Metadata

Release files for nobelagentic 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for nobelagentic 0.1.2
File Size Uploaded Provenance Actions
nobelagentic-0.1.2.tar.gz 24.4 kB Without provenance Details for nobelagentic-0.1.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for nobelagentic 0.1.2
File Interpreter ABI Platform Actions
nobelagentic-0.1.2-py3-none-any.whl Python 3 none any Details for nobelagentic-0.1.2-py3-none-any.whl

Total release size: 51.3 kB

Release files / nobelagentic-0.1.2.tar.gz

Download URL nobelagentic-0.1.2.tar.gz
Size 24.4 kB
Tags Source
SHA-256 checksum
How to use checksums
d4fff26c2da59f135273bdedac905db35c9fd2bb1619ec15898eb8f8d0f4bdfc
BLAKE2b-256 checksum
How to use checksums
8af92f0cb0c94fb09df6b74cd2f000a9b14e7713cfd52598eed59bb3f6d5551f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.2

Release files / nobelagentic-0.1.2-py3-none-any.whl

Download URL nobelagentic-0.1.2-py3-none-any.whl
Size 26.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
61666a22e6f300fa85f92c638880cb5365bde161686724debb8e41cb95456451
BLAKE2b-256 checksum
How to use checksums
2f898b7edde0fca49f4e4909e188257796ea86926e7bd78df0c7b7b13cd5a133
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.2

Security for nobelagentic 0.1.2

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.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page