mirror of
https://github.com/rowboatlabs/rowboat.git
synced 2026-04-26 00:46:23 +02:00
Update README.md
This commit is contained in:
parent
114572d689
commit
08325dd6dd
2 changed files with 136 additions and 10 deletions
|
|
@ -4,15 +4,31 @@ Please visit https://www.rowboatlabs.com to learn more about RowBoat Labs
|
|||
# Agents
|
||||
|
||||
## Overview
|
||||
- RowBoat Agents is a multi-agent framework which powers agentic workflows. The best way to configure these workflows is via the RowBoat Studio (UI), instructions to set up which are in the [main README](https://github.com/rowboatlabs/rowboat/tree/dev).
|
||||
- RowBoat Agents is a multi-agent framework which powers conversations based on agentic workflows.
|
||||
- The Rowboat Agents framework has been built upon [OpenAI Swarm](https://github.com/openai/swarm), with modifications and improvements. Please see the `NOTICE.md` file in this directory, for attribution notes and more details. OpenAI Swarm is available under the MIT license as of the time of this writing.
|
||||
|
||||
## Framework design
|
||||
- Multi-agent systems are typically implemented as graphs, where each agent is a node in the graph. At every turn of conversation, the graph is traversed based on the a) `state` which contains currently active agent and agent-level histories and b) the current set of `messages`.
|
||||
- RowBoat Agents is a stateless implementation of such a graph-based system (specifically, a DAG or directed acyclic graph). The incoming request JSON (corresponding to a turn of conversation) is parsed to extract `messages`, `state` and the `workflow`.
|
||||
- The `workflow` is a representation of the DAG containing agents, with each agent having a set of tools and connected children agents. See `tests/sample_requests/default_example.json` for an example of a complete request JSON from an upstream service.
|
||||
## Graph-based framework
|
||||
- Multi-agent systems are typically implemented as graphs, where each agent is a node in the graph.
|
||||
- RowBoat Agents is a stateless implementation of such a graph-based system (specifically, a DAG or directed acyclic graph).
|
||||
- At every turn of conversation, the graph is traversed based on `messages`, `state` and `workflow` (which defines the agents, tools and connections between them)
|
||||
- `Workflows` can be configured in the no-code RowBoat Studio (UI) with the assistance of an AI copilot. Instructions to set up the Studio can be found in the [main README](https://github.com/rowboatlabs/rowboat/tree/dev).
|
||||
- At each turn of conversation, the agent graph object is created from scratch. The graph is then run, which produces the next set of `messages` and `state`. The `messages` will be shown to the user by the upstream service. Additionally, if the `messages` contain tool calls, then the upstream service must invoke the necessary tools and send the results back to the framework as the next turn.
|
||||
|
||||
## Key request and response fields
|
||||
|
||||
### Request
|
||||
- `messages`: List of messages from the user
|
||||
- `state`: Represents the currently active agent and agent-level histories
|
||||
- `workflow`: Represents the graph of agents, tools and connections between them
|
||||
|
||||
Note: See `tests/sample_requests/default_example.json` for an example of a complete request JSON
|
||||
|
||||
### Response
|
||||
- `messages`: List of response messages (which might have tool calls to be invoked)
|
||||
- `state`: New state of the conversation which is to be passed back during invocation of the next turn, since the framework itself is stateless
|
||||
|
||||
Note: See `tests/sample_responses/default_example.json` for an example of a complete response JSON
|
||||
|
||||
# Using the framework
|
||||
|
||||
## Set up conda env
|
||||
|
|
@ -60,10 +76,6 @@ Copy `.env.example` to `.env` and add your API keys
|
|||
- A list of one user-facing message and one or more tool calls
|
||||
- **Errors**: Errors are thrown as a tool call `raise_error` with the error message as the argument. Real-time error handling will be managed by the upstream service.
|
||||
|
||||
## Limitations
|
||||
- Does not support streaming currently.
|
||||
- Cannot respond with multiple user-facing messages in the same turn.
|
||||
|
||||
## Important directories and files
|
||||
- `src/`: Contains all source code for the agents app
|
||||
- `src/app/`: Contains Flask app which exposes the framework as a service
|
||||
|
|
@ -79,4 +91,8 @@ Copy `.env.example` to `.env` and add your API keys
|
|||
- `src/graph/core.py` creates the agent graph object from scratch and uses `src/swarm/core.py` to run the turn
|
||||
- `src/swarm/core.py` runs the turn by performing actual LLM calls and internal tool invocations to transitiion between agents
|
||||
- `src/graph/core.py` returns the response messages and the new state to `app/main.py`, which relays it back to the upstream service
|
||||
- The upstream services appends any new user messages to the history of messages and sends the messages back along with the new state to `app/main.py` as part of the next request. The process repeats until the upstream service completes its conversation with the user.
|
||||
- The upstream services appends any new user messages to the history of messages and sends the messages back along with the new state to `app/main.py` as part of the next request. The process repeats until the upstream service completes its conversation with the user.
|
||||
|
||||
## Limitations
|
||||
- Does not support streaming currently.
|
||||
- Cannot respond with multiple user-facing messages in the same turn.
|
||||
Loading…
Add table
Add a link
Reference in a new issue