Mastermind is a CLI tool designed to generate clue words for spymasters in the game of Codenames, leveraging large language models (LLMs) of your choice!
Written in Rust 🦀, because why not?
To get started, prepare two text files:
- Words to Link Together - Contains the words from your own team.
- Words to Avoid - Contains:
- Your opponent's words
- Neutral words
- The assassin word
One word per line. Refer to the examples directory for sample files.
Here are what you need to configure before running mastermind:
- API key
- The base URL of an OpenAI-compatible API
- A default language model
There are two ways to configure this program:
During the first run, a config file will be created at your system's preferred location. The specific location will be given in the output. Generally, it is located at:
- For Linux:
$HOME/.config/mastermind/config.toml - For macOS:
$HOME/Library/Application Support/mastermind/config.toml - For Windows:
C:\Users\[your username]\AppData\Roaming\mastermind\config.toml
Simply pass these environment variables during run time:
API_KEYOPENAI_API_BASE_URLDEFAULT_MODEL_ID
mastermind [TO_LINK] [TO_AVOID]Feel free to run the program multiple times to get the best result!
-g,--get-models: Print all available language models-m,--set-models: Select language model(s)-o,--output: Specify an output file-t,--token-usage: Print token usage-h,--help: Print help-V,--version: Print version
