diff options
| author | CaptainJack2491 <jayrupnakawala@gmail.com> | 2026-03-04 17:52:09 +0000 |
|---|---|---|
| committer | CaptainJack2491 <jayrupnakawala@gmail.com> | 2026-03-04 17:52:09 +0000 |
| commit | 08fe9e0943aac5806beecb4ad38e25378e866e05 (patch) | |
| tree | 3570d1ccbbd77eab2125fc6ed453afb519eda808 | |
| parent | 718b635a114a19a0a440fde5e9a1e608a3db05b8 (diff) | |
fix(agent): added reasoning extraction from groq models
| -rw-r--r-- | src/agent.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/agent.py b/src/agent.py index cfc77e7..77b0de4 100644 --- a/src/agent.py +++ b/src/agent.py @@ -153,7 +153,11 @@ class Agent: if hasattr(response_message, 'reasoning_content') and response_message.reasoning_content: reasoning = response_message.reasoning_content reasoning_format = "reasoning_content" - # 2. Check for reasoning_details (structured — OpenAI reasoning models) + # 2. Check for reasoning (Groq GPT-OSS models) + elif hasattr(response_message, 'reasoning') and response_message.reasoning: + reasoning = response_message.reasoning + reasoning_format = "reasoning" + # 3. Check for reasoning_details (structured — OpenAI reasoning models) elif hasattr(response_message, 'reasoning_details') and response_message.reasoning_details: reasoning_parts = [] for item in response_message.reasoning_details: |
