agent-service-toolkit  by JoshuaC215

Toolkit for building AI agent services

created 1 year ago
3,379 stars

Top 14.7% on sourcepulse

GitHubView on GitHub
Project Summary

This toolkit provides a comprehensive solution for building and deploying AI agent services, targeting developers and researchers who want to leverage LangGraph for complex agentic workflows. It simplifies the process from agent definition to a user-facing Streamlit application, offering a robust template for rapid development and deployment.

How It Works

The project utilizes LangGraph for agent orchestration, enabling advanced features like human-in-the-loop interactions (interrupt()) and flow control (Command, langgraph-supervisor). A FastAPI service exposes the agent with both streaming and non-streaming endpoints, featuring a novel approach to handle token-based and message-based streaming. Pydantic is used for data structures and settings, ensuring type safety and clear configuration.

Quick Start & Requirements

  • Install: pip install uv then uv sync --frozen (creates .venv), source .venv/bin/activate.
  • Prerequisites: At least one LLM API key (e.g., OPENAI_API_KEY) set in a .env file.
  • Run:
    • Service: python src/run_service.py
    • UI: streamlit run src/streamlit_app.py
  • Docker: docker compose watch (recommended for development).
  • Docs: LangGraph, FastAPI, Streamlit

Highlighted Details

  • LangGraph v0.3 features including interrupt(), Command, and langgraph-supervisor.
  • Advanced streaming support for both token-based and message-based outputs.
  • Multiple agent support with distinct URL paths.
  • Content moderation via LlamaGuard (requires Groq API key).
  • Integrated LangSmith feedback mechanism.
  • Comprehensive unit and integration tests.

Maintenance & Community

The project is actively maintained by JoshuaC215. Contributions are welcome via pull requests. Testing instructions are provided for local development.

Licensing & Compatibility

  • License: MIT License.
  • Compatibility: Permissive MIT license allows for commercial use and integration with closed-source applications.

Limitations & Caveats

Ollama support is experimental. Running tests requires the local development setup without Docker.

Health Check
Last commit

5 days ago

Responsiveness

1 day

Pull Requests (30d)
7
Issues (30d)
6
Star History
601 stars in the last 90 days

Explore Similar Projects

Starred by Peter Norvig Peter Norvig(Author of Artificial Intelligence: A Modern Approach; Research Director at Google), Michael Han Michael Han(Cofounder of Unsloth), and
15 more.

open-interpreter by openinterpreter

0.1%
60k
Natural language interface for computers
created 2 years ago
updated 4 days ago
Feedback? Help us improve.