GithubHelp home page GithubHelp logo

yonishelach / genai-factory Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mlrun/genai-factory

0.0 0.0 0.0 556 KB

Rapid build and deployment of Gen AI applications

Makefile 1.07% Dockerfile 1.44% Python 49.52% JavaScript 0.82% HTML 0.40% TypeScript 45.33% CSS 1.43%

genai-factory's Introduction

GenAI Factory

Demo an end to end LLM agent solution with modular architecture, persistent storage and front-end UI that can work with various LLM models and storage solutions.

the configuration is specified in a YAML file, which indicate the model, embeddings, storage to use, and various parameters. the user can point to the configuration file by setting the AGENT_CONFIG_PATH environment variable.

environment variables and credentials can be loaded from a .env file in the root directory. or an alternate path set by the AGENT_ENV_PATH environment variable. data can be stored in local files or remote SQL and Vector databases. the local file storage path can be set by the AGENT_DATA_PATH environment variable (defaults to ./data/).

Getting it to work

In order to deploy the GenAI Factory locally, we need to update the docker desktop software and to enable host networking. For more information, please refer to the following link: https://docs.docker.com/network/drivers/host/#docker-desktop

Deploy the controller

This command will start the API controller server into a local docker container.

make controller

Initialize the database:

The database is Initialized when building the controller. In order to erase and start fresh, we can simply use the controller's command line interface.

python -m controller.src.main initdb

To start the application's API:

uvicorn pipeline:app

To start UI:

Future work will include a UI command to run the UI.

make ui

CLI usage

To ingest data into the vector database:

python -m controller.src.main ingest -l web https://milvus.io/docs/overview.md

To ask a question:

python -m controller.src.main query "What is a vector?" 

Full CLI:

python -m controller.src.main

Usage: python -m controller.src.main [OPTIONS] COMMAND [ARGS]...

Options:
  --help  Show this message and exit.

Commands:
  config  Print the config as a yaml file
  ingest  Ingest documents into the vector database
  initdb  Initialize the database (delete old tables)
  list    List the different objects in the database (by category)
  query   Run a chat query on the vector database collection

genai-factory's People

Contributors

baaalint avatar yonishelach avatar guy1992l avatar yaronha 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.