Commit 1372a57
authored
fix(provider,client): improve tool call merging and filtering (#1552)
- Refactor tool call merging logic to use id, index, or name as key,
ensuring more robust accumulation of streaming tool call deltas.
- Update tool call filtering to exclude entries without a name,
preventing incomplete tool calls from being returned.
- Remove fallback default values for id, index, and name in provider
output, ensuring only valid tool call data is included.
- Minor formatting adjustment in init.lua.
Signed-off-by: Tomas Slusny <slusnucky@gmail.com>1 parent 4f643c7 commit 1372a57
3 files changed
Lines changed: 28 additions & 16 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
445 | 445 | | |
446 | 446 | | |
447 | 447 | | |
448 | | - | |
449 | | - | |
450 | | - | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
451 | 452 | | |
452 | 453 | | |
453 | | - | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
454 | 464 | | |
455 | 465 | | |
456 | 466 | | |
| |||
597 | 607 | | |
598 | 608 | | |
599 | 609 | | |
| 610 | + | |
| 611 | + | |
| 612 | + | |
| 613 | + | |
| 614 | + | |
600 | 615 | | |
601 | 616 | | |
602 | 617 | | |
603 | 618 | | |
604 | 619 | | |
605 | | - | |
| 620 | + | |
606 | 621 | | |
607 | 622 | | |
608 | 623 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
397 | 397 | | |
398 | 398 | | |
399 | 399 | | |
400 | | - | |
401 | 400 | | |
402 | 401 | | |
403 | | - | |
404 | 402 | | |
405 | | - | |
406 | | - | |
407 | | - | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
408 | 406 | | |
409 | 407 | | |
410 | 408 | | |
| |||
436 | 434 | | |
437 | 435 | | |
438 | 436 | | |
439 | | - | |
| 437 | + | |
440 | 438 | | |
441 | | - | |
| 439 | + | |
442 | 440 | | |
443 | 441 | | |
444 | 442 | | |
| |||
481 | 479 | | |
482 | 480 | | |
483 | 481 | | |
484 | | - | |
485 | | - | |
486 | 482 | | |
487 | | - | |
488 | | - | |
| 483 | + | |
| 484 | + | |
489 | 485 | | |
490 | 486 | | |
491 | 487 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
546 | 546 | | |
547 | 547 | | |
548 | 548 | | |
| 549 | + | |
549 | 550 | | |
550 | 551 | | |
551 | 552 | | |
| |||
0 commit comments