This project provides a user interface that allows users to observe a conversation between two Large Language Models (LLMs). The UI enables the creation of unique character personas for each model, and the models converse with each other based on the predefined personas. The conversation can be progressed manually (step-by-step) or be fully automated for a predefined number of interactions. Further, the conversation history is logged via a JSON and can be saved for further analysis or synthetic dataset generation.
NOTE: The current state of the project is WORK IN PROGRESS/PROOF OF CONCEPT. The current version is usable, but suffers from minor halucinations due to residuals from the standard prompt remaining in the conversation history. This will be addressed when time allows, but would probably be an easy fix in a fork.
- Define Character Personas: Customize the personality and role of each LLM character.
- Watch LLMs Converse: Observe how two LLMs interact with each other based on the defined personas.
- Download Conversation History: Save the conversation history in JSON format for analysis.
- Ollama Integration: Interfaces directly with the chat endpoint of Ollama and can use it to perform on-device inference with all supported models.
- Python must be installed on your system. The current version is developed and tested under Python 3.11 and may or may not work with other versions. Integration tests with other versions is TODO
- Ollama server Ensure it is installed and available in your system's PATH.
Clone the Repository:
git clone https://github.com/SvenPfiffner/LLM-Duel-Arena.git
cd LLM-Duel-ArenaAutomatic Launch:
The main entry point for the application is start.py. You can start the UI by running:
python start.pyThis script will:
- Create a virtual environment with the required dependencies (if it does not exist).
- Start the Ollama server.
- Launch the UI.
Manual Launch:
If you prefer to set up and launch manually, you can install the requirements from requirements.txt and directly run the UI
pip install -r requirements.txt
python llmarena/ui.pyNote: Manual launch skips the ollama management. So you must ensure that ollama is serving in the background
Contribution is more than welcome. Feel free to fork the project and submit pull requests. For major changes, please open an issue first to discuss what you would like to change.
This project is licensed under the MIT License.
