generating-flutter-ui

generating-flutter-ui is a skill for Claude Code, Codex from Poorgramer-Zack/dart-expert-skills. It costs 121 tokens per session (1,247 once invoked), scanned A, original, MIT.

A guide to building Flutter interfaces that an AI can create or change from its responses instead of using only fixed screens.

In plain words
What is it for?
Use it for AI-generated screens, chat-based interfaces, dynamic dashboards, conversational flows, and layouts returned by a server or language model.
Why use it?
It helps connect the AI, the allowed widgets, and the app’s data so generated screens can respond to a conversation.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it for AI-generated screens, chat-based interfaces, dynamic dashboards, conversational flows, and layouts returned by a server or language model.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/poorgramer-zack/dart-expert-skills/flutter-genui
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add Poorgramer-Zack/dart-expert-skills --skill flutter-genui
Clone the repo
git clone --depth 1 https://github.com/Poorgramer-Zack/dart-expert-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for generating-flutter-ui

README.md
[![agentmods](https://agentmods.dev/badge/skills/poorgramer-zack/dart-expert-skills/flutter-genui/github.svg)](https://agentmods.dev/skills/poorgramer-zack/dart-expert-skills/flutter-genui)
Your own site
<a href="https://agentmods.dev/skills/poorgramer-zack/dart-expert-skills/flutter-genui"><img src="https://agentmods.dev/badge/skills/poorgramer-zack/dart-expert-skills/flutter-genui/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for generating-flutter-ui

Your own site · 80×15
<a href="https://agentmods.dev/skills/poorgramer-zack/dart-expert-skills/flutter-genui"><img src="https://agentmods.dev/badge/skills/poorgramer-zack/dart-expert-skills/flutter-genui.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 121 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,247 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00121 $0.01247
Opus 5.5 $0.00048 $0.00499
Sonnet 5.5 $0.00024 $0.00249
Haiku 4.5 $0.00012 $0.00125

Measured 1mo ago against content hash e7dbb016d69b, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

generating-flutter-ui scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/flutter-genui/SKILL.md · 126 lines

How it starts

The opening of the file, as written. The whole thing — 126 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Flutter Generative UI (GenUI) Best Practices

Goal

Implement a dynamic user interface generated by AI using the genui package. This is the recommended approach when an application needs to build reactive screens or components directly from AI responses without hardcoding the layout.

Instructions

The genui package orchestrates a conversational loop between the user, the AI (via ContentGenerator), and the Flutter UI (via A2uiMessageProcessor and DataModel).

1. Project Setup

Add the necessary packages to your pubspec.yaml:

flutter pub add genui
# For Gemini integration via Firebase:
flutter pub add genui_firebase_ai

If targeting macOS/iOS, enable outbound network requests in entitlements:

<key>com.apple.security.network.client</key>
<true/>

2. Core Integration Structure

To connect your Flutter application to the AI agent, you need to instantiate three main components:

  1. A2uiMessageProcessor: Handles the UI side, translating AI messages into UI actions. Supply it with a Catalog of widgets the AI is allowed to use.
  2. ContentGenerator: Handles communication with the AI. Supply it with system instructions and tools.
  3. GenUiConversation: The facade coordinating the processor and generator.

Example Setup in a StatefulWidget:

import 'package:flutter/material.dart';
import 'package:genui/genui.dart';
import 'package:genui_firebase_ai/genui_firebase_ai.dart';

class GenUIPage extends StatefulWidget {
  const GenUIPage({super.key});

  @override
  State<GenUIPage> createState() => _GenUIPageState();
}

class _GenUIPageState extends State<GenUIPage> {
  late final A2uiMessageProcessor _a2uiMessageProcessor;
  late final GenUiConversation _genUiConversation;

  @override
  void initState() {
    super.initState();

    // 1. Initialize Message Processor with predefined catalog widgets
    _a2uiMessageProcessor = A2uiMessageProcessor(
      catalogs: [CoreCatalogItems.asCatalog()],
    );

    // 2. Initialize Content Generator (e.g., Firebase AI / Gemini)
    final contentGenerator = FirebaseAiContentGenerator(
      catalog: CoreCatalogItems.asCatalog(),
      systemInstruction: '''
        You are an AI assistant. You must generate UI by responding with JSON
        matching the provided widget schemas. Always output valid UI structures.
      ''',
      tools: _a2uiMessageProcessor.getTools(),
    );

    // 3. Orchestrate the Conversation
    _genUiConversation = GenUiConversation(
      a2uiMessageProcessor: _a2uiMessageProcessor,
      contentGenerator: contentGenerator,
      // Implement your handlers for rendering generated surfaces
      onSurfaceAdded: (surfaceId) { /* Handle surface creation */ },
      onSurfaceDeleted: (surfaceId) { /* Handle surface deletion */ },
      onTextResponse: (text) { /* Optional: show text explicitly */ },
      onError: (error) { /* Handle generation errors */ },
    );
  }

  @override
  void dispose() {
    _genUiConversation.dispose();
    super.dispose();
  }

  @override
  Widget build(BuildContext context) {
    // UI Implementation interacting with _genUiConversation.sendRequest()
    return const Scaffold();
  }
}

Read the full file on GitHub · 126 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 126 lines · 121 tokens per session scan A e7dbb016d69b

Subscribe to this mod's changes

generating-flutter-ui is a skill published in the GitHub repository Poorgramer-Zack/dart-expert-skills (7 stars, last pushed 2mo ago), licensed MIT. It adds 121 tokens to every session and 1,247 once invoked, about $0.0005 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

at_client_skills-sdk

Use this skill when a developer is building a Dart or Flutter app that depends on atclient or atclientflutter from pub.dev, stores or shares data via the Atsign Protocol, needs onboarding (CRAM new-atsign, atKeys file, keychain, APKAM) or APKAM enrollment, asks how to open, own, stop or switch an AtClient or read its…

atsign-foundation/at_client_sdk · 267 tokens

flutter-pre-caching

Use when preloading fonts, asset/network images, Lottie/Rive animations, local JSON/config, warming initial API data, or optimizing Flutter Web startup.

evanca/flutter-ai-rules · 36 tokens

firebase-messaging

Use when setting up Firebase Cloud Messaging, managing permissions and tokens, handling background/foreground notification taps, or dispatching messages server-side (HTTP v1).

evanca/flutter-ai-rules · 35 tokens

bloc

Use when creating a Cubit or Bloc, modeling state with sealed classes or status enums, wiring BlocBuilder/BlocListener/BlocProvider, writing bloc tests, or choosing between Cubit and Bloc.

evanca/flutter-ai-rules · 42 tokens

generate-images-with-firebase-ai

Use when generating or editing images from Flutter/Dart with Firebase AI Logic and a Gemini image model (Nano Banana), making the first call work, choosing Gemini Developer API vs Vertex AI, hitting quota, billing or App Check failures, getting empty or image-only responses, sending a user photo as input, controlling…

evanca/flutter-ai-rules · 84 tokens

firebase-app-check

Use when implementing app attestation, configuring App Check providers, setting up debug tokens, enabling backend enforcement, or managing token refresh.

evanca/flutter-ai-rules · 30 tokens