You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Note: APISIX requires the model name in the URL path
124
138
- To generate the APISIX authentication token, use the [generate-token.sh](https://github.com/opea-project/Enterprise-Inference/blob/main/core/scripts/generate-token.sh) script
125
139
- The token is generated using Keycloak client credentials
126
140
127
-
Configuration requirements:
128
-
- INFERENCE_API_ENDPOINT: URL to your inference service (example: https://api.example.com)
129
-
- INFERENCE_API_TOKEN: Authentication token/API key for your chosen service
130
-
- EMBEDDING_MODEL_NAME: Embedding model name (default: BAAI/bge-base-en-v1.5)
131
-
- INFERENCE_MODEL_NAME: Inference model name (default: meta-llama/Llama-3.1-8B-Instruct)
132
-
- EMBEDDING_API_ENDPOINT: (Optional, for APISIX only) URL with embedding model in path
133
-
- INFERENCE_MODEL_ENDPOINT: (Optional, for APISIX only) URL with inference model in path
134
-
135
-
### Local Development Configuration
136
-
137
-
**For Local Testing Only**
138
-
139
-
If you're testing with a local inference endpoint using a custom domain (e.g., `api.example.com` mapped to localhost in your hosts file):
140
-
141
-
1. Edit `api/.env` and set:
142
-
```bash
143
-
LOCAL_URL_ENDPOINT=inference.example.com
144
-
```
145
-
(Use the domain name from your INFERENCE_API_ENDPOINT without `https://`)
146
-
147
-
2. This allows Docker containers to resolve your local domain correctly.
148
-
149
-
**Note:** For public domains or cloud-hosted endpoints, leave the default value `not-needed`.
150
-
151
141
### Verify Docker Installation
152
142
153
143
```bash
@@ -173,126 +163,29 @@ cd Enterprise-Inference/sample_solutions/MultiAgentQnA
173
163
174
164
### Set up the Environment
175
165
176
-
This application requires **two `.env` files** for proper configuration:
**Note:** If using a local domain (e.g., `api.example.com` mapped to localhost), replace `not-needed` with your domain name (without `https://`).
192
-
193
-
#### Step 2: Create `api/.env` File
194
-
195
-
This application requires an `api/.env` file for proper configuration. Create it with the commands below:
166
+
This application requires an `.env` file in the root directory for proper configuration. Create it using [.env.example](./.env.example) with the commands below:
196
167
197
168
```bash
198
-
# Create the api/.env file
199
-
cat > api/.env <<EOF
200
-
# Inference API Configuration
201
-
# INFERENCE_API_ENDPOINT: URL to your inference service (without /v1 suffix)
202
-
#
203
-
# **GenAI Gateway**: Provide your GenAI Gateway URL and API key
204
-
# - URL format: https://genai-gateway.example.com
205
-
# - To generate the GenAI Gateway API key, use the [generate-vault-secrets.sh] script
206
-
# - The API key is the litellm_master_key value from the generated vault.yml file
207
-
#
208
-
# **APISIX Gateway**: Provide your APISIX Gateway URL and authentication token
209
-
# - For APISIX, include the model name in the INFERENCE_API_ENDPOINT path
# Local URL Endpoint (only needed for non-public domains)
278
-
# If using a local domain like api.example.com mapped to localhost:
279
-
# Set this to: api.example.com (domain without https://)
280
-
# If using a public domain, set any placeholder value like: not-needed
281
-
LOCAL_URL_ENDPOINT=not-needed
282
-
283
-
# SSL Verification Settings
284
-
# Set to false only for dev with self-signed certs
285
-
VERIFY_SSL=true
169
+
cp .env.example .env
286
170
```
171
+
Then modify it as needed, with special consideration to certain environment variables mentioned below. Read through the .env file for full instructions.
287
172
288
173
**Important Configuration Notes:**
289
174
290
-
-**INFERENCE_API_ENDPOINT**: Your actual inference service URL (replace `https://your-api-endpoint.com/deployment`)
291
-
- For APISIX/Keycloak deployments, the model name must be included in the endpoint URL (e.g., `https://apisix-gateway.example.com/Llama-3.1-8B-Instruct`)
175
+
-**INFERENCE_API_ENDPOINT**: Your actual inference service URL (replace `https://api.example.com`)
176
+
- For APISIX/Keycloak deployments, the model name must be included in the endpoint URL (e.g., `https://api.example.com/Llama-3.1-8B-Instruct`)
292
177
-**INFERENCE_API_TOKEN**: Your actual pre-generated authentication token
293
-
-**LOCAL_URL_ENDPOINT**: Only needed if using local domain mapping (see [Local Development Configuration](#local-development-configuration))
294
-
295
-
**Note**: The docker-compose.yml file automatically loads environment variables from both `.env` (root) and `./api/.env` (backend) files.
178
+
-**EMBEDDING_MODEL_NAME**, **INFERENCE_MODEL_NAME**: Use the exact model name from your inference service
179
+
- To check available models: `curl https://api.example.com/v1/models -H "Authorization: Bearer your-token"`
180
+
-**EMBEDDING_API_ENDPOINT** (APISIX only): Your actual embedding service URL. **Comment out** for GenAI Gateway
181
+
-**LOCAL_URL_ENDPOINT**: Only needed if using local domain mapping (i.e. `api.example.com` mapped to localhost) for Docker containers to resolve correctly.
182
+
- Use the domain name from INFERENCE_API_ENDPOINT without `https://`
183
+
- For public domains or cloud-hosted endpoints, leave the default value `not-needed`
0 commit comments