[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M77JSA2ZFHTNHAG4522S4QWE":3,"skill-same:01M77JSA2ZFHTNHAG4522S4QWE":45},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":18,"linkOnly":19,"markdownContent":20,"markdownBody":21,"frontMatter":22,"refName":23,"commitSha":24,"skillDirectory":25,"forksCount":26,"repositoryHtmlUrl":27,"repositoryHomepageUrl":28,"ownerHtmlUrl":29,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":30,"install":31,"resources":44},"01M77JSA2ZFHTNHAG4522S4QWE","retail-build-warehouse",null,"Author the silver + gold migration SQL for a mapped retail table from its APPROVED source-map, then STOP before executing. Use after a table's mapping gate is CLEARED in the Seshat BI repo and someone asks to build the silver\u002Fgold SQL, write the migration, or fill the retail-orchestrate build seam. Author-and-stop: it writes warehouse\u002Fmigrations\u002F*.sql FILES only, never connects to a database, never applies the SQL, and HARD-STOPS at any judgment call the map does not already answer.","Kemetra\u002FSeshat-BI","Kemetra","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F206601658?v=4","01M77J5APND9QAJK8XMBH5B1A8","01M77J5AR4TM1GN2G4GS5KH02J",2,"Apache-2.0","https:\u002F\u002Fgithub.com\u002FKemetra\u002FSeshat-BI\u002Fblob\u002Fmain\u002Fintegrations\u002Fcodex\u002Fseshat-bi\u002Fskills\u002Fretail-build-warehouse\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: retail-build-warehouse\ndescription: >-\n  Author the silver + gold migration SQL for a mapped retail table from its\n  APPROVED source-map, then STOP before executing. Use after a table's mapping\n  gate is CLEARED in the Seshat BI repo and someone asks to build the\n  silver\u002Fgold SQL, write the migration, or fill the retail-orchestrate build seam.\n  Author-and-stop: it writes warehouse\u002Fmigrations\u002F*.sql FILES only, never connects\n  to a database, never applies the SQL, and HARD-STOPS at any judgment call the map\n  does not already answer.\n---\n\n# retail-build-warehouse\n\nTurns an APPROVED `mappings\u002F\u003Ctable>\u002Fsource-map.yaml` into the two migration `.sql`\nfiles -- `silver` (typed\u002Fcleaned flat table) then `gold` (Kimball star) -- in the\norder the medallion playbook proves load-bearing. It fills the silver\u002Fgold\n`[SEAM]` the `retail-orchestrate` conductor parks at.\n\nThe agent is the runtime: this is a procedure you follow, authoring SQL by adapting\nthe proven `warehouse\u002Fmigrations\u002F0003`\u002F`0004` shape. There is NO codegen engine, NO\n`.sql.tmpl` template, and NO `retail build` CLI -- by design (the source-map cannot\ncarry the transform logic; an engine would emit only boilerplate). That is a\nrecorded design decision, not an omission to be fixed.\n\n## Author vs execute (read first)\n\n- **You AUTHOR `.sql` files. That is in-scope** -- writing reviewable migration text,\n  no side effects, the same category as `source-mapping` authoring `mappings\u002F`.\n- **You NEVER execute.** Do not open a DB connection, do not run the migration, do\n  not run the Phase-5 PK dry-run or the Phase-6 orphan\u002Freconcile checks -- those need\n  live data and are the deferred DB-write seam (creds + the `db` extra, Principle\n  VIII). Authoring -> static `seshat check` -> a HUMAN applies the SQL -> only then\n  `retail-validate`. Never claim the silver\u002Fgold tables exist or were validated.\n\n## Preconditions (STOP unless all hold)\n\n1. **Canonical gate signal:** `mappings\u002F\u003Ctable>\u002Freadiness-status.yaml` ->\n   `stages.mapping_ready.status == pass` WITH a matching `approvals[]` entry (RS1).\n   Its human-readable mirror `mappings\u002F\u003Ctable>\u002Funresolved-questions.md`\n   `Gate status: CLEARED` (ZERO open rows) MUST agree. A missing readiness-status\n   file, `mapping_ready != pass`, or a mismatch between the two -> STOP (Principle\n   IV). Never self-grant.\n2. `mappings\u002F\u003Ctable>\u002Fsource-map.yaml` parses and carries grain, primary_key, per\n   column type\u002Frename\u002Fdrop\u002Fpii\u002Fgold_placement, the gold_star, derived_columns.\n3. Read `assumptions.md` (the business literals the YAML cannot hold: junk-filter\n   list, CASE maps, is_return value set, sentinels, mojibake range) and\n   `source-profile.md` (row counts to annotate, the date span for the calendar).\n4. Pick the next contiguous migration number `NNNN` over `warehouse\u002Fmigrations\u002F` (S4a).\n5. **Adapter checkpoint -- surface the choice before writing SQL by hand.** Run\n   `seshat orchestration-assess` and REPORT its verdict to the human before\n   authoring migrations. This repo ships two transformation\u002Forchestration\n   adapters (dbt, Dagster); hand-written migrations are the default path, so\n   without this step they get bypassed silently rather than declined on purpose\n   (issue #489). The assessor is read-only: it emits a categorical verdict\n   (`consider` \u002F `not_recommended` \u002F `already_adopted`), never a numeric score,\n   and it never adopts anything. If it says `already_adopted`, prefer the adapter\n   over new hand-written SQL. If it says `consider`, state that and let the human\n   choose -- do NOT adopt an adapter on your own, and do NOT treat `consider` as\n   permission to skip authoring. If it says `not_recommended`, proceed here and\n   say so.\n\n## Silver: the load-bearing Phase-5 order (NUMBERED -- do NOT reorder)\n\nAuthor `warehouse\u002Fmigrations\u002FNNNN_create_silver_\u003Ctable>.sql`. The order is\nload-bearing; a reordering passes `seshat check` (the gate is order-blind) yet is\nWRONG. Transcribe in this exact sequence, adapting the proven `0003`:\n\n1. **`src` CTE -- TRIM every text column** (kills whitespace-variant phantom distincts).\n2. **Encoding\u002Fmojibake whitelist** on display columns (e.g. `regexp_replace(... keep\n   chr 32-126 + the domain's needed ranges ...)`), sourced from `assumptions.md`.\n3. **`filtered` CTE -- junk-row filters BEFORE `''`->NULL** (`WHERE col NOT IN (...,\n   '')`). MUST come before step 4 -- once `''` becomes NULL, `IN ('')` stops matching.\n4. **`''`->NULL** via `NULLIF(trim(x), '')` (folded into the casts below).\n5. **Casts** via `NULLIF(trim(x), '')::type` -- money\u002Fqty `numeric`, dates `date`,\n   leading-zero ids stay `TEXT`, ordinals `smallint` (RC7).\n6. **Numeric-based row filters on the CAST value, not text** (`'0.0' \u003C> '0'`).\n7. **Derived columns** -- is_return from the AUTHORITATIVE column (never the measure\n   sign), business rollups with `ELSE 'UNMAPPED'`.\n8. **Sentinel UPDATEs** after the SELECT -- fill grouping-dim text NULLs with the\n   `assumptions.md` sentinel; leave fact NULLs as NULL.\n\nWrap: `SET client_encoding TO 'UTF8'; BEGIN; CREATE SCHEMA IF NOT EXISTS silver;\nDROP TABLE IF EXISTS silver.\u003Ct>; CREATE TABLE silver.\u003Ct> AS WITH ... SELECT ...;`\nthen the sentinel UPDATEs, then `ALTER TABLE ... ADD PRIMARY KEY (...)`, then\n`CREATE INDEX ...`, then `COMMIT;`. Bare DROP+CREATE in one txn (S4b layer-aware\nallows this for derived silver\u002Fgold). UTF-8 no BOM. Write the file in ONE Write call.\n\nFlag `ADD PRIMARY KEY` as **UNVERIFIED-UNTIL-APPLIED**: PK uniqueness is only\nprovable on transformed data (the live dry-run), which is the deferred seam.\n\n## Gold: the Kimball star (Phase 6)\n\nAuthor `warehouse\u002Fmigrations\u002FNNNN+1_create_gold_\u003Ctable>_star.sql`, adapting `0004`:\n- One fact at silver grain + one conformed dim per business entity.\n- Surrogate `_sk` (`GENERATED BY DEFAULT AS IDENTITY`); keep natural keys as attrs.\n- **Unknown member at `_sk = -1`** in every ENTITY dim (`INSERT ... OVERRIDING\n  SYSTEM VALUE VALUES (-1, ...)`), then real rows collapsed 1:1 by natural key\n  (`GROUP BY`). The DATE dim is the EXCEPTION -- see the `dim_date` bullet below;\n  S6 (ERROR) requires the member on entity dims, S8 (ERROR) FORBIDS it on the date\n  dim, so \"every dim\" without the carve-out authors SQL the gate rejects.\n- Fact FK columns `COALESCE(d.x_sk, -1)` via LEFT JOIN -- for ENTITY dims only.\n  NEVER `COALESCE(dd.date_sk, -1)`: a real out-of-span date would be silently\n  bucketed to Unknown while the coverage checks stay green (RC19). Leave the date\n  FK bare and let `NOT NULL` reject the unmatched row.\n- Transaction ids with no attributes -> **degenerate dims on the fact**, not a dim.\n- **`dim_date` = contiguous `generate_series(from, to, '1 day')`** over the map's\n  date span -- NEVER `SELECT DISTINCT date` (S7; missing days break time-intel).\n  It carries **NO `-1`\u002FNULL unknown member** (S8, ERROR): it becomes a marked date\n  table (`dataCategory: Time`), which Power BI validates as unique\u002Fcontiguous\u002Fno-\n  nulls, so a `-1` member breaks refresh and time-intelligence even though the SQL\n  succeeds and every other check stays green.\n- FK constraints + FK indexes AFTER load (so `-1` members and rows exist first).\n- Idempotent: drop fact before dims (FK order), recreate all in one txn.\n\n## Judgment stops (fail LOUD -- never satisfy with a silent default)\n\nSTOP and raise an `unresolved-questions.md` row (do not guess) if:\n- `stages.mapping_ready.status` != `pass` (or its `approvals[]` entry is absent), or\n  the `Gate status: CLEARED` mirror does not agree, or any open row remains.\n- A column's `silver_type` \u002F `missing_policy` \u002F `gold_placement` is missing or\n  ambiguous -> never guess a type or invent a placement.\n- The junk-filter `NOT IN (...)` values are not pinned in `assumptions.md`.\n- The authoritative returns column \u002F the `is_return` value list is absent -> never\n  derive is_return from a measure sign (RC8).\n- A categorical\u002Fbilling CASE map or business rollup is incomplete -> only\n  `ELSE 'UNMAPPED'` is an allowed sentinel; never invent an arm.\n- A sentinel is requested but its 0-collision safety was not verified (RC6).\n- The `dim_date` span is absent -> never hardcode a guessed calendar range.\n- A `pii: true` column is not `decision: drop`.\n- A dim `max()`\u002F`GROUP BY` 1:1 collapse where the map did not confirm id->attribute\n  is 1:1 (max() silently picks one value if it is actually 1:many).\n\n## After authoring (the handoff)\n\n1. Run `seshat check` (static, local, no DB) -- the authored SQL must exit 0. The\n   SQL family is S1, S2, S3, S4a, S4b, S5, S6, S7, S8 (there is no bare \"S4\", and\n   S8 is real -- do not cite the family as a \"S1-S7\" range).\n2. **Self-review the order:** diff your silver SQL against the numbered checklist\n   above. The checker is order-blind; this manual step is the only catch for a\n   reordering bug (e.g. `''`->NULL before the junk filter).\n3. Print the apply command and the sequence, then STOP:\n   `psql \"$DATABASE_URL\" -f warehouse\u002Fmigrations\u002FNNNN_create_silver_\u003Ctable>.sql`\n   then the gold file, in numeric order. Then `retail validate --source-map\n   mappings\u002F\u003Ctable>\u002Fsource-map.yaml`.\n\n**`seshat check` exit 0 is NECESSARY, not SUFFICIENT.** It proves form (snake_case,\nschemas, idempotent shape, `-1` member present, generate_series used). It does NOT\nprove correctness -- right row count, no sentinel collision, complete enums, penny\nreconciliation. That is proven ONLY by the live `retail-validate` after a human\napplies the SQL. Say this in your handoff; do not let green read as \"correct\".\n\n## Orchestration\n\n`retail-orchestrate` invokes this skill at its silver\u002Fgold build phase (the `[SEAM]`\nit previously only parked at). This skill still STOPS at the execute boundary -- the\nconductor does not apply SQL either; a human applies, then the conductor resumes at\n`retail-validate`. The self-heal loop lives in `retail-orchestrate`, not here.\n\n## See also\n\n- The conductor: the `retail-orchestrate` skill.\n- The method + skeletons: the medallion playbook, Phase 5\u002F6 + Appendix A\u002FB.\n- The proven reference: `warehouse\u002Fmigrations\u002F0003_create_silver_retail_store_sales.sql`,\n  `0004_create_gold_retail_store_sales_star.sql`.\n- The approved input: `mappings\u002F\u003Ctable>\u002F` (e.g. the filled `mappings\u002Fretail_store_sales\u002F`).\n- The live half (after a human applies): the `retail-validate` skill.\n","# retail-build-warehouse\n\nTurns an APPROVED `mappings\u002F\u003Ctable>\u002Fsource-map.yaml` into the two migration `.sql`\nfiles -- `silver` (typed\u002Fcleaned flat table) then `gold` (Kimball star) -- in the\norder the medallion playbook proves load-bearing. It fills the silver\u002Fgold\n`[SEAM]` the `retail-orchestrate` conductor parks at.\n\nThe agent is the runtime: this is a procedure you follow, authoring SQL by adapting\nthe proven `warehouse\u002Fmigrations\u002F0003`\u002F`0004` shape. There is NO codegen engine, NO\n`.sql.tmpl` template, and NO `retail build` CLI -- by design (the source-map cannot\ncarry the transform logic; an engine would emit only boilerplate). That is a\nrecorded design decision, not an omission to be fixed.\n\n## Author vs execute (read first)\n\n- **You AUTHOR `.sql` files. That is in-scope** -- writing reviewable migration text,\n  no side effects, the same category as `source-mapping` authoring `mappings\u002F`.\n- **You NEVER execute.** Do not open a DB connection, do not run the migration, do\n  not run the Phase-5 PK dry-run or the Phase-6 orphan\u002Freconcile checks -- those need\n  live data and are the deferred DB-write seam (creds + the `db` extra, Principle\n  VIII). Authoring -> static `seshat check` -> a HUMAN applies the SQL -> only then\n  `retail-validate`. Never claim the silver\u002Fgold tables exist or were validated.\n\n## Preconditions (STOP unless all hold)\n\n1. **Canonical gate signal:** `mappings\u002F\u003Ctable>\u002Freadiness-status.yaml` ->\n   `stages.mapping_ready.status == pass` WITH a matching `approvals[]` entry (RS1).\n   Its human-readable mirror `mappings\u002F\u003Ctable>\u002Funresolved-questions.md`\n   `Gate status: CLEARED` (ZERO open rows) MUST agree. A missing readiness-status\n   file, `mapping_ready != pass`, or a mismatch between the two -> STOP (Principle\n   IV). Never self-grant.\n2. `mappings\u002F\u003Ctable>\u002Fsource-map.yaml` parses and carries grain, primary_key, per\n   column type\u002Frename\u002Fdrop\u002Fpii\u002Fgold_placement, the gold_star, derived_columns.\n3. Read `assumptions.md` (the business literals the YAML cannot hold: junk-filter\n   list, CASE maps, is_return value set, sentinels, mojibake range) and\n   `source-profile.md` (row counts to annotate, the date span for the calendar).\n4. Pick the next contiguous migration number `NNNN` over `warehouse\u002Fmigrations\u002F` (S4a).\n5. **Adapter checkpoint -- surface the choice before writing SQL by hand.** Run\n   `seshat orchestration-assess` and REPORT its verdict to the human before\n   authoring migrations. This repo ships two transformation\u002Forchestration\n   adapters (dbt, Dagster); hand-written migrations are the default path, so\n   without this step they get bypassed silently rather than declined on purpose\n   (issue #489). The assessor is read-only: it emits a categorical verdict\n   (`consider` \u002F `not_recommended` \u002F `already_adopted`), never a numeric score,\n   and it never adopts anything. If it says `already_adopted`, prefer the adapter\n   over new hand-written SQL. If it says `consider`, state that and let the human\n   choose -- do NOT adopt an adapter on your own, and do NOT treat `consider` as\n   permission to skip authoring. If it says `not_recommended`, proceed here and\n   say so.\n\n## Silver: the load-bearing Phase-5 order (NUMBERED -- do NOT reorder)\n\nAuthor `warehouse\u002Fmigrations\u002FNNNN_create_silver_\u003Ctable>.sql`. The order is\nload-bearing; a reordering passes `seshat check` (the gate is order-blind) yet is\nWRONG. Transcribe in this exact sequence, adapting the proven `0003`:\n\n1. **`src` CTE -- TRIM every text column** (kills whitespace-variant phantom distincts).\n2. **Encoding\u002Fmojibake whitelist** on display columns (e.g. `regexp_replace(... keep\n   chr 32-126 + the domain's needed ranges ...)`), sourced from `assumptions.md`.\n3. **`filtered` CTE -- junk-row filters BEFORE `''`->NULL** (`WHERE col NOT IN (...,\n   '')`). MUST come before step 4 -- once `''` becomes NULL, `IN ('')` stops matching.\n4. **`''`->NULL** via `NULLIF(trim(x), '')` (folded into the casts below).\n5. **Casts** via `NULLIF(trim(x), '')::type` -- money\u002Fqty `numeric`, dates `date`,\n   leading-zero ids stay `TEXT`, ordinals `smallint` (RC7).\n6. **Numeric-based row filters on the CAST value, not text** (`'0.0' \u003C> '0'`).\n7. **Derived columns** -- is_return from the AUTHORITATIVE column (never the measure\n   sign), business rollups with `ELSE 'UNMAPPED'`.\n8. **Sentinel UPDATEs** after the SELECT -- fill grouping-dim text NULLs with the\n   `assumptions.md` sentinel; leave fact NULLs as NULL.\n\nWrap: `SET client_encoding TO 'UTF8'; BEGIN; CREATE SCHEMA IF NOT EXISTS silver;\nDROP TABLE IF EXISTS silver.\u003Ct>; CREATE TABLE silver.\u003Ct> AS WITH ... SELECT ...;`\nthen the sentinel UPDATEs, then `ALTER TABLE ... ADD PRIMARY KEY (...)`, then\n`CREATE INDEX ...`, then `COMMIT;`. Bare DROP+CREATE in one txn (S4b layer-aware\nallows this for derived silver\u002Fgold). UTF-8 no BOM. Write the file in ONE Write call.\n\nFlag `ADD PRIMARY KEY` as **UNVERIFIED-UNTIL-APPLIED**: PK uniqueness is only\nprovable on transformed data (the live dry-run), which is the deferred seam.\n\n## Gold: the Kimball star (Phase 6)\n\nAuthor `warehouse\u002Fmigrations\u002FNNNN+1_create_gold_\u003Ctable>_star.sql`, adapting `0004`:\n- One fact at silver grain + one conformed dim per business entity.\n- Surrogate `_sk` (`GENERATED BY DEFAULT AS IDENTITY`); keep natural keys as attrs.\n- **Unknown member at `_sk = -1`** in every ENTITY dim (`INSERT ... OVERRIDING\n  SYSTEM VALUE VALUES (-1, ...)`), then real rows collapsed 1:1 by natural key\n  (`GROUP BY`). The DATE dim is the EXCEPTION -- see the `dim_date` bullet below;\n  S6 (ERROR) requires the member on entity dims, S8 (ERROR) FORBIDS it on the date\n  dim, so \"every dim\" without the carve-out authors SQL the gate rejects.\n- Fact FK columns `COALESCE(d.x_sk, -1)` via LEFT JOIN -- for ENTITY dims only.\n  NEVER `COALESCE(dd.date_sk, -1)`: a real out-of-span date would be silently\n  bucketed to Unknown while the coverage checks stay green (RC19). Leave the date\n  FK bare and let `NOT NULL` reject the unmatched row.\n- Transaction ids with no attributes -> **degenerate dims on the fact**, not a dim.\n- **`dim_date` = contiguous `generate_series(from, to, '1 day')`** over the map's\n  date span -- NEVER `SELECT DISTINCT date` (S7; missing days break time-intel).\n  It carries **NO `-1`\u002FNULL unknown member** (S8, ERROR): it becomes a marked date\n  table (`dataCategory: Time`), which Power BI validates as unique\u002Fcontiguous\u002Fno-\n  nulls, so a `-1` member breaks refresh and time-intelligence even though the SQL\n  succeeds and every other check stays green.\n- FK constraints + FK indexes AFTER load (so `-1` members and rows exist first).\n- Idempotent: drop fact before dims (FK order), recreate all in one txn.\n\n## Judgment stops (fail LOUD -- never satisfy with a silent default)\n\nSTOP and raise an `unresolved-questions.md` row (do not guess) if:\n- `stages.mapping_ready.status` != `pass` (or its `approvals[]` entry is absent), or\n  the `Gate status: CLEARED` mirror does not agree, or any open row remains.\n- A column's `silver_type` \u002F `missing_policy` \u002F `gold_placement` is missing or\n  ambiguous -> never guess a type or invent a placement.\n- The junk-filter `NOT IN (...)` values are not pinned in `assumptions.md`.\n- The authoritative returns column \u002F the `is_return` value list is absent -> never\n  derive is_return from a measure sign (RC8).\n- A categorical\u002Fbilling CASE map or business rollup is incomplete -> only\n  `ELSE 'UNMAPPED'` is an allowed sentinel; never invent an arm.\n- A sentinel is requested but its 0-collision safety was not verified (RC6).\n- The `dim_date` span is absent -> never hardcode a guessed calendar range.\n- A `pii: true` column is not `decision: drop`.\n- A dim `max()`\u002F`GROUP BY` 1:1 collapse where the map did not confirm id->attribute\n  is 1:1 (max() silently picks one value if it is actually 1:many).\n\n## After authoring (the handoff)\n\n1. Run `seshat check` (static, local, no DB) -- the authored SQL must exit 0. The\n   SQL family is S1, S2, S3, S4a, S4b, S5, S6, S7, S8 (there is no bare \"S4\", and\n   S8 is real -- do not cite the family as a \"S1-S7\" range).\n2. **Self-review the order:** diff your silver SQL against the numbered checklist\n   above. The checker is order-blind; this manual step is the only catch for a\n   reordering bug (e.g. `''`->NULL before the junk filter).\n3. Print the apply command and the sequence, then STOP:\n   `psql \"$DATABASE_URL\" -f warehouse\u002Fmigrations\u002FNNNN_create_silver_\u003Ctable>.sql`\n   then the gold file, in numeric order. Then `retail validate --source-map\n   mappings\u002F\u003Ctable>\u002Fsource-map.yaml`.\n\n**`seshat check` exit 0 is NECESSARY, not SUFFICIENT.** It proves form (snake_case,\nschemas, idempotent shape, `-1` member present, generate_series used). It does NOT\nprove correctness -- right row count, no sentinel collision, complete enums, penny\nreconciliation. That is proven ONLY by the live `retail-validate` after a human\napplies the SQL. Say this in your handoff; do not let green read as \"correct\".\n\n## Orchestration\n\n`retail-orchestrate` invokes this skill at its silver\u002Fgold build phase (the `[SEAM]`\nit previously only parked at). This skill still STOPS at the execute boundary -- the\nconductor does not apply SQL either; a human applies, then the conductor resumes at\n`retail-validate`. The self-heal loop lives in `retail-orchestrate`, not here.\n\n## See also\n\n- The conductor: the `retail-orchestrate` skill.\n- The method + skeletons: the medallion playbook, Phase 5\u002F6 + Appendix A\u002FB.\n- The proven reference: `warehouse\u002Fmigrations\u002F0003_create_silver_retail_store_sales.sql`,\n  `0004_create_gold_retail_store_sales_star.sql`.\n- The approved input: `mappings\u002F\u003Ctable>\u002F` (e.g. the filled `mappings\u002Fretail_store_sales\u002F`).\n- The live half (after a human applies): the `retail-validate` skill.\n",{"name":5,"description":7},"main","6266e304556a72b75d951b9433fd833481c61233","integrations\u002Fcodex\u002Fseshat-bi\u002Fskills\u002Fretail-build-warehouse",0,"https:\u002F\u002Fgithub.com\u002FKemetra\u002FSeshat-BI","https:\u002F\u002Fpypi.org\u002Fproject\u002Fseshat-bi\u002F","https:\u002F\u002Fgithub.com\u002FKemetra","2026-11-11 21:44:25",{"source":8,"skillName":5,"commands":32,"prompt":42,"zipAvailable":43},[33,36,39],{"tool":34,"command":35},"npx","npx skills add Kemetra\u002FSeshat-BI --skill retail-build-warehouse",{"tool":37,"command":38},"bunx","bunx skills add Kemetra\u002FSeshat-BI --skill retail-build-warehouse",{"tool":40,"command":41},"pnpm","pnpm dlx skills add Kemetra\u002FSeshat-BI --skill retail-build-warehouse","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FKemetra\u002FSeshat-BI\u002Fblob\u002Fmain\u002Fintegrations\u002Fcodex\u002Fseshat-bi\u002Fskills\u002Fretail-build-warehouse\u002FSKILL.md",true,[],[46,53,58,64,69,76],{"skillNo":47,"name":48,"nameZh":6,"description":49,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":50,"categories":51,"keywords":52,"publishedAt":18},"01M77JWCTJ88JWPDD25WZ2NEY8","fake-skill","A fixture skill with declaring frontmatter, used as positive shipped evidence.","https:\u002F\u002Fgithub.com\u002FKemetra\u002FSeshat-BI\u002Fblob\u002Fmain\u002Ftests\u002Funit\u002Ffixtures\u002Fcapability_inventory\u002Funlisted\u002F.claude\u002Fskills\u002Ffake-skill\u002FSKILL.md",[],[],{"skillNo":54,"name":48,"nameZh":6,"description":49,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":55,"categories":56,"keywords":57,"publishedAt":18},"01M77JWA0BTG4JB2HR52Q99216","https:\u002F\u002Fgithub.com\u002FKemetra\u002FSeshat-BI\u002Fblob\u002Fmain\u002Ftests\u002Funit\u002Ffixtures\u002Fcapability_inventory\u002Forphan\u002F.claude\u002Fskills\u002Ffake-skill\u002FSKILL.md",[],[],{"skillNo":59,"name":60,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":61,"categories":62,"keywords":63,"publishedAt":18},"01M77JW6VE59XEFHWBTNDYAS2Q","bare-skill-no-frontmatter","https:\u002F\u002Fgithub.com\u002FKemetra\u002FSeshat-BI\u002Fblob\u002Fmain\u002Ftests\u002Funit\u002Ffixtures\u002Fcapability_inventory\u002Forphan\u002F.claude\u002Fskills\u002Fbare-skill-no-frontmatter\u002FSKILL.md",[],[],{"skillNo":65,"name":48,"nameZh":6,"description":49,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":66,"categories":67,"keywords":68,"publishedAt":18},"01M77JW4TD1FNFSBNP5C0WXAA5","https:\u002F\u002Fgithub.com\u002FKemetra\u002FSeshat-BI\u002Fblob\u002Fmain\u002Ftests\u002Funit\u002Ffixtures\u002Fcapability_inventory\u002Fgood\u002F.claude\u002Fskills\u002Ffake-skill\u002FSKILL.md",[],[],{"skillNo":70,"name":71,"nameZh":6,"description":72,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":73,"categories":74,"keywords":75,"publishedAt":18},"01M77JVWCVE3WZ82ZNFCSFVDCP","retail-kpi-knowledge","Retail KPI \u002F metric-contract reasoning layer for BI agents in the Seshat BI project. Use when an agent must reason about the BUSINESS MEANING of a retail KPI before any implementation — defining a KPI in business terms, classifying additivity (fully\u002Fsemi\u002Fnon-additive), identifying grain, listing required source fields, resolving ambiguity (gross vs net, VAT, returns, cost method, same-store), choosing an MVP KPI pack, reviewing a metric contract for completeness, or preparing a clean handoff to an implementation layer. Also use it to classify KPI sufficiency or prepare an owner policy decision packet. This is a meaning\u002Fdefinition + review layer, not an executor: it does not write DAX\u002FSQL\u002FPython, grant readiness, approve policy, or design dashboards. See INDEX.md for live\u002Fplanned routes; registry.yaml is the authoritative machine-readable inventory.","https:\u002F\u002Fgithub.com\u002FKemetra\u002FSeshat-BI\u002Fblob\u002Fmain\u002Fskills\u002Fretail-kpi-knowledge\u002FSKILL.md",[],[],{"skillNo":77,"name":78,"nameZh":6,"description":79,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":80,"categories":81,"keywords":82,"publishedAt":18},"01M77JVNDM1NGYGSCPTBW9ZCF5","bi-sql-knowledge","SQL reasoning, validation, reconciliation, transformation, diagnostics, and anti-pattern knowledge layer for Seshat BI agents. Use when a task involves reasoning about source SQL: source profiling, table grain, keys & uniqueness, joins & fan-out amplification, aggregation correctness, COUNT\u002FNULL semantics, deduplication, validation queries, reconciliation queries, silver\u002Fgold transformation logic, window\u002Fdate-time analytics, SQL anti-patterns, or basic SQL performance reasoning, or interpretation of a supplied sanitized PostgreSQL JSON execution plan. The SQL counterpart to bi-dax-knowledge. It is a thinking & validation layer, not a database executor, runtime validator, dbt\u002FDagster project, or automatic tuning service.","https:\u002F\u002Fgithub.com\u002FKemetra\u002FSeshat-BI\u002Fblob\u002Fmain\u002Fskills\u002Fbi-sql-knowledge\u002FSKILL.md",[],[]]