/kivo-creator:section-matchingfrom kivo-creator
Maps design section specs to existing project blocks using a rubric-based matching system. Builds a match plan, applies compatibility filters, and scores candidates before generating new blocks.
Ships in kivo-creator. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Recognise first, generate last. Each section is matched to a block the project already has; a new block is generated only when nothing fits. The plan is written to disk and approved before anything is emitted.
html-ingest or figma-ingest produced valid specs.block-scaffolding-from-design) or checking the rendered page (visual-fidelity)..creator/<run>/ with valid specs..roots-stack.json, or the kivo-wise detector JSON passed with --stack=<file>..kivo-creator/ folder beside the skill folders).Read the catalog: node <kivo-creator>/scripts/match.mjs --catalog --project=. (name, type, title, description, whenToUse, fields). It holds every existing block of both types (ACF Composer classes and block.json files); a section may fill either. The project's block type only matters for new blocks (blockType in the plan; see /creator).
Build the plan: node <kivo-creator>/scripts/match.mjs --run=.creator/<run> --project=.. It writes match-plan.json and prints the sections to judge. Already decided by the script:
skip;spec.codeConnect.block): fill with confidence 1;scaffold (or gap when the target forbids generated blocks).For each section in judge, read its spec, its reference image and its candidates (blocks whose fields can hold every slot, ranked by field coverage). Score each candidate with the rubric, then write the decision into match-plan.json:
| Criterion | Question | Weight |
|---|---|---|
| Purpose | Do the block's description and whenToUse describe this kind of section? | Decisive: a block built for another purpose is never a match, even when its fields fit |
| Structure | Do the slots and the repeat count fit without dropping content? Unused optional fields are fine | High |
| Layout | Can the block show the media position and column count (styles, variants)? | Medium |
| Cost of a new block | Would a new block duplicate one that only needs a style variant or one field? | Tie-breaker |
Always consider none: when the only candidates serve another purpose (a testimonial fits a hero's fields but is not a hero), choose scaffold with block: null.
Decision shape:
{ "action": "fill", "block": "acf/faq", "confidence": 0.85, "reason": "Questions and answers; the questions repeater holds the three items" }
Confidence: 0.9 or more when purpose and structure are clear; 0.6 to 0.9 with a caveat written in reason; below the plan's threshold (0.6) set "action": "ask" and ask the person.
Ask the person about every ask decision, listing the candidates and none. Record the answer as the decision with "approvedBy": "person".
Check: node <kivo-creator>/scripts/match.mjs --run=.creator/<run> --check --project=.. Fix every error it prints and run it again.
Show match-plan.md and stop. Emitting happens only after the person approves the plan.
match.mjs --check exits 0 and prints match plan ok.fill names a block from the catalog that is among the section's candidates (or was approved by the person).scaffold or gap has a reason a person can accept without opening the files.| Symptom | Cause | Fix |
|---|---|---|
Every section goes to scaffold | Catalog empty: blocks live outside the adapter's folder (ACF Composer classes in app/Blocks, block.json files under the app) | Run --catalog; if blocks are missing, check the profile in .roots-stack.json and the block folder |
A good block is missing from candidates | A slot type its fields cannot hold (for example an image slot and no image field) | Decide whether the slot matters; dropping it is the person's call, never yours |
did not pass the compatibility filter | A fill names a block that cannot hold all slots | Pick a candidate, or ask the person and record approvedBy |
confidence ... is below 0.6 | A low-confidence fill without approval | Ask the person; record approvedBy: "person" |
| Same block chosen for two different purposes | Purpose criterion skipped | Re-score with the rubric; purpose is decisive |
Ask the person whenever the decision is below the threshold, when two candidates are equally good, or when the right answer is a new style variant of an existing block instead of a new block.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
7 skills in this plugin
/block-scaffolding-from-designUse when an approved kivo-creator match plan must be emitted - writing the page as block markup, scaffolding the blocks that were missing in the project's conventions (run the project's generator first, then review and copy the prepared files), turning unmatched design values into token proposals and importing media. For deciding which block a section uses use section-matching; for checking the rendered result use visual-fidelity./code-connectUse when Figma components should point at the project's blocks and Blade components through Code Connect - reading the existing map, proposing new mappings from the block catalog, flagging components with no code counterpart, and sending mappings with send_code_connect_mappings only after the person approves the exact list. For reading a frame into specs use figma-ingest./creatorUse when the person runs the creator command to turn a Figma frame, an HTML file or a URL into a WordPress page on the Roots stack - routes the source, runs the ingest, builds and checks the match plan, and stops for approval before anything is emitted. Resumes a run with --run=.creator/<run>. For one step on its own use html-ingest, figma-ingest, section-matching, block-scaffolding-from-design or visual-fidelity./figma-ingestUse when a Figma frame URL has to become kivo-creator section specs - reading the frame through the official Figma MCP server in the main session (get_metadata for the tree, get_design_context per section, get_variable_defs for tokens, get_screenshot to look, get_code_connect_map for mapped components), writing exact or inferred values only, and stopping with connection steps when the server is missing. For HTML sources use html-ingest; for creating Code Connect mappings use code-connect./html-ingestUse when an HTML file, a URL or a published page has to become kivo-creator section specs - rendering it at 390 and 1440 px with the project's own Playwright, splitting it into sections, recording text slots, links, media, computed styles and one reference screenshot per section and width under .creator/<run>/. For a Figma source use figma-ingest; for choosing blocks use section-matching./visual-fidelityUse when a page emitted by kivo-creator must be proved against its design - rendering the block markup on the local site, screenshotting every section at 390 and 1440 px with the project's Playwright, pixel diff against the references (2 percent per section by default), style check of exact values, lint for arbitrary values and inline styles, and up to three fix rounds before handing the report to the person. For emitting the page use block-scaffolding-from-design.npx claudepluginhub hekivo/kivo-wise --plugin kivo-creatorOther plugins' skills for the same job