[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M77K3YNT7BZ7J8D93M5B2KQD":3,"skill-same:01M77K3YNT7BZ7J8D93M5B2KQD":72},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":30,"commitSha":31,"skillDirectory":32,"forksCount":33,"repositoryHtmlUrl":34,"repositoryHomepageUrl":6,"ownerHtmlUrl":35,"ownerBlogUrl":36,"ownerDescription":37,"updatedAt":38,"install":39,"resources":51},"01M77K3YNT7BZ7J8D93M5B2KQD","map-data",null,"Entity-relationship diagram from committed schema declarations, with no database connection: Prisma models win over a stated subset of Entity Framework fluent mappings, which win over SQL migrations read from a stated subset of statements, and a disagreement is reported. Use when 'map data', 'ERD', 'entity relationship', 'schema diagram', 'cardinality from mappings', or 'which tables relate'. Skip when the question is deployment topology, runtime state, or data volume.","melodic-software\u002Fclaude-code-plugins","melodic-software","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F58273638?v=4","01M77JVQTXNGKCE4MDFY2BC936","Melodic Software","01M77JVQVN9QDWKAH6W03ANP76",30,"MIT","https:\u002F\u002Fgithub.com\u002Fmelodic-software\u002Fclaude-code-plugins\u002Fblob\u002Fmain\u002Fplugins\u002Farchitecture\u002Fskills\u002Fmap-data\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\ndescription: \"Entity-relationship diagram from committed schema declarations, with no database connection: Prisma models win over a stated subset of Entity Framework fluent mappings, which win over SQL migrations read from a stated subset of statements, and a disagreement is reported. Use when 'map data', 'ERD', 'entity relationship', 'schema diagram', 'cardinality from mappings', or 'which tables relate'. Skip when the question is deployment topology, runtime state, or data volume.\"\nargument-hint: \"[--scope module|all|\u003Cmodule>] [--include-columns] [--dialect mermaid|dbml] [--out \u003Cdir>]\"\nuser-invocable: true\ndisable-model-invocation: false\nshell: bash\nmetadata:\n  workflow-stage: explore\n  summary: Draw an ERD from a committed schema, offline\n---\n\n## Repository context\n\nThe current repository is both the CONSUMER, whose convention home declares where artifacts land,\nand the DEFAULT SUBJECT, whose tracked files declare the schema.\n\nCollect with an **individual** Bash call, one command per call: the project root,\n`git rev-parse --show-toplevel`. Treat a failure (not a repository, git unavailable) as an unknown\nvalue and carry on; `${CLAUDE_PROJECT_DIR}` is the resolver's `--root` either way.\n\n## Purpose\n\nAnswer \"what are the entities and how do they relate\" from declarations in the tree. Every entity\nand every cardinality traces to a named file. The scripts collect and render. Do not draw a box the\nscript did not emit, and do not invent a cardinality the script did not record.\n\nThis is not a C4 diagram: an entity-relationship diagram is not one of the C4 views (the record\nis under Gotchas).\n\n## Resolve home and dialect\n\nRead `${CLAUDE_PLUGIN_ROOT}\u002Freference\u002Fconfig.md` first. This skill writes into `architecture_dir`.\nIt does not read `landscape_dialect` and adds no dialect key: the diagram dialect is\n`diagram_dialect.data` from the authoring-formats topic doc.\n\nRun `bash \"${CLAUDE_PLUGIN_ROOT}\u002Flib\u002Fresolve-convention-home.sh\" --root \"${CLAUDE_PROJECT_DIR}\"` and\nfollow the exit code; never parse the root instruction file yourself. Exit 0: read\n`\u003Chome>\u002Farchitecture\u002FREADME.md` for `architecture_dir`. Exit 1, 2, or 3: no declared home.\n\nPer key, in order: `--out \u003Cdir>` wins for this run alone, then a declared `architecture_dir`, then\none question. `architecture_dir` has NO default. An undeclared and unconfirmed home, including\nevery non-interactive run, STOPS and points at `\u002Farchitecture:setup`. Do not invent a directory.\n\nResolve `diagram_dialect.data` by restating this ladder, then running the resolver rather than\nparsing the topic doc yourself. The ladder is a resolution order, not a task list:\n\n```markdown\n1. Anchor at the repository root: `${CLAUDE_PROJECT_DIR}` when set, otherwise\n   `git rev-parse --show-toplevel`. Never a CWD-relative read.\n2. Resolve the convention home `\u003Chome>` with the bundled resolver above. Never hand-parse the root\n   file.\n3. The printed home is repo-relative: join it to the root, then pass\n   `\u003Croot>\u002F\u003Chome>\u002Fauthoring-formats\u002FREADME.md` to the resolver.\n4. Layer order is one layer deep: an explicit `--dialect` argument, then the team convention doc,\n   then the documented default `mermaid`. There is no personal override.\n5. Default: `diagram_dialect.data` is `mermaid`. Allowed values are `mermaid` and `dbml`.\n6. Degrade soft, and say so. No pointer, no doc, no key, or an unrecognized value each resolve to\n   `mermaid`. The resolver names the cause on stderr. Do not hard-fail and do not ask the operator\n   to create the surface mid-task.\n7. Report provenance: the key, the value, and the layer (`argument`, `team convention doc \u003Cpath>`,\n   or `default`).\n```\n\n```bash\nbash \"${CLAUDE_PLUGIN_ROOT}\u002Flib\u002Fresolve-diagram-dialect.sh\" --kind data \\\n  --formats \"\u003Croot>\u002F\u003Chome>\u002Fauthoring-formats\u002FREADME.md\"\n```\n\nOmit `--formats` when no convention home resolved. Stdout is `mermaid` or `dbml`. An explicit\n`--dialect` on the invocation wins and the resolver is not required.\n\nThis skill never writes the consumer's root instruction file or its topic doc.\n\n## Build the record\n\n```bash\n\"${CLAUDE_SKILL_DIR}\u002Fscripts\u002Fcollect-data.sh\" \\\n  --repo \"\u003Csubject-repo>\" --out \"\u003Carchitecture_dir>\u002Fdata-model.json\" \\\n  --generated-on \"\u003CYYYY-MM-DD|unknown>\"\n```\n\nPass `--generated-on` from `git -C \u003Croot> log -1 --format=%cs`, or `unknown` when that fails.\nPass `--live` only when the invocation asked for a live connection: the script opens none, writes a\nrefusal, and does not read the schema.\n\nThe record is schema_version 1, one object per line. `status` is `drawn` or `refused`; a refusal\nnames `reason` and writes no relationships. Shipped tiers, first present wins the diagram:\n\n- **model \u002F prisma.** `*.prisma` model blocks.\n- **orm \u002F ef-fluent.** A stated subset of one-to-many and one-to-one chains. The chain starts at\n  `Entity\u003CT>()` or, in a file that declares exactly one `class X : IEntityTypeConfiguration\u003CT>`\n  (also among several base types), at the `Configure` builder parameter. `HasOne`\u002F`HasMany` take a\n  generic argument or, for one-to-many, a lambda navigation (`HasMany(e => e.Posts).WithOne(e => e.Blog)`,\n  `HasOne(e => e.Blog).WithMany(e => e.Posts)`); the navigation's target comes from the property\n  declared on the configured entity's class in the scanned `.cs` files (`ICollection`, `List`,\n  `IList`, `IEnumerable` or `HashSet` of one identifier for a collection, `T` or `T?` for a\n  reference). `HasForeignKey` and `HasPrincipalKey` take one string literal or one single-member\n  lambda. Requiredness is an explicit `IsRequired()`, `IsRequired(true)` or `IsRequired(false)`;\n  with none, it is the foreign-key property's declared type on the dependent class: `T?`,\n  `Nullable\u003CT>` and `string?` are optional, and `int`, `uint`, `long`, `ulong`, `short`, `ushort`,\n  `byte`, `sbyte`, `Guid`, `DateTime` and `DateTimeOffset` are required.\n- **migration \u002F sql-migration.** `*.sql` under a `migrations` directory at any depth, including one\n  at the repository root, replayed in path order. The readable statements are `CREATE TABLE`\n  (with inline `REFERENCES`, table-level `FOREIGN KEY`, `UNIQUE` and `PRIMARY KEY`),\n  `CREATE UNIQUE INDEX`, `DROP INDEX`, `DROP TABLE`, and `ALTER TABLE` with `ADD COLUMN`,\n  `DROP COLUMN`, `ADD [CONSTRAINT n] FOREIGN KEY | UNIQUE | PRIMARY KEY`, and `DROP CONSTRAINT`\n  naming a constraint the migrations declared. Any other `ALTER TABLE` action (`RENAME`,\n  `ALTER COLUMN`, a `DROP CONSTRAINT` it cannot map) refuses the tier with `sql-alter-unreadable`.\n\nA second shipped tier that disagrees becomes a mismatch row. The diagram stays on the winning tier.\nA tier that loses and cannot be read (an EF chain outside the subset, an unreadable migration) does\nnot refuse the record: it is left out of the comparison and listed as a `not-compared` row.\nDjango models, SQLAlchemy columns, EF `[ForeignKey]` annotations, and a Prisma many-to-many with no\n`fields:` list refuse the record (`partial-read` or a named reason), as does an EF chain outside the\nsubset when EF is the winning tier (`ef-fluent-unreadable`), a migration outside the subset when\nSQL is the winning tier (`sql-alter-unreadable`), and a composite foreign key with no unique column\nset inside it (`unknown-cardinality`). A shipped diagram beside an unread mechanism would be a\npartial read.\n\nA module is the first path segment of the declaring file, or `.` at the repository root. It is\nlisted only when the winning tier declares an entity in it.\n\n## Render\n\n```bash\n\"${CLAUDE_SKILL_DIR}\u002Fscripts\u002Frender-data.sh\" \\\n  --record \"\u003Carchitecture_dir>\u002Fdata-model.json\" --out \"\u003Carchitecture_dir>\" \\\n  --dialect \"\u003Cmermaid|dbml>\" --scope \"\u003Cmodule|all|id>\"\n```\n\nAdd `--include-columns` only when the invocation asked for columns. The default scope is `module`:\none module is drawn; several modules write a refusal that lists them and the script exits 3. Draw\nnothing until the operator passes `--scope \u003Cid>` or `--scope all`. In a non-interactive run, stop\nafter that refusal. Do not pick a module. With more than one module in scope, every node is named\n`module\u002FEntity`, so `orders\u002FUser` and `billing\u002FUser` stay two nodes.\n\nMermaid writes an `erDiagram` inside `data-model.md`. DBML writes `data-model.dbml` and points at\nit from `data-model.md`. Column names and types appear in the diagram only with `--include-columns`;\nthe relationship list and the mismatch list are not a column dump.\n\nThe script prints one summary line. Keep it:\n\n`data: status=\u003Cdrawn|refused> reason=\u003Creason|none> tier=\u003Ctier> tool=\u003Ctool> modules=\u003Cn> entities=\u003Cn> relationships=\u003Cn> mismatches=\u003Cn> columns=\u003Cyes|no> dialect=\u003Cmermaid|dbml> scope=\u003Cid|all|unresolved|none>`\n\nExit 1 means the record is unreadable or not schema_version 1 in the one-object-per-line layout;\nnothing was written. Report that message. Do not reformat the record by hand.\n\n## Close with the report\n\nEnd every run with this block, in this order:\n\n- **Artifacts**: each path written, or `none written` when the run stopped before a home existed.\n- **Status**: `drawn` or `refused`, and the reason when it is a refusal.\n- **Source**: the tier and the tool, quoted from the summary, or `none` on a refusal.\n- **Dialect**: `mermaid` or `dbml`, and the layer it came from.\n- **Scope**: the module, `all`, or `unresolved` with the module list.\n- **Columns**: omitted, or included.\n- **Mismatches**: the count. A mismatch is reported, not silently resolved.\n- **Live**: not requested, or requested and refused. No connection was opened.\n\n## Interactive view\n\nAfter the report, offer an interactive view of `data-model.json` in one sentence. The markdown and\nthe record stay authoritative. Build it only with `${CLAUDE_PLUGIN_ROOT}\u002Fscripts\u002Fbuild-view.mjs data`,\nnever hand-written; the shared medium resolver decides the destination, with this plugin's `medium`\noption `${user_config.medium}`, or `\"\"` when that reads empty or unsubstituted (never put a\n`${user_config.*}` string in a shell command), and its report line is printed. Procedure:\n[`${CLAUDE_PLUGIN_ROOT}\u002Freference\u002Frendered-view.md`](${CLAUDE_PLUGIN_ROOT}\u002Freference\u002Frendered-view.md).\n\n## What this skill does NOT do\n\n- Open a database connection, read production data, or compare live rows to the declaration.\n- Indexes, data volumes, query plans, lineage, or ETL.\n- A C4 view, or a new dialect key. The dialect is the existing `diagram_dialect.data`.\n- Adapters other than Prisma models, the EF fluent subset above, and the SQL statements listed\n  above. Other mechanisms refuse. Within EF, these refuse: a composite key, `HasOne(lambda)` paired\n  with `WithOne`, a navigation with no single declared type (an expression-bodied property, a\n  positional record member, an undeclared name), two declarations of one class property in the\n  same module, a file with zero or several `IEntityTypeConfiguration\u003CT>` classes, an `IsRequired`\n  argument other than `true` or `false`, and, when `IsRequired` is absent, a foreign key that is\n  undeclared or has a plain `string`, enum or other type, because its nullability depends on the\n  project's nullable setting. A `[ForeignKey]` annotation is not read.\n- Guess a cardinality the declaration does not state. Implicit Prisma many-to-many and a composite\n  foreign key with no unique column set refuse.\n- Invent a home. No declared, no `--out`, and no confirmed `architecture_dir` is a stop.\n\n## Next\n\n- The schema settles a decision worth keeping: `\u002Farchitecture:record-decision`.\n- The schema needs a data-model change decided: `\u002Fplanning:design data`.\n- The question is which systems the repository sits among: `\u002Farchitecture:map-landscape`.\n\n## Gotchas\n\n- **The picture is not a C4 diagram.** An entity-relationship diagram is not a C4 view, so this\n  skill adds no C4 dialect key and reads `diagram_dialect.data` (`mermaid` or `dbml`). Pointer:\n  when checking which views C4 defines, fetch\n  [C4 diagrams § Static structure diagrams](https:\u002F\u002Fc4model.com\u002Fdiagrams#static-structure-diagrams)\n  and [§ Supporting diagrams](https:\u002F\u002Fc4model.com\u002Fdiagrams#supporting-diagrams) live.\n- **A Prisma one-to-many is read from `@relation(fields:, references:)`.** The reader takes the\n  scalar that `fields` names as the foreign key, and reads the relation as required when neither\n  the relation field nor that scalar carries `?`. Pointer: when\n  checking where Prisma stores a one-to-many foreign key or what makes it required, fetch\n  [one-to-many relations § 1-n in the database](https:\u002F\u002Fwww.prisma.io\u002Fdocs\u002Form\u002Fprisma-schema\u002Fdata-model\u002Frelations\u002Fone-to-many-relations#1-n-in-the-database)\n  and\n  [§ Required vs optional relation fields](https:\u002F\u002Fwww.prisma.io\u002Fdocs\u002Form\u002Fprisma-schema\u002Fdata-model\u002Frelations\u002Fone-to-many-relations#required-vs-optional-relation-fields)\n  live.\n- **The EF reader is a stated subset of the fluent chain.** It reads `HasMany`\u002F`HasOne`,\n  `WithOne`\u002F`WithMany`, `HasForeignKey`, and `IsRequired`, including the lambda form. Without\n  `IsRequired` it takes requiredness from the foreign-key property's nullability alone, whatever\n  the navigation's: `int? BlogId` is optional and `int BlogId` required, even beside\n  `Blog Blog = null!`. That reading was observed in an EF Core 10.0.0 probe with nullable\n  reference types on; the probe is not recorded in this repository. Pointer: when checking how EF\n  sets requiredness, fetch\n  [foreign and principal keys § Non-nullable foreign key columns](https:\u002F\u002Flearn.microsoft.com\u002Fen-us\u002Fef\u002Fcore\u002Fmodeling\u002Frelationships\u002Fforeign-and-principal-keys#non-nullable-foreign-key-columns)\n  and\n  [one-to-many § Required one-to-many](https:\u002F\u002Flearn.microsoft.com\u002Fen-us\u002Fef\u002Fcore\u002Fmodeling\u002Frelationships\u002Fone-to-many#required-one-to-many)\n  live. The script's stderr names the property or chain that stopped a refused read; the\n  record's reason stays `ef-fluent-unreadable`. A declaration in the configuration file's own\n  module is preferred over the rest of the repository. A chain outside the subset refuses the\n  record only when EF is the winning tier. Beside a Prisma schema it is a `not-compared` row, so a\n  test or sample file cannot block the diagram.\n- **The SQL reader replays a stated subset.** It reads the statements listed under the tiers and\n  refuses the tier with `sql-alter-unreadable` on any other `ALTER TABLE` action, because a renamed\n  table or a changed column would leave the replayed shape wrong. A migration it cannot read never\n  produces a mismatch claim against the winning tier.\n- **Two modules can declare the same short name.** Nodes are keyed by module and name. The\n  diagram names a node `module\u002FEntity` whenever more than one module is in scope, quoted in\n  Mermaid (`\"orders\u002FUser\"`). Pointer: when checking which entity names Mermaid needs quoted, fetch\n  [entity relationship diagrams § Entities and relationships](https:\u002F\u002Fmermaid.js.org\u002Fsyntax\u002FentityRelationshipDiagram.html#entities-and-relationships)\n  live.\n- **A required relationship does not mean the principal has at least one dependent.** The diagram\n  uses `||--o{` for a required foreign key. That matches both Prisma and EF: the many side may be\n  empty. The same EF page states there is no standard way to require a minimum number of\n  dependents. Do not draw `||--|{` from a required foreign key.\n- **A foreign key covered by a unique column set is one-to-one, drawn `||--o|` or `|o--o|`.** The\n  referenced entity is on the left, so `||` says each dependent row names exactly one principal,\n  and `o|` says the principal has zero or one dependent. A required unique foreign key is\n  `||--o|`; an optional one is `|o--o|`. Never `||--||`, which would demand a dependent for every\n  principal. Uniqueness is a Prisma `@unique`, `@id`, `@@unique([..])` or `@@id([..])`, or a SQL\n  `UNIQUE`, `PRIMARY KEY`, `CREATE UNIQUE INDEX` or `ALTER TABLE ... ADD UNIQUE`, whose columns\n  lie inside the foreign-key columns. A composite foreign key with no such set has no readable\n  cardinality, so the record refuses with `unknown-cardinality` rather than drawing one-to-many.\n  Pointer: when checking the cardinality markers or what makes a relation one-to-one, fetch\n  [entity relationship diagrams § Relationship syntax](https:\u002F\u002Fmermaid.js.org\u002Fsyntax\u002FentityRelationshipDiagram.html#relationship-syntax)\n  and\n  [one-to-one relations § 1-1 in the database](https:\u002F\u002Fwww.prisma.io\u002Fdocs\u002Form\u002Fprisma-schema\u002Fdata-model\u002Frelations\u002Fone-to-one-relations#1-1-in-the-database)\n  live.\n- **DBML names the referenced column the declaration names.** Prisma `references: [..]` and SQL\n  `REFERENCES t(col)` fill it, and EF `HasPrincipalKey(\"Col\")` does. Where the declaration names\n  none, the `Ref` becomes a `\u002F\u002F` comment that says so, because DBML needs a column on both sides;\n  the script never assumes `id`.\n- **A reformatted record reads as empty unless the reader refuses it.** Render exits 1 on any\n  layout other than one object per line and writes nothing.\n- **Tracked files only.** `git ls-files` is the source list. An untracked schema is not a\n  declaration. A directory that is not a git repository is a refusal.\n- **`--live` is a refusal.** No connection string is read and no client is invoked. Offline tiers\n  are not silently substituted.\n- **Two mechanisms are not half-read.** Django, SQLAlchemy, and EF data annotations are recognized\n  and then the run stops, even when a Prisma schema is also present.\n","## Repository context\n\nThe current repository is both the CONSUMER, whose convention home declares where artifacts land,\nand the DEFAULT SUBJECT, whose tracked files declare the schema.\n\nCollect with an **individual** Bash call, one command per call: the project root,\n`git rev-parse --show-toplevel`. Treat a failure (not a repository, git unavailable) as an unknown\nvalue and carry on; `${CLAUDE_PROJECT_DIR}` is the resolver's `--root` either way.\n\n## Purpose\n\nAnswer \"what are the entities and how do they relate\" from declarations in the tree. Every entity\nand every cardinality traces to a named file. The scripts collect and render. Do not draw a box the\nscript did not emit, and do not invent a cardinality the script did not record.\n\nThis is not a C4 diagram: an entity-relationship diagram is not one of the C4 views (the record\nis under Gotchas).\n\n## Resolve home and dialect\n\nRead `${CLAUDE_PLUGIN_ROOT}\u002Freference\u002Fconfig.md` first. This skill writes into `architecture_dir`.\nIt does not read `landscape_dialect` and adds no dialect key: the diagram dialect is\n`diagram_dialect.data` from the authoring-formats topic doc.\n\nRun `bash \"${CLAUDE_PLUGIN_ROOT}\u002Flib\u002Fresolve-convention-home.sh\" --root \"${CLAUDE_PROJECT_DIR}\"` and\nfollow the exit code; never parse the root instruction file yourself. Exit 0: read\n`\u003Chome>\u002Farchitecture\u002FREADME.md` for `architecture_dir`. Exit 1, 2, or 3: no declared home.\n\nPer key, in order: `--out \u003Cdir>` wins for this run alone, then a declared `architecture_dir`, then\none question. `architecture_dir` has NO default. An undeclared and unconfirmed home, including\nevery non-interactive run, STOPS and points at `\u002Farchitecture:setup`. Do not invent a directory.\n\nResolve `diagram_dialect.data` by restating this ladder, then running the resolver rather than\nparsing the topic doc yourself. The ladder is a resolution order, not a task list:\n\n```markdown\n1. Anchor at the repository root: `${CLAUDE_PROJECT_DIR}` when set, otherwise\n   `git rev-parse --show-toplevel`. Never a CWD-relative read.\n2. Resolve the convention home `\u003Chome>` with the bundled resolver above. Never hand-parse the root\n   file.\n3. The printed home is repo-relative: join it to the root, then pass\n   `\u003Croot>\u002F\u003Chome>\u002Fauthoring-formats\u002FREADME.md` to the resolver.\n4. Layer order is one layer deep: an explicit `--dialect` argument, then the team convention doc,\n   then the documented default `mermaid`. There is no personal override.\n5. Default: `diagram_dialect.data` is `mermaid`. Allowed values are `mermaid` and `dbml`.\n6. Degrade soft, and say so. No pointer, no doc, no key, or an unrecognized value each resolve to\n   `mermaid`. The resolver names the cause on stderr. Do not hard-fail and do not ask the operator\n   to create the surface mid-task.\n7. Report provenance: the key, the value, and the layer (`argument`, `team convention doc \u003Cpath>`,\n   or `default`).\n```\n\n```bash\nbash \"${CLAUDE_PLUGIN_ROOT}\u002Flib\u002Fresolve-diagram-dialect.sh\" --kind data \\\n  --formats \"\u003Croot>\u002F\u003Chome>\u002Fauthoring-formats\u002FREADME.md\"\n```\n\nOmit `--formats` when no convention home resolved. Stdout is `mermaid` or `dbml`. An explicit\n`--dialect` on the invocation wins and the resolver is not required.\n\nThis skill never writes the consumer's root instruction file or its topic doc.\n\n## Build the record\n\n```bash\n\"${CLAUDE_SKILL_DIR}\u002Fscripts\u002Fcollect-data.sh\" \\\n  --repo \"\u003Csubject-repo>\" --out \"\u003Carchitecture_dir>\u002Fdata-model.json\" \\\n  --generated-on \"\u003CYYYY-MM-DD|unknown>\"\n```\n\nPass `--generated-on` from `git -C \u003Croot> log -1 --format=%cs`, or `unknown` when that fails.\nPass `--live` only when the invocation asked for a live connection: the script opens none, writes a\nrefusal, and does not read the schema.\n\nThe record is schema_version 1, one object per line. `status` is `drawn` or `refused`; a refusal\nnames `reason` and writes no relationships. Shipped tiers, first present wins the diagram:\n\n- **model \u002F prisma.** `*.prisma` model blocks.\n- **orm \u002F ef-fluent.** A stated subset of one-to-many and one-to-one chains. The chain starts at\n  `Entity\u003CT>()` or, in a file that declares exactly one `class X : IEntityTypeConfiguration\u003CT>`\n  (also among several base types), at the `Configure` builder parameter. `HasOne`\u002F`HasMany` take a\n  generic argument or, for one-to-many, a lambda navigation (`HasMany(e => e.Posts).WithOne(e => e.Blog)`,\n  `HasOne(e => e.Blog).WithMany(e => e.Posts)`); the navigation's target comes from the property\n  declared on the configured entity's class in the scanned `.cs` files (`ICollection`, `List`,\n  `IList`, `IEnumerable` or `HashSet` of one identifier for a collection, `T` or `T?` for a\n  reference). `HasForeignKey` and `HasPrincipalKey` take one string literal or one single-member\n  lambda. Requiredness is an explicit `IsRequired()`, `IsRequired(true)` or `IsRequired(false)`;\n  with none, it is the foreign-key property's declared type on the dependent class: `T?`,\n  `Nullable\u003CT>` and `string?` are optional, and `int`, `uint`, `long`, `ulong`, `short`, `ushort`,\n  `byte`, `sbyte`, `Guid`, `DateTime` and `DateTimeOffset` are required.\n- **migration \u002F sql-migration.** `*.sql` under a `migrations` directory at any depth, including one\n  at the repository root, replayed in path order. The readable statements are `CREATE TABLE`\n  (with inline `REFERENCES`, table-level `FOREIGN KEY`, `UNIQUE` and `PRIMARY KEY`),\n  `CREATE UNIQUE INDEX`, `DROP INDEX`, `DROP TABLE`, and `ALTER TABLE` with `ADD COLUMN`,\n  `DROP COLUMN`, `ADD [CONSTRAINT n] FOREIGN KEY | UNIQUE | PRIMARY KEY`, and `DROP CONSTRAINT`\n  naming a constraint the migrations declared. Any other `ALTER TABLE` action (`RENAME`,\n  `ALTER COLUMN`, a `DROP CONSTRAINT` it cannot map) refuses the tier with `sql-alter-unreadable`.\n\nA second shipped tier that disagrees becomes a mismatch row. The diagram stays on the winning tier.\nA tier that loses and cannot be read (an EF chain outside the subset, an unreadable migration) does\nnot refuse the record: it is left out of the comparison and listed as a `not-compared` row.\nDjango models, SQLAlchemy columns, EF `[ForeignKey]` annotations, and a Prisma many-to-many with no\n`fields:` list refuse the record (`partial-read` or a named reason), as does an EF chain outside the\nsubset when EF is the winning tier (`ef-fluent-unreadable`), a migration outside the subset when\nSQL is the winning tier (`sql-alter-unreadable`), and a composite foreign key with no unique column\nset inside it (`unknown-cardinality`). A shipped diagram beside an unread mechanism would be a\npartial read.\n\nA module is the first path segment of the declaring file, or `.` at the repository root. It is\nlisted only when the winning tier declares an entity in it.\n\n## Render\n\n```bash\n\"${CLAUDE_SKILL_DIR}\u002Fscripts\u002Frender-data.sh\" \\\n  --record \"\u003Carchitecture_dir>\u002Fdata-model.json\" --out \"\u003Carchitecture_dir>\" \\\n  --dialect \"\u003Cmermaid|dbml>\" --scope \"\u003Cmodule|all|id>\"\n```\n\nAdd `--include-columns` only when the invocation asked for columns. The default scope is `module`:\none module is drawn; several modules write a refusal that lists them and the script exits 3. Draw\nnothing until the operator passes `--scope \u003Cid>` or `--scope all`. In a non-interactive run, stop\nafter that refusal. Do not pick a module. With more than one module in scope, every node is named\n`module\u002FEntity`, so `orders\u002FUser` and `billing\u002FUser` stay two nodes.\n\nMermaid writes an `erDiagram` inside `data-model.md`. DBML writes `data-model.dbml` and points at\nit from `data-model.md`. Column names and types appear in the diagram only with `--include-columns`;\nthe relationship list and the mismatch list are not a column dump.\n\nThe script prints one summary line. Keep it:\n\n`data: status=\u003Cdrawn|refused> reason=\u003Creason|none> tier=\u003Ctier> tool=\u003Ctool> modules=\u003Cn> entities=\u003Cn> relationships=\u003Cn> mismatches=\u003Cn> columns=\u003Cyes|no> dialect=\u003Cmermaid|dbml> scope=\u003Cid|all|unresolved|none>`\n\nExit 1 means the record is unreadable or not schema_version 1 in the one-object-per-line layout;\nnothing was written. Report that message. Do not reformat the record by hand.\n\n## Close with the report\n\nEnd every run with this block, in this order:\n\n- **Artifacts**: each path written, or `none written` when the run stopped before a home existed.\n- **Status**: `drawn` or `refused`, and the reason when it is a refusal.\n- **Source**: the tier and the tool, quoted from the summary, or `none` on a refusal.\n- **Dialect**: `mermaid` or `dbml`, and the layer it came from.\n- **Scope**: the module, `all`, or `unresolved` with the module list.\n- **Columns**: omitted, or included.\n- **Mismatches**: the count. A mismatch is reported, not silently resolved.\n- **Live**: not requested, or requested and refused. No connection was opened.\n\n## Interactive view\n\nAfter the report, offer an interactive view of `data-model.json` in one sentence. The markdown and\nthe record stay authoritative. Build it only with `${CLAUDE_PLUGIN_ROOT}\u002Fscripts\u002Fbuild-view.mjs data`,\nnever hand-written; the shared medium resolver decides the destination, with this plugin's `medium`\noption `${user_config.medium}`, or `\"\"` when that reads empty or unsubstituted (never put a\n`${user_config.*}` string in a shell command), and its report line is printed. Procedure:\n[`${CLAUDE_PLUGIN_ROOT}\u002Freference\u002Frendered-view.md`](${CLAUDE_PLUGIN_ROOT}\u002Freference\u002Frendered-view.md).\n\n## What this skill does NOT do\n\n- Open a database connection, read production data, or compare live rows to the declaration.\n- Indexes, data volumes, query plans, lineage, or ETL.\n- A C4 view, or a new dialect key. The dialect is the existing `diagram_dialect.data`.\n- Adapters other than Prisma models, the EF fluent subset above, and the SQL statements listed\n  above. Other mechanisms refuse. Within EF, these refuse: a composite key, `HasOne(lambda)` paired\n  with `WithOne`, a navigation with no single declared type (an expression-bodied property, a\n  positional record member, an undeclared name), two declarations of one class property in the\n  same module, a file with zero or several `IEntityTypeConfiguration\u003CT>` classes, an `IsRequired`\n  argument other than `true` or `false`, and, when `IsRequired` is absent, a foreign key that is\n  undeclared or has a plain `string`, enum or other type, because its nullability depends on the\n  project's nullable setting. A `[ForeignKey]` annotation is not read.\n- Guess a cardinality the declaration does not state. Implicit Prisma many-to-many and a composite\n  foreign key with no unique column set refuse.\n- Invent a home. No declared, no `--out`, and no confirmed `architecture_dir` is a stop.\n\n## Next\n\n- The schema settles a decision worth keeping: `\u002Farchitecture:record-decision`.\n- The schema needs a data-model change decided: `\u002Fplanning:design data`.\n- The question is which systems the repository sits among: `\u002Farchitecture:map-landscape`.\n\n## Gotchas\n\n- **The picture is not a C4 diagram.** An entity-relationship diagram is not a C4 view, so this\n  skill adds no C4 dialect key and reads `diagram_dialect.data` (`mermaid` or `dbml`). Pointer:\n  when checking which views C4 defines, fetch\n  [C4 diagrams § Static structure diagrams](https:\u002F\u002Fc4model.com\u002Fdiagrams#static-structure-diagrams)\n  and [§ Supporting diagrams](https:\u002F\u002Fc4model.com\u002Fdiagrams#supporting-diagrams) live.\n- **A Prisma one-to-many is read from `@relation(fields:, references:)`.** The reader takes the\n  scalar that `fields` names as the foreign key, and reads the relation as required when neither\n  the relation field nor that scalar carries `?`. Pointer: when\n  checking where Prisma stores a one-to-many foreign key or what makes it required, fetch\n  [one-to-many relations § 1-n in the database](https:\u002F\u002Fwww.prisma.io\u002Fdocs\u002Form\u002Fprisma-schema\u002Fdata-model\u002Frelations\u002Fone-to-many-relations#1-n-in-the-database)\n  and\n  [§ Required vs optional relation fields](https:\u002F\u002Fwww.prisma.io\u002Fdocs\u002Form\u002Fprisma-schema\u002Fdata-model\u002Frelations\u002Fone-to-many-relations#required-vs-optional-relation-fields)\n  live.\n- **The EF reader is a stated subset of the fluent chain.** It reads `HasMany`\u002F`HasOne`,\n  `WithOne`\u002F`WithMany`, `HasForeignKey`, and `IsRequired`, including the lambda form. Without\n  `IsRequired` it takes requiredness from the foreign-key property's nullability alone, whatever\n  the navigation's: `int? BlogId` is optional and `int BlogId` required, even beside\n  `Blog Blog = null!`. That reading was observed in an EF Core 10.0.0 probe with nullable\n  reference types on; the probe is not recorded in this repository. Pointer: when checking how EF\n  sets requiredness, fetch\n  [foreign and principal keys § Non-nullable foreign key columns](https:\u002F\u002Flearn.microsoft.com\u002Fen-us\u002Fef\u002Fcore\u002Fmodeling\u002Frelationships\u002Fforeign-and-principal-keys#non-nullable-foreign-key-columns)\n  and\n  [one-to-many § Required one-to-many](https:\u002F\u002Flearn.microsoft.com\u002Fen-us\u002Fef\u002Fcore\u002Fmodeling\u002Frelationships\u002Fone-to-many#required-one-to-many)\n  live. The script's stderr names the property or chain that stopped a refused read; the\n  record's reason stays `ef-fluent-unreadable`. A declaration in the configuration file's own\n  module is preferred over the rest of the repository. A chain outside the subset refuses the\n  record only when EF is the winning tier. Beside a Prisma schema it is a `not-compared` row, so a\n  test or sample file cannot block the diagram.\n- **The SQL reader replays a stated subset.** It reads the statements listed under the tiers and\n  refuses the tier with `sql-alter-unreadable` on any other `ALTER TABLE` action, because a renamed\n  table or a changed column would leave the replayed shape wrong. A migration it cannot read never\n  produces a mismatch claim against the winning tier.\n- **Two modules can declare the same short name.** Nodes are keyed by module and name. The\n  diagram names a node `module\u002FEntity` whenever more than one module is in scope, quoted in\n  Mermaid (`\"orders\u002FUser\"`). Pointer: when checking which entity names Mermaid needs quoted, fetch\n  [entity relationship diagrams § Entities and relationships](https:\u002F\u002Fmermaid.js.org\u002Fsyntax\u002FentityRelationshipDiagram.html#entities-and-relationships)\n  live.\n- **A required relationship does not mean the principal has at least one dependent.** The diagram\n  uses `||--o{` for a required foreign key. That matches both Prisma and EF: the many side may be\n  empty. The same EF page states there is no standard way to require a minimum number of\n  dependents. Do not draw `||--|{` from a required foreign key.\n- **A foreign key covered by a unique column set is one-to-one, drawn `||--o|` or `|o--o|`.** The\n  referenced entity is on the left, so `||` says each dependent row names exactly one principal,\n  and `o|` says the principal has zero or one dependent. A required unique foreign key is\n  `||--o|`; an optional one is `|o--o|`. Never `||--||`, which would demand a dependent for every\n  principal. Uniqueness is a Prisma `@unique`, `@id`, `@@unique([..])` or `@@id([..])`, or a SQL\n  `UNIQUE`, `PRIMARY KEY`, `CREATE UNIQUE INDEX` or `ALTER TABLE ... ADD UNIQUE`, whose columns\n  lie inside the foreign-key columns. A composite foreign key with no such set has no readable\n  cardinality, so the record refuses with `unknown-cardinality` rather than drawing one-to-many.\n  Pointer: when checking the cardinality markers or what makes a relation one-to-one, fetch\n  [entity relationship diagrams § Relationship syntax](https:\u002F\u002Fmermaid.js.org\u002Fsyntax\u002FentityRelationshipDiagram.html#relationship-syntax)\n  and\n  [one-to-one relations § 1-1 in the database](https:\u002F\u002Fwww.prisma.io\u002Fdocs\u002Form\u002Fprisma-schema\u002Fdata-model\u002Frelations\u002Fone-to-one-relations#1-1-in-the-database)\n  live.\n- **DBML names the referenced column the declaration names.** Prisma `references: [..]` and SQL\n  `REFERENCES t(col)` fill it, and EF `HasPrincipalKey(\"Col\")` does. Where the declaration names\n  none, the `Ref` becomes a `\u002F\u002F` comment that says so, because DBML needs a column on both sides;\n  the script never assumes `id`.\n- **A reformatted record reads as empty unless the reader refuses it.** Render exits 1 on any\n  layout other than one object per line and writes nothing.\n- **Tracked files only.** `git ls-files` is the source list. An untracked schema is not a\n  declaration. A directory that is not a git repository is a refusal.\n- **`--live` is a refusal.** No connection string is read and no client is invoked. Offline tiers\n  are not silently substituted.\n- **Two mechanisms are not half-read.** Django, SQLAlchemy, and EF data annotations are recognized\n  and then the run stops, even when a Prisma schema is also present.\n",{"shell":24,"metadata":25,"description":7,"argument-hint":28,"user-invocable":29,"disable-model-invocation":20},"bash",{"summary":26,"workflow-stage":27},"Draw an ERD from a committed schema, offline","explore","[--scope module|all|\u003Cmodule>] [--include-columns] [--dialect mermaid|dbml] [--out \u003Cdir>]",true,"main","d0e68c3f36b92a1d6381f0ba0060d7a0b8b886c5","plugins\u002Farchitecture\u002Fskills\u002Fmap-data",7,"https:\u002F\u002Fgithub.com\u002Fmelodic-software\u002Fclaude-code-plugins","https:\u002F\u002Fgithub.com\u002Fmelodic-software","https:\u002F\u002Fmelodicsoftware.com","Independent software studio building developer tools, automation, and application services, with roots in music.","2026-11-15 05:15:06",{"source":8,"skillName":5,"commands":40,"prompt":50,"zipAvailable":29},[41,44,47],{"tool":42,"command":43},"npx","npx skills add melodic-software\u002Fclaude-code-plugins --skill map-data",{"tool":45,"command":46},"bunx","bunx skills add melodic-software\u002Fclaude-code-plugins --skill map-data",{"tool":48,"command":49},"pnpm","pnpm dlx skills add melodic-software\u002Fclaude-code-plugins --skill map-data","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fmelodic-software\u002Fclaude-code-plugins\u002Fblob\u002Fmain\u002Fplugins\u002Farchitecture\u002Fskills\u002Fmap-data\u002FSKILL.md",[52,58,64,68],{"path":53,"resourceType":54,"resourceTypeDesc":55,"sizeBytes":56,"sourceHtmlUrl":57},"evals\u002Fevals.json","REFERENCE","参考文档",6834,"https:\u002F\u002Fgithub.com\u002Fmelodic-software\u002Fclaude-code-plugins\u002Fblob\u002Fmain\u002Fplugins\u002Farchitecture\u002Fskills\u002Fmap-data\u002Fevals\u002Fevals.json",{"path":59,"resourceType":60,"resourceTypeDesc":61,"sizeBytes":62,"sourceHtmlUrl":63},"scripts\u002Fcollect-data.sh","SCRIPT","脚本",51866,"https:\u002F\u002Fgithub.com\u002Fmelodic-software\u002Fclaude-code-plugins\u002Fblob\u002Fmain\u002Fplugins\u002Farchitecture\u002Fskills\u002Fmap-data\u002Fscripts\u002Fcollect-data.sh",{"path":65,"resourceType":60,"resourceTypeDesc":61,"sizeBytes":66,"sourceHtmlUrl":67},"scripts\u002Fcollect-data.test.sh",34709,"https:\u002F\u002Fgithub.com\u002Fmelodic-software\u002Fclaude-code-plugins\u002Fblob\u002Fmain\u002Fplugins\u002Farchitecture\u002Fskills\u002Fmap-data\u002Fscripts\u002Fcollect-data.test.sh",{"path":69,"resourceType":60,"resourceTypeDesc":61,"sizeBytes":70,"sourceHtmlUrl":71},"scripts\u002Frender-data.sh",19178,"https:\u002F\u002Fgithub.com\u002Fmelodic-software\u002Fclaude-code-plugins\u002Fblob\u002Fmain\u002Fplugins\u002Farchitecture\u002Fskills\u002Fmap-data\u002Fscripts\u002Frender-data.sh",[73,80,87,94,99,106],{"skillNo":74,"name":75,"nameZh":6,"description":76,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":77,"categories":78,"keywords":79,"publishedAt":19},"01M7DYYDG31B9YX7N9MB9QW2GW","track","Backlog reads through the bound tracker: search open and closed items, view one item with its comments and state history. Use when another skill searches or reads tracker items.","https:\u002F\u002Fgithub.com\u002Fmelodic-software\u002Fclaude-code-plugins\u002Fblob\u002Fmain\u002Fplugins\u002Fsession-flow\u002Fevals\u002Frecall-still-reports-reopened-bug\u002Fwork-items-stub\u002Fskills\u002Ftrack\u002FSKILL.md",[],[],{"skillNo":81,"name":82,"nameZh":6,"description":83,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":84,"categories":85,"keywords":86,"publishedAt":19},"01M7DYXVBAVG3NV30PA7GKW9Q6","reviewer-media","Reviewer media for one pull request: decides whether it needs a narrated walkthrough, builds the storyboard from \u002Freview:explain-change's digest, has \u002Fexplainer-video:produce render it and hands the manifest to \u002Fsource-control:pull-request media. Use when asked for 'reviewer media', 'a walkthrough video for this PR', 'a produced video of this change', or when pull-request ready or monitor hands a PR over.","https:\u002F\u002Fgithub.com\u002Fmelodic-software\u002Fclaude-code-plugins\u002Fblob\u002Fmain\u002Fplugins\u002Freview\u002Fskills\u002Freviewer-media\u002FSKILL.md",[],[],{"skillNo":88,"name":89,"nameZh":6,"description":90,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":91,"categories":92,"keywords":93,"publishedAt":19},"01M7DYRZ5YD44AMYH26YR25GZ8","route","Model and effort per agent role (orchestrator, worker, verifier, retrieval) for a multi-agent run, resolved through the bundled defaults and the user, team and personal override config layers into fenced JSON with single-agent and fan-out variants and the layer behind each value. Use when asked 'which model for the subagents', 'route the roles' or 'model routing', or before a skill passes a role's model on a spawn.","https:\u002F\u002Fgithub.com\u002Fmelodic-software\u002Fclaude-code-plugins\u002Fblob\u002Fmain\u002Fplugins\u002Fdiscovery\u002Fevals\u002Fex-model-pin-without-override\u002Fmulti-agent-stub\u002Fskills\u002Froute\u002FSKILL.md",[],[],{"skillNo":95,"name":89,"nameZh":6,"description":90,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":96,"categories":97,"keywords":98,"publishedAt":19},"01M7DYRTVT4FWTGDJY0HCCFJMZ","https:\u002F\u002Fgithub.com\u002Fmelodic-software\u002Fclaude-code-plugins\u002Fblob\u002Fmain\u002Fplugins\u002Fdiscovery\u002Fevals\u002Fex-model-override-from-route\u002Fmulti-agent-stub\u002Fskills\u002Froute\u002FSKILL.md",[],[],{"skillNo":100,"name":101,"nameZh":6,"description":102,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":103,"categories":104,"keywords":105,"publishedAt":19},"01M7DYNZC8PNW3T27V2ADKECKJ","principles","Module-design vocabulary for architecture findings, and the checks built on it. Use when: 'what is a deep module', 'what is a seam', 'deep vs shallow module', 'what is the deletion test', 'leverage and locality', 'module design vocabulary', 'which word do we use for X in architecture findings'. Scanning a codebase for friction is \u002Farchitecture:improve.","https:\u002F\u002Fgithub.com\u002Fmelodic-software\u002Fclaude-code-plugins\u002Fblob\u002Fmain\u002Fplugins\u002Farchitecture\u002Fskills\u002Fprinciples\u002FSKILL.md",[],[],{"skillNo":107,"name":108,"nameZh":6,"description":109,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":110,"categories":111,"keywords":112,"publishedAt":19},"01M7DYNMCZNEWBFHV9KTSS6H60","write","Structured five-field bug report (title, steps to reproduce, expected vs actual, justified severity, suggested fix location) from an informal description, read-only. Use when the user names a defect they observed, or asks for one written up ('report a bug', 'file a bug', 'write this up as a bug').","https:\u002F\u002Fgithub.com\u002Fmelodic-software\u002Fclaude-code-plugins\u002Fblob\u002Fmain\u002Fplugins\u002Farchitecture\u002Fevals\u002Fdeepening-defect-goes-to-bugs-write\u002Fbugs-stub\u002Fskills\u002Fwrite\u002FSKILL.md",[],[]]