Skip to main content

A package for managing AI agents and chatrooms

Project description

AgentFleet

A Python package for managing AI agents and chatrooms that work with LLM-based capabilities.

Installation

pip install agentfleet

Usage

from agentfleet import Agent, Chatroom, create_chatroom

# Example: Create an agent
from langchain_openai import ChatOpenAI
llm = ChatOpenAI()
agent = Agent(name="Assistant", llm=llm, sys_prompt="You are a helpful assistant")

# Example: Set up a chatroom
chatroom = Chatroom(llm=llm, agents=[agent], current_agent=agent)

Using Custom Tools

from agentfleet import create_chatroom
from langchain_core.tools import tool

# Define your custom tool functions
@tool
def lookup_data(query: str) -> str:
    """Look up data from a database."""
    # Implementation...
    return f"Data for {query}"
@tool
def process_request(request_id: str) -> str:
    """Process a request with the given ID."""
    # Implementation...
    return f"Processed request {request_id}"

# Create a dictionary mapping tool names to functions
tool_dict = {
    'lookup_data': lookup_data,
    'process_request': process_request
}

# Create a chatroom with tool dictionary
chatroom_config = {
    "states": [...],
    "agents": [
        {
            "name": "support_agent",
            "sys_prompt": "You are a support agent...",
            "util_tools": ["lookup_data", "process_request"],
            "transfer_tools": []
        }
    ],
    "initial_agent": "support_agent"
}

chatroom = create_chatroom(chatroom_config, llm, tool_dict=tool_dict)

Features

  • Create AI agents with different capabilities
  • Build chatrooms with multiple specialized agents
  • Transfer conversation control between agents
  • Maintain conversation state across interactions
  • Pass custom tools to agents via tool dictionary

License

MIT License

Copyright (c) 2025 Wei Zhou

Contributing

Individual Contributor: Wei Zhou

We welcome contributions! Please review our contribution guidelines for details on our code of conduct, and the process for submitting pull requests.

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

agentfleet-0.1.1.tar.gz (5.2 kB view details)

Uploaded Source

Built Distribution

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

agentfleet-0.1.1-py3-none-any.whl (5.8 kB view details)

Uploaded Python 3

File details

Details for the file agentfleet-0.1.1.tar.gz.

File metadata

  • Download URL: agentfleet-0.1.1.tar.gz
  • Upload date:
  • Size: 5.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for agentfleet-0.1.1.tar.gz
Algorithm Hash digest
SHA256 8f78755b82df6e83c3e2fa1de7f0550fb90eb0d2748781b7d00077bf64e0fe74
MD5 39dfff5352030b5aa875a5aaeb0a1a42
BLAKE2b-256 9e2c9b5bcff0eecf59e15dc93ed74ad4720d752c2f0378246408f1262ee8951d

See more details on using hashes here.

File details

Details for the file agentfleet-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: agentfleet-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 5.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for agentfleet-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 b55774f489feea23ee246616ff413c779baaf079f3d73bb4f1a371f001fdfd8a
MD5 ea67bc8014b2a6dd54c4d4d64beed36f
BLAKE2b-256 d24f064d83e8cca1230bfbc08e234dc900ed626871ccd2a4bc4f0cb9e3613a0c

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