From 502bbf474abcc9be1d952ae902d31b0fe80d608a Mon Sep 17 00:00:00 2001 From: Hayden Hung Hoang Date: Sun, 15 Nov 2026 21:40:17 +0700 Subject: [PATCH 1/5] feat(openapi): add curation diversity and rule matching options from v30.2 CurationRule gains synonyms, stem and stemming_dictionary, which change how a search query is matched against the rule. Curation items gain diversity, which re-ranks the top hits of matching queries by similarity. Both schemas are shared, so this covers PUT /curation_sets/{curationSetName} and its items route. --- openapi.yml | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/openapi.yml b/openapi.yml index bc78960..91c0cdf 100644 --- a/openapi.yml +++ b/openapi.yml @@ -4632,6 +4632,33 @@ components: id: type: string description: ID of the curation item + diversity: + type: object + description: > + Diversifies the top hits of search queries that match the curation rule, by penalising hits + similar to those ranked above them. An empty object turns diversification off. + The search param `diversity_lambda` tunes it. + properties: + similarity_metric: + type: array + minItems: 1 + description: The measures that are combined to score how similar two hits are. + items: + type: object + required: + - field + - method + properties: + field: + type: string + description: The field to compare. + method: + type: string + enum: [equality, jaccard, vector_distance] + description: How the field's values are compared (case-insensitive). + weight: + type: number + description: "Weight of this measure in the combined similarity. Default: 1." CurationItemSchema: @@ -4691,6 +4718,18 @@ components: type: string description: > Indicates that the curation should apply when the filter_by parameter in a search query exactly matches the string specified here (including backticks, spaces, brackets, etc). + synonyms: + type: boolean + description: > + Also match search queries that match `query` through synonyms. Default: false. + stem: + type: boolean + description: > + Stem both the rule's `query` and the search query before matching them. Default: false. + stemming_dictionary: + type: string + description: > + Name of the stemming dictionary to stem with. Only used when `stem` is true. CurationInclude: type: object From 97a7360e8702abfe6cdf65dbf24aefa60ced388b Mon Sep 17 00:00:00 2001 From: Hayden Hung Hoang Date: Sun, 15 Nov 2026 21:40:36 +0700 Subject: [PATCH 2/5] feat(openapi): add autodelete to API keys POST /keys reads autodelete in v30.2. The housekeeper deletes expired keys that have it set. --- openapi.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/openapi.yml b/openapi.yml index 91c0cdf..544e432 100644 --- a/openapi.yml +++ b/openapi.yml @@ -3006,6 +3006,11 @@ components: expires_at: type: integer format: int64 + autodelete: + type: boolean + description: > + Delete the key once it has expired, instead of keeping it. Expired keys are purged hourly. + Default: false. ApiKey: allOf: - $ref: "#/components/schemas/ApiKeySchema" From 85c76cb4c7e9bbdd406963ff30e825133702d089 Mon Sep 17 00:00:00 2001 From: Hayden Hung Hoang Date: Sun, 15 Nov 2026 21:40:58 +0700 Subject: [PATCH 3/5] feat(openapi): add url and service_account to NL search models v30.2 requires url for Azure models and accepts a GCP service account for Vertex AI models. NLSearchModelBase is shared, so this covers POST /nl_search_models and PUT /nl_search_models/{modelId}. --- openapi.yml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/openapi.yml b/openapi.yml index 544e432..5b7bafa 100644 --- a/openapi.yml +++ b/openapi.yml @@ -4413,6 +4413,9 @@ components: api_url: type: string description: Custom API URL for the NL model service + url: + type: string + description: Endpoint URL of the Azure OpenAI deployment. Required for `azure/` models. max_bytes: type: integer description: Maximum number of bytes to process @@ -4451,6 +4454,22 @@ components: client_secret: type: string description: Client secret for GCP Vertex AI + service_account: + type: object + description: > + GCP service account credentials for Vertex AI, used instead of `access_token`, + `refresh_token`, `client_id` and `client_secret`. + required: + - client_email + - private_key + properties: + client_email: + type: string + private_key: + type: string + token_uri: + type: string + description: "Default: `https://oauth2.googleapis.com/token`." region: type: string description: Region for GCP Vertex AI From 2ba7035b9792f4d2dd3ea5ed1aa0ecc56b8c8246 Mon Sep 17 00:00:00 2001 From: Hayden Hung Hoang Date: Mon, 23 Nov 2026 19:19:15 +0700 Subject: [PATCH 4/5] feat(openapi): add conversation model options read by v30.2 ConversationModelUpdateSchema gains openai_url and openai_path for OpenAI-compatible services and url for Azure models. The create schema extends it, so this covers POST /conversations/models and PUT /conversations/models/{modelId}. --- openapi.yml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/openapi.yml b/openapi.yml index 5b7bafa..0708bf9 100644 --- a/openapi.yml +++ b/openapi.yml @@ -4364,6 +4364,15 @@ components: vllm_url: description: URL of vLLM service type: string + openai_url: + description: "Base URL of an OpenAI-compatible service, for `openai/` models. Default: `https://api.openai.com`." + type: string + openai_path: + description: "Path of the chat completions endpoint under `openai_url`. Default: `/v1/chat/completions`." + type: string + url: + description: Endpoint URL of the Azure OpenAI deployment. Required for `azure/` models. + type: string ConversationModelSchema: allOf: - $ref: '#/components/schemas/ConversationModelCreateSchema' From 85e711d566b99b7b45a209cdbd373c77b2d4f21b Mon Sep 17 00:00:00 2001 From: Hayden Hung Hoang Date: Sun, 15 Nov 2026 21:42:22 +0700 Subject: [PATCH 5/5] feat(openapi): allow creating an analytics rule through its upsert PUT /analytics/rules/{ruleName} creates the rule when none has that name, and v30.2 then requires type, collection and event_type. On an existing rule they must match its current values. --- openapi.yml | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/openapi.yml b/openapi.yml index 0708bf9..fd90989 100644 --- a/openapi.yml +++ b/openapi.yml @@ -4132,10 +4132,20 @@ components: enum: [popular_queries, nohits_queries, counter, log] AnalyticsRuleUpdate: type: object - description: Fields allowed to update on an analytics rule + description: > + Fields allowed to update on an analytics rule. When no rule has this name, the rule is + created, and `type`, `collection` and `event_type` are required. properties: name: type: string + type: + $ref: "#/components/schemas/AnalyticsRuleType" + collection: + type: string + description: Required when creating the rule. Can't be changed on an existing rule. + event_type: + type: string + description: Required when creating the rule. Can't be changed on an existing rule. rule_tag: type: string params: