virnavi_ai_agent_compose 0.0.3 copy "virnavi_ai_agent_compose: ^0.0.3" to clipboard
virnavi_ai_agent_compose: ^0.0.3 copied to clipboard

Ties Flutter UI to MCP tool results. Widgets rebuild reactively when AI agents invoke tools — no setState needed.

0.0.3 #

New features #

  • Nested model propagationMcpComposeBinding now accepts an optional McpSummary. When provided, after every successful tool call the binding walks the result model's nestedExtractors and stores each nested model's JSON in McpResultStore under its own model ID. Recurses for arbitrarily deep nesting. This means @McpView widgets bound to nested models (e.g. Dimensions inside Product) react automatically without a separate tool call.

0.0.1 #

Initial release.

  • McpToolState — sealed state type: McpIdle, McpLoading, McpSuccess(data), McpError(message).
  • McpResultStoreChangeNotifier that holds per-tool state; updates reactively as AI agents invoke tools.
  • McpComposeBinding — wraps ToolDefinition handlers to drive McpResultStore through idle → loading → success | error transitions automatically.
  • McpResultBuilder — Flutter widget backed by ListenableBuilder that rebuilds whenever a specific tool's state changes.
  • McpViewDefinition — pairs a model ID with a Widget Function(Object?) builder; attached to McpSummary via McpSummaryViewsX extension.
  • McpSummaryViewsX extension on McpSummarybindViews(), views, buildView() using an Expando to avoid circular dependencies.
  • McpView annotation re-exported from virnavi_ai_agent_mcp — app code only needs to import compose.
  • List<ToolDefinition>.registerWith(bridge, binding) convenience extension.
0
likes
160
points
151
downloads

Documentation

API reference

Publisher

verified publishervirnavi.com

Weekly Downloads

Ties Flutter UI to MCP tool results. Widgets rebuild reactively when AI agents invoke tools — no setState needed.

Repository (GitHub)
View/report issues

Topics

#mcp #ai #agent #flutter #reactive

License

MIT (license)

Dependencies

flutter, virnavi_ai_agent_mcp

More

Packages that depend on virnavi_ai_agent_compose