BYOI (Bring Your Own Infrastructure)
Connect your own infrastructure components for complete control over your chatbot's backend.
Overview
BYOI allows you to replace WizChat's default infrastructure with your own:
- Custom LLM - Use your own OpenAI-compatible endpoint
- Custom Embeddings - Use your own embedding service
- Custom Vector Store - Use your own PostgreSQL with pgvector
- Custom FalkorDB - Use your own graph database for GraphRAG
- Custom Conversations DB - Use your own PostgreSQL for chat history
Who Is This For?
BYOI is ideal for:
- Enterprise customers with data residency requirements
- Organizations with existing AI infrastructure investments
- Teams requiring specific model configurations
- Companies with compliance needs requiring self-hosted components
BYOI is available on Pro, Pro+, Business, and Enterprise plans.
Supported Components
Custom LLM
Use any OpenAI-compatible API endpoint as your language model.
Compatible with:
- Azure OpenAI
- AWS Bedrock (via proxy)
- Google Vertex AI (via proxy)
- Ollama
- vLLM
- LocalAI
- Any OpenAI-compatible endpoint
Configuration:
| Field | Description |
|---|---|
| API Endpoint | Base URL (e.g., https://your-api.com/v1) |
| API Key | Authentication key |
| Model Name | Model identifier (e.g., gpt-4o, llama-3.1-70b) |
Custom Embeddings
Use your own embedding service for document vectorization.
Compatible with:
- Azure OpenAI Embeddings
- Cohere Embeddings
- Voyage AI
- Any OpenAI-compatible embedding endpoint
Configuration:
| Field | Description |
|---|---|
| API Endpoint | Base URL for embeddings |
| API Key | Authentication key |
| Model Name | Embedding model (e.g., text-embedding-3-large) |
| Dimensions | Vector dimensions (default: 3072) |
Custom Vector Store
Use your own PostgreSQL database with pgvector extension for document storage.
Requirements:
- PostgreSQL 14+
- pgvector extension installed
- SSL connection supported
Configuration:
| Field | Description |
|---|---|
| Host | Database host |
| Port | Database port (default: 5432) |
| Database | Database name |
| Username | Database user |
| Password | Database password |
| SSL Mode | SSL connection mode |
WizChat will create required tables automatically on first use.
Custom FalkorDB
Use your own FalkorDB instance for GraphRAG capabilities.
Requirements:
- FalkorDB 4.0+
- Redis-compatible connection
Configuration:
| Field | Description |
|---|---|
| Host | FalkorDB host |
| Port | FalkorDB port (default: 6379) |
| Password | Connection password (optional) |
| SSL | Enable SSL connection |
Custom Conversations Database
Use your own PostgreSQL for storing chat conversations.
Requirements:
- PostgreSQL 14+
- SSL connection supported
Configuration:
| Field | Description |
|---|---|
| Host | Database host |
| Port | Database port (default: 5432) |
| Database | Database name |
| Username | Database user |
| Password | Database password |
| SSL Mode | SSL connection mode |
Setting Up BYOI
Step 1: Create a New Chatbot
BYOI is configured during chatbot creation:
- Go to Dashboard > Chatbots
- Click "Create New Chatbot"
- Scroll down to find the "BYOI (Bring Your Own Infrastructure)" panel
Step 2: Enable and Configure Components
- Toggle "Enable BYOI" to expand the configuration panel
- For each component you want to customize:
- Toggle the component switch (LLM, Embeddings, Vector Store, etc.)
- Fill in the required connection details
- Click "Test Connection" to validate
- Complete the rest of the chatbot creation form
- Click "Create Chatbot"
Step 3: Verify Configuration
After creating the chatbot:
- Check that all BYOI components show green checkmarks
- Test the chatbot with a sample query
- Verify data flows to your infrastructure correctly
Environment Variables
When deploying your chatbot, BYOI settings are injected as environment variables:
LLM:
CUSTOM_LLM_ENDPOINT=https://your-api.com/v1
CUSTOM_LLM_API_KEY=***
CUSTOM_LLM_MODEL=gpt-4o
Embeddings:
CUSTOM_EMBEDDINGS_ENDPOINT=https://your-api.com/v1
CUSTOM_EMBEDDINGS_API_KEY=***
CUSTOM_EMBEDDINGS_MODEL=text-embedding-3-large
CUSTOM_EMBEDDINGS_DIMENSIONS=3072
Vector Store:
CUSTOM_PGVECTOR_HOST=your-db.com
CUSTOM_PGVECTOR_PORT=5432
CUSTOM_PGVECTOR_DATABASE=vectors
CUSTOM_PGVECTOR_USER=***
CUSTOM_PGVECTOR_PASSWORD=***
CUSTOM_PGVECTOR_SSL_MODE=require
FalkorDB:
CUSTOM_FALKORDB_HOST=your-falkor.com
CUSTOM_FALKORDB_PORT=6379
CUSTOM_FALKORDB_PASSWORD=***
CUSTOM_FALKORDB_SSL=true
Conversations:
CUSTOM_CONVERSATIONS_HOST=your-db.com
CUSTOM_CONVERSATIONS_PORT=5432
CUSTOM_CONVERSATIONS_DATABASE=conversations
CUSTOM_CONVERSATIONS_USER=***
CUSTOM_CONVERSATIONS_PASSWORD=***
CUSTOM_CONVERSATIONS_SSL_MODE=require
Security
Credential Storage
- All credentials are encrypted at rest
- Credentials are stored in secure, isolated storage
- Access is limited to your account only
- Credentials can be rotated at any time
Network Security
- Connections use SSL/TLS when available
- API keys are never logged
- Connection strings are not exposed in UI after saving
Best Practices
- Use dedicated service accounts with minimal permissions
- Rotate credentials regularly
- Enable SSL for all connections
- Use network firewalls to restrict access
- Monitor connection logs for anomalies
Never use production database admin credentials. Create dedicated service accounts with only the required permissions.
Validation & Testing
Testing Connections
Use the "Test Connection" button to verify:
- Network connectivity
- Authentication
- Required permissions
- SSL configuration
Validation Checklist
| Component | Validation |
|---|---|
| LLM | Test chat completion request |
| Embeddings | Test vector generation |
| Vector Store | Test insert and query operations |
| FalkorDB | Test graph write and read |
| Conversations | Test table creation and queries |
Troubleshooting
Connection Timeout:
- Check firewall rules
- Verify host is reachable
- Confirm port is open
Authentication Failed:
- Verify API key or password
- Check user permissions
- Confirm account is active
SSL Error:
- Match SSL mode with server configuration
- Verify certificate validity
- Try different SSL modes
Migration
Moving to BYOI
- Set up your infrastructure components
- Configure BYOI settings in WizChat
- Test with a new chatbot first
- Migrate existing chatbots gradually
Moving from BYOI
- Disable custom components
- WizChat will use default infrastructure
- Note: Data in custom infrastructure is not migrated