liquid_glass_widgets
AGENTS.md854 starsChanged 7 months agoMITView on GitHub
This document is for AI agents interacting with the liquid_glass_widgets repository itself — contributing code, running tests, fixing bugs, or reviewing PRs. Two audiences — two documents: Always verify changes using these commands before finalising: When modifying fragment shaders in shaders/: All widget rules, component API patterns, app setup lifecycle, and anti-hallucination checklists live in the canonical consumer skill: 👉 skills/liquid-glass-widgets/SKILL.md Read that file before generating or reviewing any Flutter UI code that uses this package.
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.
Of the AGENTS.md files we read, the 33,315 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repositoryOne other file it gives its agents.
- liquid-glass-widgetsSkill
The file
We split this AGENTS.md into the rules it gives an agent
9 rules. About 0 are common, 5 are distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈5
Distinctive · estimate
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 17
Single Public Entry Point: All public APIs must be exported from lib/liquid_glass_widgets.dart.
- Distinctive: line 23
Always verify changes using these commands before finalising:
- Very specific: line 43
When modifying fragment shaders in shaders/:
- Very specific: line 46
No Dynamic Array Indexing: Avoid indexing uniform arrays with variable expressions (lights[i] where i is a non-constant loop index without …
- Distinctive: line 47
Loop Bounds: All loops must have static, compile-time constant bounds.
- Distinctive: line 55
No Unprompted Commits to
main: Default to feature branches and pull requests unless the user explicitly asks to work or commit directly … - Very specific: line 57
Zero Hallucination Rule: Never introduce speculative parameters or undocumented imports.
- Distinctive: line 63
All widget rules, component API patterns, app setup lifecycle, and anti-hallucination checklists live in the canonical consumer skill:
- Distinctive: line 67
Read that file before generating or reviewing any Flutter UI code that uses this package.
≈ “Common” is an estimate: at least 1 in 5 of the 42,283 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Agent Guide for liquid_glass_widgets
This document is for AI agents interacting with the liquid_glass_widgets repository itself — contributing code, running tests, fixing bugs, or reviewing PRs.
Two audiences — two documents:
| Your goal | Read |
| Contribute to this repo (fix bugs, add widgets, modify shaders) | This file |
| Build a Flutter app that uses this package | skills/liquid-glass-widgets/SKILL.md |
1. Environment & Requirements
- Flutter SDK: Requires Flutter ≥ 3.41.0 (Dart ≥ 3.5.0) for Impeller shader support.
- Single Public Entry Point: All public APIs must be exported from
lib/liquid_glass_widgets.dart. Internal implementations live underlib/src/. Never expose private engine internals.
2. Standard Commands
Always verify changes using these commands before finalising:
# Analyse code for lint and type errors
flutter analyze
# Run unit and widget tests
flutter test
# Format all Dart files
dart format .
# Validate documentation comments
dart doc --dry-run3. Shader Development Rules (GLSL / Impeller / SkSL)
When modifying fragment shaders in shaders/:
- Dual-Pipeline Compatibility: Shaders must compile on both Impeller (Metal/Vulkan) and SkSL / SPIR-V (Windows/Linux fallback).
- No Dynamic Array Indexing: Avoid indexing uniform arrays with variable expressions (
lights[i]whereiis a non-constant loop index without unrolling). - Loop Bounds: All loops must have static, compile-time constant bounds.
- No Forbidden Builtins:
dFdx,dFdy,fwidthare unavailable on some SPIR-V targets — avoid them in shared shaders. - Shader Validation: Validate locally using
glslangValidatororflutter testbefore opening a PR.
4. Git & Release Conventions
- No Unprompted Commits to
main: Default to feature branches and pull requests unless the user explicitly asks to work or commit directly onmain. - CHANGELOG Updates: Non-trivial changes must be documented in
CHANGELOG.mdfollowing the established release format. - Zero Hallucination Rule: Never introduce speculative parameters or undocumented imports. Verify against the actual Dart source in
lib/.
5. Building UI with liquid_glass_widgets
All widget rules, component API patterns, app setup lifecycle, and anti-hallucination checklists live in the canonical consumer skill:
👉 skills/liquid-glass-widgets/SKILL.md
Read that file before generating or reviewing any Flutter UI code that uses this package.
Further Reference
- Architecture & Guidelines — Core design principles and internal architecture.
- Platform Support — Platform matrices and rendering pipeline compatibility.
- Migration Guide (0.x → 1.0) — Step-by-step upgrade guide for 1.0.0 breaking changes.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

