1- # Python Boilerplate with OpenAI Agents
1+ # Python Boilerplate
22
33This template is a ** lean starting point** for Python projects that use:
44
5- * ✅ Ruff – formatting & linting
6- * 🧪 Pytest – testing
7- * ⚙️ Pydantic Settings – typed environment configuration
8- * 📦 uv – fast dependency management / locking
5+ - ✅ Ruff – formatting & linting
6+ - 🧪 Pytest – testing
7+ - ⚙️ Pydantic Settings – typed environment configuration
8+ - 📦 uv – fast dependency management / locking
99
1010---
1111
1212## Quick Start
1313
14141 . ** Create & Activate Virtual Environment:**
15+
1516 ``` bash
1617 # Create the virtual environment using uv
1718 uv venv
1819 # Activate it (on macOS/Linux)
1920 source .venv/bin/activate
2021 # On Windows, use: .venv\Scripts\activate
2122 ```
22- * This creates a ` .venv` directory in your project.*
23+
24+ _This creates a ` .venv` directory in your project._
2325
24262. ** Install Dependencies:**
27+
2528 ` ` ` bash
2629 # Installs core + dev dependencies into your active venv
2730 make setup
2831 ` ` `
2932
30333. ** Run the Quick-Start Agent Demo:**
34+
3135 ` ` ` bash
3236 # This will use your activated environment
3337 make run
3438 ` ` `
3539
36404. ** Run Quality Checks:**
3741 ` ` ` bash
38- make format-check && make lint && make test
42+ make format && make lint && make test
3943 ` ` `
4044
41- ` main.py` is a minimal script that spins up an assistant. Modify it to explore the SDK.
45+ ` src/ main.py` is a minimal script that spins up an assistant. Modify it to explore the SDK.
4246
4347---
4448
4549# # Make Commands
4650
47- | Command | Description |
48- | ------------------ | ------------------------------------ |
49- | ` make install` | Install core dependencies |
50- | ` make install-dev` | Install core + dev dependencies |
51- | ` make format` | Format code with Ruff |
52- | ` make format-check` | Check formatting (CI mode) |
53- | ` make lint` | Run Ruff linter |
54- | ` make test` | Run Pytest |
55- | ` make clean` | Remove * .pyc & cache directories |
56- | ` make lock-check` | Assert ` uv.lock` is in sync |
51+ | Command | Description |
52+ | ------------------ | --------------------------------------- |
53+ | ` make install` | Install core dependencies |
54+ | ` make install-dev` | Install core + dev dependencies |
55+ | ` make setup` | Install dependencies + pre-commit hooks |
56+ | ` make format` | Format code with Ruff |
57+ | ` make lint` | Run Ruff linter |
58+ | ` make typecheck` | Run Pyright type checker |
59+ | ` make test` | Run Pytest |
60+ | ` make clean` | Remove \* .pyc & cache directories |
61+ | ` make lock-check` | Assert ` uv.lock` is in sync |
5762
5863---
5964
6065# # Environment Variables
6166
6267` utils/settings.py` reads variables from a ` .env` file or the environment.
6368
64- | Variable | Default | Description |
65- | ----------------- | ------------- | - ----------------------------------- |
66- | ` OPENAI_API_KEY` | (required) | Your OpenAI API key. |
67- | ` LOG_LEVEL` | ` INFO` | ` DEBUG` , ` INFO` , ` WARNING` , ` ERROR` |
68- | ` LOG_FORMAT` | ` console` | ` console` (colored) or ` json` . |
69- | ` DEFAULT_MODEL` | ` gpt-4o-mini ` | Default model for agents. |
69+ | Variable | Default | Description |
70+ | ---------------- | ------------ | ----------------------------------- |
71+ | ` OPENAI_API_KEY` | (required) | Your OpenAI API key. |
72+ | ` LOG_LEVEL` | ` INFO` | ` DEBUG` , ` INFO` , ` WARNING` , ` ERROR` |
73+ | ` LOG_FORMAT` | ` console` | ` console` (colored) or ` json` . |
74+ | ` DEFAULT_MODEL` | ` gpt-5-nano ` | Default model for agents. |
7075
7176See ` .env.example` for a template.
7277
@@ -77,7 +82,8 @@ See `.env.example` for a template.
7782Only what you need, nothing more:
7883
7984```
80- ├── main.py # Minimal OpenAI Agents example
85+ ├── src/
86+ │ └── main.py # Minimal OpenAI Agents example
8187├── utils/
8288│ └── settings.py # Pydantic Settings helper
8389├── tests/
0 commit comments