Skip to content

Instantly share code, notes, and snippets.

"""
Schema-Guided Reasoning (SGR) Demo with OpenAI
This Python code demonstrates Schema-Guided Reasoning (SGR) with OpenAI. It:
- Implements a business agent capable of planning and reasoning
- Implements tool calling using only SGR and simple dispatch
- Uses a simple (inexpensive) non-reasoning model for that
To give this agent something to work with, we ask it to help with running
a small business - selling courses to help achieve AGI faster.