Skip to main content

A production-ready framework for building safe, capable, and observable AI agents with native connector integrations.

Project description

pycelest — AI Agent Framework

Build · Orchestrate · Defend · Connect A production-ready Python framework for safe, capable, and observable AI agents.

PyPI version Python 3.11+ License


What is pycelest?

pycelest is a Python framework for building AI agents that are safe, capable, and observable — designed from day one for production deployment, not just demos.

Unlike frameworks that bolt guardrails on as an afterthought, pycelest puts security, traceability, and reliability at the center of its architecture.


Features

Feature Description
🔁 ReAct Loop Native Reasoning + Acting loop
🌐 Multi-Provider OpenAI · Anthropic · Google · Mistral · DeepSeek · Ollama · LM Studio
🧠 Memory STM · Scratchpad · RAG · automatic compression
🛡️ Guardrails Tool Firewall · Execution Budget · token limits
👥 Multi-Agent Native agent collaboration via AgentBus
📡 Streaming First-class async token streaming
🔌 Plugins Lifecycle hooks: on_session_start, on_turn_end, on_tool_call
🔗 MCP Client MCPAdapter — consume any MCP server as agent tools
🖥️ MCP Server MCPServer — expose any agent as an MCP server (stdio / SSE)
📬 Native Connectors Gmail · Slack · Notion · Meta (Facebook + Instagram)
📊 Langfuse LangfusePlugin — full LLM observability out of the box
⚙️ YAML Config Code or YAML — your choice

Installation

# Core framework
pip install pycelest

# With providers
pip install pycelest[anthropic]   # Claude
pip install pycelest[openai]      # GPT-4o, Gemini, DeepSeek, Mistral, Grok

# Extras
pip install pycelest[mcp]         # MCP client + server
pip install pycelest[langfuse]    # Observability
pip install pycelest[gmail]       # Gmail connector
pip install pycelest[rag]         # ChromaDB RAG

# Everything
pip install pycelest[all]

Quick Start

import asyncio
from celest import SessionManager, SessionConfig
from celest.providers import AnthropicAdapter

config = SessionConfig(
    system_prompt="You are a helpful, careful AI agent.",
    max_iterations=8,
)

session = SessionManager(
    config=config,
    provider=AnthropicAdapter(model="claude-sonnet-4-6", api_key="sk-ant-..."),
)

result = asyncio.run(session.run("Plan a 3-day trip to Kyoto"))
print(result.response)

Local Models (no API key)

from celest.providers import OllamaAdapter

session = SessionManager(
    config=config,
    provider=OllamaAdapter(model="llama3.2"),
)

Install Ollama from ollama.com, then ollama pull llama3.2.


With Tools

from celest.tools import FunctionTool

@FunctionTool.register(description="Search the web for current information")
async def web_search(query: str) -> str:
    ...

session = SessionManager(config=config, provider=provider, tools=[web_search])
result = await session.run("What are the latest AI news?")

MCP Client — consume any MCP server

from celest.tools.mcp import MCPAdapter

# Stdio (local subprocess)
async with MCPAdapter(command="uvx", args=["mcp-server-time"]) as mcp:
    tools = await mcp.discover_tools()
    session = SessionManager(config=config, provider=provider, tools=tools)

# SSE (remote server) with auth + auto-reconnect
async with MCPAdapter(
    url="https://my-mcp-server.com/sse",
    headers={"Authorization": "Bearer sk-..."},
    auto_reconnect=True,
) as mcp:
    tools = await mcp.discover_tools()

MCP Server — expose your agent as an MCP server

from celest import SessionManager, SessionConfig, MCPServer
from celest.providers import AnthropicAdapter

def make_session():
    return SessionManager(
        config=SessionConfig(system_prompt="You are a helpful assistant."),
        provider=AnthropicAdapter(model="claude-sonnet-4-6", api_key="sk-ant-..."),
    )

server = MCPServer(session_factory=make_session, name="my-agent")
server.run_stdio()   # or server.run_sse(port=8080)

Add to claude_desktop_config.json:

{
  "mcpServers": {
    "my-agent": {
      "command": "python",
      "args": ["my_agent.py"]
    }
  }
}

Native Connectors

from celest.connectors.native.gmail import GmailConnector
from celest.connectors.native.slack import SlackConnector
from celest.connectors.native.notion import NotionConnector

gmail = GmailConnector(access_token="ya29....")
tools = gmail.get_tools()   # gmail_send, gmail_read

slack = SlackConnector(bot_token="xoxb-...")
tools += slack.get_tools()  # slack_send, slack_read

session = SessionManager(config=config, provider=provider, tools=tools)

Observability with Langfuse

pip install pycelest[langfuse]
from celest.plugins.langfuse import LangfusePlugin

plugin = LangfusePlugin(
    public_key="pk-lf-...",
    secret_key="sk-lf-...",
    host="https://cloud.langfuse.com",
    agent_name="my-agent",
)

session = SessionManager(config=config, provider=provider, plugins=[plugin])
# Every run is now traced in Langfuse: turns, tool calls, tokens, latency

YAML Config

# celest.yaml
system_prompt: "You are a helpful AI agent"
max_iterations: 8
provider: anthropic
model: claude-sonnet-4-6
guardrails:
  tool_firewall: ask   # accept | deny | ask
session = SessionManager.from_yaml("celest.yaml")
result = await session.run("Your task here")

CLI

celest init                           # Generate starter celest.yaml
celest run celest.yaml "Your prompt"  # Run agent from config

Changelog

Version Highlights
v0.5.0 MCPServer (stdio + SSE) · MCPAdapter auto-reconnect + auth headers
v0.4.0 LangfusePlugin — full LLM observability
v0.3.0 Native connectors: Gmail · Slack · Notion · Meta
v0.2.0 Plugin system · AgentBus · Streaming · OpenTelemetry
v0.1.2 MCP client · RAG · Compression · YAML config

License

Proprietary © 2026 Lovanirainy Theogene Eddy Celestin RAFANOMEZANA — flycelest.com

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pycelest-0.9.0.tar.gz (672.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pycelest-0.9.0-py3-none-any.whl (121.8 kB view details)

Uploaded Python 3

File details

Details for the file pycelest-0.9.0.tar.gz.

File metadata

  • Download URL: pycelest-0.9.0.tar.gz
  • Upload date:
  • Size: 672.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for pycelest-0.9.0.tar.gz
Algorithm Hash digest
SHA256 eb996523d58fe66015cba1ecf7affad6ad13ab5754cca021c11c94c631aeab96
MD5 535d6d55fb00a74bcd7c981450b40eb5
BLAKE2b-256 0c960d94b9eb41382b37a180e77bf8131b719dc029fced7b3a3cd4be5c7b52a8

See more details on using hashes here.

File details

Details for the file pycelest-0.9.0-py3-none-any.whl.

File metadata

  • Download URL: pycelest-0.9.0-py3-none-any.whl
  • Upload date:
  • Size: 121.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for pycelest-0.9.0-py3-none-any.whl
Algorithm Hash digest
SHA256 8627e11d2521051cdbe4dd0741298fb03adc7c33a366bcbe1dbea84f526ea1b7
MD5 47634abfbf4751d2e9e4231a0f646357
BLAKE2b-256 41a2ea1fdb5dac669e62e1be0fa4cb479dfaad93b009342cbebdb007843cceb1

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page