Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.anyfast.ai/llms.txt

Use this file to discover all available pages before exploring further.

1. About DB-GPT

DB-GPT is an open-source AI Native Data App Development framework. It provides multi-model management, Text2SQL optimization, RAG framework, and Multi-Agent collaboration capabilities.

2. Get an API Key

Open the Anyfast console and sign up (or log in). Go to API Keys, create a new API Key, and copy it.

3. Deploy DB-GPT

3.1 Clone DB-GPT

git clone https://github.com/eosphoros-ai/DB-GPT.git
cd DB-GPT

3.2 Create virtual environment and install dependencies

conda create -n dbgpt_env python=3.10
conda activate dbgpt_env
pip install -e ".[proxy]"

3.3 Configure environment variables

cp .env.template .env
Edit .env and configure Anyfast models:
# Use Anyfast as the proxy model provider
LLM_MODEL=proxy_openai
PROXY_OPENAI_API_BASE=https://www.anyfast.ai/v1
PROXY_OPENAI_API_KEY={your-anyfast-api-key}
PROXY_OPENAI_BACKEND=gpt-4o

# Embedding model (OpenAI-compatible)
EMBEDDING_MODEL=proxy_http_openapi
PROXY_HTTP_OPENAPI_PROXY_SERVER_URL=https://www.anyfast.ai/v1/embeddings
PROXY_HTTP_OPENAPI_PROXY_API_KEY={your-anyfast-api-key}
PROXY_HTTP_OPENAPI_PROXY_BACKEND=text-embedding-3-small

3.4 Start DB-GPT

dbgpt start webserver --port 5670
Open http://127.0.0.1:5670/ in your browser.

4. Using Anyfast via DB-GPT Python SDK

4.1 Install

pip install "dbgpt>=0.6.3rc2" openai

4.2 Use Anyfast language model

from openai import OpenAI

client = OpenAI(
    api_key="{your-anyfast-api-key}",
    base_url="https://www.anyfast.ai/v1"
)

response = client.chat.completions.create(
    model="gpt-4o",
    messages=[
        {"role": "system", "content": "You are a helpful AI assistant."},
        {"role": "user", "content": "Hello"}
    ]
)
print(response.choices[0].message.content)

5. Getting Started

  1. Add a data source — Select a database type (MySQL, PostgreSQL, etc.) and connect.
  2. Choose ChatData mode — Use the natural language-to-data conversation feature.
  3. Start data conversations — Select the Anyfast model and your database, then start chatting with your data.