Skip to content

feat: add TaskToolCall component, structured entries for TodoWrite#42

Open
BingqingLyu wants to merge 2 commits into
mainfrom
pr-1711-mingholy-feat-slash-command-share-followup
Open

feat: add TaskToolCall component, structured entries for TodoWrite#42
BingqingLyu wants to merge 2 commits into
mainfrom
pr-1711-mingholy-feat-slash-command-share-followup

Conversation

@BingqingLyu

@BingqingLyu BingqingLyu commented Apr 27, 2026

Copy link
Copy Markdown
Owner

TLDR

Introduces a new TaskToolCall UI component for displaying subagent execution with runtime and replay modes. Refactors UpdatedPlanToolCall to use structured entries data instead of markdown parsing.

Dive Deeper

TaskToolCall Component

  • Displays subagent/task tool execution in the chat interface
  • Runtime mode: expandable view showing nested tool calls, execution stats (rounds, duration, tokens), and progress
  • Replay mode: compact summary view with execution statistics only
  • Auto-detects mode based on presence of nested tool call data
  • Shows subagent name, task description, execution status, and success rate
  • Note: This component works around a limitation where ACP does not have a native task kind tool. Subagent execution is mapped to the task kind on the client side for display purposes.

UpdatedPlanToolCall Refactor

  • Changed from parsing markdown checklists (- [x]) to consuming structured entries data
  • collect.ts now passes structured entries with type: 'entries' directly to the component
  • Maintains backward compatibility with text parsing as fallback
  • Improves data reliability and removes dependency on markdown formatting

Schema Updates

  • Added entries type to toolCallContentSchema with array of {content, status} objects
  • Added optional name field to session update schemas for tool call identification

Reviewer Test Plan

  1. Test Task Tool Call Display:

    • Use @code-analyzer or @general-purpose subagent in a conversation
    • Verify the task card displays subagent name and description
    • Click "Show details" to expand and see nested tool calls
    • Verify execution stats (rounds, duration, tokens) are displayed
  2. Test TodoWrite Display:

    • Use the todo_write tool to create/update a plan
    • Verify plan entries render correctly with status indicators
    • Check that completed, in-progress, and pending states display properly
  3. Run Component Tests:

    npm run storybook
    # Navigate to ToolCalls/TaskToolCall and ToolCalls/UpdatedPlanToolCall stories
  4. Build Verification:

    npm run build

Testing Matrix

🍏 🪟 🐧
npm run
npx
Docker
Podman - -
Seatbelt - -

Linked issues / bugs

Mingholy and others added 2 commits February 9, 2026 17:06
… text

- Update collect.ts to pass structured entries directly instead of converting to markdown
- Update UpdatedPlanToolCall to consume structured entries with text parsing fallback
- Add 'entries' type to ToolCallContent schema and types
- Update stories to use new structured data format
- Fix PermissionDrawer story import issue

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
@BingqingLyu BingqingLyu added conflicting-group-1 Conflicting PR group 1 — review as a batch conflicting-pr Shares at least one cross-PR dependency with other PRs and removed conflicting-pr labels May 7, 2026
@BingqingLyu

BingqingLyu commented May 7, 2026

Copy link
Copy Markdown
Owner Author

Conflict Group 1

This PR shares modified functions with 5 other PR(s): #112, #113, #114, #117, #88.

These PRs should be reviewed as a batch — merging one may affect the others.

Function File Also modified by
getToolCallComponent ChatViewer.tsx #112, #113, #114, #117, #88
graph LR
    PR42["PR #42"]
    FgetToolCallComponent_7344["getToolCallComponent<br>ChatViewer.tsx"]
    PR42 -->|modifies| FgetToolCallComponent_7344
    PR112["PR #112"]
    PR112 -->|modifies| FgetToolCallComponent_7344
    PR113["PR #113"]
    PR113 -->|modifies| FgetToolCallComponent_7344
    PR114["PR #114"]
    PR114 -->|modifies| FgetToolCallComponent_7344
    PR117["PR #117"]
    PR117 -->|modifies| FgetToolCallComponent_7344
    PR88["PR #88"]
    PR88 -->|modifies| FgetToolCallComponent_7344
Loading

Posted by codegraph-ai conflict detection.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

conflicting-group-1 Conflicting PR group 1 — review as a batch conflicting-pr Shares at least one cross-PR dependency with other PRs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants