Skip to content

:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.

fix(replay-vision): accept `now` as an observation date bound (#96159)

posthog[bot]e3c5da0781b0
diff --git a/products/replay_vision/backend/api/observations.py b/products/replay_vision/backend/api/observations.py
index eadf53b0ec5c..ea30c3021854 100644
--- a/products/replay_vision/backend/api/observations.py
+++ b/products/replay_vision/backend/api/observations.py
@@ -580,15 +580,16 @@ class ReplayObservationFilter(django_filters.FilterSet):
date_from = django_filters.CharFilter(
method="_filter_date_from",
help_text=(
- "Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; "
- "values without an explicit offset are interpreted in the project's timezone."
+ "Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, "
+ "or `now`; values without an explicit offset are interpreted in the project's timezone."
),
)
date_to = django_filters.CharFilter(
method="_filter_date_to",
help_text=(
- "Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; "
- "date-only values include the whole day, interpreted in the project's timezone."
+ "Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, "
+ "or `now` for the current time; omit it to query through the current time. Date-only values "
+ "include the whole day, interpreted in the project's timezone."
),
)
labeled = django_filters.BooleanFilter(
@@ -1117,15 +1118,16 @@ class ObservationSearchQuerySerializer(serializers.Serializer):
date_from = serializers.CharField(
required=False,
help_text=(
- "Only observations analyzed at or after this time. Accepts ISO 8601 or a relative date like `-7d`; "
- "values without an explicit offset are interpreted in the project's timezone."
+ "Only observations analyzed at or after this time. Accepts ISO 8601, a relative date like `-7d`, "
+ "or `now`; values without an explicit offset are interpreted in the project's timezone."
),
)
date_to = serializers.CharField(
required=False,
help_text=(
- "Only observations analyzed at or before this time. Accepts ISO 8601 or a relative date like `-1d`; "
- "date-only values include the whole day, interpreted in the project's timezone."
+ "Only observations analyzed at or before this time. Accepts ISO 8601, a relative date like `-1d`, "
+ "or `now` for the current time; omit it to query through the current time. Date-only values "
+ "include the whole day, interpreted in the project's timezone."
),
)
limit = serializers.IntegerField(
diff --git a/products/replay_vision/backend/max_tools.py b/products/replay_vision/backend/max_tools.py
index c2e151a39340..849a4eaf5c57 100644
--- a/products/replay_vision/backend/max_tools.py
+++ b/products/replay_vision/backend/max_tools.py
@@ -369,11 +369,12 @@ class SearchObservationsArgs(BaseModel):
)
date_from: str | None = Field(
default=None,
- description="Only recordings analyzed at or after this time: ISO 8601 or relative like '-7d'.",
+ description="Only recordings analyzed at or after this time: ISO 8601, relative like '-7d', or 'now'.",
)
date_to: str | None = Field(
default=None,
- description="Only recordings analyzed at or before this time: ISO 8601 or relative like '-1d'.",
+ description="Only recordings analyzed at or before this time: ISO 8601, relative like '-1d', or 'now'. "
+ "Omit it to search through the current time.",
)
limit: int | None = Field(
default=None,
diff --git a/products/replay_vision/backend/search.py b/products/replay_vision/backend/search.py
index e88a283e3962..0797f0f4b611 100644
--- a/products/replay_vision/backend/search.py
+++ b/products/replay_vision/backend/search.py
@@ -270,13 +270,17 @@ def fetch_ranked_observations(
def parse_date_bound(value: str, timezone_info: ZoneInfo | None, *, end_of_range: bool) -> datetime:
- """Parse a caller-supplied date bound: ISO 8601 or relative (`-7d`), naive values in the project's
- timezone. A date-only upper bound covers its whole day. Shared by the observation list and search.
- Raises `ValueError` on text that is neither, rather than silently treating it as now."""
- parsed, delta_mapping, _ = relative_date_parse_with_delta_mapping(value, timezone_info or ZoneInfo("UTC"))
+ """Parse a caller-supplied date bound: ISO 8601, `now`, or relative (`-7d`), naive values in the
+ project's timezone. A date-only upper bound covers its whole day. Shared by the observation list and
+ search. Raises `ValueError` on text that is none of those, rather than treating it as now."""
+ timezone_info = timezone_info or ZoneInfo("UTC")
+ if value.strip().lower() == "now":
+ # `now` already carries a time of day, so it skips the end-of-range widening below.
+ return datetime.now(timezone_info)
+ parsed, delta_mapping, _ = relative_date_parse_with_delta_mapping(value, timezone_info)
# The relative branch hands back an empty mapping when nothing in the text matched a period.
if delta_mapping == {}:
- raise ValueError(f"Unrecognized date: {value!r}. Use ISO 8601 or a relative date like -7d.")
+ raise ValueError(f"Unrecognized date: {value!r}. Use ISO 8601, a relative date like -7d, or 'now'.")
if end_of_range and not value.startswith(("-", "+")) and "T" not in value and ":" not in value:
parsed = parsed.replace(hour=23, minute=59, second=59, microsecond=999999)
return parsed
diff --git a/products/replay_vision/backend/tests/test_api.py b/products/replay_vision/backend/tests/test_api.py
index f3b1679e31bf..8b5c1a95e057 100644
--- a/products/replay_vision/backend/tests/test_api.py
+++ b/products/replay_vision/backend/tests/test_api.py
@@ -1445,6 +1445,11 @@ class TestReplayObservationViewSet(_VisionAPITestCase):
self.assertEqual(resp.status_code, 200, resp.json())
self.assertEqual([r["session_id"] for r in resp.json()["results"]], ["old"])
+ # `now` is an accepted upper bound, so a caller can bound a query at the current time.
+ resp = self.client.get(f"{self.observations_url(str(self.scanner.id))}?date_from=-7d&date_to=now")
+ self.assertEqual(resp.status_code, 200, resp.json())
+ self.assertEqual([r["session_id"] for r in resp.json()["results"]], ["recent"])
+
def test_list_date_range_bounds_use_project_timezone(self) -> None:
self.team.timezone = "US/Pacific"
self.team.save()
@@ -3244,6 +3249,12 @@ class TestObservationSearchAction(_VisionAPITestCase):
# A date-only upper bound covers its whole day, like the observation list filter.
self.assertEqual((filters.date_to.hour, filters.date_to.minute, filters.date_to.second), (23, 59, 59))
+ # `now` is an accepted upper bound here too, and reaches the filters as the current time.
+ before = timezone.now()
+ resp = self.client.get(f"{self.search_url}?q=anything&date_from=-7d&date_to=now")
+ self.assertEqual(resp.status_code, 200, resp.json())
+ self.assertGreaterEqual(mock_rank.call_args[0][5].date_to, before)
+
@patch("products.replay_vision.backend.search.rank_observations", return_value=[])
@patch("products.replay_vision.backend.search.generate_embedding")
def test_search_reuses_the_query_vector_for_a_repeated_query(self, mock_embed: MagicMock, _rank: MagicMock) -> None:
diff --git a/products/replay_vision/backend/tests/test_search.py b/products/replay_vision/backend/tests/test_search.py
index 21881195821b..2edb8bc4cfbd 100644
--- a/products/replay_vision/backend/tests/test_search.py
+++ b/products/replay_vision/backend/tests/test_search.py
@@ -1,8 +1,9 @@
import json
import uuid
-from datetime import timedelta
+from datetime import UTC, datetime, timedelta
import pytest
+from freezegun import freeze_time
from posthog.test.base import APIBaseTest, ClickhouseTestMixin
from unittest.mock import MagicMock, patch
@@ -59,6 +60,13 @@ class TestParseDateBound:
def test_date_only_upper_bound_covers_the_whole_day(self) -> None:
assert parse_date_bound("2026-09-01", None, end_of_range=True).hour == 23
+ @parameterized.expand([("lowercase", "now"), ("mixed_case", "Now"), ("padded", " now ")])
+ @freeze_time("2026-09-01T10:30:00Z")
+ def test_now_is_the_current_time_even_as_an_upper_bound(self, _name: str, value: str) -> None:
+ # `now` must not widen to end of day the way a date-only bound does, or an upper bound of
+ # `now` reaches into the future.
+ assert parse_date_bound(value, None, end_of_range=True) == datetime(2026, 9, 1, 10, 30, tzinfo=UTC)
+
@parameterized.expand([("prose", "last week"), ("empty", ""), ("noise", "banana")])
def test_rejects_text_that_would_otherwise_become_now(self, _name: str, value: str) -> None:
with pytest.raises(ValueError):
diff --git a/products/replay_vision/frontend/generated/api.schemas.ts b/products/replay_vision/frontend/generated/api.schemas.ts
index 6514279d0a9d..5fa67f100996 100644
--- a/products/replay_vision/frontend/generated/api.schemas.ts
+++ b/products/replay_vision/frontend/generated/api.schemas.ts
@@ -2330,11 +2330,11 @@ export type VisionObservationsRetrieveParams = {
*/
backfill_id?: string
/**
- * Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone.
+ * Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone.
*/
date_from?: string
/**
- * Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone.
+ * Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone.
*/
date_to?: string
/**
@@ -2381,12 +2381,12 @@ export type VisionObservationsRetrieveParams = {
export type VisionObservationsSearchRetrieveParams = {
/**
- * Only observations analyzed at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone.
+ * Only observations analyzed at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone.
* @minLength 1
*/
date_from?: string
/**
- * Only observations analyzed at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone.
+ * Only observations analyzed at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone.
* @minLength 1
*/
date_to?: string
@@ -2518,11 +2518,11 @@ export type VisionScannersObservationsListParams = {
*/
backfill_id?: string
/**
- * Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone.
+ * Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone.
*/
date_from?: string
/**
- * Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone.
+ * Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone.
*/
date_to?: string
/**
@@ -2581,11 +2581,11 @@ export type VisionScannersObservationsRetrieveParams = {
*/
backfill_id?: string
/**
- * Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone.
+ * Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone.
*/
date_from?: string
/**
- * Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone.
+ * Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone.
*/
date_to?: string
/**
@@ -2636,11 +2636,11 @@ export type VisionScannersObservationsStatsRetrieveParams = {
*/
backfill_id?: string
/**
- * Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone.
+ * Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone.
*/
date_from?: string
/**
- * Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone.
+ * Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone.
*/
date_to?: string
/**
diff --git a/products/replay_vision/mcp/tools.yaml b/products/replay_vision/mcp/tools.yaml
index e7279ad57ab1..31803dc0e6e8 100644
--- a/products/replay_vision/mcp/tools.yaml
+++ b/products/replay_vision/mcp/tools.yaml
@@ -166,9 +166,9 @@ tools:
the query. Scope with `scanner_id` to search one scanner, otherwise every scanner the caller can read is
searched. Narrow by exact outcome with `verdict` (comma-separated, e.g. `yes,inconclusive`), `tags`
(comma-separated classifier tags), and `min_score`/`max_score` (scorer bounds), or by time with
- `date_from`/`date_to` (ISO 8601 or relative like `-7d`). These filter, while `q` ranks. `limit` defaults to
- 20 (max 50). Use `vision-observations-retrieve` for a result's full detail, or `vision-observations-list`
- for everything observed about one session.
+ `date_from`/`date_to` (ISO 8601, relative like `-7d`, or `now`). These filter, while `q` ranks. `limit`
+ defaults to 20 (max 50). Use `vision-observations-retrieve` for a result's full detail, or
+ `vision-observations-list` for everything observed about one session.
requires_ai_consent: true
vision-observations-search-suggestions-retrieve:
operation: vision_observations_search_suggestions_retrieve
diff --git a/products/replay_vision/skills/exploring-replay-vision-observations/SKILL.md b/products/replay_vision/skills/exploring-replay-vision-observations/SKILL.md
index 036d98030954..ec514b1cd4aa 100644
--- a/products/replay_vision/skills/exploring-replay-vision-observations/SKILL.md
+++ b/products/replay_vision/skills/exploring-replay-vision-observations/SKILL.md
@@ -51,9 +51,11 @@ know it's a monitor; a score only means something against the scorer's `scale`).
Pick the axis that matches the question:
- **What has this scanner found, over time?** → `vision-scanners-observations-list` (the workhorse). Filter to
- `status=succeeded` to get only sessions with a finding, then narrow by `verdict` (monitors) or `tags`
- (classifiers). Scorers aren't filtered by score — rank them with `order_by=-result_score` instead. Use
- `order_by` (e.g. `-result_score`, `-completed_at`) to surface the strongest hits first.
+ `status=succeeded` to get only sessions with a finding, then narrow by `verdict` (monitors), `tags`
+ (classifiers), or `min_score` / `max_score` (scorers). Use `order_by` (e.g. `-result_score`,
+ `-completed_at`) to rank the matching set and surface the strongest hits first. Bound the window with
+ `date_from` / `date_to`, which take ISO 8601, a relative date like `-7d`, or `now`; omit `date_to` to
+ read through the current time.
- **What did every scanner find about one session?** → `vision-observations-list` (the `session_id` query
parameter is REQUIRED). Use this while investigating a single recording.
- **The distribution, not the rows?** → `vision-scanners-observations-stats` gives one scanner's status mix
diff --git a/services/mcp/schema/generated-tool-definitions.json b/services/mcp/schema/generated-tool-definitions.json
index a4ee76f86dfb..189aa152fddc 100644
--- a/services/mcp/schema/generated-tool-definitions.json
+++ b/services/mcp/schema/generated-tool-definitions.json
@@ -11584,7 +11584,7 @@
}
},
"vision-observations-search": {
- "description": "Search replay vision observations by meaning, not keywords: `q` is a natural-language description of what to find (e.g. \"users confused by the pricing page\") and results come back under `results`, most relevant first. Each result pairs the `observation` with its `distance` to the query (lower is closer, only comparable within one response) and `matched_content`, the observation's text that matched (may be empty for old rows). Observations too far from the query are not returned at all, so an off-topic search yields no results rather than the nearest unrelated ones. The search ranks each observation's LLM output (a summarizer's title and summary, other scanners' reasoning) by semantic similarity, so it finds sessions described differently from the query. Scope with `scanner_id` to search one scanner, otherwise every scanner the caller can read is searched. Narrow by exact outcome with `verdict` (comma-separated, e.g. `yes,inconclusive`), `tags` (comma-separated classifier tags), and `min_score`/`max_score` (scorer bounds), or by time with `date_from`/`date_to` (ISO 8601 or relative like `-7d`). These filter, while `q` ranks. `limit` defaults to 20 (max 50). Use `vision-observations-retrieve` for a result's full detail, or `vision-observations-list` for everything observed about one session.",
+ "description": "Search replay vision observations by meaning, not keywords: `q` is a natural-language description of what to find (e.g. \"users confused by the pricing page\") and results come back under `results`, most relevant first. Each result pairs the `observation` with its `distance` to the query (lower is closer, only comparable within one response) and `matched_content`, the observation's text that matched (may be empty for old rows). Observations too far from the query are not returned at all, so an off-topic search yields no results rather than the nearest unrelated ones. The search ranks each observation's LLM output (a summarizer's title and summary, other scanners' reasoning) by semantic similarity, so it finds sessions described differently from the query. Scope with `scanner_id` to search one scanner, otherwise every scanner the caller can read is searched. Narrow by exact outcome with `verdict` (comma-separated, e.g. `yes,inconclusive`), `tags` (comma-separated classifier tags), and `min_score`/`max_score` (scorer bounds), or by time with `date_from`/`date_to` (ISO 8601, relative like `-7d`, or `now`). These filter, while `q` ranks. `limit` defaults to 20 (max 50). Use `vision-observations-retrieve` for a result's full detail, or `vision-observations-list` for everything observed about one session.",
"category": "Replay vision",
"feature": "replay_vision",
"summary": "Semantically search replay vision observations",
diff --git a/services/mcp/schema/tool-definitions-all.json b/services/mcp/schema/tool-definitions-all.json
index 7cc31dce26af..074af8570ab0 100644
--- a/services/mcp/schema/tool-definitions-all.json
+++ b/services/mcp/schema/tool-definitions-all.json
@@ -12229,7 +12229,7 @@
}
},
"vision-observations-search": {
- "description": "Search replay vision observations by meaning, not keywords: `q` is a natural-language description of what to find (e.g. \"users confused by the pricing page\") and results come back under `results`, most relevant first. Each result pairs the `observation` with its `distance` to the query (lower is closer, only comparable within one response) and `matched_content`, the observation's text that matched (may be empty for old rows). Observations too far from the query are not returned at all, so an off-topic search yields no results rather than the nearest unrelated ones. The search ranks each observation's LLM output (a summarizer's title and summary, other scanners' reasoning) by semantic similarity, so it finds sessions described differently from the query. Scope with `scanner_id` to search one scanner, otherwise every scanner the caller can read is searched. Narrow by exact outcome with `verdict` (comma-separated, e.g. `yes,inconclusive`), `tags` (comma-separated classifier tags), and `min_score`/`max_score` (scorer bounds), or by time with `date_from`/`date_to` (ISO 8601 or relative like `-7d`). These filter, while `q` ranks. `limit` defaults to 20 (max 50). Use `vision-observations-retrieve` for a result's full detail, or `vision-observations-list` for everything observed about one session.",
+ "description": "Search replay vision observations by meaning, not keywords: `q` is a natural-language description of what to find (e.g. \"users confused by the pricing page\") and results come back under `results`, most relevant first. Each result pairs the `observation` with its `distance` to the query (lower is closer, only comparable within one response) and `matched_content`, the observation's text that matched (may be empty for old rows). Observations too far from the query are not returned at all, so an off-topic search yields no results rather than the nearest unrelated ones. The search ranks each observation's LLM output (a summarizer's title and summary, other scanners' reasoning) by semantic similarity, so it finds sessions described differently from the query. Scope with `scanner_id` to search one scanner, otherwise every scanner the caller can read is searched. Narrow by exact outcome with `verdict` (comma-separated, e.g. `yes,inconclusive`), `tags` (comma-separated classifier tags), and `min_score`/`max_score` (scorer bounds), or by time with `date_from`/`date_to` (ISO 8601, relative like `-7d`, or `now`). These filter, while `q` ranks. `limit` defaults to 20 (max 50). Use `vision-observations-retrieve` for a result's full detail, or `vision-observations-list` for everything observed about one session.",
"category": "Replay vision",
"feature": "replay_vision",
"summary": "Semantically search replay vision observations",
diff --git a/services/mcp/src/api/generated.ts b/services/mcp/src/api/generated.ts
index 4a9f912843e4..2c1d800bc975 100644
--- a/services/mcp/src/api/generated.ts
+++ b/services/mcp/src/api/generated.ts
@@ -102017,11 +102017,11 @@ export namespace Schemas {
*/
backfill_id?: string;
/**
- * Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone.
+ * Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone.
*/
date_from?: string;
/**
- * Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone.
+ * Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone.
*/
date_to?: string;
/**
@@ -102068,12 +102068,12 @@ export namespace Schemas {
export type VisionObservationsSearchRetrieveParams = {
/**
- * Only observations analyzed at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone.
+ * Only observations analyzed at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone.
* @minLength 1
*/
date_from?: string;
/**
- * Only observations analyzed at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone.
+ * Only observations analyzed at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone.
* @minLength 1
*/
date_to?: string;
@@ -102205,11 +102205,11 @@ export namespace Schemas {
*/
backfill_id?: string;
/**
- * Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone.
+ * Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone.
*/
date_from?: string;
/**
- * Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone.
+ * Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone.
*/
date_to?: string;
/**
@@ -102268,11 +102268,11 @@ export namespace Schemas {
*/
backfill_id?: string;
/**
- * Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone.
+ * Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone.
*/
date_from?: string;
/**
- * Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone.
+ * Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone.
*/
date_to?: string;
/**
@@ -102323,11 +102323,11 @@ export namespace Schemas {
*/
backfill_id?: string;
/**
- * Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone.
+ * Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone.
*/
date_from?: string;
/**
- * Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone.
+ * Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone.
*/
date_to?: string;
/**
diff --git a/services/mcp/src/generated/replay_vision/api.ts b/services/mcp/src/generated/replay_vision/api.ts
index cad90af92021..78b30ad916a5 100644
--- a/services/mcp/src/generated/replay_vision/api.ts
+++ b/services/mcp/src/generated/replay_vision/api.ts
@@ -50,13 +50,13 @@ export const VisionObservationsRetrieveQueryParams = () => zod.object({
.string()
.optional()
.describe(
- "Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone."
+ "Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone."
),
date_to: zod
.string()
.optional()
.describe(
- "Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone."
+ "Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone."
),
labeled: zod
.string()
@@ -172,14 +172,14 @@ export const VisionObservationsSearchRetrieveQueryParams = () => zod.object({
.min(1)
.optional()
.describe(
- "Only observations analyzed at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone."
+ "Only observations analyzed at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone."
),
date_to: zod
.string()
.min(1)
.optional()
.describe(
- "Only observations analyzed at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone."
+ "Only observations analyzed at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone."
),
limit: zod
.number()
@@ -712,13 +712,13 @@ export const VisionScannersObservationsListQueryParams = () => zod.object({
.string()
.optional()
.describe(
- "Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone."
+ "Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone."
),
date_to: zod
.string()
.optional()
.describe(
- "Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone."
+ "Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone."
),
labeled: zod
.boolean()
@@ -792,13 +792,13 @@ export const VisionScannersObservationsRetrieveQueryParams = () => zod.object({
.string()
.optional()
.describe(
- "Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone."
+ "Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone."
),
date_to: zod
.string()
.optional()
.describe(
- "Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone."
+ "Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone."
),
labeled: zod
.string()
@@ -869,13 +869,13 @@ export const VisionScannersObservationsStatsRetrieveQueryParams = () => zod.obje
.string()
.optional()
.describe(
- "Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone."
+ "Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone."
),
date_to: zod
.string()
.optional()
.describe(
- "Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone."
+ "Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone."
),
labeled: zod
.string()
diff --git a/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-observations-retrieve.json b/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-observations-retrieve.json
index 9dd496a5543d..80590cdef76a 100644
--- a/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-observations-retrieve.json
+++ b/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-observations-retrieve.json
@@ -6,11 +6,11 @@
"type": "string"
},
"date_from": {
- "description": "Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone.",
+ "description": "Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone.",
"type": "string"
},
"date_to": {
- "description": "Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone.",
+ "description": "Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone.",
"type": "string"
},
"id": {
diff --git a/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-observations-search.json b/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-observations-search.json
index 533519c4fe3e..94f241cbb7f5 100644
--- a/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-observations-search.json
+++ b/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-observations-search.json
@@ -2,12 +2,12 @@
"$schema": "https://json-schema.org/draft/2020-12/schema",
"properties": {
"date_from": {
- "description": "Only observations analyzed at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone.",
+ "description": "Only observations analyzed at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone.",
"minLength": 1,
"type": "string"
},
"date_to": {
- "description": "Only observations analyzed at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone.",
+ "description": "Only observations analyzed at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone.",
"minLength": 1,
"type": "string"
},
diff --git a/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-scanners-observations-get.json b/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-scanners-observations-get.json
index dc88a66fe2b8..03d70e6af99d 100644
--- a/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-scanners-observations-get.json
+++ b/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-scanners-observations-get.json
@@ -6,11 +6,11 @@
"type": "string"
},
"date_from": {
- "description": "Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone.",
+ "description": "Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone.",
"type": "string"
},
"date_to": {
- "description": "Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone.",
+ "description": "Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone.",
"type": "string"
},
"id": {
diff --git a/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-scanners-observations-list.json b/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-scanners-observations-list.json
index 78c86de5b216..6c50db9f30fe 100644
--- a/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-scanners-observations-list.json
+++ b/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-scanners-observations-list.json
@@ -6,11 +6,11 @@
"type": "string"
},
"date_from": {
- "description": "Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone.",
+ "description": "Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone.",
"type": "string"
},
"date_to": {
- "description": "Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone.",
+ "description": "Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone.",
"type": "string"
},
"labeled": {
diff --git a/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-scanners-observations-stats.json b/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-scanners-observations-stats.json
index 90bce0d3a430..e781b125ad6a 100644
--- a/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-scanners-observations-stats.json
+++ b/services/mcp/tests/unit/__snapshots__/tool-schemas/vision-scanners-observations-stats.json
@@ -6,11 +6,11 @@
"type": "string"
},
"date_from": {
- "description": "Only observations created at or after this time. Accepts ISO 8601 or a relative date like `-7d`; values without an explicit offset are interpreted in the project's timezone.",
+ "description": "Only observations created at or after this time. Accepts ISO 8601, a relative date like `-7d`, or `now`; values without an explicit offset are interpreted in the project's timezone.",
"type": "string"
},
"date_to": {
- "description": "Only observations created at or before this time. Accepts ISO 8601 or a relative date like `-1d`; date-only values include the whole day, interpreted in the project's timezone.",
+ "description": "Only observations created at or before this time. Accepts ISO 8601, a relative date like `-1d`, or `now` for the current time; omit it to query through the current time. Date-only values include the whole day, interpreted in the project's timezone.",
"type": "string"
},
"labeled": {