Skip to content

Conversation

@stalkermustang
Copy link

@stalkermustang stalkermustang commented Oct 9, 2025

Description

(I'm sorry I'm putting two changes into one PR, but I just noticed one while working on another...)

  1. build_schema_only_tool added to allow for tools in StatefulToolEnv that have non-Pydanticable args (+ tests). Previously, if one had to skip non-pydantic tool args they'd got an error, because we first convert then filter args.
  2. ToolEnv now has disallow_non_tool_responses argument (True by default to keep the behaviour the same), and assert on the type of response message is thus optional. Meaning, the model can respond with text and not only tool calls (which is a common case I met during work on PaperBench and DABStep envs).

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Test improvement

Testing

  • All existing tests pass when running uv run pytest locally.
  • New tests have been added to cover the changes

Checklist

  • My code follows the style guidelines of this project as outlined in AGENTS.md
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • Any dependent changes have been merged and published

@CLAassistant
Copy link

CLAassistant commented Oct 9, 2025

CLA assistant check
All committers have signed the CLA.

@stalkermustang
Copy link
Author

ToolEnv now has disallow_non_tool_responses argument (True by default to keep the behaviour the same), and assert on the type of response message is thus optional. Meaning, the model can respond with text and not only tool calls (which is a common case I met during working on PaperBench and DABStep envs).

To elaborate a little, I came up with this when I was analyzing the PaperBench code. The OpenAI folks added "nudge messages" to the model if it didn't invoke any tool calls and just yaps. This isn't always bad -> we might want to allow the model to do so by setting a flag.

See: https://github.com/openai/frontier-evals/blob/main/project/paperbench/paperbench/agents/aisi-basic-agent/_basic_agent_plus.py#L61 and https://github.com/openai/frontier-evals/blob/main/project/paperbench/paperbench/agents/aisi-basic-agent/_basic_agent_plus.py#L323

@willccbb
Copy link
Member

Ah nice! Think I understand, def a good feature -- will prob make a couple tweaks then can add

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.

3 participants