Skip to content

Conversation

@michaelneale
Copy link
Collaborator

@michaelneale michaelneale commented Oct 17, 2025

Currently openai won't work due to:

Request failed: Invalid schema for function 'dynamic_task__create_task': In context=('properties', 'extensions', 'type', '0'), array schema items is not an object. (code: invalid_function_parameters, type: invalid_request_error) (status 400).

as that tool generates an invalid schema for openai, which started with: #5189

pub description: Option<String>,

#[serde(skip_serializing_if = "Option::is_none")]
#[schemars(with = "Option<Vec<serde_json::Map<String, Value>>>")]
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the right fix is to change the Values here to Map<String, Value>, not just in the schemars annotation but in the actual type

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

items: true is apparently a valid way in json schema to say anything goes, but openai doesn't like that. But also, it's not what we want (or at least not what the prior hand-rolled schema had). we want objects only, not other values

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unrelated to this issue, but how does this tool work if we are just putting plain objects in the schema? are we telling the model somewhere else what those parameters look like?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah, this is how this works! we should just insert the json schema derived from an actual Recipe definition in here @tlongwell-block @yingjiehe-xyz

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah I think we have hit this with openai before - things don't always adhere to what is technically allowed.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we can always fix things up in the provider formatter as we do for google, but here we just need to generate the correct schema, not use Value

@jamadeo jamadeo merged commit 7aae5ef into main Oct 17, 2025
11 checks passed
@jamadeo jamadeo deleted the micn/hotfix-openai-broken branch October 17, 2025 14:29
jamadeo added a commit that referenced this pull request Oct 17, 2025
anthonydmays pushed a commit to anthonydmays/goose that referenced this pull request Oct 17, 2025
zanesq added a commit that referenced this pull request Oct 17, 2025
* 'main' of github.com:block/goose: (22 commits)
  Rewrite extension management tools (#5057)
  fix: re-sync package-lock.json (#5235)
  docs: Hacktoberfest MCP youtube short entry to community-content.json (#5150)
  feat: add schedule button to recipe entries (#5217)
  Autocompact threshold UI cleanup (#5232)
  fix: correct schema for openai tools (#5229)
  Break compaction back into check_ and do_ compaction (#5212)
  fix: revert built app name to uppercase Goose (#5206)
  feat: add Code Documentation Generator recipe (#5121) (#5125)
  Revert "feat: enhance goose to search sessions for easy recall (#5177)" (#5209)
  Blog: Best Practices for Prompt Engineering with goose (#5204)
  force WAL sync after session create (#5202)
  Feat: goose Apify MCP integration docs (#5047)
  feat: enhance goose to search sessions for easy recall (#5177)
  Skip hidden & real format (#5194)
  docs: Hacktoberfest blog submission - Best Practices for Using Goose in Enterprise Environments by Anudhyan Datta. (#5184)
  docs: prompt injection detection (#5193)
  Fix mcp large response race condition (#5065)
  Compaction overhaul (#5186)
  fix: #3960 better approach to input schema for dynamic task params (#5189)
  ...
wpfleger96 added a commit to wpfleger96/goose that referenced this pull request Oct 17, 2025
* main:
  delete flaky pricing integration tests (block#5207)
  chore: upgrade most npm packages to latest (block#5185)
  Release/1.11.0 (block#5224)
  Rewrite extension management tools (block#5057)
  fix: re-sync package-lock.json (block#5235)
  docs: Hacktoberfest MCP youtube short entry to community-content.json (block#5150)
  feat: add schedule button to recipe entries (block#5217)
  Autocompact threshold UI cleanup (block#5232)
  fix: correct schema for openai tools (block#5229)
  Break compaction back into check_ and do_ compaction (block#5212)
  fix: revert built app name to uppercase Goose (block#5206)
  feat: add Code Documentation Generator recipe (block#5121) (block#5125)
michaelneale added a commit that referenced this pull request Oct 18, 2025
* main:
  Standardize Session Name Attribute (#5085)
  Docs: Include step-by-step model configuration instructions for first… (#5239)
  Delete message visibility filter (#5216)
  delete flaky pricing integration tests (#5207)
  chore: upgrade most npm packages to latest (#5185)
  Release/1.11.0 (#5224)
  Rewrite extension management tools (#5057)
  fix: re-sync package-lock.json (#5235)
  docs: Hacktoberfest MCP youtube short entry to community-content.json (#5150)
  feat: add schedule button to recipe entries (#5217)
  Autocompact threshold UI cleanup (#5232)
  fix: correct schema for openai tools (#5229)
tlongwell-block added a commit that referenced this pull request Oct 18, 2025
* origin/main: (66 commits)
  Revert "Rewrite extension management tools" (#5243)
  Standardize Session Name Attribute (#5085)
  Docs: Include step-by-step model configuration instructions for first… (#5239)
  Delete message visibility filter (#5216)
  delete flaky pricing integration tests (#5207)
  chore: upgrade most npm packages to latest (#5185)
  Release/1.11.0 (#5224)
  Rewrite extension management tools (#5057)
  fix: re-sync package-lock.json (#5235)
  docs: Hacktoberfest MCP youtube short entry to community-content.json (#5150)
  feat: add schedule button to recipe entries (#5217)
  Autocompact threshold UI cleanup (#5232)
  fix: correct schema for openai tools (#5229)
  Break compaction back into check_ and do_ compaction (#5212)
  fix: revert built app name to uppercase Goose (#5206)
  feat: add Code Documentation Generator recipe (#5121) (#5125)
  Revert "feat: enhance goose to search sessions for easy recall (#5177)" (#5209)
  Blog: Best Practices for Prompt Engineering with goose (#5204)
  force WAL sync after session create (#5202)
  Feat: goose Apify MCP integration docs (#5047)
  ...
lifeizhou-ap added a commit that referenced this pull request Oct 19, 2025
* main: (32 commits)
  turn off WAL (#5203)
  Skip subagents for gemini (#5257)
  Revert "Standardize Session Name Attribute" (#5250)
  improve provider request logging a bit (#5236)
  Fix OpenAI empty choices panic (#5248)
  Revert "Rewrite extension management tools" (#5243)
  Standardize Session Name Attribute (#5085)
  Docs: Include step-by-step model configuration instructions for first… (#5239)
  Delete message visibility filter (#5216)
  delete flaky pricing integration tests (#5207)
  chore: upgrade most npm packages to latest (#5185)
  Release/1.11.0 (#5224)
  Rewrite extension management tools (#5057)
  fix: re-sync package-lock.json (#5235)
  docs: Hacktoberfest MCP youtube short entry to community-content.json (#5150)
  feat: add schedule button to recipe entries (#5217)
  Autocompact threshold UI cleanup (#5232)
  fix: correct schema for openai tools (#5229)
  Break compaction back into check_ and do_ compaction (#5212)
  fix: revert built app name to uppercase Goose (#5206)
  ...
katzdave added a commit that referenced this pull request Oct 20, 2025
* 'main' of github.com:block/goose:
  Rewrite extension management tools (#5057)
  fix: re-sync package-lock.json (#5235)
  docs: Hacktoberfest MCP youtube short entry to community-content.json (#5150)
  feat: add schedule button to recipe entries (#5217)
  Autocompact threshold UI cleanup (#5232)
  fix: correct schema for openai tools (#5229)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants