loam 0.1.3
loam: ^0.1.3 copied to clipboard
Codebase intelligence for Dart & Flutter: finds project-wide unused public API (dead code) behind a baseline/ratchet CI gate. More rules on the roadmap.
Codebase intelligence & anti-AI-slop for Dart & Flutter.
loam.dev is the product;
loamis this CLI command and pub.dev package. Web: getloam.dev · Source: github.com/silvio-l/loam
loam is a Dart-native CLI for codebase intelligence and anti-AI-slop. It runs
on the Dart analyzer package — semantically accurate, project-wide, offline by
default — behind a baseline/ratchet CI gate that never paints a grown codebase
red on day one.
🚧 0.1.0 — early preview. This is the first functional release. It ships one rule (
unused-public-exports) end to end to prove the architecture; the rest of the capabilities below are on the roadmap, each landing as its own rule behind the same stableRuleinterface.
What it catches #
Available now (0.1.0): project-wide unused public API — exports, classes,
methods, getters/setters and fields that nothing in the project references —
emitted as findings behind the baseline/ratchet gate, in human, sarif, json, markdown or html.
Everything else is the target surface (🚧 = planned, not in 0.1.0):
| Structural drift (deterministic, semantic) | AI-slop (deterministic + optional LLM) |
|---|---|
| ✅ Unused public exports, files, members | 🚧 Empty / swallowing catch blocks |
| 🚧 Circular dependencies | 🚧 Narrative filler comments |
| 🚧 Code duplication (AST-normalised) | 🚧 Ungrounded // ignore: |
| 🚧 Complexity hotspots + health score | 🚧 Duplicated helpers, dead guards |
| 🚧 Architecture-boundary violations | 🚧 Hallucinated / superfluous abstractions |
What makes it different #
- 🌱 Semantic, not regex — resolved Dart element model + project-wide graphs. (in 0.1.0)
- 🔒 Baseline / ratchet gate (default) — freeze today's findings; only new ones fail CI. (in 0.1.0)
- ♻️ Reproducible even with an LLM — verdicts cached by
sha(code)+prompt@ver, fixed thresholds decide. Same code = cache hit = stable verdict, zero token cost. (🚧 planned) - 📄 Self-contained HTML report — one offline file; toggle findings, copy a deterministic
prompt@verfix-prompt for your AI agent. (in 0.1.3) - 🔧 Configurable suppression —
loam.yamlrule toggles and project-relativeignore:globs, plus inline// loam-ignore: <ruleId> – reason;loam initscaffolds the file. (in 0.1.3)
Install #
dart pub global activate loam
Make sure $HOME/.pub-cache/bin is on your PATH (Dart prints a reminder if it
isn't). To update, re-run the exact same command.
On Apple Silicon macOS / Linux you can skip the PATH step entirely with
Homebrew: brew install silvio-l/loam/loam.
Install the unreleased dev branch instead
dart pub global activate --source git https://github.com/silvio-l/loam.git \
--git-path packages/loam_cli --git-ref dev
Quick start #
loam scan # full audit: unused public API across the whole repo
loam baseline --write # freeze the accepted state to baseline.json
loam gate # CI: ratchet — only new findings fail (exit 1)
loam --help lists every command; planned ones are marked (coming soon).
Status #
Walking skeleton in progress. Founding spec, domain glossary and architecture decisions live in the repository.
License #
MIT © 2026 Silvio Lindstedt