Files
semprini-data-product-templ…/README.md
T
paulandClaude Opus 5 62a3714562 Add the canonical data product template
Moves the data product template from semprini-blog-dataproducts, as adapted to
the semprini-data domain platform, into canonical_data_product/. Its worked
example passed 9 of 9 checks on the domain platform on 2026-09-17.

Adds agent-canonical-product, the blog's agent-product adapted to generate a
product into a domain repository from a declaration in the domain's model
repository, and README/CLAUDE.md describing the template catalogue, the
product contract with the domain platform, and team ownership. Source-aligned
and experience templates are planned.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-17 22:55:11 +12:00

4.9 KiB

semprini-data-product-templates

Data product templates for the semprini-data domain platform, one folder per class of data product, owned by the data product engineering teams.

A template is the answer to "what does a deployable product of this class look like on this platform": the directory layout, naming, type mapping, and every file the platform needs, as {{placeholders}} that a generation agent fills in from one MD-DDL data product declaration. The canonical template started in semprini-blog-dataproducts, where it shared a repository with its platform, model and products.

Catalogue

Template Product class MD-DDL class Status
canonical_data_product/ Canonical: a slice of the domain's canonical model, published as modelled through GraphQL, Kafka and Trino domain-aligned Available. Verified 2026-09-17 on the domain platform, 9 of 9 checks
source_aligned_data_product/ Source aligned: one source system's data in its own shape, for audit, replay and debugging source-aligned Planned
experience_<class>_data_product/ Experience: shaped for an audience. Several classes, e.g. lake tables built by scheduled dbt models consumer-aligned Planned

Where templates sit between the teams

 modelling team                engineering teams                      data platform team
 ─────────────                 ─────────────────                      ──────────────────
 semprini-domain-<d>-datamodel  semprini-data-product-templates        semprini-data-domain
   data_products/*.md  ───────▶   <class>_data_product/  ◀── product contract ──  data-domain CLI
   handoffs/<slug>.md             .claude/agents/agent-<class>-product.md         compose.domain.yml
                    │                        │
                    └──────── generate ──────┴──▶ semprini-domain-<d>/products/<slug>/ ── deploy ──▶ domain stack
  • From the modelling team: a product declaration and the entities and enums it names, plus a handoff note for decisions the model cannot carry. The declaration's MD-DDL class picks the template.
  • To the data platform team: every template produces directories that meet the domain platform's product contract (semprini-data-domain README.md): the product.yaml manifest the data-domain CLI reads, and the SQL, schema, job and smoke-test files it applies. A template that needs something the contract does not offer asks the platform team first.
  • Products are generated into the domain repository that runs them, and deployed and operated from there by the domain's engineering team.

All teams work on semprini-core, the enterprise landing zone: Keycloak for identity, and Gitea (git.semprini.me) for these repositories.

Generating a product

From a checkout of this repository, with the model repository and the domain repository at hand:

/agent-canonical-product Generate Canonical Party for the digital-core domain

The agent reads the declaration and any pending handoff, writes products/<slug>/ in the domain repository, runs uv run data-domain deploy and test there, and reports the model and template versions it generated from. Commit the product in the domain repository with both.

Versioning

  • Tag a release of this repository when a template changes (v0.1.0, ...). Domain repositories record the tag they generated from and regenerate deliberately, not on every commit here.
  • A template change that alters what a product directory contains may need a platform change first. Check the product contract, and agree the change with the data platform team.
  • Every template keeps a worked example/ that deploys and passes data-domain test on the current domain platform. That example is the template's test, and the platform team's smoke test for the domain template.

Adding a template

  1. Create <class>_data_product/ with a README.md contract (what the product is, the mapping to platform interfaces, layout, naming, placeholders, type mapping, the generation input table, prerequisites and known gaps) and the template files.
  2. Add a worked example/ and verify it on a domain stack with data-domain deploy and test.
  3. Add its generation agent as .claude/agents/agent-<class>-product.md, with a command wrapper in .claude/commands/.
  4. Add it to the catalogue above.

Repository layout during setup

While the systems are being set up, this repository is a submodule of semprini-data, beside the domain platform and the Digital Core model, so all of it can be read and changed together. Most organisations keep these repositories apart, each owned and released by its own team, and link them only by version.