Skip to content
Jael Gu edited this page Aug 11, 2023 · 13 revisions

Build a Demo

Before getting started, you need to have llm and database services ready to connect. For example, if you're using default modules, you should prepare:

Follow steps below to build a demo with Gradio interface:

  1. Downloads

    $ git clone https://github.com/zilliztech/akcio.git
    $ cd akcio
  2. Installation

    $ pip install -r requirements.txt
  3. Configuration

    • Set up OpenAI & Milvus connection:

      $ export OPENAI_API_KEY=your_keys_here  # Make sure your API key has access/credits for the selected service (default: gpt-3.5-turbo)
      $ export MILVUS_URI=https://localhost:19530  # This will connect to a local-hosted Milvus with port 19530
      $ export SQL_URI=sqlite:///./sqlite.db  # This will use SQLite with storage at ./sqlite.db
    • [Optional] Enable scalar store using Elastic:

      $ export USE_SCALAR=True
      $ export ES_CLOUD_ID=your_elastic_cloud_id
      $ export ES_USER=your_elastic_username
      $ export ES_PASSWORD=your_elastic_password

    Refer to Configuration for more detailed instructions.

  4. Start Gradio

    python gradio_demo.py --towhee
    # python gradio_demo.py --langchain

  5. Open in browser

    Open local or public url returned by step 4 to access the online demo.

Play it Online

  • Add project

    Enter url Upload file
  • Start Conversation

Clone this wiki locally