# Make a template

> Turn a page you made into a pattern you can use again.

Kind: guide · ~2 min · Verified v0.237.0 · Next: [Release to the marketplace](https://pr-2197-stg.superartifacts.app/docs/marketplace.md)

## Goal

Keep a page's design as a pattern for future content.

## What you'll have

A draft template and a fresh artifact built from it.

## Needs

An artifact you can read and a connected agent allowed to save template drafts. Decide which content varies and whether new instances should collect data together. Drafting and marketplace release are separate actions.

## Prompt

**Turn your KPI board into a template**

```prompt
Promote my artifact "Weekly KPI board" into a reusable Super Artifacts template.

Read super_template_save's schema before you start. The short version: a template is the
PATTERN this artifact is an instance of, not the artifact. Do not send this artifact's files
unchanged.

The artifact:
- id: <artifact id>
- slug: weekly-kpi
- kind: dashboard
- live at: <artifact URL>
- files: index.html
- collects: nothing

What to do:
1. Read the artifact's own code with super_artifacts {artifact: "<artifact id>", path} — one call
   per file above. Do not fetch its URL; anything not public redirects to a sign-in page.
2. List the DISTINCT components in it. Forty rows of the same card is one card component,
   not forty. Sixty slides of five layouts is five layouts.
3. Write the runtime as that list, once each, driven by a
   `<script id="sa-template-values" type="application/json">` block — exactly one occurrence.
4. Reduce the content to five to ten samples chosen to DEMONSTRATE VARIETY, not volume. One
   of every component, every field type, the empty state, the finish state.
5. Turn everything that varies between instances into a slot. Name the slots for what they
   are, never for what this artifact's content happened to be.

Then:
- Save it with super_template_save, slug "weekly-kpi-template".
- Include `spec.examplePrompts`: five or six sentences I could paste at an agent to get an
  artifact out of this blueprint.
- Include a `sample` that shows one of every component — it is what the marketplace renders
  and photographs, so it is the blueprint’s shop window rather than test data.
- Build one instance from it with super_publish (`template` and `values`) and show me both URLs.

If the instance is not as good as the artifact you started from, the template is not
finished. Tell me what is missing rather than shipping it.
```

## Steps

### Keep the pattern

1. Open the artifact's **Settings** and use **Copy template prompt** in its template section. The artifact-specific prompt points the agent to the files and data it must inspect.
2. Have the agent keep representative components, turn changing content into slots and save the draft with `super_template_save`.
3. For a collecting template, check its data declaration and series. Template-built instances can contribute to that series in your workspace. A released change to the data model advances its model number; each instance records the model it used.
4. Build a new instance with different content and inspect it. For several existing pages, use `super_data_schema` to compare their fields and settle conflicts before combining their patterns.

A revision records another draft version. A saved draft is not a marketplace listing.

### What it costs

| One-page KPI board | Median per run |
| --- | --- |
| From scratch (n=3) | 31,452 tokens processed · 1,534 output tokens · 10.043 seconds |
| From a template (n=3) | 66,428 tokens processed · 1,594 output tokens · 13.479 seconds |
| Make a template (n=1) | 80,939 tokens processed · 5,844 output tokens · 37.08 seconds |

The recorded benchmark is three scratch builds, three template builds and one template extraction for a small KPI board on 2026-10-13. The template was already installed. Its run processed more tokens and took slightly longer; output tokens were similar. The measurement supports consistency and reuse, not a general token-saving claim.

## Check it worked

The template page shows its draft version. The new artifact keeps the pattern with different content. Check the declared fields and series before collecting real responses.

## If not

Ask the agent to compare required slots, runtime files and sample values. Do not guess how conflicting data fields should be combined.

## Variations

Team and Business provide a private workspace shelf. Public distribution needs a separate eligible release.

## Next

[Release to the marketplace](https://pr-2197-stg.superartifacts.app/docs/marketplace.md).
