Skip to main content

A comprehensive Python framework for building and deploying AI agents with multi-model support and advanced capabilities

Project description

🤖 Buddy AI

A model-agnostic Python framework for building production-grade AI agents

PyPI version Python 3.10+ License: MIT GitHub stars

Documentation · GitHub · CHANGELOG · Examples


What is Buddy AI?

Buddy AI is a comprehensive Python framework for creating, deploying, and managing intelligent AI agents. It provides a unified interface across 25+ LLM providers, a powerful memory system, extensible tools, RAG-based knowledge management, multi-agent teams, and workflows — all production-ready out of the box.

New in v2.1.0 → PULSE — give your AI an employee identity, teach it through interactive knowledge transfer, have it attend meetings, manage tasks, and more.


Installation

# Core install
pip install buddy-ai

# With all optional dependencies (recommended)
pip install buddy-ai[all]

# Specific providers
pip install buddy-ai[openai]
pip install buddy-ai[anthropic]
pip install buddy-ai[google]
pip install buddy-ai[groq]

Quick Start

from buddy import Agent
from buddy.models.openai import OpenAIChat

agent = Agent(
    name="Assistant",
    model=OpenAIChat(),
    instructions="You are a helpful assistant."
)

response = agent.run("What can you do?")
print(response.content)

✨ PULSE — Virtual Employee's ERA

The flagship feature of v2.1.0

PULSE turns a Buddy AI agent into a fully-functional virtual human team member — complete with a professional identity, the ability to learn from documents and live human sessions (KT), attend meetings, manage tasks, and communicate across channels.

Launch the PULSE web UI

pip install buddy-ai[all]

# Set your LLM key
export OPENAI_API_KEY=sk-...

# Start the dashboard (or configure the key inside the UI)
buddy pulse start
# Open http://localhost:8888

Or use PULSE in Python

from buddy.pulse import PulseEmployee
from buddy.pulse.identity import EmployeeProfile
from buddy.models.openai import OpenAIChat

# Create the employee
priya = PulseEmployee(
    employee_profile=EmployeeProfile(
        full_name="Priya Sharma",
        role="Senior Backend Engineer",
        department="Engineering",
        skills=["Python", "FastAPI", "PostgreSQL"],
        timezone="Asia/Kolkata",
    ),
    model=OpenAIChat(id="gpt-4o"),
)

# Introduce herself
print(priya.introduce_yourself())

# Learn from a document
summary = priya.take_kt(
    source="architecture.md",
    session_name="Payments Architecture",
    knowledge_giver="Arjun Nair",
)
print(f"Confidence: {summary.confidence_score:.0%}")
print(f"Mental model: {summary.mental_model}")

# Start a live interactive KT session
session = priya.start_live_kt(
    session_name="Auth Service Deep Dive",
    knowledge_giver="Rahul",
)

# Human explains, Priya asks targeted questions
turn = session.human_explains("Our auth uses JWT with RS256...")
print(turn.pulse_message)  # Priya's response + questions
print(turn.questions)      # Clarifying questions

# Attend a meeting and extract actions
notes = priya.attend_meeting(
    transcript="Alice: Let's ship the new API by Friday...",
    title="Sprint Planning",
)
for action in notes.action_items:
    print(f"[{action.priority}] {action.description}{action.owner}")

# Receive and track a task
task = priya.receive_task(
    title="Refactor payment retry logic",
    description="Reduce retry latency by 40%",
    priority="high",
    deadline="2026-06-20",
)
print(priya.report_status(task.task_id).message)

PULSE Web UI — 9 pages

Page What it does
Onboarding Wizard 4-step setup: identity → company/role → skills → launch
Dashboard KT stats, active tasks, knowledge domains
KT Center Launch live (chat) or async (document/URL) KT sessions
Live KT Session 3-panel view: dialogue + real-time Confidence Meter + Mental Model
Meeting Room Paste transcript → extract decisions + action items instantly
Task Board Kanban board with move buttons and status updates
Chat WebSocket streaming chat directly with your PULSE employee
Knowledge Explorer Search across everything PULSE has learned
Settings Configure AI model, API keys, and employee profile

Core Features

🤖 Agent System

from buddy import Agent
from buddy.models.anthropic import Claude
from buddy.tools.web import DuckDuckGoSearch
from buddy.memory.agent import AgentMemory

agent = Agent(
    name="ResearchBot",
    model=Claude(id="claude-opus-4-5"),
    tools=[DuckDuckGoSearch()],
    memory=AgentMemory(),
    instructions="You are a research assistant.",
    markdown=True,
)

response = agent.run("Latest developments in quantum computing?")

🧠 25+ Model Providers

from buddy.models.openai import OpenAIChat
from buddy.models.anthropic import Claude
from buddy.models.google import Gemini
from buddy.models.groq import Groq
from buddy.models.ollama import Ollama

# Local model via Ollama
agent = Agent(model=Ollama(id="llama3.2"))

# Switch models at runtime
agent.model = Claude(id="claude-sonnet-4-5")

🛠️ Tools

from buddy.tools.web import DuckDuckGoSearch, BrowserTools
from buddy.tools.files import FileTools
from buddy.tools.code import PythonTools

# Custom tool with decorator
@agent.tool
def get_stock_price(ticker: str) -> str:
    """Get real-time stock price for a ticker symbol."""
    return fetch_price(ticker)

🧠 Memory & Knowledge (RAG)

from buddy.knowledge.pdf import PDFKnowledge
from buddy.vectordb.chroma import ChromaDb

knowledge = PDFKnowledge(
    path="company_handbook.pdf",
    vector_db=ChromaDb(collection="handbook"),
)

agent = Agent(
    model=OpenAIChat(),
    knowledge=knowledge,
    search_knowledge=True,
)

👥 Multi-Agent Teams

from buddy import Agent, Team

researcher = Agent(name="Researcher", role="Research the topic")
writer = Agent(name="Writer", role="Write a clear summary")
reviewer = Agent(name="Reviewer", role="Review and improve")

team = Team(
    agents=[researcher, writer, reviewer],
    mode="coordinate",
    instructions="Produce a polished research report.",
)

response = team.run("Write a report on renewable energy trends.")

⚙️ Workflows

from buddy.workflow.workflow import Workflow

class ResearchWorkflow(Workflow):
    def run(self, topic: str):
        research = self.researcher.run(f"Research: {topic}")
        draft = self.writer.run(f"Write based on: {research.content}")
        return self.reviewer.run(f"Review: {draft.content}")

CLI

# Initialize a project
buddy init my-agent

# PULSE virtual employee
buddy pulse start             # Launch web UI (http://localhost:8888)
buddy pulse create            # Interactive employee setup
buddy pulse kt --source doc.pdf --name "KT Session" --giver Alice
buddy pulse status            # Module health check

# Training
buddy train /data --name my-model

Deployment

# FastAPI
from buddy.app.fastapi import create_agent_app

app = create_agent_app(agent)
# uvicorn app:app --host 0.0.0.0 --port 8000
# Docker
FROM python:3.12-slim
RUN pip install buddy-ai[all]
COPY . /app
WORKDIR /app
CMD ["buddy", "pulse", "start", "--host", "0.0.0.0"]

What's New in v2.1.0

  • PULSE — Virtual Employee's ERA: identity, interactive KT, meetings, tasks, comms, feedback, onboarding
  • PULSE Web UI — Full React 18 + TypeScript dashboard with 9 pages
  • Live KT — Real-time dialogue with Confidence Meter and Mental Model panel
  • LLM Settings UI — Configure provider, model, and API key directly in the browser
  • 36 unit tests — Full test coverage for all PULSE modules
  • Bug fixProfessionalMemory composition refactor

Full CHANGELOG →


Optional Dependencies

Extra Installs
buddy-ai[openai] OpenAI SDK
buddy-ai[anthropic] Anthropic SDK
buddy-ai[google] Google Generative AI SDK
buddy-ai[groq] Groq SDK
buddy-ai[aws] boto3 (AWS Bedrock)
buddy-ai[training] PyTorch, Transformers, PEFT
buddy-ai[multimodal] Pillow, OpenCV, librosa
buddy-ai[tools] Playwright, Selenium, Slack SDK
buddy-ai[all] Everything above

Links


License

MIT License — see LICENSE


Built with ❤️ by Sriram Sangeeth Mantha

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

buddy_ai-2.1.2.tar.gz (1.1 MB view details)

Uploaded Source

Built Distribution

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

buddy_ai-2.1.2-py3-none-any.whl (1.3 MB view details)

Uploaded Python 3

File details

Details for the file buddy_ai-2.1.2.tar.gz.

File metadata

  • Download URL: buddy_ai-2.1.2.tar.gz
  • Upload date:
  • Size: 1.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.3

File hashes

Hashes for buddy_ai-2.1.2.tar.gz
Algorithm Hash digest
SHA256 5afb0cd65a30f65570bbe38e06cd88e27a16226db2b61c3755510bff83c2ea8f
MD5 e2a9597ecff762405cdb93f375dd8bc8
BLAKE2b-256 c70ad22c181607210e62c467eaf6ede1c5a539160042b20854b7b671768564ec

See more details on using hashes here.

File details

Details for the file buddy_ai-2.1.2-py3-none-any.whl.

File metadata

  • Download URL: buddy_ai-2.1.2-py3-none-any.whl
  • Upload date:
  • Size: 1.3 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.3

File hashes

Hashes for buddy_ai-2.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 766d8f09488caa874e8a6d7fe776c0f4d11c309b90bd188ced7af35651ed9797
MD5 2ba9fb2110225f6072cc11be999de0f6
BLAKE2b-256 3ac66a4cfb156030e86bcd836f6f025a7450397852827c9993fd04ea4956c8ed

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