Posted Jul 26, 2025
Gets current MLB standings, generates line charts to display the standings per division, uses OpenAI API to generate captions, and emails me the content.
0
2
.env in ~/.config/mlb-graphical-standings using .env.sampleMAILTRAP_API_TOKEN.TARGET_EMAIL in .env file to be your email address that you used to sign up for Mailtrap.FROM_EMAIL in .env to be the email address you want to send from. We only want to send emails to ourself so just use demo@demomailtrap.com. Otherwise, provide your own email in the mailtrap.io web ui.OPENAI_API_KEY in .env to be your OpenAI Project API key dedicated to this venture.python -m mlb_graphical_standings.graphical_standings~/.config/mlb-graphical-standings/prompt.txt. You can even have multiple prompts and have some script choose one at random. Just have fun with it.sample_files you will find a basic shell script and some prompts that are selected based on the day of the week.