@noir-ai/skills 1.16.0 → 1.17.0-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # @noir-ai/skills
2
2
 
3
- The native `noir-*` skill pack (27 builtins plus 1 integration) and a copy-and-validate compiler. `noir init` / `noir sync` emit it idempotently for hosts with a skill surface: Claude uses `.claude/skills/`; Cursor uses `.cursor/rules/*.mdc`. There is no plugin or marketplace.
3
+ The native `noir-*` skill pack (32 builtins plus 1 integration) and a copy-and-validate compiler. `noir init` / `noir sync` emit it idempotently for hosts with a skill surface: Claude uses `.claude/skills/`; Cursor uses `.cursor/rules/*.mdc`. There is no plugin or marketplace.
4
4
 
5
5
  Part of the **[Noir](https://github.com/agaaaptr/noir#readme)** toolkit — the discipline, context, and memory layer for any agentic CLI.
6
6
 
@@ -1,6 +1,6 @@
1
1
  ---
2
- name: noir-code-hygiene
3
- description: Use when writing or reviewing comments, docstrings, summaries, or documents — keep every line carrying something a reader can act on. Use when the user says "clean this up", "this reads like machine output", or asks for a comment sweep. Do NOT use for layout (indentation, quoting, line length); this is about what the text says.
2
+ name: noir-codebase-audit
3
+ description: Use when auditing a codebase, a diff, or a report for what to cut and what reads machine-written — name over-engineering to delete, harvest deliberate debt, and de-slop the prose. Use when the user says "audit this", "what should I cut", or asks for a comment sweep. Do NOT use for layout, formatting, or linting; this is about what to cut and what the text says.
4
4
  metadata:
5
5
  category: meta
6
6
  version: 1.0.0
@@ -10,32 +10,86 @@ references:
10
10
  - examples.md
11
11
  ---
12
12
 
13
- # noir-code-hygiene
13
+ <!-- noir-hygiene: exempt -->
14
14
 
15
- Text that reads as machine-generated fails in a small number of ways, and every
16
- one of them is a sentence a reader cannot act on. The ten defects below are
17
- those ways, each as a Tell (what it looks like), a Why (what it costs a reader)
18
- and a Fix (what to write instead). Four of them — restating, stale text, jargon,
19
- unstated assumptions — are judgements a person makes; the rest are mechanical
20
- enough that the quality gate checks them itself.
15
+ # noir-codebase-audit
16
+
17
+ An audit finds what a reader pays to understand twice. It runs in four passes
18
+ over the same code: over-engineering to delete, deliberate debt to record,
19
+ prose to de-slop, and the mechanical defects that make text read as generated.
20
+ The last pass is also enforced by the quality gate, so this guidance and the
21
+ gate agree on what counts as noise.
21
22
 
22
23
  ## When to use
23
24
 
24
- - Writing or reviewing a comment, docstring, summary, or document that a reader will meet without the context its author had.
25
- - Sweeping a file, a diff, or a report for text that reads as generated.
26
- - The user says "clean this up", "this reads like machine output", or asks for a comment sweep.
25
+ - Auditing a codebase, a diff, or a report for what can be deleted.
26
+ - Harvesting deliberate debt markers into a ledger a later change can read.
27
+ - Sweeping comments, summaries, or documents that a reader will meet without the context their author had.
28
+ - The user says "audit this", "what should I cut", "this reads like machine output", or asks for a comment sweep.
27
29
  - Reviewing your own output before handing it back: comments and summaries are where these defects concentrate.
28
- - **Do NOT use:** for layout (indentation, quoting, line length), or as a substitute for a formatter or a type checker. This is about what the text says, not how it is drawn.
30
+ - **Do NOT use:** for layout (indentation, quoting, line length), for linting or formatting, or as a substitute for a type checker. This is about what to cut and what the text says, not how it is drawn.
29
31
 
30
32
  ## Procedure
31
33
 
32
- 1. **Read the text as somebody who did not write it.** For each sentence, ask what a reader learns that the code, the diff, or the line above does not already say. A sentence that teaches nothing is the one to delete.
33
- 2. **Delete before rewriting.** Most defects end at deletion: a divider, a restated line, an empty label, a fact that is no longer true. Rewriting a comment that should not exist only makes the noise longer.
34
- 3. **Keep what the code cannot say.** The reason a value is what it is, the invariant a caller depends on, the condition that would break the order, the precondition. When only a restatement would be left, the comment is finished.
34
+ 1. **Run the four passes in order.** Delete over-engineering first, record deliberate debt, de-slop the prose, then sweep the mechanical defects. Deletion first shrinks the surface the later passes have to read.
35
+ 2. **Delete before rewriting.** Most findings end at deletion: a wrapper, a restated line, a fact that is no longer true. Rewriting a thing that should not exist only makes the noise longer.
36
+ 3. **Keep what the code cannot say.** The reason a value is what it is, the invariant a caller depends on, the ceiling a shortcut accepted and the trigger that retires it. When only a restatement would be left, the comment is finished.
35
37
  4. **Name things in the reader's terms.** Replace a codename, or a shorthand that resolves only against a planning document, with the mechanism it stood for. State the path, the command, or the precondition instead of assuming the reader knows it.
36
38
  5. **Run the gate.** `noir skills lint` over a skill body, `noir doctor` over a repository. Fix every fail-tier finding; read a warn-tier one as a question about the line rather than a rule to satisfy.
37
39
 
38
- ## Tell / Why / Fix
40
+ ## Over-engineering audit
41
+
42
+ One finding per line: name the thing, then delete it. When a finding needs a
43
+ second sentence to explain, the deletion was not obvious enough to do today.
44
+
45
+ - A wrapper around one standard-library call that adds nothing — delete the wrapper.
46
+ - An interface with one implementation — delete the interface until a second one exists.
47
+ - A factory that builds one product — delete the factory.
48
+ - A configuration knob nobody has changed and nobody will — delete the knob.
49
+ - A branch, flag, or parameter written "for later" with no caller — delete it; later can write it.
50
+ - A dependency pulled in for something a few lines would have covered — drop the dependency.
51
+ - A test that asserts the implementation rather than the behavior — rewrite it against the behavior, or delete it.
52
+
53
+ ## Deliberate debt
54
+
55
+ A shortcut that cuts a real corner and names its ceiling is debt a later reader
56
+ can pay off; a shortcut that names nothing is a slow bug wearing a comment. The
57
+ `noir-debt:` marker records the first kind.
58
+
59
+ Write the marker as a source comment with both halves, the ceiling and the
60
+ condition that justifies the upgrade: `noir-debt: global lock; per-account locks
61
+ once throughput matters`. The second half is not optional: `noir-debt: global
62
+ lock` names the ceiling but no trigger, so nobody knows when to pay it.
63
+
64
+ Harvest the markers into a ledger grouped by file, one line per marker, with
65
+ the ceiling, the trigger, and the file it sits in. Read the ledger before the
66
+ next change in that file. A marker whose trigger has arrived is not debt to
67
+ keep; it is the work to do now.
68
+
69
+ ## Anti-slop
70
+
71
+ De-sloping removes the vocabulary a generator reaches for first. Three lists,
72
+ three treatments.
73
+
74
+ - **Banned** — delete on sight, replace with a plain verb or noun: delve, utilize, leverage, facilitate, elucidate, embark, endeavor, encompass, multifaceted, tapestry, testament, paradigm, synergy, holistic, catalyze, juxtapose, realm, landscape, myriad, plethora.
75
+ - **Rationed** — at most one per paragraph, and only when it names something concrete: robust, comprehensive, seamless, cutting-edge, innovative, streamline, empower, foster, enhance, elevate, optimize, scalable, pivotal, intricate, profound, resonate, underscore, navigate, cultivate, bolster, galvanize, cornerstone, game-changer.
76
+ - **Filler** — delete the frame, write the claim: "it is important to note that", "needless to say", "a testament to", "in the realm of", "serves as a".
77
+
78
+ ## Humanizer tells
79
+
80
+ Three prose tells mark a writer trying to sound human rather than be useful.
81
+
82
+ - **Em-dash density.** More than two em-dashes in one paragraph is a tell; the em-dash is the punctuation a generator leans on when a period would do. Split the sentence, or use a parenthetical.
83
+ - **Hedging openers.** "It is worth mentioning", "it should be noted", "it goes without saying" frame a claim before making it. Delete the frame and make the claim.
84
+ - **The not-X-but-Y contrast.** "This is not a bug but a feature" reads written because the first clause exists only to set up the second. State the second clause alone.
85
+
86
+ ## The mechanical defects
87
+
88
+ The ten defects below are the shapes a generator produces, each as a Tell (what
89
+ it looks like), a Why (what it costs a reader) and a Fix (what to write
90
+ instead). Four of them — restating, stale text, jargon, unstated assumptions —
91
+ are judgements a person makes; the rest are mechanical enough that the quality
92
+ gate checks them itself.
39
93
 
40
94
  ### Decorative separators and banners
41
95
 
@@ -181,11 +235,11 @@ The rules themselves are one table in the skills package, and each entry carries
181
235
 
182
236
  ## Verification
183
237
 
184
- - [ ] Every sentence kept carries something the code, the diff, or the line above does not.
238
+ - [ ] Every line kept carries something the code, the diff, or the line above does not.
239
+ - [ ] Every finding of the over-engineering pass names one thing to delete, and it is gone.
240
+ - [ ] Every `noir-debt:` marker names a ceiling and a trigger, and the ledger lists them.
185
241
  - [ ] No divider, no restatement, no ordinal marker, no empty label survives the pass.
186
242
  - [ ] Every fact stated beside the code is true of the code as it stands now.
187
- - [ ] Every codename or shorthand is replaced by the mechanism it stood for.
188
- - [ ] The path, the command, and the precondition are stated rather than assumed.
189
243
  - [ ] `noir skills lint` (skill body) or `noir doctor` (repository) reports no fail-tier finding.
190
244
 
191
245
  ## Notes
@@ -1,4 +1,4 @@
1
- <!-- Worked examples for the noir-code-hygiene skill.
1
+ <!-- Worked examples for the noir-codebase-audit skill.
2
2
 
3
3
  This file exists to show the shapes the rules forbid, so it must contain
4
4
  them. It therefore declares the exemption the rules honour with the marker
@@ -0,0 +1,69 @@
1
+ ---
2
+ name: noir-dataviz
3
+ description: Use when the user asks for a chart, graph, plot, dashboard, or any data visualization — pick the chart form before the palette, apply the four color jobs and the legibility floors, then set mark sizes and ship a text alternative for every chart. Do NOT use for general UI design (noir-design) or picking a visual style (noir-design-reference).
4
+ metadata:
5
+ category: domain
6
+ version: 1.0.0
7
+ license: MIT
8
+ compatibility: claude · agents-md · gemini · cursor · opencode
9
+ ---
10
+
11
+ # noir-dataviz
12
+
13
+ Charts in one surface should hold together as a single system: pick the parts in a fixed order — form first, color last, marks between. Color is the last decision, not the first, because a chart that works in grayscale still works, and a chart that leans on color alone falls apart the moment the hue is removed.
14
+
15
+ ## When to use
16
+
17
+ - The user asks for a chart, graph, plot, dashboard, or any data visualization, in any medium (HTML, SVG, matplotlib, plotly, d3, or a rendered image).
18
+ - A screen needs a stat tile, sparkline, heatmap, legend, axis, or tooltip, and no chart standard is set.
19
+ - The question is about chart colors, series palettes, or how many colors a chart needs.
20
+ - Do NOT use for general UI layout, styling, or screen design. noir-design owns those.
21
+ - Do NOT use for picking an aesthetic, a style, or the token schema. noir-design-reference owns those.
22
+
23
+ ## Procedure
24
+
25
+ 1. Pick the chart form first, before any color. Match the data shape to a form and write the form down:
26
+ - Compare categories → bar chart.
27
+ - Show change over time → line chart.
28
+ - Show parts of a whole → stacked bar or donut.
29
+ - Show how values are distributed → histogram.
30
+ - Show the relationship between two measures → scatter plot.
31
+ A palette must not drive this choice; the data shape does.
32
+
33
+ 2. Pick the one color job that matches the data. There are four, and each encodes a different relationship:
34
+ - Categorical: distinct hues, equal lightness, and a fixed order the whole chart family reuses. No series may read as more important than another.
35
+ - Ordinal: one hue ramped from light to dark in steps, so rank reads as lightness.
36
+ - Sequential: one hue stepped from its 100 to its 700, where a larger value is a darker step.
37
+ - Diverging: two hues that meet at a neutral midpoint; the midpoint is the meaningful center (zero, the mean, a threshold), and both sides darken away from it.
38
+
39
+ 3. Check the legibility floors before rendering. Each pair of series colors needs enough separation to read as different data: hold at least a delta-E of 15 between any two series, and at least 3:1 luminance contrast between any data element and its background (text stays at 4.5:1). Keep the separation color-vision-safe: never let red versus green be the only difference between two series — add a shape, dash, label, or lightness step instead. Keep categorical hues inside OKLCH lightness 0.45 to 0.75 on light surfaces and 0.50 to 0.70 on dark surfaces, with chroma no lower than 0.08, so a hue that reads on white still reads on near-black.
40
+
41
+ 4. Set the mark grammar. Minimums keep marks visible and clickable at any size:
42
+ - Bars: at least 8 px wide, with a gap smaller than the bar itself.
43
+ - Lines: at least 2 px of weight so a line reads as data, not a hairline.
44
+ - Markers: at least 8 px across so a point stays visible and hittable.
45
+ - Gridlines: light and behind the data, never competing with it.
46
+ - Axes: hairline weight in a muted color; the frame supports the data, it does not star.
47
+
48
+ 5. Add the accessibility twin. Every chart ships a table or a text alternative that carries the same numbers, so the chart stays useful when the image is not there. Never let color be the only signal: pair every color with a label, shape, or pattern so the chart still reads in grayscale.
49
+
50
+ For example, a monthly revenue chart maps time to a line, uses a single hue ramped light to dark, adds a table of the same twelve numbers under the SVG, and relies on the line and its point markers, not its hue, to carry the trend.
51
+
52
+ ## Verification
53
+
54
+ - [ ] The form is chosen and written down before any color decision.
55
+ - [ ] The color job is named and matches the data relationship (one of the four).
56
+ - [ ] Series colors clear a delta-E of 15 and 3:1 contrast against the background.
57
+ - [ ] Red versus green is never the only separator between two series.
58
+ - [ ] Bars, lines, and markers meet their minimum sizes; gridlines are light; axes are hairlines.
59
+ - [ ] Every chart has a table or text alternative, and no signal rests on color alone.
60
+
61
+ ## Notes
62
+
63
+ - A form chosen first survives a palette change; a palette chosen first does not survive a form change.
64
+ - Reuse the project's existing palette before inventing a parallel one.
65
+ - In dark mode, keep the same four jobs but re-derive the light-to-dark direction so the contrast floors still hold.
66
+
67
+ ## When done → next skill
68
+
69
+ → noir-design for general UI layout and styling. → noir-design-reference for a style or palette lookup.
@@ -0,0 +1,43 @@
1
+ ---
2
+ name: noir-debt
3
+ description: Use when the user asks "what did we defer", "list the shortcuts", "debt ledger", or mentions noir-debt. Grep the repo for the noir-debt markers, then group them by file into a ledger that names each marker's ceiling and upgrade trigger. Do NOT use to fix the debt (the owning task does that), for a general read-only codebase search (noir-exploring), or as a whole-repo audit (noir-codebase-audit owns that pass).
4
+ metadata:
5
+ category: meta
6
+ version: 1.0.0
7
+ license: MIT
8
+ compatibility: claude · agents-md · gemini · cursor · opencode
9
+ ---
10
+
11
+ # noir-debt
12
+
13
+ Harvest every `noir-debt:` marker in the repository into a ledger grouped by file. Each entry names the marker's ceiling and the trigger that retires it, so a later change can pay the debt back instead of rediscovering it.
14
+
15
+ ## When to use
16
+
17
+ - The user asks "what did we defer", "list the shortcuts", "debt ledger", or mentions noir-debt.
18
+ - Before changing a file, to see which markers inside it have a trigger that has already arrived.
19
+ - **Do NOT use** to fix the debt itself; the owning task pays it. For a general read-only codebase search, use `noir-exploring`; this skill only greps `noir-debt:` markers and builds the ledger. For the whole-repo over-engineering and prose pass, use `noir-codebase-audit`.
20
+
21
+ ## Procedure
22
+
23
+ 1. **Find the markers.** Grep the repo for `noir-debt:` in source comments, for example: `grep -rn "noir-debt:" .`. Narrow the include patterns to the languages present.
24
+ 2. **Read each marker's two halves.** A marker names a ceiling and the condition that justifies the upgrade, for example: `// noir-debt: global lock, per-account locks when throughput matters`. A marker with only a ceiling is incomplete; list it as such rather than inventing a trigger.
25
+ 3. **Group by file.** Order entries by path, then line. One line per marker: file, line, ceiling, trigger.
26
+ 4. **Print the ledger to stdout.** Keep it copyable: one line per marker, no summary paragraphs. A marker whose trigger has already arrived is flagged in its group as due now.
27
+
28
+ ## Verification
29
+
30
+ - [ ] Every `noir-debt:` marker in the repo appears in the ledger, grouped by file.
31
+ - [ ] Each entry carries the ceiling and the trigger, or is flagged when the trigger half is missing.
32
+ - [ ] Entries are one line each, ordered by file then line.
33
+ - [ ] Markers whose trigger has arrived are called out as due.
34
+
35
+ ## Notes
36
+
37
+ - The ledger is read-only output; writing it to a file or paying the markers belongs to the owning task.
38
+ - A marker without a trigger cannot be paid back on time; report it as incomplete rather than completing it silently.
39
+ - Read the ledger before the next change in a file, so a due marker becomes the work of that change.
40
+
41
+ ## When done → next skill
42
+
43
+ → `noir-executing-plans`, or the owning task, to pay a marker whose trigger has arrived. Or `noir-codebase-audit` for the full audit pass.
@@ -0,0 +1,56 @@
1
+ ---
2
+ name: noir-design
3
+ description: Use when the user says "design this", "style this", "make it look good", or "frontend design" — commit to one bold aesthetic, run the anti-template checks, and resolve the precedence ladder before any styling code. Do NOT use for token system mechanics (noir-design-reference) or charts and data visualization (noir-dataviz).
4
+ metadata:
5
+ category: domain
6
+ version: 1.0.0
7
+ license: MIT
8
+ compatibility: claude · agents-md · gemini · cursor · opencode
9
+ ---
10
+
11
+ # noir-design
12
+
13
+ Set one committed aesthetic before any styling code, and spend the boldness in a single place. A page that is half brutalist and half glassy reads as unsure; a page that is one thing, done deliberately, reads as designed.
14
+
15
+ ## When to use
16
+
17
+ - The user says "design this", "style this", "make it look good", or "frontend design".
18
+ - A UI brief is vague and needs a direction before anyone writes CSS.
19
+ - An existing screen looks like a template and needs a distinct point of view.
20
+ - Do NOT use for token system mechanics, the style inventory, or the palette schema. noir-design-reference owns those.
21
+ - Do NOT use for charts, graphs, or data visualization. noir-dataviz owns those.
22
+
23
+ ## Procedure
24
+
25
+ 1. Commit to one bold aesthetic. Pick a single style from noir-design-reference (neobrutalism, editorial, glassmorphism, and the rest) and carry it through every decision. Spend the boldness once, on an oversized headline or one saturated accent, and keep everything else quiet so that one moment lands.
26
+ 2. Run the anti-template check. Reject a design that leans on these ready-made tells:
27
+ - The cream background with terracotta accents, the near-black with acid-green pairing, and every other two-color recipe that shows up unchanged across AI output.
28
+ - A small tracked ALL-CAPS eyebrow above every headline.
29
+ - The generic card: a soft drop shadow, a hairline border, and content floating in it with no structural reason.
30
+ - Monospace type used as decoration on labels that are not code.
31
+ - A call-to-action label that trails an arrow character, repeated on every link.
32
+ These are not wrong because they are common; they are wrong because they read as unexamined. If one earns its place, keep it and say why.
33
+ 3. Resolve the precedence ladder, in this order: the user's instruction and brand guide first, the project's existing design system second, the accessibility floor third, and the brief's own suggestions last. When two levels conflict, the higher one wins.
34
+ 4. First pass: define tokens before code. Name the colors, spacing, radius, and type scale as variables before writing a component. Reuse the project's existing tokens when they exist; do not invent a parallel system. For example, a landing page might commit to editorial type with one oversized headline, and keep every other element quiet. noir-design-reference carries the 16-token semantic palette when no system exists.
35
+ 5. Build component-first, responsive by default, and accessible. One component, one file, one job. Mobile layout first, wider breakpoints after. Semantic elements, keyboard reachability, a visible focus indicator, and a label on every input.
36
+ - Wide tables and code blocks scroll inside their own container (`overflow-x: auto`); the page body never scrolls horizontally.
37
+ - Buttons and links are real `<button>` and `<a>` elements, never a `<div onClick>`.
38
+ - Optimistic updates feel faster, but they roll back on failure; a failed action must undo itself visibly.
39
+ 6. Second pass: review against the brief. Read the original request again and check that every visible choice answers it. Cut anything that exists only because it looked good.
40
+
41
+ ## Verification
42
+
43
+ - [ ] One aesthetic is named and carried through every screen.
44
+ - [ ] The anti-template list was checked, and any surviving cliché has a stated reason.
45
+ - [ ] The precedence ladder was applied top-down with conflicts resolved in order.
46
+ - [ ] Tokens are defined before components, reusing the project's system when it exists.
47
+ - [ ] Every interactive element is keyboard-reachable and labeled; text meets WCAG AA contrast.
48
+
49
+ ## Notes
50
+
51
+ - Boldness is a budget, not a default. One strong choice per screen is enough; two competing choices cancel out.
52
+ - When a design system already exists, follow it. This skill directs the aesthetic, not the token plumbing.
53
+
54
+ ## When done → next skill
55
+
56
+ → noir-design-reference when a style name, palette, or font pairing needs looking up. → noir-verifying when the UI must be checked against the spec.
@@ -0,0 +1,47 @@
1
+ ---
2
+ name: noir-design-reference
3
+ description: Use when the user asks "what style should I use", names a style like "neobrutalism" or "glassmorphism", says "pick a style", or needs a design reference — consult references/design.md and return the matching style's tokens, cost, and accessibility floor. Do NOT use for generating assets or for general layout questions.
4
+ metadata:
5
+ category: domain
6
+ version: 1.0.0
7
+ license: MIT
8
+ compatibility: claude · agents-md · gemini · cursor · opencode
9
+ references:
10
+ - design.md
11
+ ---
12
+
13
+ # noir-design-reference
14
+
15
+ The style inventory. When a design question needs a named style, its tokens, its build cost, its accessibility floor, a semantic palette, a rule ladder, a font pairing, or a motion budget, this skill reads references/design.md and returns the relevant part. It answers the "which style, and what does it cost" question; noir-design answers the "what should this screen commit to" question.
16
+
17
+ ## When to use
18
+
19
+ - The user asks "what style should I use", "pick a style", or "design reference".
20
+ - The user names a style (neobrutalism, glassmorphism, and the rest) and wants its tokens.
21
+ - A screen needs a semantic color palette or a font pairing and none exists yet.
22
+ - Do NOT use for generating images, icons, or any binary asset. This skill names large assets as pointers, never as files.
23
+ - Do NOT use for general layout questions or for deciding a direction. noir-design owns those.
24
+
25
+ ## Procedure
26
+
27
+ 1. Read the question for what is being asked: a named style, an open choice between styles, a palette, a font pairing, or a motion budget.
28
+ 2. Open references/design.md and find the section that matches.
29
+ 3. For a named style, return that style's era, tokens, cost, accessibility floor, and use-and-avoid guidance.
30
+ 4. For an open choice, shortlist two or three styles by build cost and context, and present each in one line so the user can commit.
31
+ 5. For tokens, pull the 16-token semantic palette and fill it with the chosen style's colors, light and dark.
32
+ 6. For the rest, pull the relevant rung from the UX rule ladder, the font-pairing guidance, or the motion tiers. For example, asking for neobrutalism returns its era, tokens, cost, floor, and fit.
33
+
34
+ ## Verification
35
+
36
+ - [ ] The returned guidance came from references/design.md, not from memory.
37
+ - [ ] A named style came back with cost and accessibility floor, not only its look.
38
+ - [ ] An open choice names the trade-off (cost, floor, fit), not just a list of names.
39
+ - [ ] No asset is generated; anything large is named as a pointer.
40
+
41
+ ## Notes
42
+
43
+ - This file is a reference: consult it, quote from it, and hand the decision back to noir-design.
44
+
45
+ ## When done → next skill
46
+
47
+ → noir-design to apply the chosen direction. → noir-verifying to check the finished screen against the spec.
@@ -0,0 +1,200 @@
1
+ # Design reference — styles, tokens, rules, fonts, motion
2
+
3
+ This file is the inventory noir-design-reference consults. It holds the style taxonomy, the semantic color palette, the UX rule ladder, the font-pairing guidance, and the motion tiers. It is a reference, not a playbook: noir-design decides the direction; this file supplies the raw material for that decision.
4
+
5
+ ## How to read this file
6
+
7
+ - For a named style, read its entry under the taxonomy and return era, tokens, cost, accessibility floor, and fit.
8
+ - For an open choice between styles, compare the Cost and Accessibility floor lines first, then the fit.
9
+ - For color, copy the 16-token palette and fill it with the chosen style's colors.
10
+ - For any other rule, find the rung or tier that matches and quote it.
11
+
12
+ Cost is the effort to build the style well and keep it accessible. Low means a day of CSS. Medium means several days with fallbacks. High means bespoke assets or platform-specific work.
13
+
14
+ ## Style taxonomy
15
+
16
+ Fourteen styles. Each entry names the era, the signature in one line, the tokens that carry it, the cost, the accessibility floor, and when it earns its place.
17
+
18
+ ### neobrutalism
19
+
20
+ **Era**: 1990s web revival, popular again from 2020.
21
+ **Signature**: flat blocks with thick borders and hard offset shadows; the layout owns its grid.
22
+ **Tokens**: saturated primaries on off-white or near-black; radius 0; hard shadow with no blur (4px 4px 0); a 2px to 4px solid border, often black; bold grotesque display type.
23
+ **Cost**: low to medium. The borders and shadows are cheap CSS; the real work is restraint, because every element shouting at once collapses the style.
24
+ **Accessibility floor**: contrast is strong by default, but pure saturated color pairs can drop below 4.5:1, so check text pairs. The offset shadow must never be the only focus indicator.
25
+ **Use**: playful, opinionated, or developer-facing products. **Avoid**: quiet, clinical, or financial surfaces.
26
+
27
+ ### glassmorphism
28
+
29
+ **Era**: early 2020s frosted-panel trend.
30
+ **Signature**: translucent panels that blur what sits behind them, edged with a thin light border.
31
+ **Tokens**: semi-transparent white fill at 10 to 20 percent opacity; backdrop blur; a 1px border in a lighter tone; radius 16 to 24px; a soft diffuse shadow; light or mid-weight sans type.
32
+ **Cost**: medium to high. backdrop-filter is expensive on low-end GPUs and needs a solid fallback behind it.
33
+ **Accessibility floor**: translucency cuts text contrast, so a glass panel needs a darker scrim or a solid fallback. Never let blur carry legibility alone.
34
+ **Use**: dashboards and cards over imagery, where depth sells the hierarchy. **Avoid**: dense data tables and forms, where the blur adds cost without clarity.
35
+
36
+ ### neumorphism
37
+
38
+ **Era**: 2019 soft-UI experiment.
39
+ **Signature**: elements that look extruded from the background, built from two shadows on a matching surface.
40
+ **Tokens**: background and element share one color; radius 12 to 20px; paired shadows, one light and one dark offset, with no border; low-contrast monochrome type.
41
+ **Cost**: low to build, high to keep accessible.
42
+ **Accessibility floor**: the near-identical tones give weak affordance and poor contrast, so interactive elements need a stronger hover and pressed state, and text needs 4.5:1 against its surface.
43
+ **Use**: decorative control panels and demos. **Avoid**: anything a user must operate quickly, and every form.
44
+
45
+ ### claymorphism
46
+
47
+ **Era**: 2021 playful 3D-soft look.
48
+ **Signature**: puffy, rounded, toy-like surfaces with an inner top highlight and a soft outer shadow.
49
+ **Tokens**: pastel or mid-tone fills; radius 24 to 40px; a bright inner highlight near the top; a soft outer shadow; a minimal border; rounded friendly type.
50
+ **Cost**: medium. Shadow layering and gradient work add up, and each state needs its own pass.
51
+ **Accessibility floor**: pastels often fall under 4.5:1 on white, so text needs a darker ink, and interactive clay elements need a clear pressed state.
52
+ **Use**: kid-friendly products, onboarding, and empty states. **Avoid**: enterprise dashboards and data-dense screens.
53
+
54
+ ### skeuomorphism
55
+
56
+ **Era**: mid-2000s realism, the era before flat design.
57
+ **Signature**: digital elements that imitate physical materials such as leather, paper, brushed metal, and glass.
58
+ **Tokens**: realistic gradients and textures; heavy inner and outer shadows; beveled borders; ornament; type that matches the object's period.
59
+ **Cost**: high. Texture and lighting assets are bespoke, and every state needs its own art.
60
+ **Accessibility floor**: texture must not sit behind text without a solid scrim, and imitation depth must not replace labels and focus states.
61
+ **Use**: niche realism where the metaphor teaches the interface, such as music gear, note apps, and games. **Avoid**: general product UI, where texture fights the content.
62
+
63
+ ### minimalism
64
+
65
+ **Era**: timeless reduction with Swiss design roots.
66
+ **Signature**: the fewest elements needed, with whitespace carrying the hierarchy.
67
+ **Tokens**: one accent color on a neutral background; radius 0 to 8px; no shadow or a hairline shadow; a hairline or no border; restrained type on a strong grid.
68
+ **Cost**: low to build, high to keep disciplined.
69
+ **Accessibility floor**: low contrast is the common failure, so keep text at 4.5:1 or better, and never let whitespace be the only grouping cue a screen reader can rely on.
70
+ **Use**: editorial, documentation, and developer tools. **Avoid**: playful or child-facing products that need warmth.
71
+
72
+ ### brutalism
73
+
74
+ **Era**: raw early-web ethos, revived around 2016.
75
+ **Signature**: deliberately unrefined defaults: system fonts, default link colors, and exposed structure.
76
+ **Tokens**: system type; browser-default colors; radius 0; visible table borders; no shadows; often a single flat background.
77
+ **Cost**: low to build, medium to keep readable at scale.
78
+ **Accessibility floor**: default contrast is fine, but decorative rawness must not remove focus rings or semantic structure.
79
+ **Use**: personal sites, art projects, and statements. **Avoid**: mainstream products where users expect polish.
80
+
81
+ ### bento grid
82
+
83
+ **Era**: 2022 dashboard-layout trend descended from Apple-style grid tiles.
84
+ **Signature**: a packed grid of rounded tiles in varied sizes, each holding one piece of content.
85
+ **Tokens**: neutral card fills; radius 16 to 24px; a hairline border; a soft shadow; small clear labels; tight padding.
86
+ **Cost**: medium. Responsive grid sizing and fitting content into tiles both take real work.
87
+ **Accessibility floor**: keep each tile's text at 4.5:1, and keep the tab order matching the visual order.
88
+ **Use**: dashboards, landing summaries, and app home screens. **Avoid**: long-form reading, where the grid fragments the text.
89
+
90
+ ### editorial
91
+
92
+ **Era**: print magazine typography carried onto the screen.
93
+ **Signature**: strong serif display type, a strict column grid, and generous whitespace.
94
+ **Tokens**: serif display with a clean sans body; off-white or paper background; near-black ink; hairline rules; radius 0; no shadows.
95
+ **Cost**: medium. The type pairing and grid discipline are the product.
96
+ **Accessibility floor**: serif display at small sizes loses legibility, so body text stays 16px or larger in a readable face at 4.5:1.
97
+ **Use**: media, culture, publishing, and portfolios. **Avoid**: dense product UI and data tools.
98
+
99
+ ### luxury
100
+
101
+ **Era**: understated high-end retail aesthetic.
102
+ **Signature**: quiet, spacious, matte surfaces with a single precious accent.
103
+ **Tokens**: a deep neutral or cream background; a gold or deep accent; wide letter-spacing on small caps; hairline borders; soft or no shadow; serif display type.
104
+ **Cost**: medium to high. Photography and spacing carry the product.
105
+ **Accessibility floor**: tiny tracked caps and thin serifs fail 4.5:1, so body text needs a readable size and weight.
106
+ **Use**: fashion, jewelry, hospitality, and premium services. **Avoid**: utilities and tools where speed matters more than mood.
107
+
108
+ ### cyberpunk
109
+
110
+ **Era**: 1980s neon-noir future.
111
+ **Signature**: glowing neon on dark, with scanlines and high-tech motifs.
112
+ **Tokens**: neon cyan and magenta on deep navy or black; glow shadows; thin borders; mono or tech display type; grid and scanline texture.
113
+ **Cost**: high. Glow effects, texture, and dark-mode-only maintenance all add up.
114
+ **Accessibility floor**: neon on black can bloom and blur, so keep body text bright white or add a dark scrim, and never rely on glow for focus.
115
+ **Use**: games, music, developer tools, and event sites. **Avoid**: long-form reading and anything light-mode-only.
116
+
117
+ ### Y2K
118
+
119
+ **Era**: late-1990s and early-2000s nostalgia.
120
+ **Signature**: chrome, gradients, and bubbly type from the turn of the millennium.
121
+ **Tokens**: chrome and gradient fills; a pink, blue, and silver palette; glossy bevels; 3D-ish buttons; italic or bubbly display type.
122
+ **Cost**: high. Gradient and bevel art is needed for every state.
123
+ **Accessibility floor**: metallic gradients make text contrast unstable, so put labels on a flat band or scrim and keep touch targets at 44px.
124
+ **Use**: fashion, music, and nostalgia campaigns. **Avoid**: forms, dashboards, and anything with strict legibility needs.
125
+
126
+ ### spatial (visionOS)
127
+
128
+ **Era**: 2023 glass-and-depth spatial computing idiom.
129
+ **Signature**: frosted glass layers that float at depth with soft light from the environment.
130
+ **Tokens**: frosted glass; subtle depth blur; rounded panels at 20 to 28px; a soft ambient shadow; system sans with generous spacing.
131
+ **Cost**: high. Depth layering and glass are platform-specific.
132
+ **Accessibility floor**: glass over busy scenes needs a scrim, text stays at 4.5:1, and depth must never be the only grouping cue.
133
+ **Use**: spatial and immersive interfaces, premium apps. **Avoid**: plain 2D web where the depth has nothing behind it.
134
+
135
+ ### material / flat
136
+
137
+ **Era**: Google's 2014 layered-flat system, and the flat design it answered.
138
+ **Signature**: flat color surfaces with soft elevation, grid-aligned and geometric.
139
+ **Tokens**: a small color system; radius 4 to 8px; layered elevation shadows; no gradients; clean sans type.
140
+ **Cost**: low to medium. It is well documented and componentized.
141
+ **Accessibility floor**: elevation shadows are weak affordance, so states need more than a shadow change, and text keeps 4.5:1.
142
+ **Use**: broad product UI, admin tools, and Android-flavored apps. **Avoid**: a bold brand moment, where flat reads as default.
143
+
144
+ ## The 16-token semantic palette
145
+
146
+ The schema to copy into a project that has no design system. It follows the shadcn and Tailwind naming so it drops into plain CSS variables or Tailwind's color slots. Define every token in light and dark, and never hardcode a hex inside a component.
147
+
148
+ | Token | Role | Notes |
149
+ |---|---|---|
150
+ | primary | the main brand fill | buttons, links, active states |
151
+ | on-primary | ink and icons that sit on primary | must reach 4.5:1 against primary |
152
+ | secondary | a quieter fill for hover and secondary buttons | a tone of primary or a neutral |
153
+ | on-secondary | ink and icons that sit on secondary | the same 4.5:1 rule |
154
+ | accent | the highlight used once, sparingly | the boldness budget lives here |
155
+ | on-accent | ink and icons that sit on accent | check contrast, since accent is often bright |
156
+ | background | the page background | near-white in light, near-black in dark |
157
+ | foreground | default text and icons on background | 4.5:1 against background |
158
+ | card | fill for cards and panels | one step off background |
159
+ | card-foreground | text and icons that sit on card | 4.5:1 against card |
160
+ | muted | a faint fill for hints and disabled areas | never used for body text |
161
+ | muted-foreground | secondary text on background or card | 4.5:1 for meaningful text |
162
+ | border | hairline rules and input borders | 3:1 against adjacent fills for component boundaries |
163
+ | destructive | the danger fill | buttons that delete or warn |
164
+ | on-destructive | ink and icons that sit on destructive | usually white |
165
+ | ring | the focus ring color | must stand out from background and primary |
166
+
167
+ An on- token always names the ink that sits on its base token. Keep the list at exactly these 16; a color that appears in one component and nowhere else does not earn a token.
168
+
169
+ ## The UX rule ladder
170
+
171
+ Check in this order. Each rung outranks the one below it, so a style that fails a higher rung is dropped no matter how it looks.
172
+
173
+ 1. **Accessibility.** 4.5:1 contrast for normal text and 3:1 for large text and component boundaries; every interactive element keyboard-reachable; a visible focus indicator; a label or aria-label on every input; alt text on images. This rung is non-negotiable and comes first.
174
+ 2. **Touch and interaction.** 44 by 44px targets with space between them; hover, focus, active, and disabled states on every control; pressed feedback so the user knows the tap registered.
175
+ 3. **Performance.** Images sized to their slot and lazy-loaded off-screen; fonts subset or variable; no layout shift from late-loading media; a first paint fast enough that nothing blocks interaction.
176
+ 4. **Style selection.** Commit to one aesthetic, as noir-design directs. A style that cannot hold the three rungs above is disqualified.
177
+ 5. **Layout and responsive.** Mobile first, widening at breakpoints; an 8px spacing grid so every gap is a step of 8; no horizontal page scroll.
178
+ 6. **Typography and color.** 16px minimum body text; a type scale with clear steps; one accent used sparingly; text never sits directly on a busy texture or image.
179
+ 7. **Animation.** 150 to 250ms transitions with one purpose each; transform and opacity only; no motion that delays the task.
180
+ 8. **Forms and feedback.** A label on every field; errors next to the field they name; empty, loading, error, and success states all present.
181
+ 9. **Navigation.** Predictable placement; a visible current state; keyboard operable; no links that lead nowhere.
182
+ 10. **Charts and data.** noir-dataviz owns the detail; the floor is a colorblind-safe palette and labelled axes.
183
+
184
+ ## Font pairing
185
+
186
+ - Two families at most: one display face and one body face. Three is a poster, not an interface.
187
+ - The pairing needs contrast in one dimension: a serif display with a neutral sans body, a grotesque display with its own light cut for body, or one variable family with clear weight and size steps.
188
+ - Body text stays at 16px or larger with a line-height near 1.5; the display face is for headings only.
189
+ - A mono face may join for code and data only, never for paragraphs.
190
+ - Pairs that work: a high-contrast serif display with a neutral grotesque body; a geometric sans display with the same family's regular cut for body; an editorial serif display with a humanist sans body.
191
+
192
+ ## Motion tiers and reduced motion
193
+
194
+ Pick one tier and keep the whole product in it.
195
+
196
+ - **None.** Static. For forms, data tools, and anything the user must read carefully.
197
+ - **Subtle.** 150 to 250ms ease-out transitions on hover and focus, with short fades and slides for appearing content. The default for most product UI.
198
+ - **Expressive.** Longer keyframed sequences for heroes and onboarding, with a clear narrative reason to exist.
199
+
200
+ Every tier wraps behind prefers-reduced-motion: a user who asks for reduced motion gets the None tier regardless of the product's choice. Never animate layout properties that force reflow; transform and opacity are the safe pair.
@@ -0,0 +1,43 @@
1
+ ---
2
+ name: noir-lazy
3
+ description: Use when the user says "be lazy", "simplest solution", "do less", "yagni", "shortest path", or "minimal solution". Climb the laziness ladder before writing code, and record each deliberate shortcut with a ceiling and a trigger. Do NOT use for non-coding requests, a read-only codebase search (noir-exploring), a project-health diagnostic (noir-doctor), a correctness or security review (noir-verifying or noir-security), or a whole-repo audit (noir-codebase-audit).
4
+ metadata:
5
+ category: execute
6
+ version: 1.0.0
7
+ license: MIT
8
+ compatibility: claude · agents-md · gemini · cursor · opencode
9
+ ---
10
+
11
+ # noir-lazy
12
+
13
+ Adopt the laziness ladder as the stance for the next coding change: make the smallest change that is still correct, and record every deliberate shortcut with a ceiling and a trigger so a later reader can pay it back.
14
+
15
+ ## When to use
16
+
17
+ - The user says "be lazy", "simplest solution", "do less", "yagni", "shortest path", or "minimal solution".
18
+ - A request is growing and a smaller version would cover it.
19
+ - **Do NOT use** for non-coding requests, a read-only codebase search (`noir-exploring`), a project-health diagnostic (`noir-doctor`), a correctness or security review (`noir-verifying`, `noir-security`), or a whole-repo audit (`noir-codebase-audit`). This skill is a stance applied while coding, not a review of code that already exists.
20
+
21
+ ## Procedure
22
+
23
+ 1. **Climb the ladder before writing.** Ask the questions in order and stop at the first rung that holds: does this need to exist at all; is it already in this repo; does the stdlib cover it; does the platform; does an installed dependency; can it be one line. Write the minimal code only when every earlier rung failed.
24
+ 2. **Fix the root cause, not the symptom.** Before editing a function, find every path that reaches it. Make the change at the shared point so all callers get it in one edit; patching only the reported path leaves the others broken.
25
+ 3. **Delete over add.** When two changes produce the same behavior, take the one that removes a line.
26
+ 4. **Record deliberate shortcuts.** A cut corner with a known ceiling gets a marker, not silence. For example: `// noir-debt: global lock, per-account locks when throughput matters`. Name both the ceiling and the upgrade trigger; the trigger half is not optional.
27
+
28
+ ## Verification
29
+
30
+ - [ ] Each rung was considered in order, and the answer is the highest rung that held.
31
+ - [ ] The fix sits at the shared root, not duplicated across callers.
32
+ - [ ] Every deliberate shortcut carries a `noir-debt:` marker with a ceiling and a trigger.
33
+ - [ ] The diff is the shortest change that solves the stated problem, and nothing else.
34
+
35
+ ## Notes
36
+
37
+ - Lazy means efficient, not careless: read the task and the code it touches before climbing the ladder.
38
+ - Two stdlib options of the same size: take the one that is correct on edge cases, not the flimsier one.
39
+ - State what was skipped and when to add it, in one line, instead of building it now.
40
+
41
+ ## When done → next skill
42
+
43
+ → `noir-verifying` to prove the change works. Or `noir-debt` to harvest the markers just written into a ledger.