A reeln-cli plugin for OpenAI-powered LLM integration — livestream metadata, game thumbnails, playlist descriptions, and multi-language translation.
- Livestream metadata — LLM-generated title and description for game livestreams
- Playlist metadata — creative playlist titles and descriptions
- Game image thumbnails — ESPN/NBC Sports broadcast-style thumbnails from team logos via OpenAI image generation
- Multi-language translation — batch or per-language translation with custom commentator personas
- Prompt templates — customizable
{{variable}}templates with override support
pip install reeln-plugin-openaiOr for development:
git clone https://github.com/StreamnDad/reeln-plugin-openai
cd reeln-plugin-openai
make dev-installAdd the plugin to your reeln config:
{
"plugins": {
"enabled": ["openai"],
"settings": {
"openai": {
"enabled": true,
"api_key_file": "~/.config/reeln/secrets/openai_api_key.txt",
"model": "gpt-4.1",
"playlist_enabled": true,
"game_image_enabled": true,
"game_image_output_dir": "~/Documents/game_images"
}
}
}
}The plugin resolves the OpenAI API key in this order:
api_key_fileconfig — reads key from the specified file (recommended)OPENAI_API_KEYenvironment variable — fallback for dev/CI
| Field | Type | Default | Description |
|---|---|---|---|
enabled |
bool | false |
Enable OpenAI LLM integration |
api_key_file |
str | "" |
Path to file containing the OpenAI API key |
model |
str | "gpt-4.1" |
OpenAI model for text generation |
request_timeout_seconds |
float | 30.0 |
API request timeout |
prompt_overrides |
str (JSON) | "{}" |
Dict of prompt name to override file path |
prompt_context |
str (JSON) | "{}" |
Dict of prompt name to extra context lines |
translate_enabled |
bool | false |
Enable multi-language translation |
translate_languages |
str (JSON) | "{}" |
Dict of language code to name |
translate_per_language_prompts |
str (JSON) | "{}" |
Dict of language code to prompt name |
playlist_enabled |
bool | false |
Enable LLM-generated playlist metadata |
game_image_enabled |
bool | false |
Enable game image thumbnail generation |
game_image_model |
str | "gpt-5.2" |
Model for image generation orchestration |
game_image_renderer_model |
str | "gpt-image-1.5" |
Model for image rendering |
game_image_output_dir |
str | "" |
Directory to save generated game images |
| Hook | What it does |
|---|---|
ON_GAME_INIT |
Generates livestream metadata, playlist metadata, game image thumbnail, and translations |
The plugin writes to context.shared for other plugins to consume:
context.shared["livestream_metadata"] # {"title": "...", "description": "...", "translations": {...}}
context.shared["playlist_metadata"] # {"title": "...", "description": "...", "translations": {...}}
context.shared["game_image"] # {"image_path": "/path/to/thumbnail.png"}make dev-install # uv venv + editable install with dev deps
make test # pytest with 100% coverage
make lint # ruff check
make format # ruff format
make check # lint + mypy + testAGPL-3.0-only