add-malli-schemas
Efficiently add Malli schemas to API endpoints in the Metabase codebase with proper patterns,…
Suggest a space-themed name for a cyclic cluster of backend modules when metabase.core.module-cycles-test reports a cluster without a name, usually after a split. Use when someone needs to name a module cycle or add a line to .clj-kondo/config/modules/cycle-clusters.edn.
$ npx -y skills add metabase/metabase --skill name-module-cycle --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/name-module-cycleContext preview
The summary Claude sees to decide when to auto-load this skill.
Suggest a space-themed name for a cyclic cluster of backend modules when metabase.core.module-cycles-test reports a cluster without a name, usually after a split. Use when someone needs to name a module cycle or add a line to .clj-kondo/config/modules/cycle-clusters.edn.
name: name-module-cycle description: Suggest a space-themed name for a cyclic cluster of backend modules when metabase.core.module-cycles-test reports a cluster without a name, usually after a split. Use when someone needs to name a module cycle or add a line to .clj-kondo/config/modules/cycle-clusters.edn. allowed-tools: Read, Grep, Glob, Bash
`.clj-kondo/config/modules/cycle-clusters.edn` maps each cyclic cluster of the module require graph to an anchor module. When a change splits a cluster, the new half has no name, and the person who split it gets to choose one. Help them choose; do not pick for them.
The test failure lists the cluster's modules and, for a small cluster, the requires between them that make it a cycle. For the full picture, including teams, run:
clojure -X:dev dev.module-cycles/print-clusters
Unnamed clusters print first.
Look at everything the branch changes, committed or not: `git diff $(git merge-base origin/master HEAD)`, plus new files from `git ls-files --others --exclude-standard`. If it removed requires and these modules were part of a named cluster on master, the cluster split: name the new half. If it added a require between these modules, it created a new cycle: help break it instead, and stop here.
A module's namespaces are `metabase.<module>.*`, with dashes as underscores in the path, so `cloud-migration` lives in `src/metabase/cloud_migration/`, and `enterprise/foo` in `enterprise/backend/src/metabase_enterprise/foo/`. Some modules declare an `:ns-prefix` in `.clj-kondo/config/modules/config.edn` instead: `core.cmd` lives in `src/metabase/cmd/`, and `mcp.oauth-server` in `src/metabase/oauth_server/`.
`core.clj` is often a bare facade. The `ns` docstrings of `api.clj`, `models/` and any `README.md` usually say more, and so do the requires that close the cycle: they show what each module needs from the others.
Offer three to five names, each with one line on why it fits. A good name:
The current names show the range:
| Name | Anchor | Why it fits | |---|---|---| | `galactic-center` | `query-processor` | The dense core everything orbits | | `foundation` | `app-db` | The base layer, and Asimov's Foundation | | `tardis` | `lib` | A plain box from the outside; internally complex, and it can take you places | | `stargate` | `api-routes` | The gateway every request comes through | | `first-contact` | `mcp` | The protocol outside agents use to talk to Metabase | | `deep-thought` | `metabot` | The computer built to answer the big question |
The `<anchor>-knot` placeholder from the test failure is a valid fallback when nothing better comes up.
The anchor can be any module in the cluster, and the name follows it. Prefer one that is central and unlikely to leave the cluster or be renamed. The test proposes the member with the most requires to and from the rest of the cluster, ties broken alphabetically; in a small cluster everything often ties, and then the proposal carries no signal.
Add `<name> <anchor>` to the map in `.clj-kondo/config/modules/cycle-clusters.edn`, keeping the entries sorted and the anchors aligned one space past the longest name, then run:
./bin/test-agent :only '[metabase.core.module-cycles-test]'
Mention the new name in the PR, so reviewers see the split.
Metabase is the easy, open-source way for everyone in your company to ask questions and learn from data.
Repo: metabase/metabase
Efficiently add Malli schemas to API endpoints in the Metabase codebase with proper patterns,…
Add OpenTelemetry tracing spans to Clojure code following Metabase tracing conventions. Use…
Add product analytics events to track user interactions in the Metabase frontend
Evaluate Clojure code via nREPL using clj-nrepl-eval. Use this when you need to test code,…
Review Clojure and ClojureScript code changes for compliance with Metabase coding standards,…
Guide Clojure and ClojureScript development using REPL-driven workflow, coding conventions,…