Skip to main content
Use session state variables directly in team instructions with template syntax. The values are injected into the instructions automatically, so the team can use them during execution.
1

Create a Python file

session_state_in_instructions.py
2

Set up your virtual environment

3

Install dependencies

4

Export your OpenAI API key

Set OpenAI Key

Set your OPENAI_API_KEY as an environment variable. You can get one from OpenAI.
5

Run Team