Skip to content

Commit 5fc5e4f

Browse files
committed
Merge branch 'main' into preview-rc-rdi
2 parents 0427b13 + 2ff439c commit 5fc5e4f

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+4263
-394
lines changed

.github/workflows/redisvl_docs_sync.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -284,6 +284,9 @@ jobs:
284284
python3 build/version_archiver.py redisvl ${version} --skip-archive
285285
fi
286286
287+
# Globally replace unicode quotes to ASCII
288+
find content/develop/ai/redisvl/ -type f -exec sed -i 's/[“”]/"/g' {} \;
289+
287290
- name: 'Create pull request if necessary'
288291
env:
289292
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

assets/css/index.css

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -240,16 +240,16 @@ select {
240240
}
241241

242242
.search-item {
243-
@apply bg-white rounded-md relative text-redis-ink-900 border border-redis-pen-800;
243+
@apply bg-gray-700 rounded-md relative text-gray-300 border border-gray-600;
244244
}
245245

246246
.search-item[aria-selected] {
247-
@apply bg-red-100;
247+
@apply bg-gray-600;
248248
}
249249

250250
.search-item:hover,
251251
.search-item:not([aria-selected]):focus-within {
252-
@apply bg-red-50 text-redis-pen-800;
252+
@apply bg-gray-600 text-white;
253253
}
254254

255255
.search-item > a {

content/develop/ai/langcache/api-examples.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ For example:
3434
curl -s -X POST "https://$HOST/v1/caches/$CACHE_ID/entries/search" \
3535
-H "accept: application/json" \
3636
-H "Authorization: Bearer $API_KEY" \
37-
-d "{ 'prompt': 'What is semantic caching' }"
37+
-d '{ "prompt": "What is semantic caching" }'
3838
{{< /clients-example >}}
3939

4040
This example expects several variables to be set in the shell:

content/develop/ai/redisvl/0.6.0/api/cache.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ Semantic Cache for Large Language Models.
1919

2020
* **Parameters:**
2121
* **name** (*str* *,* *optional*) – The name of the semantic cache search index.
22-
Defaults to llmcache.
22+
Defaults to "llmcache".
2323
* **distance_threshold** (*float* *,* *optional*) – Semantic threshold for the
2424
cache. Defaults to 0.1.
2525
* **ttl** (*Optional* *[* *int* *]* *,* *optional*) – The time-to-live for records cached
@@ -416,10 +416,10 @@ Embeddings Cache for storing embedding vectors with exact key matching.
416416
Initialize an embeddings cache.
417417

418418
* **Parameters:**
419-
* **name** (*str*) – The name of the cache. Defaults to embedcache.
419+
* **name** (*str*) – The name of the cache. Defaults to "embedcache".
420420
* **ttl** (*Optional* *[* *int* *]*) – The time-to-live for cached embeddings. Defaults to None.
421421
* **redis_client** (*Optional* *[* *Redis* *]*) – Redis client instance. Defaults to None.
422-
* **redis_url** (*str*) – Redis URL for connection. Defaults to redis://localhost:6379.
422+
* **redis_url** (*str*) – Redis URL for connection. Defaults to "redis://localhost:6379".
423423
* **connection_kwargs** (*Dict* *[* *str* *,* *Any* *]*) – Redis connection arguments. Defaults to {}.
424424
* **Raises:**
425425
**ValueError** – If vector dimensions are invalid

content/develop/ai/redisvl/0.6.0/api/filter.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ f = Text("job") == "engineer"
126126

127127
#### `__mod__(other)`
128128

129-
Create a Text LIKE filter expression. A flexible expression that
129+
Create a Text "LIKE" filter expression. A flexible expression that
130130
yields filters that can use a variety of additional operators like
131131
wildcards (\*), fuzzy matches (%%), or combinatorics (|) of the supplied
132132
term(s).
@@ -344,9 +344,9 @@ Create a GeoRadius specification (GeoSpec)
344344
* **longitude** (*float*) – The longitude of the center of the radius.
345345
* **latitude** (*float*) – The latitude of the center of the radius.
346346
* **radius** (*int* *,* *optional*) – The radius of the circle. Defaults to 1.
347-
* **unit** (*str* *,* *optional*) – The unit of the radius. Defaults to “km”.
347+
* **unit** (*str* *,* *optional*) – The unit of the radius. Defaults to "km".
348348
* **Raises:**
349-
**ValueError** – If the unit is not one of “m”, “km”, “mi”, or “ft”.
349+
**ValueError** – If the unit is not one of "m", "km", "mi", or "ft".
350350

351351
#### `__init__(longitude, latitude, radius=1, unit='km')`
352352

@@ -356,6 +356,6 @@ Create a GeoRadius specification (GeoSpec)
356356
* **longitude** (*float*) – The longitude of the center of the radius.
357357
* **latitude** (*float*) – The latitude of the center of the radius.
358358
* **radius** (*int* *,* *optional*) – The radius of the circle. Defaults to 1.
359-
* **unit** (*str* *,* *optional*) – The unit of the radius. Defaults to “km”.
359+
* **unit** (*str* *,* *optional*) – The unit of the radius. Defaults to "km".
360360
* **Raises:**
361-
**ValueError** – If the unit is not one of “m”, “km”, “mi”, or “ft”.
361+
**ValueError** – If the unit is not one of "m", "km", "mi", or "ft".

content/develop/ai/redisvl/0.6.0/api/query.md

Lines changed: 30 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ expression.
2727
* **filter_expression** (*Union* *[* *str* *,* [*FilterExpression*]({{< relref "filter/#filterexpression" >}}) *]* *,* *optional*) – A filter to apply
2828
along with the vector search. Defaults to None.
2929
* **dtype** (*str* *,* *optional*) – The dtype of the vector. Defaults to
30-
float32.
30+
"float32".
3131
* **num_results** (*int* *,* *optional*) – The top k results to return from the
3232
vector search. Defaults to 10.
3333
* **return_score** (*bool* *,* *optional*) – Whether to return the vector
@@ -40,14 +40,14 @@ expression.
4040
the same order as the terms in the query filter, regardless of
4141
the offsets between them. Defaults to False.
4242
* **hybrid_policy** (*Optional* *[* *str* *]*) – Controls how filters are applied during vector search.
43-
Options are BATCHES (paginates through small batches of nearest neighbors) or
44-
ADHOC_BF (computes scores for all vectors passing the filter).
45-
BATCHES mode is typically faster for queries with selective filters.
46-
ADHOC_BF mode is better when filters match a large portion of the dataset.
43+
Options are "BATCHES" (paginates through small batches of nearest neighbors) or
44+
"ADHOC_BF" (computes scores for all vectors passing the filter).
45+
"BATCHES" mode is typically faster for queries with selective filters.
46+
"ADHOC_BF" mode is better when filters match a large portion of the dataset.
4747
Defaults to None, which lets Redis auto-select the optimal policy.
48-
* **batch_size** (*Optional* *[* *int* *]*) – When hybrid_policy is BATCHES, controls the number
48+
* **batch_size** (*Optional* *[* *int* *]*) – When hybrid_policy is "BATCHES", controls the number
4949
of vectors to fetch in each batch. Larger values may improve performance
50-
at the cost of memory usage. Only applies when hybrid_policy=BATCHES.
50+
at the cost of memory usage. Only applies when hybrid_policy="BATCHES".
5151
Defaults to None, which lets Redis auto-select an appropriate batch size.
5252
* **ef_runtime** (*Optional* *[* *int* *]*) – Controls the size of the dynamic candidate list for HNSW
5353
algorithm at query time. Higher values improve recall at the expense of
@@ -90,7 +90,7 @@ Add a expander field to the query.
9090

9191
Match only documents where the query terms appear in
9292
the same order in the document.
93-
i.e. for the query hello world, we do not match world hello
93+
i.e. for the query "hello world", we do not match "world hello"
9494

9595
* **Return type:**
9696
*Query*
@@ -184,7 +184,7 @@ Default is TFIDF.
184184
Set the batch size for the query.
185185

186186
* **Parameters:**
187-
**batch_size** (*int*) – The batch size to use when hybrid_policy is BATCHES.
187+
**batch_size** (*int*) – The batch size to use when hybrid_policy is "BATCHES".
188188
* **Raises:**
189189
* **TypeError** – If batch_size is not an integer
190190
* **ValueError** – If batch_size is not positive
@@ -215,8 +215,8 @@ Set the filter expression for the query.
215215
Set the hybrid policy for the query.
216216

217217
* **Parameters:**
218-
**hybrid_policy** (*str*) – The hybrid policy to use. Options are BATCHES
219-
or ADHOC_BF.
218+
**hybrid_policy** (*str*) – The hybrid policy to use. Options are "BATCHES"
219+
or "ADHOC_BF".
220220
* **Raises:**
221221
**ValueError** – If hybrid_policy is not one of the valid options
222222

@@ -336,7 +336,7 @@ distance threshold.
336336
* **filter_expression** (*Union* *[* *str* *,* [*FilterExpression*]({{< relref "filter/#filterexpression" >}}) *]* *,* *optional*) – A filter to apply
337337
along with the range query. Defaults to None.
338338
* **dtype** (*str* *,* *optional*) – The dtype of the vector. Defaults to
339-
float32.
339+
"float32".
340340
* **distance_threshold** (*float*) – The threshold for vector distance.
341341
A smaller threshold indicates a stricter semantic search.
342342
Defaults to 0.2.
@@ -357,14 +357,14 @@ distance threshold.
357357
the same order as the terms in the query filter, regardless of
358358
the offsets between them. Defaults to False.
359359
* **hybrid_policy** (*Optional* *[* *str* *]*) – Controls how filters are applied during vector search.
360-
Options are BATCHES (paginates through small batches of nearest neighbors) or
361-
ADHOC_BF (computes scores for all vectors passing the filter).
362-
BATCHES mode is typically faster for queries with selective filters.
363-
ADHOC_BF mode is better when filters match a large portion of the dataset.
360+
Options are "BATCHES" (paginates through small batches of nearest neighbors) or
361+
"ADHOC_BF" (computes scores for all vectors passing the filter).
362+
"BATCHES" mode is typically faster for queries with selective filters.
363+
"ADHOC_BF" mode is better when filters match a large portion of the dataset.
364364
Defaults to None, which lets Redis auto-select the optimal policy.
365-
* **batch_size** (*Optional* *[* *int* *]*) – When hybrid_policy is BATCHES, controls the number
365+
* **batch_size** (*Optional* *[* *int* *]*) – When hybrid_policy is "BATCHES", controls the number
366366
of vectors to fetch in each batch. Larger values may improve performance
367-
at the cost of memory usage. Only applies when hybrid_policy=BATCHES.
367+
at the cost of memory usage. Only applies when hybrid_policy="BATCHES".
368368
Defaults to None, which lets Redis auto-select an appropriate batch size.
369369
* **normalize_vector_distance** (*bool*) – Redis supports 3 distance metrics: L2 (euclidean),
370370
IP (inner product), and COSINE. By default, L2 distance returns an unbounded value.
@@ -404,7 +404,7 @@ Add a expander field to the query.
404404

405405
Match only documents where the query terms appear in
406406
the same order in the document.
407-
i.e. for the query hello world, we do not match world hello
407+
i.e. for the query "hello world", we do not match "world hello"
408408

409409
* **Return type:**
410410
*Query*
@@ -498,7 +498,7 @@ Default is TFIDF.
498498
Set the batch size for the query.
499499

500500
* **Parameters:**
501-
**batch_size** (*int*) – The batch size to use when hybrid_policy is BATCHES.
501+
**batch_size** (*int*) – The batch size to use when hybrid_policy is "BATCHES".
502502
* **Raises:**
503503
* **TypeError** – If batch_size is not an integer
504504
* **ValueError** – If batch_size is not positive
@@ -539,8 +539,8 @@ Set the filter expression for the query.
539539
Set the hybrid policy for the query.
540540

541541
* **Parameters:**
542-
**hybrid_policy** (*str*) – The hybrid policy to use. Options are BATCHES
543-
or ADHOC_BF.
542+
**hybrid_policy** (*str*) – The hybrid policy to use. Options are "BATCHES"
543+
or "ADHOC_BF".
544544
* **Raises:**
545545
**ValueError** – If hybrid_policy is not one of the valid options
546546

@@ -693,20 +693,20 @@ Instantiates a HybridQuery object.
693693
* **vector** (*Union* *[* *bytes* *,* *List* *[* *float* *]* *]*) – The vector to perform vector similarity search.
694694
* **vector_field_name** (*str*) – The vector field name to search in.
695695
* **text_scorer** (*str* *,* *optional*) – The text scorer to use. Options are {TFIDF, TFIDF.DOCNORM,
696-
BM25, DISMAX, DOCSCORE, BM25STD}. Defaults to BM25STD.
696+
BM25, DISMAX, DOCSCORE, BM25STD}. Defaults to "BM25STD".
697697
* **filter_expression** (*Optional* *[*[*FilterExpression*]({{< relref "filter/#filterexpression" >}}) *]* *,* *optional*) – The filter expression to use.
698698
Defaults to None.
699699
* **alpha** (*float* *,* *optional*) – The weight of the vector similarity. Documents will be scored
700700
as: hybrid_score = (alpha) \* vector_score + (1-alpha) \* text_score.
701701
Defaults to 0.7.
702-
* **dtype** (*str* *,* *optional*) – The data type of the vector. Defaults to float32.
702+
* **dtype** (*str* *,* *optional*) – The data type of the vector. Defaults to "float32".
703703
* **num_results** (*int* *,* *optional*) – The number of results to return. Defaults to 10.
704704
* **return_fields** (*Optional* *[* *List* *[* *str* *]* *]* *,* *optional*) – The fields to return. Defaults to None.
705705
* **stopwords** (*Optional* *[* *Union* *[* *str* *,* *Set* *[* *str* *]* *]* *]* *,* *optional*) – The stopwords to remove from the
706-
provided text prior to searchuse. If a string such as english” “german is
706+
provided text prior to searchuse. If a string such as "english" "german" is
707707
provided then a default set of stopwords for that language will be used. if a list,
708708
set, or tuple of strings is provided then those will be used as stopwords.
709-
Defaults to english. if set to None then no stopwords will be removed.
709+
Defaults to "english". if set to "None" then no stopwords will be removed.
710710
* **dialect** (*int* *,* *optional*) – The Redis dialect version. Defaults to 2.
711711
* **Raises:**
712712
* **ValueError** – If the text string is empty, or if the text string becomes empty after
@@ -728,7 +728,7 @@ Specify one or more projection expressions to add to each result
728728

729729
- **kwexpr**: One or more key-value pairs for a projection. The key is
730730
: the alias for the projection, and the value is the projection
731-
expression itself, for example apply(square_root=sqrt(@foo))
731+
expression itself, for example apply(square_root="sqrt(@foo)")
732732

733733
* **Return type:**
734734
*AggregateRequest*
@@ -986,7 +986,7 @@ Add a expander field to the query.
986986

987987
Match only documents where the query terms appear in
988988
the same order in the document.
989-
i.e. for the query hello world, we do not match world hello
989+
i.e. for the query "hello world", we do not match "world hello"
990990

991991
* **Return type:**
992992
*Query*
@@ -1198,7 +1198,7 @@ Add a expander field to the query.
11981198

11991199
Match only documents where the query terms appear in
12001200
the same order in the document.
1201-
i.e. for the query hello world, we do not match world hello
1201+
i.e. for the query "hello world", we do not match "world hello"
12021202

12031203
* **Return type:**
12041204
*Query*
@@ -1415,7 +1415,7 @@ Add a expander field to the query.
14151415

14161416
Match only documents where the query terms appear in
14171417
the same order in the document.
1418-
i.e. for the query hello world, we do not match world hello
1418+
i.e. for the query "hello world", we do not match "world hello"
14191419

14201420
* **Return type:**
14211421
*Query*

content/develop/ai/redisvl/0.6.0/api/vectorizer.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -671,7 +671,7 @@ Initialize the VoyageAI vectorizer.
671671
Visit [https://docs.voyageai.com/docs/embeddings](https://docs.voyageai.com/docs/embeddings) to learn about embeddings and check the available models.
672672

673673
* **Parameters:**
674-
* **model** (*str*) – Model to use for embedding. Defaults to voyage-large-2.
674+
* **model** (*str*) – Model to use for embedding. Defaults to "voyage-large-2".
675675
* **api_config** (*Optional* *[* *Dict* *]* *,* *optional*) – Dictionary containing the API key.
676676
Defaults to None.
677677
* **dtype** (*str*) – the default datatype to use when embedding text as byte arrays.

content/develop/ai/redisvl/0.7.0/api/cache.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ Semantic Cache for Large Language Models.
1919

2020
* **Parameters:**
2121
* **name** (*str* *,* *optional*) – The name of the semantic cache search index.
22-
Defaults to llmcache.
22+
Defaults to "llmcache".
2323
* **distance_threshold** (*float* *,* *optional*) – Semantic threshold for the
2424
cache. Defaults to 0.1.
2525
* **ttl** (*Optional* *[* *int* *]* *,* *optional*) – The time-to-live for records cached
@@ -416,10 +416,10 @@ Embeddings Cache for storing embedding vectors with exact key matching.
416416
Initialize an embeddings cache.
417417

418418
* **Parameters:**
419-
* **name** (*str*) – The name of the cache. Defaults to embedcache.
419+
* **name** (*str*) – The name of the cache. Defaults to "embedcache".
420420
* **ttl** (*Optional* *[* *int* *]*) – The time-to-live for cached embeddings. Defaults to None.
421421
* **redis_client** (*Optional* *[* *SyncRedisClient* *]*) – Redis client instance. Defaults to None.
422-
* **redis_url** (*str*) – Redis URL for connection. Defaults to redis://localhost:6379.
422+
* **redis_url** (*str*) – Redis URL for connection. Defaults to "redis://localhost:6379".
423423
* **connection_kwargs** (*Dict* *[* *str* *,* *Any* *]*) – Redis connection arguments. Defaults to {}.
424424
* **async_redis_client** (*Redis* *|* *RedisCluster* *|* *None*)
425425
* **Raises:**

content/develop/ai/redisvl/0.7.0/api/filter.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ f = Text("job") == "engineer"
126126

127127
#### `__mod__(other)`
128128

129-
Create a Text LIKE filter expression. A flexible expression that
129+
Create a Text "LIKE" filter expression. A flexible expression that
130130
yields filters that can use a variety of additional operators like
131131
wildcards (\*), fuzzy matches (%%), or combinatorics (|) of the supplied
132132
term(s).
@@ -344,9 +344,9 @@ Create a GeoRadius specification (GeoSpec)
344344
* **longitude** (*float*) – The longitude of the center of the radius.
345345
* **latitude** (*float*) – The latitude of the center of the radius.
346346
* **radius** (*int* *,* *optional*) – The radius of the circle. Defaults to 1.
347-
* **unit** (*str* *,* *optional*) – The unit of the radius. Defaults to “km”.
347+
* **unit** (*str* *,* *optional*) – The unit of the radius. Defaults to "km".
348348
* **Raises:**
349-
**ValueError** – If the unit is not one of “m”, “km”, “mi”, or “ft”.
349+
**ValueError** – If the unit is not one of "m", "km", "mi", or "ft".
350350

351351
#### `__init__(longitude, latitude, radius=1, unit='km')`
352352

@@ -356,6 +356,6 @@ Create a GeoRadius specification (GeoSpec)
356356
* **longitude** (*float*) – The longitude of the center of the radius.
357357
* **latitude** (*float*) – The latitude of the center of the radius.
358358
* **radius** (*int* *,* *optional*) – The radius of the circle. Defaults to 1.
359-
* **unit** (*str* *,* *optional*) – The unit of the radius. Defaults to “km”.
359+
* **unit** (*str* *,* *optional*) – The unit of the radius. Defaults to "km".
360360
* **Raises:**
361-
**ValueError** – If the unit is not one of “m”, “km”, “mi”, or “ft”.
361+
**ValueError** – If the unit is not one of "m", "km", "mi", or "ft".

0 commit comments

Comments
 (0)