Skip to content

feat(llm): add ToolUse and ToolResult message parts #255

@bug-ops

Description

@bug-ops

Problem

MessagePart enum lacks variants for native tool use/result flow.

Solution

Add to MessagePart:

  • `ToolUse { id: String, name: String, input: serde_json::Value }`
  • `ToolResult { tool_use_id: String, content: String, is_error: bool }`

Wire through flatten_parts() for LLM content generation and SQLite persistence.

Acceptance Criteria

  • New MessagePart variants
  • Serialization/deserialization roundtrip
  • flatten_parts() handles new variants
  • SQLite persistence via existing parts JSON column

Part of #253 (M20)

Metadata

Metadata

Assignees

No one assigned

    Labels

    llmLLM provider related

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions