Skip to content

A fun wee project that creates bedtime tales using OpenAI and sends them to a destination of your choosing.

License

Notifications You must be signed in to change notification settings

onefastsnail/tail-time

Repository files navigation

📚 Tail time CI

A fun wee project that creates bedtime tales using OpenAI and sends those tales onwards to one's reading device of choice, for example a Kindle via email.

A very much WIP and hobby project.

I plan to make this into a usable service that would publish the generated tales for all to enjoy, however until that time, this project can easily be forked and modified to fit your own needs.

Background

I love reading to my kids. I love technology. Why not mix the two together and have some fun.

Architecture

This solution is 💯 overkill, and could be done in far simpler ways, but what would be the fun be in that!

architecture.png

However, the implemented and deployed microservice architecture does provide advantages over a more monolith counterpart such as:

  • Increased resilience should one part of the pipeline fail.
  • Easier testing, debugging and local development.
  • Faster and easier future development / maintenance.
  • Single and clear responsibilities of the service implementations.
  • Improved scalability should that time ever come.

All services are written in Go.

The infrastructure is provisioned with Terraform and deployed to AWS and runs fully in the free tier.

Development

Prerequisites

Setup the environment

Copy and configure .env.sample to .env. It will be read at run time by the Go code.

Install dependencies

go mod download to download all the Go dependencies.

Run local version

go run cmd/tail-time-generate-text-demo/main.go to run a local version which creates a tale and logs it out.

Deployment

See the Terraform documentation.

Up next...

Many things in the roadmap but here are a few:

  • Allow the pipeline to be invoked by an Alexa custom skill.
  • Build a prompt flow to validate, improve and augment the tale.
  • Build a larger tale consisting of chapters covering various topics.
  • Present tales generated to the public for access and usage.
  • Augment the tale with imaginary.

About

A fun wee project that creates bedtime tales using OpenAI and sends them to a destination of your choosing.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages