Skip to content

Add Chat#step single-iteration execution#698

Open
Gujiassh wants to merge 2 commits intocrmne:mainfrom
Gujiassh:feat/chat-step
Open

Add Chat#step single-iteration execution#698
Gujiassh wants to merge 2 commits intocrmne:mainfrom
Gujiassh:feat/chat-step

Conversation

@Gujiassh
Copy link

Summary

  • add Chat#step to run exactly one provider iteration plus any resulting tool execution without recursing through the full agent loop
  • refactor complete to delegate to step so existing behavior stays unchanged while Tool::Halt semantics are preserved
  • add focused chat tool regressions proving step executes one tool-calling turn and returns Tool::Halt immediately when a halting tool is invoked

Validation

  • bundle exec rspec spec/ruby_llm/chat_tools_spec.rb --example 'step executes a single tool-calling iteration without recursing' --example 'step returns Halt when a tool halts'
  • bundle exec rspec spec/ruby_llm/chat_tools_spec.rb
  • bundle exec rubocop lib/ruby_llm/chat.rb spec/ruby_llm/chat_tools_spec.rb

Gujiassh and others added 2 commits March 22, 2026 17:36
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
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.

1 participant