Skip to content

fix(ai/gemini): coerce numeric/boolean enum values to strings - #104567

Merged
steipete merged 5 commits into
openclaw:mainfrom
leonme:fix/gemini-enum-string-coercion
Jul 11, 2026
Merged

steipete merged 5 commits into
openclaw:mainfrom
leonme:fix/gemini-enum-string-coercion

Conversation

@leonme

@leonme leonme commented Jul 11, 2026

Copy link
Copy Markdown
Contributor

What Problem This Solves

Fixes #104566.

Gemini's Function Calling API only accepts string values in enum fields (Function Calling docs, AIP-143). When a tool schema contains enum: [1, 2, 3] or enum: [true, false], the Gemini API rejects the entire request with:

Invalid value at 'tools[X].function_declarations[Y].parameters...enum[N]' (TYPE_STRING), 1

Current cleanSchemaForGemini strips unsupported keywords and rewrites const → enum: [value] but does not coerce enum values. Any Gemini sub-agent whose full tool set contains a numeric or boolean enum (very common — priority levels, score ranges, boolean flags) fails 100 % of the time.

Why This Change Was Made

Two entry points in cleanSchemaForGeminiWithDefs produce enum arrays:

  1. const: <value> — rewritten to enum: [<value>] at line 327.
  2. enum: [...] — currently passes through unchanged at the trailing cleaned[key] = value branch.

Both paths need to coerce values to strings, and the schema must be retyped as "string" since Gemini's validator only accepts enum on string-typed schemas.

What This Change Does

Adds two helpers (coerceEnumValue / coerceEnumArray) and a dedicated key === "enum" case in the cleaning loop:

  • number (finite) → String(v)
  • boolean → "true" / "false"
  • bigint → v.toString()
  • string → unchanged
  • null / undefined / objects / arrays / non-finite numbers → dropped from the array (also de-duplicates)
  • If the coerced array is empty, the enum key is omitted entirely (matches existing behavior for empty required arrays)

const is coerced through the same helper and now also retypes the containing schema to "string".

Behavior Compatibility

  • Already-string enums are unchanged (identity return on typeof v === "string").
  • Coerced-to-string enums remain semantically valid: consumers of the tool call receive "1" instead of 1, which JavaScript comparisons and JSON parsing round-trip trivially. Most OpenClaw tool receivers already normalize scalar inputs.
  • type is only rewritten when the enum coercion actually happens, so pure type: "integer" schemas without enums are untouched.
  • Non-coercible entries (objects, arrays, null) are silently dropped rather than throwing, matching the "clean, don't reject" contract of this module.

Evidence

Unit tests added in clean-for-gemini.test.ts cover:

  • Numeric enum → string enum + retyped as "string"
  • Boolean enum → ["true", "false"]
  • Pre-existing string enum unchanged (regression guard)
  • Numeric const → string enum + retyped
  • null / undefined dropped, duplicates removed
  • Deeply nested numeric enum (object.properties.array.items.properties.enum) — matches the real-world failure path from the issue
  • Empty-after-coercion → enum key omitted

Local test run:

$ pnpm --filter @openclaw/ai test clean-for-gemini
✓ coerces numeric enum values to strings and retypes as string
✓ coerces boolean enum values to strings
✓ preserves already-string enum values without retyping
✓ coerces a numeric const to a string enum and retypes as string
✓ drops null/undefined enum entries and de-duplicates
✓ coerces numeric enums inside deeply nested tool parameters
✓ returns no enum key when array becomes empty after coercion

Verified Downstream

Applied the equivalent patch to a local install by mirroring the change into node_modules/@openclaw/ai/dist/openai-responses-shared-*.mjs and re-ran a Gemini sub-agent invocation that had been 100 % failing:

  • Before: provider rejected the request schema or tool payload (400 TYPE_STRING at function_declarations[29].parameters...enum[0])
  • After: sub-agent completes normally on gemini-2.5-flash-lite via an OpenAI-compatible endpoint

Related Issues / Reports

  • User-visible symptom variant: any sub-agent workflow silently falling back to Claude Opus when configured for Gemini — because Gemini requests never succeeded past the schema gate. Users pay Opus rates believing they are on Gemini.

Gemini Function Calling only accepts string enum values (see
https://ai.google.dev/gemini-api/docs/function-calling). Tool schemas
containing enum: [1,2,3] or enum: [true,false] were passed through
unchanged, causing Gemini to reject the entire request with 400
TYPE_STRING errors at 'function_declarations[X].parameters...enum[N]'.

Extend cleanSchemaForGeminiWithDefs to coerce enum and const values
via a shared helper (number/boolean/bigint -> string, drop null and
non-coercible entries, de-duplicate), and retype the containing schema
as 'string' since Gemini's validator only accepts enum on string-typed
schemas.

Adds seven vitest cases covering numeric/boolean enum, const, nested
schemas, and dedup/empty-after-coercion edge cases.

Fixes openclaw#104566

Co-Authored-By: Claude <[email protected]>
@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. P1 High-priority user-facing bug, regression, or broken workflow. labels Jul 11, 2026
@clawsweeper

clawsweeper Bot commented Jul 11, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs real behavior proof before merge. Reviewed July 11, 2026, 7:31 PM ET / 23:31 UTC.

Summary
The PR stringifies finite numeric and boolean Gemini enum/const entries, removes unsupported entries, de-duplicates the result, preserves declared schema types, and adds focused regression coverage.

PR surface: Source +38, Tests +73. Total +111 across 2 files.

Reproducibility: yes. Current main deterministically leaves numeric and boolean enum entries unchanged, and the linked issue supplies the corresponding live Gemini TYPE_STRING rejection.

Review metrics: none identified.

Root-cause cluster
Relationship: fixed_by_candidate
Canonical: #104566
Summary: This PR is the direct candidate fix for the canonical Gemini enum schema rejection report.

Members:

Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything.

Merge readiness
Overall: 🦐 gold shrimp
Proof: 🦐 gold shrimp
Patch quality: 🦞 diamond lobster
Result: blocked until stronger real behavior proof is added.

Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch.

Rank-up moves:

  • Run the exact current head against Gemini with an integer or boolean enum and post redacted request/result evidence showing the tool call completes.
  • Update the PR body with that proof so ClawSweeper re-reviews it automatically; if it does not, ask a maintainer for @clawsweeper re-review.

Proof guidance:

  • [P1] Needs stronger real behavior proof before merge: The available live output proves the prior string-type implementation, but commit 80559325ca01cc94bd7d987d18d878716fa62b6b changed the observable provider schema to preserve primitive types; add a redacted exact-head live run, then update the PR body to trigger review or ask a maintainer to comment @clawsweeper re-review.

Risk before merge

  • [P1] The contributor’s live Gemini run demonstrated the earlier head that rewrote coerced schemas to type: string; the final head now preserves integer, number, or boolean, so the exact representation proposed for merge has not yet been demonstrated in a real request.

Maintainer options:

  1. Decide the mitigation before merge
    Keep the contract-aligned provider-boundary implementation and add one redacted live Gemini request using the exact current head, showing that an integer or boolean enum is accepted and the tool call completes with the expected runtime argument type.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Next step before merge

  • [P1] No code repair is needed; the contributor should supply exact-head real behavior proof before normal maintainer merge gating.

Security
Cleared: The focused provider-source and test changes introduce no dependency, workflow, permission, credential, downloaded-code, package-resolution, or supply-chain concern.

Review details

Best possible solution:

Keep the contract-aligned provider-boundary implementation and add one redacted live Gemini request using the exact current head, showing that an integer or boolean enum is accepted and the tool call completes with the expected runtime argument type.

Do we have a high-confidence way to reproduce the issue?

Yes. Current main deterministically leaves numeric and boolean enum entries unchanged, and the linked issue supplies the corresponding live Gemini TYPE_STRING rejection.

Is this the best way to solve the issue?

Yes. The final implementation is the narrowest maintainable fix: it changes only the existing Gemini-facing schema projection and matches Google’s documented primitive-enum encoding while preserving the declared type. citeturn1view0turn1view1.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against f0676a7a7951.

Label changes

Label changes:

  • add rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🦞 diamond lobster.
  • add status: 📣 needs proof: The PR needs real behavior proof before ClawSweeper can clear the contributor ask. Needs stronger real behavior proof before merge: The available live output proves the prior string-type implementation, but commit 80559325ca01cc94bd7d987d18d878716fa62b6b changed the observable provider schema to preserve primitive types; add a redacted exact-head live run, then update the PR body to trigger review or ask a maintainer to comment @clawsweeper re-review.
  • remove proof: sufficient: Current real behavior proof status is insufficient, not sufficient.
  • remove rating: 🐚 platinum hermit: Current PR rating is rating: 🦐 gold shrimp, so this older rating label is no longer current.
  • remove status: 👀 ready for maintainer look: Current PR status label is status: 📣 needs proof.

Label justifications:

  • P1: A numeric or boolean enum can make Gemini tool requests fail completely and trigger unintended fallback to another provider.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🦞 diamond lobster.
  • status: 📣 needs proof: The PR needs real behavior proof before ClawSweeper can clear the contributor ask. Needs stronger real behavior proof before merge: The available live output proves the prior string-type implementation, but commit 80559325ca01cc94bd7d987d18d878716fa62b6b changed the observable provider schema to preserve primitive types; add a redacted exact-head live run, then update the PR body to trigger review or ask a maintainer to comment @clawsweeper re-review.
Evidence reviewed

PR surface:

Source +38, Tests +73. Total +111 across 2 files.

View PR surface stats
Area Files Added Removed Net
Source 1 39 1 +38
Tests 1 73 0 +73
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 2 112 1 +111

What I checked:

  • Current-main reproduction: Current main rewrites const to an enum but otherwise copies enum arrays unchanged, so numeric and boolean entries remain non-string in the Gemini-facing declaration. (packages/ai/src/providers/clean-for-gemini.ts:327, f0676a7a7951)
  • Current-head implementation: The final head stringifies finite numbers and booleans, filters unsupported entries, de-duplicates the result, and deliberately preserves the original primitive schema type. (packages/ai/src/providers/clean-for-gemini.ts:49, 80559325ca01)
  • Regression coverage: The current tests cover integer, boolean, string, const, property-order, nested-schema, invalid-entry, de-duplication, and empty-result behavior while asserting that primitive types remain unchanged. (packages/ai/src/providers/clean-for-gemini.test.ts:228, 80559325ca01)
  • Provider projection boundary: OpenClaw applies this cleaner while projecting tool parameter schemas for Gemini-compatible providers, keeping the change at the existing provider boundary. (packages/ai/src/providers/agent-tools-parameter-schema.ts:835, f0676a7a7951)
  • Upstream contract: Google’s official function-calling documentation shows integer enums declared with type: integer while their enum entries are string-encoded, and instructs that non-string primitive enum values be supplied as strings. citeturn1view0turn1view1.
  • Re-review continuity: The first review’s property-order finding was fixed before the previous reviewed head; the newest commit instead changes the design from rewriting the schema type to preserving it, so the earlier finding does not recur. (packages/ai/src/providers/clean-for-gemini.ts:49, 80559325ca01)

Likely related people:

  • steipete: Authored the final current-head commit aligning the cleaner with Google’s preserved-type enum contract and is assigned to this PR. (role: recent area contributor; confidence: high; commits: 80559325ca01; files: packages/ai/src/providers/clean-for-gemini.ts, packages/ai/src/providers/clean-for-gemini.test.ts)
  • lin-hongkuan: Current-main blame and file history connect this contributor to the central Gemini cleaning loop and existing const-to-enum behavior being amended. (role: recent cleaner contributor; confidence: medium; commits: 522e253c5362; files: packages/ai/src/providers/clean-for-gemini.ts)
What the crustacean ranks mean
  • 🦀 challenger crab: rare, exceptional readiness with strong proof, clean implementation, and convincing validation.
  • 🦞 diamond lobster: very strong readiness with only minor maintainer review expected.
  • 🐚 platinum hermit: good normal PR, likely mergeable with ordinary maintainer review.
  • 🦐 gold shrimp: useful signal, but proof or patch confidence is still limited.
  • 🦪 silver shellfish: thin signal; proof, validation, or implementation needs work.
  • 🧂 unranked krab: not merge-ready because proof is missing/unusable or there are serious correctness or safety concerns.
  • 🌊 off-meta tidepool: rating does not apply to this item.

Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

How this review workflow works
  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.
Review history (2 earlier review cycles)
  • reviewed 2026-07-11T17:04:45.497Z sha 75a776d :: needs real behavior proof before merge. :: [P1] Make enum retyping independent of property order
  • reviewed 2026-07-11T17:39:00.418Z sha 51ba2a5 :: needs maintainer review before merge. :: none

leonme and others added 2 commits July 12, 2026 01:17
Address @clawsweeper review on openclaw#104567:

The initial patch set cleaned.type = 'string' inline while visiting the
'enum' or 'const' key. For schemas where 'type' appears AFTER 'enum' /
'const' in the input object — a valid ordering since JSON Schema property
order is not semantic — a later 'type' pass would overwrite the coercion
via the tail 'cleaned[key] = value' branch, and Gemini would still receive
an invalid declaration.

Move the type override out of the loop: track whether any enum/const was
coerced via a boolean flag, and force cleaned.type = 'string' after the
loop finishes. This makes the fix independent of input property order.

Also add curly braces around single-line ifs to satisfy check-lint
(eslint(curly)) which failed on the previous commit.

New reversed-order regression tests added.

Co-Authored-By: Claude <[email protected]>
@leonme

leonme commented Jul 11, 2026

Copy link
Copy Markdown
Contributor Author

Thanks for the review, @clawsweeper — both findings addressed in 70fcdfdc.

1. Property-order regression — fixed

The reviewer bot was right (0.99 confidence, and the failing case reproduces trivially). The initial patch set cleaned.type = "string" inline inside the enum / const case, but for a schema like { enum: [1,2,3], type: "integer" } the trailing generic cleaned[key] = value branch would then overwrite cleaned.type back to "integer" when it reached the type key.

Fix: track coercion with a let enumCoercedToString flag inside the loop, then set cleaned.type = "string" once, after the loop finishes — so the fix is independent of input property order.

Reversed-order regression tests added in clean-for-gemini.test.ts:

  • coerces numeric enum with enum-before-type ordering
  • coerces boolean enum with enum-before-type ordering
  • coerces numeric const with const-before-type ordering
  • leaves type untouched when no enum coercion happened (regression guard: pure { type: "integer" } without enum must stay integer)

2. Real behavior proof — before/after

I mirrored the same change into the shipped dist/openai-responses-shared-*.mjs on a live install (2026.7.1-beta.5) and ran the exact cases the review flagged.

Before (current main / released 6.11 / beta.5 without this patch)

cleanSchemaForGemini({ enum: [1, 2, 3], type: "integer" }):

{"type":"integer","enum":[1,2,3]}

→ Gemini rejects with:

Invalid value at 'tools[X].function_declarations[Y].parameters...enum[0]' (TYPE_STRING), 1
Invalid value at '...enum[1]' (TYPE_STRING), 2
Invalid value at '...enum[2]' (TYPE_STRING), 3

providerRuntimeFailureKind: schema / failoverReason: format. Sub-agent hard-fails and OpenClaw falls back to Claude.

After (this patch, both orderings, all coercible types)

$ node -e 'import { cleanSchemaForGemini } from "@openclaw/ai/internal/openai"; ...'

reversed enum ({ enum: [1,2,3], type: "integer" }):
  {"enum":["1","2","3"],"type":"string"}

reversed const ({ const: 42, type: "integer" }):
  {"enum":["42"],"type":"string"}

forward enum ({ type: "integer", enum: [1,2,3] }):
  {"type":"string","enum":["1","2","3"]}

pure integer ({ type: "integer", description: "count" }):
  {"type":"integer","description":"count"}         ← unchanged, no false retyping

Gemini 2.5-flash / 2.5-flash-lite sub-agent invocations that were 100% failing on the same install (webchat dashboard → sub-agent spawn with full tool set) now complete normally end-to-end. Tool arguments come back as strings and are converted back to number/integer/boolean by the existing tool-argument coercion layer at execution time (which the review correctly noted was already in place — the runtime scalar contract is preserved).

3. check-lint failure — fixed

The previous commit had single-line if (...) return ...; inside the two helpers, tripping eslint(curly). Added block braces in the same commit.

Requesting re-review:

@clawsweeper re-review

@clawsweeper clawsweeper Bot added proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. labels Jul 11, 2026
@steipete steipete self-assigned this Jul 11, 2026
@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. and removed proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Jul 11, 2026
@steipete
steipete merged commit 1338b0d into openclaw:main Jul 11, 2026
104 of 111 checks passed
@steipete

Copy link
Copy Markdown
Contributor

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Jul 12, 2026
…aw#104567)

* fix(ai/gemini): coerce numeric/boolean enum values to strings

Gemini Function Calling only accepts string enum values (see
https://ai.google.dev/gemini-api/docs/function-calling). Tool schemas
containing enum: [1,2,3] or enum: [true,false] were passed through
unchanged, causing Gemini to reject the entire request with 400
TYPE_STRING errors at 'function_declarations[X].parameters...enum[N]'.

Extend cleanSchemaForGeminiWithDefs to coerce enum and const values
via a shared helper (number/boolean/bigint -> string, drop null and
non-coercible entries, de-duplicate), and retype the containing schema
as 'string' since Gemini's validator only accepts enum on string-typed
schemas.

Adds seven vitest cases covering numeric/boolean enum, const, nested
schemas, and dedup/empty-after-coercion edge cases.

Fixes openclaw#104566

Co-Authored-By: Claude <[email protected]>

* fix(ai/gemini): make enum retyping property-order independent

Address @clawsweeper review on openclaw#104567:

The initial patch set cleaned.type = 'string' inline while visiting the
'enum' or 'const' key. For schemas where 'type' appears AFTER 'enum' /
'const' in the input object — a valid ordering since JSON Schema property
order is not semantic — a later 'type' pass would overwrite the coercion
via the tail 'cleaned[key] = value' branch, and Gemini would still receive
an invalid declaration.

Move the type override out of the loop: track whether any enum/const was
coerced via a boolean flag, and force cleaned.type = 'string' after the
loop finishes. This makes the fix independent of input property order.

Also add curly braces around single-line ifs to satisfy check-lint
(eslint(curly)) which failed on the previous commit.

New reversed-order regression tests added.

Co-Authored-By: Claude <[email protected]>

* fix(ai): preserve Gemini enum schema types

---------

Co-authored-by: leonme <[email protected]>
Co-authored-by: Claude <[email protected]>
Co-authored-by: Peter Steinberger <[email protected]>
teknium1 added a commit to NousResearch/hermes-agent that referenced this pull request Jul 27, 2026
Port from openclaw/openclaw#104567: Gemini requires enum metadata to be strings even when the declared tool parameter type is numeric or boolean.
randlee pushed a commit to randlee/hermes-agent that referenced this pull request Aug 11, 2026
Port from openclaw/openclaw#104567: Gemini requires enum metadata to be strings even when the declared tool parameter type is numeric or boolean.
prmartinow pushed a commit to prmartinow/hermes-agent that referenced this pull request Aug 26, 2026
Port from openclaw/openclaw#104567: Gemini requires enum metadata to be strings even when the declared tool parameter type is numeric or boolean.
melon-xf added a commit to melon-xf/hermes-agent that referenced this pull request Sep 3, 2026
Port from openclaw/openclaw#104567: Gemini requires enum metadata to be strings even when the declared tool parameter type is numeric or boolean.
obviyus added a commit that referenced this pull request Nov 10, 2026
fix(ai): drop non-string enums from Gemini tool schemas

The read tool declares optional as the boolean literal true. The Gemini schema cleaner turned that into {"type":"boolean","enum":["true"]}, but Google allows enum only on string types, so every Gemini and Vertex request carrying the read tool failed with HTTP 400 "enum: only allowed for STRING type". #104567 deliberately keeps the declared type so tool arguments still match local validation (#185581); changing the type to string would make Gemini send "true" and fail that check. The cleaner now keeps enums only when the declared type is string or missing, and drops the enum for other types while keeping the type. read.optional goes out as a plain boolean, and the original schema still accepts only true. Other providers' schemas are unchanged.

Evidence: a built Gateway on node:24.22.1 in secretless Docker with 14 tools including read, against a local stand-in that enforces Google's enum rule and returns the real 400 body, two runs each. On main the request failed with "...parameters.properties[optional].enum: only allowed for STRING type". With this change the request was accepted, and the stand-in's read call with optional true passed local validation and ran. The other 13 Gemini tool schemas, every string enum and the OpenAI-compatible request are byte-identical to main. Details: #196742.

Closes #196717. Thanks @yixiaoer-520 for the report.

Co-authored-by: Ayaan Zaidi <[email protected]>
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Nov 11, 2026
fix(ai): drop non-string enums from Gemini tool schemas

The read tool declares optional as the boolean literal true. The Gemini schema cleaner turned that into {"type":"boolean","enum":["true"]}, but Google allows enum only on string types, so every Gemini and Vertex request carrying the read tool failed with HTTP 400 "enum: only allowed for STRING type". openclaw#104567 deliberately keeps the declared type so tool arguments still match local validation (openclaw#185581); changing the type to string would make Gemini send "true" and fail that check. The cleaner now keeps enums only when the declared type is string or missing, and drops the enum for other types while keeping the type. read.optional goes out as a plain boolean, and the original schema still accepts only true. Other providers' schemas are unchanged.

Evidence: a built Gateway on node:24.22.1 in secretless Docker with 14 tools including read, against a local stand-in that enforces Google's enum rule and returns the real 400 body, two runs each. On main the request failed with "...parameters.properties[optional].enum: only allowed for STRING type". With this change the request was accepted, and the stand-in's read call with optional true passed local validation and ran. The other 13 Gemini tool schemas, every string enum and the OpenAI-compatible request are byte-identical to main. Details: openclaw#196742.

Closes openclaw#196717. Thanks @yixiaoer-520 for the report.

Co-authored-by: Ayaan Zaidi <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

P1 High-priority user-facing bug, regression, or broken workflow. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. size: S status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] toolSchemaProfile "gemini" does not coerce numeric/boolean enum values to strings

2 participants