Commit f5cdf65
committed
fix: improve error messages for OpenAI-compatible providers
- Add specific guidance when OpenAI-compatible models fail to use tools
- Provide clearer instructions about XML tool format requirements
- Help users understand common issues with tool usage formatting
- Add tests for the new error message variations
Fixes #72261 parent 0cf0ee8 commit f5cdf65
File tree
3 files changed
+59
-16
lines changed- src/core
- prompts
- __tests__
- task
3 files changed
+59
-16
lines changedLines changed: 16 additions & 11 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
32 | 37 | | |
33 | 38 | | |
34 | 39 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
24 | 43 | | |
25 | | - | |
| 44 | + | |
26 | 45 | | |
27 | 46 | | |
28 | 47 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1539 | 1539 | | |
1540 | 1540 | | |
1541 | 1541 | | |
1542 | | - | |
1543 | | - | |
| 1542 | + | |
| 1543 | + | |
| 1544 | + | |
| 1545 | + | |
| 1546 | + | |
| 1547 | + | |
| 1548 | + | |
| 1549 | + | |
| 1550 | + | |
| 1551 | + | |
| 1552 | + | |
| 1553 | + | |
| 1554 | + | |
| 1555 | + | |
| 1556 | + | |
| 1557 | + | |
| 1558 | + | |
| 1559 | + | |
| 1560 | + | |
| 1561 | + | |
| 1562 | + | |
1544 | 1563 | | |
1545 | 1564 | | |
1546 | 1565 | | |
1547 | 1566 | | |
1548 | 1567 | | |
1549 | | - | |
| 1568 | + | |
1550 | 1569 | | |
1551 | 1570 | | |
1552 | 1571 | | |
| |||
1557 | 1576 | | |
1558 | 1577 | | |
1559 | 1578 | | |
1560 | | - | |
| 1579 | + | |
1561 | 1580 | | |
1562 | 1581 | | |
1563 | 1582 | | |
| |||
0 commit comments