Agent skill

Malloy HTML Data Apps

by malloydata in malloydata/publisher

Build or modify an in-package HTML data app for a Malloy Publisher package (a public/ directory the package serves): design it, write its Publisher.query code, embed it.

MITAuto-check passed

Install Malloy HTML Data Apps

skills CLI
$ npx skills add malloydata/publisher --skill malloy-html-data-apps -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install malloydata/publisher malloy-html-data-apps --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/malloydata/publisher.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/malloy-html-data-apps .claude/skills/malloy-html-data-apps && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
malloy-html-data-apps
GitHub stars
116
Token cost
~3.5k tokens
SKILL.md length
1,832 words
Files
10
Skills in repo
29
Repo updated
First seen
Licence
MIT

At a glance

Build or modify an in-package HTML data app for a Malloy Publisher package (a public/ directory the package serves): design it, write its Publisher.query code, embed it.

  • Works in 8 steps: DESIGN IT FIRST. Read… → READ THE MODEL. Get the model's real… → SCAFFOLD the package (template below). → …
  • SKILL.md covers When this is the right tool, Package anatomy, Build sequence and What "done" means (production…, plus 2 more sections
  • Calls npx, python3 and node

What it does

Malloy HTML Data Apps is an agent skill from malloydata/publisher. Build or modify an in-package HTML data app for a Malloy Publisher package (a public/ directory the package serves): design it, write its Publisher.query code, embed it. Hand-authored, no build step.

Its SKILL.md is about 3.5k tokens, which your agent loads only when the skill is triggered. The skill folder holds 10 other files (for example `reference/archetypes.md`, `reference/depth-patterns.md` and `reference/design.md`).

The repository describes itself as: Publisher is the open-source analytics engine for Malloy. It lets you define data models once — and use them everywhere. The licence is MIT.

Example prompts

  • “/malloy-html-data-apps”

Requirements

  • Python 3
  • Node.js

Workflow steps

8 steps, taken from the first numbered list in SKILL.md.

  1. DESIGN IT FIRST. Read reference/design.md: who opens it, the decision it serves, the archetype, the form each tile takes, and the depth…
  2. READ THE MODEL. Get the model's real source and view names, through your environment's context tool if it has one, or by opening the…
  3. SCAFFOLD the package (template below).
  4. WRITE THE QUERIES. Read reference/runtime.md. Validate each before pasting it into the page, using whatever query tool your environment…
  5. CHOOSE CHARTS with skill:malloy-charts when rendering through ; otherwise it is your own chart library drawing the returned rows. Vendor…
  6. EMBED (optional). Read reference/embedding.md.
  7. PREVIEW with the local authoring loop (below).
  8. VERIFY before you call it done (see "What 'done' means" below). This step is not optional.

What it can do on your machine

Read from SKILL.md and the folder at commit acc1acd. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • npx
    • python3
    • node

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use npx, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Malloy HTML Data Apps loads about 3.5k tokens when it runs. Until then it costs about 55 tokens; SKILL.md has 1,832 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~55
When it runs · the whole SKILL.md, loaded when a task matches
~3.5k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from malloydata/publisher at commit acc1acd, republished under its MIT licence (© malloydata). 1,832 words, ~3,522 tokens.

Download SKILL.mdSave it as .claude/skills/malloy-html-data-apps/SKILL.md (or your agent's skills folder). This skill also uses 9 other files; get the full folder from GitHub.
name
malloy-html-data-apps
description
Build or modify an in-package HTML data app for a Malloy Publisher package (a public/ directory the package serves): design it, write its Publisher.query code, embed it. Hand-authored, no build step.
<!--
Copyright (c) Credible Data Inc.
SPDX-License-Identifier: MIT
-->

In-Package HTML Data Apps

A package becomes a web app by adding a public/ directory. Publisher serves those files and gives the page Publisher.query(...) to run Malloy against the package's models. No build step, no npm, no framework.

When this is the right tool

The user wantsUse
A hand-authored HTML/JS dashboard, no toolchainthis skill (an HTML data app)
A React app with managed componentsthe Publisher React SDK (out of scope here)
An analyst notebook with chartsa Malloy notebook (notebooks/<slug>.malloy)
Point-and-click exploration, no codethe Publisher Explorer

Pick an HTML data app when the user wants full control of the markup and only plain web files.

Package anatomy

my-package/
  publisher.json        # name, version, description
  subscriptions.malloy  # the model(s), stays private
  subscriptions.parquet # data, stays private
  public/               # ONLY this directory is web-served
    index.html
    app.js
    vendor/             # chart library, vendored rather than loaded from a CDN
      chart.umd.js

Only public/ is reachable over the web, at /environments/<env>/packages/<pkg>/<file>. Models, data, and publisher.json are private and reached only through the query API, which still applies the model's filters, access modifiers, and authorize rules. There is no flag to set: a public/ directory is what makes a package an app.

Build sequence

The agent orchestrates these. Each query and chart step hands off to a focused skill.

  1. DESIGN IT FIRST. Read reference/design.md: who opens it, the decision it serves, the archetype, the form each tile takes, and the depth plan. Skipping this is what produces an app that enumerates the model - a KPI row and a chart grid, whatever the domain - instead of one that answers a question. Hand the brief to the user before scaffolding.
  2. READ THE MODEL. Get the model's real source and view names, through your environment's context tool if it has one, or by opening the .malloy file directly. Never guess field or view names.
  3. SCAFFOLD the package (template below).
  4. WRITE THE QUERIES. Read reference/runtime.md. Validate each before pasting it into the page, using whatever query tool your environment provides or a running Publisher (see reference/runtime.md). Malloy syntax questions go to skill:malloy-queries.
  5. CHOOSE CHARTS with skill:malloy-charts when rendering through <malloy-render>; otherwise it is your own chart library drawing the returned rows. Vendor any chart library into public/ and load it locally, not from a CDN. Two reasons: embedded author JavaScript runs with the viewing user's data authority, and a blocked CDN (agent sandboxes and many corporate networks block them) is easy to miss, because the script never runs and the charts come up empty. The storefront example ships its chart library in public/vendor/ and loads it from public/index.html as ./vendor/chart.umd.js. Copy that, but resolve the path against the page's own directory: a page in a subdirectory (public/reports/index.html) needs ../vendor/chart.umd.js. A wrong relative path 404s and leaves the charts blank, which is the failure you are trying to avoid.
  6. EMBED (optional). Read reference/embedding.md.
  7. PREVIEW with the local authoring loop (below).
  8. VERIFY before you call it done (see "What 'done' means" below). This step is not optional.

The scaffold in step 3 only proves the wiring. It is the start, not the deliverable. What you ship is a production app that meets the recipe below.

What "done" means (production recipe)

A data app you can defend has all of these. Build to this list, not to the scaffold.

  • Real names, never guessed. Every source, view, and field name comes from the model you read in step 2. A name you derived or assumed is a bug waiting to surface as an empty tile.
  • A real name is not the same as a correct measure. Using the model's declared measures is right by default, but a wrong one fails far more quietly than a wrong name: an empty tile is obvious, a plausible wrong number is not. Before a measure reaches a headline, confirm it against the raw column values (reference/design.md step 2 of the inventory). The case that bites is a predicate like != null over a column whose "absent" value is a sentinel string - measured on a real build, that reported 95.6% of police cases cleared where the true figure was 16.6%, and every check in this skill still passed.
  • DOM-only - never innerHTML with interpolated values. Build every element with createElement + textContent; do not assign innerHTML (or insertAdjacentHTML, document.write) with any string that contains a model value. Query results render any markup they contain - an XSS vector, and blocked outright under a Trusted-Types CSP. This is a hard build rule, not a lint suggestion: an app that interpolates a model value into innerHTML is not done.
  • Modular, not one inline blob. Split the page into modules per reference/runtime.md (pure formatting helpers, a chart layer, your tile/query definitions as data, a thin entry point). One source of truth for each tile's model/source/view, no parallel maps that drift.
  • Every tile handles loading, empty, and error on its own. One failing query must not blank the page. (reference/runtime.md.)
  • Defensible numbers. Missing ≠ zero (omit the point, don't plot a fake 0); show the latest non-null value for "current"; guard division with nullif; convert units explicitly. (reference/runtime.md.)
  • Visible assumptions. When you assume something (two sources joined by month, an in-month proxy that differs from a certified definition) or a metric is incomplete, say so in the app: a caption, a footnote, a placeholder card with the reason. The non-technical user cannot see your reasoning; bury a caveat and you have misled them. Don't silently drop a metric you couldn't model. Show a placeholder that names what's missing and why.
  • Built to the design brief, not to the model's shape. The app matches the archetype, forms, and depth plan from step 1 (reference/design.md), carries a real token contract (surfaces, text ramp, semantic colors, a categorical chart palette) that the chart code reads at runtime rather than hardcoding, and puts visible weight on the two or three numbers that lead. A uniform grid of same-size cards, or a tile per view, means the brief was skipped.
  • Vendored libraries. Chart and helper libraries live in public/, loaded locally (step 5).
  • Lazy-load below the fold, once the page has more than about eight query-backed tiles. ("Many" is not decidable; that is the threshold.) Tiles sitting below the fold is why the technique works, not a second trigger for it - almost every real data app scrolls, so reading it as one makes the rule "always" and contradicts the count. Under that threshold, firing every tile at once is cheaper than the machinery. Don't fire every tile's query on load. reference/lazy-load.md is the recipe: IntersectionObserver (rootMargin ~240px) + a small concurrency cap + reserve each tile's height so lazy tiles don't reflow. Includes the verification trap - on a short/tall-default viewport all tiles intersect at once and you get a false "everything deferred" pass, so test on a deliberately small viewport.
Show full SKILL.md (735 more words)Show less
Verify before you call it done

You are building for someone who cannot tell a correct dashboard from a broken one. Verification is your job, not theirs.

  • Validate every query against the model before wiring it in (step 4): confirm it compiles and that the column names match what your render code reads.
  • Load the finished page and confirm every tile shows real numbers: not stuck on "Loading…", not an error, not an empty state you didn't intend. In a headless browser, wait on load plus a content selector, not network idle (publisher.js holds an SSE stream open; see reference/runtime.md). Don't hand-roll this each time - reference/verification-harness.md is a copy-adaptable recipe: a mock sdk/publisher.js returning canned rows keyed by (model, query), a python3 -m http.server webroot, and Playwright assertions (KPIs non-null, no .is-error, no stuck .kit-skeleton, a chart/table present). It also documents the false-"stuck skeleton" trap (assert after the mock's async delay, never on networkidle).
  • Unit-test any non-trivial pure logic (a month-join, a de-cumulation, a unit conversion). Keep that logic in DOM-free helpers so node --test can cover it, and run it.

Minimal scaffold

publisher.json at the package root:

json
{ "name": "my-package", "version": "0.0.1", "description": "..." }

public/index.html is a NEW file you create (make the public/ directory if it does not exist). Load the runtime root-relative, then query. The examples below assume a subscriptions.malloy model with a subscriptions source; the names are illustrative, so swap in your own model and a view it defines.

Start with the smallest page that proves the wiring, dumping the rows:

html
<!doctype html>
<title>My dashboard</title>
<pre id="out"></pre>
<script src="/sdk/publisher.js"></script>
<script>
  Publisher.query("subscriptions.malloy", "run: subscriptions -> plan_mix").then((rows) => {
    document.getElementById("out").textContent = JSON.stringify(rows, null, 2);
  });
</script>

Then render the rows. This page builds a table from whatever columns the view returns, so it does not depend on the exact field names:

html
<!doctype html>
<title>Account mix by plan</title>
<table id="t"><thead></thead><tbody></tbody></table>
<script src="/sdk/publisher.js"></script>
<script>
  Publisher.query("subscriptions.malloy", "run: subscriptions -> plan_mix").then((rows) => {
    const t = document.getElementById("t");
    if (!rows.length) { t.textContent = "No rows."; return; }
    const cols = Object.keys(rows[0]);
    const headRow = t.tHead.insertRow();
    for (const c of cols) {
      const th = document.createElement("th");
      th.textContent = c;
      headRow.appendChild(th);
    }
    for (const r of rows) {
      const tr = t.tBodies[0].insertRow();
      for (const c of cols) tr.insertCell().textContent = r[c];
    }
  });
</script>

Build row content with textContent, not innerHTML with model values: an innerHTML table renders any markup a value contains. This is the HTML-output side of the don't-trust-interpolated-values rule that reference/runtime.md applies to Malloy query strings.

Two invariants break a page most often:

  • The file must live under public/. Publisher serves only public/, so a page written anywhere else (for example /tmp) is never reachable at /environments/<env>/packages/<pkg>/<file>.
  • The script src must be the root-relative /sdk/publisher.js, not a relative path.

A third gotcha: the first argument to Publisher.query is the model FILE path ("subscriptions.malloy"), not the source name.

Authoring loop and publishing

Authoring happens locally, then you publish. These are two stages.

Author locally (with live reload)

Run a local Publisher from the directory that holds your publisher.config.json and package folder(s):

sh
npx @malloy-publisher/server --server_root . --port 4000 --watch-env <env>

--watch-env is not optional if you are adding public/ to a package that is already loaded. Without it the server COPIES each package into publisher_data/<env>/<pkg>/ at load time and serves static files from that copy, so a public/ directory you create afterwards is never seen: every file in it 404s while the rest of the app serves normally. This is the most expensive mistake in this skill, because it looks like your page is broken rather than like the server is stale,.

If you did not start the server (someone handed you a running one), probe before you build: write a throwaway file into the package's public/, request it, and see whether you get 200 or 404. If it 404s, either restart with --watch-env <env> or mirror your files into the served copy after every edit.

--watch-env <env> (or PUBLISHER_WATCH=<env>) mounts that environment's local-dir packages in place (a symlink, not a copy) and watches them: editing a .malloy recompiles the package, and editing a public/ file live-reloads any open page over an SSE stream. Nothing to wire in the page. The app is served at http://localhost:4000/environments/<env>/packages/<pkg>/index.html.

publisher.config.json (at --server_root) declares the environment, its packages, and its connections:

json
{
  "frozenConfig": false,
  "environments": [
    {
      "name": "<env>",
      "packages": [{ "name": "<pkg>", "location": "./<pkg>" }],
      "connections": []
    }
  ]
}

A local package uses a filesystem location ("./<pkg>", relative to the directory holding publisher.config.json); a remote one uses a GitHub tree URL. If one model in the package fails to compile, the whole package fails to load, so a stray notebook/model error blanks every tile. (Common one: a notebook that imports x.malloy more than once, such as a .malloynb whose cells each import "x.malloy", compiles as one batch, so the repeated import errors Cannot redefine 'x'. Import once, at the top.)

Publishing

Publishing an app is publishing its package: get the package into publishable shape and hand it to your host's publishing workflow. A deployed package serves its public/ app the same way a local one does, at /environments/<env>/packages/<pkg>/<file>. A deployed environment has no --watch-env live reload, so the loop there is author, publish, then view.

© malloydata, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 9 other files in skills/malloy-html-data-apps of malloydata/publisher.

  • SKILL.md
  • reference/archetypes.md
  • reference/depth-patterns.md
  • reference/design.md
  • reference/embedding.md
  • reference/lazy-load.md
  • reference/runtime.md
  • reference/token-contract.md
  • reference/verification-harness.md
  • reference/visual-craft.md

Open the folder on GitHubat commit acc1acd

Compare with similar skills

Malloy HTML Data Apps next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Malloy HTML Data Apps compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Malloy HTML Data Apps this skillmalloydata/publisher116—~3.5kAutomated safety check: PassMIT
Gameobject ModifyIvanMurzak/Unity-MCP4.4k—~2.3kAutomated safety check: PassApache-2.0
Object ModifyIvanMurzak/Unity-MCP4.4k—~2.3kAutomated safety check: PassApache-2.0
Assets ModifyIvanMurzak/Unity-MCP4.4k—~1.7kAutomated safety check: PassApache-2.0
Migrating To Modifier NoderosuH/EasyWatermark1.9k1 repos~5kAutomated safety check: PassApache-2.0
Gameobject Component ModifyIvanMurzak/Unity-MCP4.4k—~2.8kAutomated safety check: PassApache-2.0

Similar skills

  • Gameobject Modify

    IvanMurzak/Unity-MCP

    Modify GameObject fields and properties in opened Prefab or in a Scene.

    4.4k GitHub stars~2.3k tokensUpdated 3 days ago
    Game DevelopmentAuto-check passed
  • Object Modify

    IvanMurzak/Unity-MCP

    Modify a Unity UnityEngine.Object's serializable fields/properties.

    4.4k GitHub stars~2.3k tokensUpdated 3 days ago
    Game DevelopmentAuto-check passed
  • Assets Modify

    IvanMurzak/Unity-MCP

    Modify an asset file in the project. An agent skill from IvanMurzak/Unity-MCP.

    4.4k GitHub stars~1.7k tokensUpdated 3 days ago
    Game DevelopmentAuto-check passed
  • Migrating To Modifier Node

    rosuH/EasyWatermark

    A skill your agent uses to author new custom Jetpack Compose modifiers and migrate legacy ones from Modifier.composed { } to Modifier.Node + ModifierNodeElement<T.

    1.9k GitHub starsUsed in 1 repo~5k tokens
    MobileAuto-check passed
  • Gameobject Component Modify

    IvanMurzak/Unity-MCP

    Modify a specific Component on a GameObject in opened Prefab or in a Scene.

    4.4k GitHub stars~2.8k tokensUpdated 3 days ago
    Game DevelopmentAuto-check passed
  • Ordering Modifier Chains

    rosuH/EasyWatermark

    A skill your agent uses to diagnose and fix Jetpack Compose Modifier ordering bugs — wrong paint region for background, wrong click area for clickable, wrong clipping for clip, wrong measurement for…

    1.9k GitHub starsUsed in 1 repo~3.8k tokens
    MobileAuto-check passed

More from malloydata/publisher

All 29 skills in this repo
  • Eval Answer

    malloydata/publisher

    Score one analytical answer against a verified golden, and score which of the entities the golden depends on retrieval delivered to the answerer.

    116 GitHub stars~4.3k tokensUpdated today
    Auto-check passed
  • Fix Scan Finding

    malloydata/publisher

    Fix a CRITICAL Trivy finding that is failing CI in this repo (a vulnerability, misconfiguration, or secret from security-scan.yml or image-scan.yml), or add, review, or retire an entry in…

    116 GitHub stars~5.1k tokensUpdated today
    Auto-check passed
  • Eval Import

    malloydata/publisher

    Turn a list of questions into an eval set, whatever shape it arrived in: a JSONL a customer sent, a CSV, a spreadsheet export, a markdown doc, an email thread, or a pull from production logs.

    116 GitHub stars~5.9k tokensUpdated today
    Auto-check passed
  • Eval Loop

    malloydata/publisher

    Conduct a local Publisher evaluation loop in five steps: scrape/run, eval, diagnose, improve, checkpoint.

    116 GitHub stars~7.8k tokensUpdated today
    Auto-check passed
  • Eval Improve

    malloydata/publisher

    Make the smallest safe Malloy model edit that closes a diagnosed model-owned gap, with a probe receipt for every factual claim.

    116 GitHub stars~2.8k tokensUpdated today
    Auto-check passed
  • Eval Judge

    malloydata/publisher

    Decide whether ONE answer matches its golden, and say whether you believe the golden.

    116 GitHub stars~3.4k tokensUpdated today
    Auto-check passed

Questions about Malloy HTML Data Apps

What does Malloy HTML Data Apps do?

Build or modify an in-package HTML data app for a Malloy Publisher package (a public/ directory the package serves): design it, write its Publisher.query code, embed it. Malloy HTML Data Apps is an agent skill from malloydata/publisher.query code, embed it.

How do I install Malloy HTML Data Apps in Claude Code?

Run `npx skills add malloydata/publisher --skill malloy-html-data-apps -a claude-code`. Or copy the skill folder (skills/malloy-html-data-apps in malloydata/publisher) into .claude/skills/malloy-html-data-apps in your project. Claude Code loads it when a task matches its description.

How do I install Malloy HTML Data Apps in Codex?

Run `npx skills add malloydata/publisher --skill malloy-html-data-apps -a codex`. Or copy the skill folder (skills/malloy-html-data-apps in malloydata/publisher) into .agents/skills/malloy-html-data-apps in your project. Codex loads it when a task matches its description.

Can I use Malloy HTML Data Apps in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add malloydata/publisher --skill malloy-html-data-apps -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/malloy-html-data-apps, .gemini/skills/malloy-html-data-apps, .github/skills/malloy-html-data-apps and .opencode/skills/malloy-html-data-apps in your project.

What does Malloy HTML Data Apps need to run?

Going by SKILL.md and its folder, Malloy HTML Data Apps needs the command-line tools its instructions call (npx, python3 and node). Our summary lists: Python 3; Node.js.

Does Malloy HTML Data Apps access the network?

SKILL.md contains no URLs. Its commands use npx, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Malloy HTML Data Apps safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Malloy HTML Data Apps use?

Malloy HTML Data Apps is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Malloy HTML Data Apps use?

About 3.5k tokens (SKILL.md is roughly 14k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Malloy HTML Data Apps?

Skills that share tags, products or a category with Malloy HTML Data Apps: Gameobject Modify (IvanMurzak/Unity-MCP, 4.4k stars), Object Modify (IvanMurzak/Unity-MCP, 4.4k stars), Assets Modify (IvanMurzak/Unity-MCP, 4.4k stars) and Migrating To Modifier Node (rosuH/EasyWatermark, 1.9k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Malloy HTML Data Apps?

malloydata (a GitHub organization) maintains it in malloydata/publisher, which has 116 GitHub stars. The repository holds 29 skills in this directory. The repository was last updated on October 7, 2026.

Source: malloydata/publisher on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.