Coder Social home page Coder Social logo

amiune / genai-stack Goto Github PK

View Code? Open in Web Editor NEW

This project forked from docker/genai-stack

0.0 0.0 0.0 1.86 MB

Langchain + Docker + Weaviate + Ollama

Home Page: https://www.generativenetworks.com/blog/#!20240206-llms-caso-de-uso

License: Creative Commons Zero v1.0 Universal

Shell 55.23% Python 30.58% Dockerfile 14.19%

genai-stack's Introduction

GenAI Stack

The GenAI Stack will get you started building your own GenAI application in no time.

Configure

Available variables:

Variable Name Default value Description
OLLAMA_BASE_URL http://host.docker.internal:11434 REQUIRED - URL to Ollama LLM API
WEAVIATE_URL weaviate cluster url OPTIONAL - URL to weaviate cluster
WEAVIATE_API_KEY weaviate token OPTIONAL - Weaviate token
LLM llama2 REQUIRED - Can be any Ollama model tag
EMBEDDING_MODEL sentence_transformer REQUIRED - Can be sentence_transformer or ollama

LLM Configuration

MacOS and Linux users can use any LLM that's available via Ollama. Check the "tags" section under the model page you want to use on https://ollama.ai/library and write the tag for the value of the environment variable LLM= in the .env file.

MacOS Install Ollama on MacOS and start it before running docker compose up.

Linux No need to install Ollama manually, it will run in a container as part of the stack when running with the Linux profile: run docker compose --profile linux up. Make sure to set the OLLAMA_BASE_URL=http://llm:11434 in the .env file when using Ollama docker container.

To use the Linux-GPU profile: run docker compose --profile linux-gpu up. Also change OLLAMA_BASE_URL=http://llm-gpu:11434 in the .env file.

Windows Not supported by Ollama, so Windows users need to generate an OpenAI API key and configure the stack to use gpt-3.5 or gpt-4 in the .env file.

Develop

Warning

There is a performance issue that impacts python applications in the 4.24.x releases of Docker Desktop. Please upgrade to the latest release before using this stack.

To start everything

docker compose up

If changes to build scripts have been made, rebuild.

docker compose up --build

To enter watch mode (auto rebuild on file changes). First start everything, then in new terminal:

docker compose watch

Shutdown If health check fails or containers don't start up as expected, shutdown completely to start up again.

docker compose down

Applications

Name Main files Compose name URLs Description
Support Bot bot.py bot http://localhost:8501 Main usecase. Fullstack Python application.

The database can be explored at http://localhost:7474.

App - Agent Bot

UI: http://localhost:8501 DB client: http://localhost:7474

  • answer support question based on recent entries
  • provide summarized answers with sources

genai-stack's People

Contributors

oskarhane avatar tomasonjo avatar jexp avatar slimslenderslacks avatar amiune avatar matthieuml avatar zach-blumenfeld avatar rahul0x00 avatar leomrocha avatar zooninja avatar chenblueridge avatar desnoo avatar ssime-git avatar sanyam-2026 avatar theculliganman avatar johnsonr avatar robsdedude avatar rafeathar avatar denverdino avatar illapavan avatar eltociear avatar ilopezluna avatar shelar1423 avatar borisromanov avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.