TFT Embedded Synergy Builder is a recommendation system for the game Teamfight Tactics (TFT). It utilizes semantic-based search and embeddings to provide players with personalized suggestions for the best champions and items based on their selected champion or champions. The system manages multiple champion embeddings by calculating the average embedding of the selected champions. This average embedding is then used to find similar champions based on their embeddings. This project aims to explore the effectiveness of semantic search in the context of champion and item recommendations in TFT.
To set up the project, follow these steps:
- Ensure that pipenv is installed on your system. If not, you can install it using
pip install pipenv
. - Clone the repository from GitHub using the following command:
git clone https://github.com/neo-con/tft-embedded-synergy-builder.git
- Navigate to the cloned repository's directory. If you cloned the repository into your current directory, you can do this with:
cd tft-embedded-synergy-builder
- Run
pipenv install
to install all dependencies listed in thePipfile
. - After the installation completes, activate the Pipenv shell:
pipenv shell
- You can now run the application using
streamlit run app.py
.
Input your chosen champion into the text box provided. The system will then generate a team composition based on the champion's embeddings match. An example of the application in use can be found at the live Streamlit app here.
Below is a brief overview of the key files and folders:
app.py
- This is the main application file where the Streamlit app is defined.assets/
- This directory contains all the static files used in the project, including images for champions and items.builders/
- This directory contains the builder files (item_builder.py
andsynergy_builder.py
) used for item and synergy recommendations.data/
- This directory contains all the data files used in the project.embeddings/
- This directory contains the embeddings for champions and items.scripts/
- This directory contains the scripts used to generate embeddings and scrape data.template/
- This directory contains the HTML template used in the Streamlit app.
Special thanks to the Facebook team for their work on FAISS, and OpenAI for their Embedding API.
Layout on mobile device sucks. This is due to Streamlit's lack of responsiveness controls. Hoping to switch frameworks in the future, perhaps Django or Flask, or even React.
This project is licensed under the terms of the MIT License. You are free to use, modify, and distribute the code, provided that proper credit is given.
Note: This project is not affiliated with or endorsed by the creators of Teamfight Tactics or Riot Games. All game images, names, and other details are property of their respective owners.