-
Notifications
You must be signed in to change notification settings - Fork 17
[v1.38] Release v1.38 documentation to main #438
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
g-despot
wants to merge
26
commits into
main
Choose a base branch
from
v1-38/main
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 25 commits
Commits
Show all changes
26 commits
Select commit
Hold shift + click to select a range
fe4b6dc
Add 1.38 docs
g-despot 192f84d
Add docs
g-despot 6af1e75
Merge branch 'main' into v1-38/main
g-despot cb116dc
Add MCP docs changes
g-despot b83fbb1
Merge branch 'v1-38/main' into v1-38/nested-object-filtering
g-despot bdfb159
Update docs
g-despot c52cc20
Update docker images
g-despot ddd580b
Add boost docs
g-despot 17d2497
Implement fixes
g-despot 8fe5060
Update REST API
g-despot 62f1a5f
Merge branch 'main' into v1-38/main
g-despot fceb9f3
Document async replication enabled by default in v1.38
g-despot 015254a
Update code examples to drop removed asyncEnabled field
g-despot 29c6858
Update async replication metrics in monitoring reference
g-despot 69d6921
Correct outdated FQDN node discovery info in cluster concepts
g-despot 831064d
Document cross-data-center (WAN) cluster configuration
g-despot 6ddec7c
Add tracking doc for removed content cleanup
g-despot b76d475
Potential fix for pull request finding
g-despot a9e4802
Merge pull request #432 from weaviate/v1-38/boost
g-despot ee1e613
Merge pull request #430 from weaviate/v1-38/mcp
g-despot 8783161
Apply suggestions from code review
g-despot ed30e66
Merge pull request #425 from weaviate/v1-38/nested-object-filtering
g-despot c24a007
Address review feedback: override precedence + Multi-DC support status
g-despot df16292
Update docs
g-despot dd2c3d8
Merge pull request #434 from weaviate/v1-38/async-by-default
g-despot 7d3fea4
Implement feedback
g-despot File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,27 @@ | ||
| # Removed content — cleanup tracking | ||
|
|
||
| This file tracks documentation content that describes **removed** Weaviate features, | ||
| environment variables, or configuration fields. Rather than deleting such content the | ||
| moment a feature is removed, we keep it in place with a short "Removed in `vX.Y`" note so | ||
| that users upgrading from an older version can still find the entry and understand what | ||
| happened to it. Once enough releases have passed that few users are upgrading across the | ||
| removal boundary, the noted content should be deleted. | ||
|
|
||
| ## Policy | ||
|
|
||
| - When a feature/env var/config field is removed from Weaviate, **mark** the corresponding | ||
| docs entry as `Removed in vX.Y` instead of deleting it immediately. | ||
| - Add a row to the table below so the kept-but-stale content can be found and cleaned later. | ||
| - **Suggested cleanup window:** keep the note for roughly three minor releases after the | ||
| removal, then delete the entry and remove its row here. (Adjust per the supported-version | ||
| policy at cleanup time — these are guidelines, not hard commitments.) | ||
|
|
||
| ## Tracked entries | ||
|
|
||
| | Page / file | Removed item | Removed in | Suggested cleanup | Notes | | ||
| | --- | --- | --- | --- | --- | | ||
| | `docs/deploy/configuration/env-vars/index.md` | `ASYNC_REPLICATION_CLUSTER_MAX_WORKERS` (table row) | `v1.38` | `v1.41`+ | Replaced by `ASYNC_REPLICATION_SCHEDULER_WORKERS`. | | ||
| | `docs/deploy/configuration/env-vars/index.md` | `ASYNC_REPLICATION_ALIVE_NODES_CHECKING_FREQUENCY` (table row) | `v1.38` | `v1.41`+ | Scheduler no longer polls alive nodes separately. | | ||
| | `docs/deploy/configuration/env-vars/runtime-config.md` | `async_replication_cluster_max_workers` (override mapping row) | `v1.38` | `v1.41`+ | Runtime override removed alongside the env var. | | ||
| | `docs/deploy/configuration/async-rep.md` | "Removed environment variables (v1.38)" `<details>` block (both vars above) | `v1.38` | `v1.41`+ | Delete the whole block at cleanup. | | ||
| | `docs/deploy/configuration/replication.md` | "Removed in `v1.38`" `:::note` admonition | `v1.38` | `v1.41`+ | Mentions both removed env vars. | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,3 +1,3 @@ | ||
| :::info Collection-level configuration — Added in `v1.36` | ||
| Async replication parameters can also be set per-collection via the `asyncConfig` object in `replicationConfig`. Per-collection settings override the cluster-wide environment variable defaults. See [Collection `asyncConfig` parameters](/weaviate/config-refs/collections#async-config) for details. | ||
| Async replication runs by default for any collection with a replication factor greater than `1` (as of `v1.38`). To fine-tune its behavior for a specific collection, set the `asyncConfig` object in `replicationConfig`. Cluster-wide environment variable settings override per-collection settings. See [Collection `asyncConfig` parameters](/weaviate/config-refs/collections#async-config) for details. | ||
| ::: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,240 @@ | ||
| # How-to: Search > Boost results — Python examples. | ||
| # | ||
| # Requires Weaviate v1.38+ and the Python client release that adds Boost | ||
| # support (PR weaviate/weaviate-python-client#2030). Boost is gRPC-only — | ||
| # REST/curl is not supported. | ||
| # | ||
| # Uses the text2vec-transformers vectorizer. Run against the local stack | ||
| # in tests/docker-compose-anon.yml (Weaviate + transformers inference). | ||
|
|
||
| import time | ||
| from datetime import datetime, timedelta, timezone | ||
|
|
||
| import weaviate | ||
| from weaviate.classes.config import Configure, DataType, Property, Tokenization | ||
| from weaviate.classes.query import Boost, Filter | ||
|
|
||
| client = weaviate.connect_to_local() | ||
|
|
||
| # ---- Fixture: an Articles collection with date + numeric properties ---- | ||
| client.collections.delete("Articles") | ||
| client.collections.create( | ||
| name="Articles", | ||
| vector_config=Configure.Vectors.text2vec_transformers(), | ||
| properties=[ | ||
| Property(name="title", data_type=DataType.TEXT), | ||
| Property(name="category", data_type=DataType.TEXT, tokenization=Tokenization.FIELD), | ||
| Property(name="published", data_type=DataType.DATE), | ||
| Property(name="likes", data_type=DataType.INT), | ||
| Property(name="price", data_type=DataType.NUMBER), | ||
| Property(name="draft", data_type=DataType.BOOL), | ||
| ], | ||
| ) | ||
|
|
||
| now = datetime.now(timezone.utc) | ||
| articles = client.collections.use("Articles") | ||
| articles.data.insert_many([ | ||
| {"title": "Transformers explained", "category": "research", "published": now - timedelta(days=2), "likes": 100, "price": 49.99, "draft": False}, | ||
| {"title": "Old transformer survey", "category": "research", "published": now - timedelta(days=400), "likes": 5000, "price": 49.99, "draft": False}, | ||
| {"title": "How to fine-tune a model", "category": "tutorial", "published": now - timedelta(days=1), "likes": 30, "price": 9.99, "draft": False}, | ||
| {"title": "Pricing transformers", "category": "tutorial", "published": now - timedelta(days=10), "likes": 5000000, "price": 199.0, "draft": False}, | ||
| {"title": "Draft: transformer architecture","category": "research", "published": now - timedelta(days=3), "likes": 200, "price": 9.99, "draft": True}, | ||
| ]) | ||
|
|
||
| # Wait briefly for the vectorizer to finish indexing the new objects. | ||
| time.sleep(3) | ||
|
|
||
|
|
||
| # ========================================== | ||
| # ===== Filter boost (soft WHERE) ===== | ||
| # ========================================== | ||
|
|
||
| # START BoostFilter | ||
| # Promote articles in the "research" category without filtering others out. | ||
| response = articles.query.near_text( | ||
| query="transformer architectures", | ||
| limit=5, | ||
| # highlight-start | ||
| boost=Boost.filter( | ||
| Filter.by_property("category").equal("research"), | ||
| weight=0.5, | ||
| ), | ||
| # highlight-end | ||
| return_properties=["title", "category"], | ||
| ) | ||
|
|
||
| for o in response.objects: | ||
| print(o.properties["category"], "-", o.properties["title"]) | ||
| # END BoostFilter | ||
|
|
||
| assert response.objects[0].properties["category"] == "research" | ||
|
|
||
|
|
||
| # ========================================== | ||
| # ===== Property boost (numeric value) ===== | ||
| # ========================================== | ||
|
|
||
| # START BoostProperty | ||
| # Bias toward articles with more `likes`. LOG1P dampens the long tail so a | ||
| # single 5-million-likes outlier doesn't dominate. | ||
| response = articles.query.near_text( | ||
| query="transformer architectures", | ||
| limit=5, | ||
| # highlight-start | ||
| boost=Boost.property( | ||
| "likes", | ||
| modifier=Boost.Modifier.LOG1P, | ||
| weight=0.7, | ||
| ), | ||
| # highlight-end | ||
| return_properties=["title", "likes"], | ||
| ) | ||
|
|
||
| for o in response.objects: | ||
| print(o.properties["likes"], "-", o.properties["title"]) | ||
| # END BoostProperty | ||
|
|
||
|
|
||
| # ========================================== | ||
| # ===== Time decay (boost recent docs) ===== | ||
| # ========================================== | ||
|
|
||
| # START BoostTimeDecay | ||
| # Score decays exponentially over time. "30d scale" + decay=0.5 means an | ||
| # article that's 30 days old gets half the score of one published "now". | ||
| response = articles.query.near_text( | ||
| query="transformer architectures", | ||
| limit=5, | ||
| # highlight-start | ||
| boost=Boost.time_decay( | ||
| "published", | ||
| origin="now", | ||
| scale=timedelta(days=30), | ||
| curve=Boost.Curve.EXPONENTIAL, | ||
| decay=0.5, | ||
| weight=0.6, | ||
| ), | ||
| # highlight-end | ||
| return_properties=["title", "published"], | ||
| ) | ||
| # END BoostTimeDecay | ||
|
|
||
| # The 400-day-old "Old transformer survey" should be demoted vs the 2-day-old article. | ||
| top_titles = [o.properties["title"] for o in response.objects[:2]] | ||
| assert "Old transformer survey" not in top_titles | ||
|
|
||
|
|
||
| # ========================================== | ||
| # ===== Numeric decay (closest to a value) ===== | ||
| # ========================================== | ||
|
|
||
| # START BoostNumericDecay | ||
| # Score peaks at a target price and falls off symmetrically. Gauss gives a | ||
| # bell-shaped falloff: items within `offset` of $49.99 score 1.0, items at | ||
| # $59.99 (one scale away) score `decay`. | ||
| response = articles.query.near_text( | ||
| query="transformer architectures", | ||
| limit=5, | ||
| # highlight-start | ||
| boost=Boost.numeric_decay( | ||
| "price", | ||
| origin=49.99, | ||
| scale=10.0, | ||
| curve=Boost.Curve.GAUSSIAN, | ||
| decay=0.5, | ||
| weight=0.5, | ||
| ), | ||
| # highlight-end | ||
| return_properties=["title", "price"], | ||
| ) | ||
| # END BoostNumericDecay | ||
|
|
||
| # Both top-2 results have the target price; the $199 outlier is pushed down. | ||
| assert all(o.properties["price"] == 49.99 for o in response.objects[:2]) | ||
|
|
||
|
|
||
| # ========================================== | ||
| # ===== Blend multiple conditions ===== | ||
| # ========================================== | ||
|
|
||
| # START BoostBlend | ||
| # Combine two soft signals: recency (weight 2) + popularity (weight 1). | ||
| # The outer weight=0.4 controls how much the blended rank affects the | ||
| # final score; the inner weights are *per-condition* and balance each | ||
| # other. | ||
| response = articles.query.near_text( | ||
| query="transformer architectures", | ||
| limit=5, | ||
| # highlight-start | ||
| boost=Boost.blend( | ||
| Boost.time_decay("published", origin="now", scale=timedelta(days=30), weight=2.0), | ||
| Boost.property("likes", modifier=Boost.Modifier.LOG1P, weight=1.0), | ||
| weight=0.4, | ||
| depth=200, # rescore the top 200 vector matches | ||
| ), | ||
| # highlight-end | ||
| return_properties=["title", "likes", "published"], | ||
| ) | ||
| # END BoostBlend | ||
|
|
||
| # Recency dominates, but the LOG1P-dampened 5M-likes article still surfaces | ||
| # in the top 3 — popularity is helping, not invisible. | ||
| assert any(o.properties["likes"] == 5_000_000 for o in response.objects[:3]) | ||
|
|
||
|
|
||
| # ========================================== | ||
| # ===== Negative weights demote ===== | ||
| # ========================================== | ||
|
|
||
| # START BoostNegativeWeight | ||
| # A negative per-condition weight pushes matching documents DOWN — they | ||
| # stay in the result set but lose ground against everything else. Use | ||
| # this to deprioritize drafts without filtering them out entirely. | ||
| response = articles.query.bm25( | ||
| query="transformer", | ||
| limit=5, | ||
| # highlight-start | ||
| boost=Boost.blend( | ||
| Boost.filter(Filter.by_property("draft").equal(True), weight=-2.0), | ||
| weight=0.5, | ||
| ), | ||
| # highlight-end | ||
| return_properties=["title", "draft"], | ||
| ) | ||
|
|
||
| # The draft article is still in results, just no longer first. | ||
| all_titles = [o.properties["title"] for o in response.objects] | ||
| assert any("Draft" in t for t in all_titles) | ||
| assert response.objects[0].properties["draft"] is False | ||
| # END BoostNegativeWeight | ||
|
|
||
|
|
||
| # ========================================== | ||
| # ===== Boost on hybrid search ===== | ||
| # ========================================== | ||
|
|
||
| # START BoostOnHybrid | ||
| # Hybrid keeps its own alpha-blend of BM25 + vector. The boost runs once | ||
| # over the fused hybrid result — the sub-search legs don't see it. | ||
| response = articles.query.hybrid( | ||
| query="transformer architectures", | ||
| alpha=0.75, | ||
| limit=5, | ||
| # highlight-start | ||
| boost=Boost.blend( | ||
| Boost.filter(Filter.by_property("category").equal("research"), weight=1.0), | ||
| Boost.filter(Filter.by_property("draft").equal(True), weight=-2.0), | ||
| weight=0.3, | ||
| ), | ||
| # highlight-end | ||
| return_properties=["title", "category", "draft"], | ||
| ) | ||
| # END BoostOnHybrid | ||
|
|
||
| # Top result is research and not a draft — both boost legs worked. | ||
| assert response.objects[0].properties["category"] == "research" | ||
| assert response.objects[0].properties["draft"] is False | ||
|
|
||
|
|
||
| client.collections.delete("Articles") | ||
| client.close() |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.