Skip to content

houyongsheng/flutter_gemma_skill

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Flutter Gemma Skills

License: MIT Flutter Version Gemma

Claude Code Skills for building offline-capable AI features with Gemma 4 on-device LLM inference in Flutter applications.

What's Included

1. flutter-gemma-scaffold

A complete scaffold guide for integrating Gemma 4 into Flutter projects. Covers:

  • Project setup with flutter_gemma, Riverpod 2.0, and GoRouter
  • iOS, Android, Web, and Desktop platform configuration
  • Model installation and loading
  • Basic inference and streaming responses
  • Function calling with structured output
  • Multimodal input (image understanding)
  • Complete example application

2. flutter-gemma-skill

A comprehensive guide for building reusable AI capabilities on top of flutter_gemma. Covers:

  • Designing function schemas for structured output
  • Implementing Skill classes with system instructions
  • Building execution engines
  • Creating result parsers and prompt builders
  • Publishing AI skill packages

Quick Start

Install Skills for Claude Code

Copy the skill directories to your Claude Code skills folder:

# Clone the repo
git clone https://github.com/houyongsheng/flutter_gemma_skill.git

# Copy skills to Claude Code
cp -r flutter_gemma_skill/flutter-gemma-scaffold ~/.claude/skills/
cp -r flutter_gemma_skill/flutter-gemma-skill ~/.claude/skills/

Use the Skills

After installation, Claude Code will automatically use these skills when you mention:

  • "integrate Gemma", "on-device LLM", "flutter_gemma"
  • "build AI capability", "function calling", "Gemma skill development"

Recommended Models

Model Size Memory Best For
Gemma 4 E2B Q4_K_M ~3.5GB <1.5GB General purpose
Gemma 4 E4B Q4_K_M ~6.5GB <2.5GB Stronger reasoning
FunctionGemma 270M ~284MB <300MB Function calling only

Example Projects

Ready-to-Run Example App

Check out the example/ directory for a complete Flutter app demonstrating:

  • Real-time chat with Gemma 4 streaming responses
  • Multiple AI skills (translation, summarization)
  • Riverpod 2.0 state management
  • Feature-based architecture
cd example
flutter run

Inline Examples

See flutter-gemma-scaffold/SKILL.md for a complete chat application example:

  • Riverpod 2.0 for state management
  • Feature-based project structure
  • Streaming responses
  • Proper error handling

Documentation

Contributing

Contributions welcome! Please open an issue or PR.

License

MIT

About

Claude Code Skills for building offline-capable AI features with Gemma 4 on-device LLM inference in Flutter apps. Includes scaffold templates, function calling guides, and reusable AI skill architecture.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages