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
> Connection fields (`host`, `port`, `db`, `user`, `password`) default to
319
+
> `${env.POSTGRES_*}` environment variable references when omitted.
320
+
307
321
**pgvector Table Schema:**
308
322
- `id` (text): UUID identifier of the chunk
309
323
- `document` (jsonb): JSON containing content and metadata
@@ -341,13 +355,7 @@ rag:
341
355
342
356
### Example 2: Multiple Knowledge Sources with pgvector
343
357
344
-
A configuration combining a local FAISS store (via `byok_rag`) with a remote pgvector store (configured directly in the Llama Stack configuration file):
345
-
346
-
> [!NOTE]
347
-
> pgvector is not yet supported via `byok_rag` in `lightspeed-stack.yaml` (see [LCORE-2437](https://redhat.atlassian.net/browse/LCORE-2437)).
348
-
> The pgvector provider must be configured directly in the Llama Stack configuration file.
349
-
350
-
**`lightspeed-stack.yaml`** — FAISS store and RAG strategy:
358
+
A configuration combining a local FAISS store with a remote pgvector store:
Copy file name to clipboardExpand all lines: docs/openapi.json
+73-5Lines changed: 73 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -11818,7 +11818,7 @@
11818
11818
"type": "string",
11819
11819
"minLength": 1,
11820
11820
"title": "RAG type",
11821
-
"description": "Type of RAG database.",
11821
+
"description": "Type of RAG database (e.g. 'inline::faiss', 'remote::pgvector').",
11822
11822
"default": "inline::faiss"
11823
11823
},
11824
11824
"embedding_model": {
@@ -11842,24 +11842,92 @@
11842
11842
"description": "Vector database identification."
11843
11843
},
11844
11844
"db_path": {
11845
-
"type": "string",
11845
+
"anyOf": [
11846
+
{
11847
+
"type": "string"
11848
+
},
11849
+
{
11850
+
"type": "null"
11851
+
}
11852
+
],
11846
11853
"title": "DB path",
11847
-
"description": "Path to RAG database."
11854
+
"description": "Path to RAG database. Required for inline::faiss."
11848
11855
},
11849
11856
"score_multiplier": {
11850
11857
"type": "number",
11851
11858
"exclusiveMinimum": 0.0,
11852
11859
"title": "Score multiplier",
11853
11860
"description": "Multiplier applied to relevance scores from this vector store. Used to weight results when querying multiple knowledge sources. Values > 1 boost this store's results; values < 1 reduce them.",
11854
11861
"default": 1.0
11862
+
},
11863
+
"host": {
11864
+
"anyOf": [
11865
+
{
11866
+
"type": "string"
11867
+
},
11868
+
{
11869
+
"type": "null"
11870
+
}
11871
+
],
11872
+
"title": "PostgreSQL host",
11873
+
"description": "PostgreSQL host for remote::pgvector. Defaults to ${env.POSTGRES_HOST} when rag_type is remote::pgvector."
11874
+
},
11875
+
"port": {
11876
+
"anyOf": [
11877
+
{
11878
+
"type": "string"
11879
+
},
11880
+
{
11881
+
"type": "null"
11882
+
}
11883
+
],
11884
+
"title": "PostgreSQL port",
11885
+
"description": "PostgreSQL port for remote::pgvector. Defaults to ${env.POSTGRES_PORT} when rag_type is remote::pgvector."
11886
+
},
11887
+
"db": {
11888
+
"anyOf": [
11889
+
{
11890
+
"type": "string"
11891
+
},
11892
+
{
11893
+
"type": "null"
11894
+
}
11895
+
],
11896
+
"title": "PostgreSQL database",
11897
+
"description": "PostgreSQL database name for remote::pgvector. Defaults to ${env.POSTGRES_DATABASE} when rag_type is remote::pgvector."
11898
+
},
11899
+
"user": {
11900
+
"anyOf": [
11901
+
{
11902
+
"type": "string"
11903
+
},
11904
+
{
11905
+
"type": "null"
11906
+
}
11907
+
],
11908
+
"title": "PostgreSQL user",
11909
+
"description": "PostgreSQL user for remote::pgvector. Defaults to ${env.POSTGRES_USER} when rag_type is remote::pgvector."
11910
+
},
11911
+
"password": {
11912
+
"anyOf": [
11913
+
{
11914
+
"type": "string",
11915
+
"format": "password",
11916
+
"writeOnly": true
11917
+
},
11918
+
{
11919
+
"type": "null"
11920
+
}
11921
+
],
11922
+
"title": "PostgreSQL password",
11923
+
"description": "PostgreSQL password for remote::pgvector. Defaults to ${env.POSTGRES_PASSWORD} when rag_type is remote::pgvector."
11855
11924
}
11856
11925
},
11857
11926
"additionalProperties": false,
11858
11927
"type": "object",
11859
11928
"required": [
11860
11929
"rag_id",
11861
-
"vector_db_id",
11862
-
"db_path"
11930
+
"vector_db_id"
11863
11931
],
11864
11932
"title": "ByokRag",
11865
11933
"description": "BYOK (Bring Your Own Knowledge) RAG configuration."
Copy file name to clipboardExpand all lines: docs/rag_guide.md
+13-28Lines changed: 13 additions & 28 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -88,10 +88,6 @@ See the full working [config example](../examples/lightspeed-stack-byok-okp-rag.
88
88
89
89
This example shows how to configure a remote PostgreSQL database with the [pgvector](https://github.com/pgvector/pgvector) extension for storing embeddings.
90
90
91
-
> [!NOTE]
92
-
> pgvector is not yet supported via `byok_rag` in `lightspeed-stack.yaml` (see [LCORE-2437](https://redhat.atlassian.net/browse/LCORE-2437)).
93
-
> It must be configured directly in the Llama Stack configuration file.
94
-
95
91
> You will need to install PostgreSQL with a matching version to pgvector, then log in with `psql` and enable the extension with:
96
92
> ```sql
97
93
> CREATE EXTENSION IF NOT EXISTS vector;
@@ -107,33 +103,22 @@ Each pgvector-backed table follows this schema:
107
103
> The `vector_store_id` (e.g. `rhdocs`) is used to point to the table named `vector_store_rhdocs` in the specified database, which stores the vector embeddings.
0 commit comments