RestGPT  by Yifan-Song793

LLM agent for controlling real-world apps via RESTful APIs

Created 2 years ago
1,388 stars

Top 29.1% on SourcePulse

GitHubView on GitHub
1 Expert Loves This Project
Project Summary

RestGPT enables large language models (LLMs) to autonomously control real-world applications by interacting with RESTful APIs. It targets developers and researchers building LLM-powered agents that require integration with external services, offering a framework for planning, API execution, and response parsing.

How It Works

RestGPT employs an iterative coarse-to-fine online planning framework. It comprises a Planner for generating sub-tasks, an API Selector to map these to specific API calls, an Executor to run the API calls, a Caller to manage parameters and documentation, and a Parser to process API responses based on provided schemas. This modular approach allows for structured interaction with diverse APIs.

Quick Start & Requirements

  • Install: pip install langchain colorama tiktoken spotipy openai
  • Prerequisites: OpenAI API key, TMDB API key, Spotify API key.
  • Setup: Create a config.yaml file with API keys. Run python init_spotify.py to initialize the Spotify environment (note: this will remove existing Spotify data).
  • Run: python run.py to interact with the agent, or use python run_tmdb.py and python run_spotify.py for benchmark execution.
  • Demo: Under construction.

Highlighted Details

  • Introduces RestBench, a benchmark dataset with 100 TMDB and 57 Spotify instructions and gold solution paths.
  • Demonstrates planning and execution for multi-step API interactions, such as searching trending movies and creating Spotify playlists.
  • Supports dynamic API parameter organization and response parsing based on API documentation and schemas.

Maintenance & Community

The project code was released in August 2023, with paper updates following. Links to community channels or roadmaps are not provided in the README.

Licensing & Compatibility

The README does not explicitly state a license. Compatibility for commercial use or closed-source linking is not specified.

Limitations & Caveats

The demo is still under construction. For Spotify benchmark execution, users must manually modify query_idx in run_spotify.py. The init_spotify.py script will remove all existing data from the user's Spotify account.

Health Check
Last Commit

1 year ago

Responsiveness

Inactive

Pull Requests (30d)
0
Issues (30d)
0
Star History
6 stars in the last 30 days

Explore Similar Projects

Starred by Elie Bursztein Elie Bursztein(Cybersecurity Lead at Google DeepMind), Chip Huyen Chip Huyen(Author of "AI Engineering", "Designing Machine Learning Systems"), and
5 more.

composio by ComposioHQ

0.1%
26k
Toolset for AI agent integrations via function calling
Created 1 year ago
Updated 15 hours ago
Feedback? Help us improve.