Commit 103ca1a
committed
fix: set include_thoughts=False when thinking_budget is 0
When thinking_budget is set to 0 (disabling thinking), include_thoughts
was hardcoded to True, causing a 400 INVALID_ARGUMENT error from the
Vertex AI API. Now include_thoughts is set based on whether thinking
is actually enabled (thinking_budget != 0).
Closes deepset-ai/haystack#28451 parent 17711c9 commit 103ca1a
2 files changed
Lines changed: 8 additions & 1 deletion
File tree
- integrations/google_genai
- src/haystack_integrations/components/generators/google_genai/chat
- tests
Lines changed: 4 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
842 | 842 | | |
843 | 843 | | |
844 | 844 | | |
845 | | - | |
| 845 | + | |
| 846 | + | |
| 847 | + | |
| 848 | + | |
846 | 849 | | |
847 | 850 | | |
848 | 851 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1433 | 1433 | | |
1434 | 1434 | | |
1435 | 1435 | | |
| 1436 | + | |
1436 | 1437 | | |
1437 | 1438 | | |
1438 | 1439 | | |
1439 | 1440 | | |
1440 | 1441 | | |
1441 | 1442 | | |
1442 | 1443 | | |
| 1444 | + | |
1443 | 1445 | | |
1444 | 1446 | | |
1445 | 1447 | | |
1446 | 1448 | | |
1447 | 1449 | | |
| 1450 | + | |
1448 | 1451 | | |
1449 | 1452 | | |
1450 | 1453 | | |
1451 | 1454 | | |
1452 | 1455 | | |
| 1456 | + | |
1453 | 1457 | | |
1454 | 1458 | | |
1455 | 1459 | | |
| |||
0 commit comments