p3nGu1nZz / Tau

Tau LLM made with Unity 6 ML Agents
MIT License
9 stars 4 forks source link

Tau LLM Unity ML Agents Project

Welcome to the Tau LLM Unity ML Agents project! This project aims to build a Language Model (LLM) from scratch using Unity, ML-Agents, and Sentence Transformers.

Table of Contents

Introduction

The Tau LLM Unity ML Agents project is an innovative initiative to create an intelligent chatbot using reinforcement learning and natural language processing techniques. By leveraging Unity's ML-Agents toolkit and Sentence Transformers, we aim to develop a robust and efficient language model.

Features

Installation

Prerequisites

Steps

  1. Clone the repository:

    git clone https://github.com/yourusername/tau-llm-unity-ml-agents.git
    cd Tau\MLAgentsProject
  2. Install Python dependencies:

    .\Scripts\setup.bat
  3. Open the project in Unity:

    • Launch Unity Hub.
    • Click on "Add" and select the project directory.
  4. Set up ML-Agents:

    • Follow the ML-Agents installation guide.
  5. Clone ML-Agents Repository:

    • Clone the ML-Agents repository from GitHub:
      git clone --branch develop https://github.com/Unity-Technologies/ml-agents.git
  6. Add ML-Agents Packages Locally:

    • Open the Unity Package Manager.
    • Click on the "+" button and select "Add package from disk...".
    • Navigate to the cloned ml-agents repository and select the com.unity.ml-agents directory.
    • Repeat the process for the com.unity.ml-agents.extensions directory.

Usage

Training the Model

  1. Configure the training environment:

    • Modify the config.yaml file to set up your training parameters.
  2. Start training:

    mlagents-learn .\config\tau_agent_sac.yaml --run-id=tau_agent_sac_A1 --env .\Build\ --torch-device cuda --timeout-wait 300 --force
    • Parameters:
      • .\config\tau_agent_sac.yaml: Path to the configuration file.
      • --run-id=tau_agent_sac_A1: Unique identifier for the training run.
      • --env .\Build\: Path to the build directory.
      • --torch-device cuda: Specifies the use of a CUDA-enabled GPU for training.
      • --timeout-wait 300: Sets the timeout wait time.
      • --force: Forces the training to start even if there are warnings.
  3. Monitor training:

    • Use TensorBoard to visualize training metrics:
      tensorboard --logdir results

Running Inference

  1. Load the trained model in Unity:

    • Drag and drop the trained model file into the Unity project.
  2. Test the agent:

    • Run the Unity scene to see the agent in action.

Project Structure

Contributing

We welcome contributions from the community! Please read our contributing guidelines for more information.

License

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

Acknowledgements


Screenshot of a the greek symbol tau