Skip to content

Ben-Pollard/bp.chat

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

38 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LLM Experiments

This project is designed to experiment with language models using a Streamlit app interface. It allows users to interact with a language model chain to generate responses based on input messages.

Setup

To set up the project, ensure you have Python 3.12 installed. Use Poetry to manage dependencies.

  1. Install dependencies:

    poetry install
  2. Set OPENAI_API_KEY as an environment variable:

Running

To run the Streamlit app, execute the following command:

streamlit run app.py

This will start a local server, and you can interact with the app through your web browser.

Testing

To run the tests, use pytest:

pytest tests/

This will execute the test suite to ensure the chain invocation works as expected.

Building and Running the Docker Image

To build the Docker image, use the following command:

docker build --target development -t chat-dev .

To run the app in the container, use:

docker run --env OPENAI_API_KEY=$Env:OPENAI_API_KEY -p 8501:8501 chat-dev

Or to run the unit tests in the container, use:

docker run chat-dev pytest /app/tests/unit

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published