Skip to main content

A console-based AI quiz game inspired by Who Wants to Be a Millionaire.

Project description

Mr. Millionaire

Mr. Millionaire is a console-based quiz game inspired by Who Wants to Be a Millionaire?, featuring 15 challenging questions, prize progression, lifelines, and AI-generated questions via LiteLLM.


Features

  • ✯ 15-question challenge with increasing prize money

  • 🧠 AI-generated questions using LiteLLM integration

  • 📀 Caches config, history, and environment in ~/.mr-millionaire

  • 🧠 Lifelines:

    • 50-50: Eliminate two wrong options
    • Phone a Friend: Ask an AI friend for help
  • 📊 Game history and last played session tracking

  • 🔧 Configurable via CLI or config manager


Installation

pip install mr-millionaire

Running & Configuring

mr-millionaire

On running the game you'll be asked for 4 options.

Choose one from options:
  [1] Play Game
  [2] Clear Memory
  [3] Configuration
  [4] Show History
  • [1] You can start playing the game. (for the first time it will ask you to setup LLM API Keys and MODEL name.)
  • [2] Clears the memory of previously asked questions.
  • [3] You can use this configuration manager to configure your LLM or difficulty of a game.
  • [4] This will show previously won sheets.

Things to know


On first run, a cache/config folder will be created automatically on playing the game:

~/.mr-millionaire/

It will ask for the environemnt variable name & key.

# Example:
LLM Environment Variable Name : GROQ_API_KEY
LLM Environment Variable Value : <your_api_key>
LLM Model (eg: groq/gemma2-9b-it) : groq/gemma2-9b-it

Please go through 'https://docs.litellm.ai/docs/providers' before giving the llm environment values.


Configuration Options

Manage settings such as:

  • Preferred LLM model
  • Cache clearing
  • History viewing

All settings and history are stored in ~/.mr-millionaire you can take a look into it for further debugging.


Tech Stack

  • Python 3.12
  • LiteLLM for AI-powered question generation
  • dotenv for environment variable management
  • Local filesystem storage for config and history

Contributing

Pull requests are welcome! For major changes, please open an issue first.


License

This project is licensed under the MIT License. See the LICENSE file for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mr_millionaire-0.1.1.tar.gz (14.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mr_millionaire-0.1.1-py3-none-any.whl (16.8 kB view details)

Uploaded Python 3

File details

Details for the file mr_millionaire-0.1.1.tar.gz.

File metadata

  • Download URL: mr_millionaire-0.1.1.tar.gz
  • Upload date:
  • Size: 14.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.3

File hashes

Hashes for mr_millionaire-0.1.1.tar.gz
Algorithm Hash digest
SHA256 b60d5b631d87b6bc80e108d672250f8e5a14706046c2cfac668dfef5b3981622
MD5 ae8e602efe421384b7bd13284bcab841
BLAKE2b-256 5e345dac2d9e22bebbac9c834f8c1a2556ec64c7b628aa00228d36a6d43cd0f9

See more details on using hashes here.

File details

Details for the file mr_millionaire-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: mr_millionaire-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 16.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.3

File hashes

Hashes for mr_millionaire-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 03e6bfa4629c2756b5c5c044041eaec699a1cb4d1ace49e24844a0804847740c
MD5 9d15da854d0ad976ea4823681e90988b
BLAKE2b-256 c975786367ca8942db8bdb589d6d927ffaaa86b3986e3a823260f7077468f181

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page