cohere-toolkit

Building and Running Locally

  1. Clone the Repository:
    git clone <repository-url>
    cd <repository-folder>
    
  2. Install Poetry and Docker: Install Poetry >= 1.7.1 Install Docker Install Docker Compose >= 2.22

  3. Set Up with Make: Run:
    make first-run
    

    This generates the necessary configuration files and applies database migrations.

  4. Manual Configuration: If you prefer:
    • Create a configuration.yaml file based on configuration.template.yaml.
    • Replace the placeholders with your actual values.

Environment Setup for Windows/MacOS

Environment Variables

Ensure your configuration.yaml and secrets.yaml file are properly generated and have valid values, especially for the following:

Local Database Setup

  1. Migrate the Database: After setting up, run:
    make migrate
    
  2. Resetting the Database: If needed, reset and migrate again:
    make reset-db
    make migrate
    

Testing and Development

  1. Install Development Dependencies:
    make install
    
  2. Run Tests: Spin up the test DB and run tests:
    make test-db
    make run-tests
    
  3. Database Model Changes: To make changes to the database models:
    • Create a migration with:
      make migration message="Your migration message"
      
    • Then migrate:
      make migrate
      

Additional Tips