This project implements a modular state machine using LangGraph and FastAPI, designed to handle workflows through independent nodes. The nodes interact via a shared state, ensuring flexibility and scalability.
-
Set OpenAI API Key:
- Rename
.env.example
to.env
and add yourOPENAI_API_KEY
to the.env
file:OPENAI_API_KEY=your_openai_api_key
- Rename
-
Install Dependencies:
- Use Poetry as the dependency manager to install the required packages:
poetry install
- Use Poetry as the dependency manager to install the required packages:
-
Run the FastAPI Server:
- Start the server:
poetry run uvicorn main:app --reload
- Start the server: