GitHub - supercog-ai/agentic: An opinionated framework for building sophisticated AI Agents (original) (raw)

Agentic - Docs

Join our Discord!

Screenshot 2025-02-24 at 12 13 31 PM

Release Notes CI PyPI - License PyPI - Downloads GitHub star chart Open Issues

Agentic makes it easy to create AI agents - autonomous software programs that understand natural language and can use tools to do work on your behalf.

Agentic is in the tradition of opinionated frameworks. We've tried to encode lots of sensible defaults and best practices into the design, testing and deployment of agents.

Agentic is a few different things:

You can pretty much use any of these features and leave the others. There are lots of framework choices but we think we have embedded some good ideas into ours.

Some of the framework features:

Visit the docs: https://supercog-ai.github.io/agentic/latest/

Pre-built agents you can run today

OSS Deep Researcher

Perform complex research on any topic. Adapted from the LangChain version (but you can actually understand the code).

Agent Operator

...full browser automation, including using authenticated sessions...

Podcast Producer

An agent team which auto-produces and publishes a daily podcast. Customize for your news interests.

Meeting Notetaker

Your own meeting bot agent with meeting summaries stored into RAG.

Install

At this stage it's probably easiest to run this repo from source. We use uv for package management:

Note If you're on Linux or Windows and installing the rag extra you will need to add --extra-index-url https://download.pytorch.org/whl/cpu to install the CPU version of PyTorch.

git clone git@github.com:supercog-ai/agentic.git uv venv --python 3.12 source .venv/bin/activate

For MacOS

uv pip install -e "./agentic[all,dev]"

For Linux or Windows

uv pip install -e "./agentic[all,dev]" --extra-index-url https://download.pytorch.org/whl/cpu --index-strategy unsafe-first-match

these commands will install the agentic package locally so that you can use the agentic CLI command and so your pythonpath is set correctly.

Install the package

You can also try installing just the package:

For MacOS

uv pip install "agentic-framework[all,dev]"

For Linux or Windows

uv pip install "agentic-framework[all,dev]" --extra-index-url https://download.pytorch.org/whl/cpu

Now setup your folder to hold your agents:

The install will copy examples and a basic file structure into the directory myagents. You can name or rename this folder however you like.

Intro Tutorial

Visit the docs for a tutorial on getting started with the framework.

Running Agents

Agentic provides multiple ways to interact with your agents, from command-line interfaces to web applications. This guide covers all available methods.

Available Interfaces

Interface Use Case Features
Command Line (CLI) Quick testing, scripting Simple text I/O, dot commands
REST API Integration with other applications HTTP endpoints, event streaming
Next.js Dashboard Professional web UI Real-time updates, thread history, background tasks
Streamlit Dashboard Quick prototyping Simple web UI with minimal setup

Command Line Interface

The CLI provides a simple REPL interface for direct conversations with your agents.

agentic thread examples/basic_agent.py

Learn more about the CLI →

REST API

The REST API allows integration with web applications, automation systems, or other services.

agentic serve examples/basic_agent.py

Learn more about the API →

Next.js Dashboard

The Next.js Dashboard offers a full-featured web interface with:

agentic dashboard start --agent-path examples/basic_agent.py

Learn more about the Next.js Dashboard →

Streamlit Dashboard

The Streamlit Dashboard provides a lightweight interface for quick prototyping.

agentic streamlit --agent-path examples/basic_agent.py

Learn more about the Streamlit Dashboard →

Programmatic Access

You can always interact with agents directly in Python:

from agentic.common import Agent

Create an agent

agent = Agent( name="My Agent", instructions="You are a helpful assistant.", model="openai/gpt-4o-mini" )

Use the << operator for a quick response

response = agent << "Hello, how are you?" print(response)

For more control over the conversation

request_id = agent.start_request("Tell me a joke").request_id for event in agent.get_events(request_id): print(event)

Learn more about Programmatic Access →

Dependencies

Agentic builds on Litellm to enable consistent support for many different LLM models.

Under the covers, Agentic uses Ray to host and run your agents. Ray implements an actor model which implements a much better architecture for running complex agents than a typical web framework.

API Keys

Agentic requires API keys for the LLM providers you plan to use. Copy the .env.example file to .env and set the following environment variables:

OPENAI_API_KEY=your_openai_api_key_here
ANTHROPIC_API_KEY=your_anthropic_api_key_here

You only need to set the API keys for the models you plan to use. For example, if you're only using OpenAI models, you only need to set OPENAI_API_KEY.

Tests and docs

Run tests:

Preview docs locally:

Deploy the docs:

Why does this exist?

Yup, there's a lot of agent frameworks. But many of these are "gen 1" frameworks - designed before anyone had really built agents and tried to put them into production. Agentic is informed by our learnings at Supercog from building and running hundreds of agents over the past year.

Some reasons why Agentic is different:

Contributing

We would love you to contribute! We especially welcome:

but obviously we appreciate bug reports, bug fixes, etc... We encourage tests with all contributions, but especially if you want to modify the core framework please submit tests in the PR.