Quizory is a (WIP) minimalistic history trivia app that generates its content on regular intervals by consuming OpenAI's GPT-4 models.
I built it because I like history, and wanted to learn in a fun way 🤓
You may try Quizory by visiting the following links:
- https://quizory.vercel.app for the app
- Swagger Docs for the API docs
Disclaimer: While Quizory aims to provide accurate historical information, it is important to acknowledge that the content generated by LLMs may occasionally include inaccuracies. Please remember that this project is intended for entertainment purposes only and should not be considered a definitive source of historical facts.
This project requires the following to be installed in your machine:
Also, make sure you have:
- A Supabase account (free tier) with Google's auth provider enabled.
- An OpenAI account with access to GPT4.
Even though not a hard requirement, having Make
available will allow you to follow the examples
detailed in this doc. You may use Make help
to take a look at the main commands available.
Make sure you have a .env.quizory
file in your root dir filled as follows:
DB_URL=postgres://postgres:postgres@localhost:5433/postgres?sslmode=disable
OPENAI_API_KEY=<your-openai-key>
JWT_SECRET=<your-supabase-jwt-secret>
Also, make sure you have a client/.env.local
file filled as follows:
VITE_SUPABASE_URL=<your-supabase-url>
VITE_SUPABASE_KEY=<your-supabase-public-key>
VITE_BASE_API_URL="http://localhost:8080"
# Install the Go & JS dependencies
$ make install
# Concurrently turn on:
# 1. A local Postgres database via docker-compose
# 2. The Go backend (port 8080), WITHOUT live-reload (for now)
# 3. The React (port 5173), with HMR
$ make dev
# Alternatively, if you would like to generate questions to seed your database, you can run the
# following, which adds periodic generation of questions.
# Note that this will consume your OpenAI credits.
$ make dev GENERATE_FLAG=-generate
You should now be able to access http://localhost:5173 and explore the app.
# Shell 1: Turn on the dev infra (specifically, we need the Postgres database container)
$ make dev
# Shell 2: Run the actual tests
$ make test
None of the questions, answers or historical context served by this project have been provided by me. All has been generated from OpenAI's GPT-4 models. So...
- Yes, thanks OpenAI.
- More importantly, thanks to whoever's data was used to train GPT4.
Furthermore, this project relied heavily on:
- DaisyUI - Licensed under the MIT License
- go-openai - Licensed under the Apache License, Version 2.0
- oapi-codegen - Licensed under the Apache License, Version 2.0
- SQLBoiler - Licensed under the BSD-3-Clause License
Copyright (c) 2024, Sebastián Salata Ruiz-Tagle
Quizory is MIT licensed.