-
Notifications
You must be signed in to change notification settings - Fork 142
feat(handlers): add reasoning text to callback handler and related tests #109
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
awsarron
merged 3 commits into
strands-agents:main
from
josephgultekin:feat/issue98-show-reasoning-text
May 25, 2025
Merged
feat(handlers): add reasoning text to callback handler and related tests #109
awsarron
merged 3 commits into
strands-agents:main
from
josephgultekin:feat/issue98-show-reasoning-text
May 25, 2025
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
awsarron
requested changes
May 25, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @josephgultekin, the changes work great!
I added a couple of minor comments, then we'll get this merged.
auto-merge was automatically disabled
May 25, 2025 15:35
Head branch was pushed to by a user without write access
awsarron
approved these changes
May 25, 2025
Awesome, thanks @josephgultekin 🚀 We'll get this published in the next version release. |
awsarron
pushed a commit
to awsarron/sdk-python
that referenced
this pull request
May 26, 2025
…sts (strands-agents#109) * feat(handlers): add reasoning text to callback handler and related tests * feat(handlers): removed redundant comment in .gitignore file * feat(handlers): Updated reasoningText type as (Optional[str]
awsarron
added a commit
that referenced
this pull request
May 26, 2025
* models - openai - argument none (#97) * docs(readme): add open PRs badge + link to samples repo + change 'Docs' to 'Documentation' (#100) * docs(readme): add logo (#101) * docs(readme): add logo, title, badges, links to other repos, standardize headings (#102) * style(readme): use dark logo for clearer visibility when system is using light color scheme (#104) * fix(readme): use logo that changes color automatically depending on user's color preference scheme (#105) * feat(handlers): add reasoning text to callback handler and related tests (#109) * feat(handlers): add reasoning text to callback handler and related tests * feat(handlers): removed redundant comment in .gitignore file * feat(handlers): Updated reasoningText type as (Optional[str] * feat: Add dynamic system prompt override functionality (#108) * Modularizing Event Loop (#106) * fix(telemetry): fix agent span start and end when using Agent.stream_async() (#119) * feat: Update SlidingWindowConversationManager (#120) * v0.1.5 --------- Co-authored-by: Patrick Gray <pgrayy@amazon.com> Co-authored-by: Gokhan (Joe) Gultekin <joseph.gueltekin@gmail.com> Co-authored-by: Shubham Raut <shubhamrao12321@gmail.com> Co-authored-by: fede-dash <fede.kamelhar@doordash.com> Co-authored-by: Nick Clegg <nac542@gmail.com>
15 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Summary of Changes
Handler Implementation (callback_handler.py):
PrintingCallbackHandler
now checks for thereasoningText
argument and prints it if present.data
, handling completion, and tracking tool usage remains consistent with the updated tests.Unit Test Improvements for Callback Handler (test_callback_handler.py):
reasoningText
argument in thePrintingCallbackHandler
.reasoningText
is present (should print the text) and when it is absent (should not print reasoning text).reasoningText
anddata
are tested, verifying correct print calls and order..gitignore:
These changes improve test coverage and clarity for the callback handler’s handling of the
reasoningText
argument and related output logic.Related Issues
Issue #98
Documentation PR
N/A
Type of Change
[Choose one of the above types of changes]
Testing
Yes. Ran all following with no errors.
hatch fmt --linter
hatch fmt --formatter
hatch test --all
Checklist
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.