Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/add-fingerprint-viewer.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"ghost-fingerprint": minor
---

Add `ghost-fingerprint emit viewer` to generate a portable HTML explorer for a fingerprint package.
14 changes: 9 additions & 5 deletions apps/docs/src/content/docs/cli-reference.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -217,13 +217,14 @@ ghost-fingerprint diff a/fingerprint.md b/fingerprint.md
ghost-fingerprint diff a.md b.md --format json
```

### Emit — derive outputs from `fingerprint.md`
### Emit — derive outputs from `profile.md`

Derive an output from `fingerprint.md`. Kinds: `review-command` (a
Derive an output from the fingerprint package profile. Kinds: `review-command` (a
per-project slash command at `.claude/commands/design-review.md`),
`context-bundle` (SKILL.md + fingerprint.md + prompt.md + tokens.css for any
generator), or `skill` (the `ghost-fingerprint` agentskills.io bundle —
install this into your host agent for the `profile` recipe).
`context-bundle` (SKILL.md + profile.md + prompt.md + tokens.css for any
generator), `viewer` (a portable single-file HTML explorer), or `skill` (the
`ghost-fingerprint` agentskills.io bundle — install this into your host agent
for the `profile` recipe).

<CliHelp tool="ghost-fingerprint" command="emit" hideDescription />

Expand All @@ -237,6 +238,9 @@ ghost-fingerprint emit review-command
# Emit a context bundle any generator can consume
ghost-fingerprint emit context-bundle

# Emit a portable HTML viewer for humans
ghost-fingerprint emit viewer

# Single prompt.md for plain-text LLM context
ghost-fingerprint emit context-bundle --prompt-only

Expand Down
7 changes: 7 additions & 0 deletions apps/docs/src/content/docs/getting-started.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -153,8 +153,15 @@ ghost-fingerprint lint map.md # ghost.map/v2
ghost-fingerprint lint survey.json # ghost.survey/v2
ghost-fingerprint verify-profile fingerprint.md survey.json --root .
# fingerprint-to-survey fidelity

# Optional human-readable explorer
ghost-fingerprint emit viewer # ./fingerprint-viewer.html
```

`emit viewer` is a derived artifact, not a second source of truth. It renders
the profile plus sibling `survey.json`, `map.md`, and `checks.yml` when they
exist so humans can visually inspect the design-language package.

</DocSection>

<DocSection title="Compare Two Systems">
Expand Down
16 changes: 12 additions & 4 deletions apps/docs/src/generated/cli-manifest.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"generatedAt": "2026-05-07T00:33:39.453Z",
"generatedAt": "2026-05-07T11:10:39.905Z",
"tools": [
{
"tool": "ghost-drift",
Expand Down Expand Up @@ -426,7 +426,7 @@
"tool": "ghost-fingerprint",
"name": "emit",
"rawName": "emit <kind>",
"description": "Emit a derived artifact from the fingerprint package profile (kinds: review-command, context-bundle, skill)",
"description": "Emit a derived artifact from the fingerprint package profile (kinds: review-command, context-bundle, viewer, skill)",
"options": [
{
"rawName": "-p, --profile <path>",
Expand All @@ -439,19 +439,27 @@
{
"rawName": "-o, --out <path>",
"name": "out",
"description": "Output path (review-command → .claude/commands/design-review.md; context-bundle → ghost-context/; skill → .claude/skills/ghost-fingerprint/)",
"description": "Output path (review-command → .claude/commands/design-review.md; context-bundle → ghost-context/; skill → .claude/skills/ghost-fingerprint/; viewer → fingerprint-viewer.html)",
"default": null,
"takesValue": true,
"negated": false
},
{
"rawName": "--stdout",
"name": "stdout",
"description": "Write to stdout instead of a file (review-command only)",
"description": "Write to stdout instead of a file (review-command, viewer)",
"default": null,
"takesValue": false,
"negated": false
},
{
"rawName": "--budget <budget>",
"name": "budget",
"description": "Survey summary depth for viewer: compact, standard, or full (default: standard)",
"default": null,
"takesValue": true,
"negated": false
},
{
"rawName": "--no-tokens",
"name": "tokens",
Expand Down
7 changes: 7 additions & 0 deletions packages/ghost-fingerprint/src/core/context/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
export type { EmitReviewInput } from "./review-command.js";
export { emitReviewCommand } from "./review-command.js";
export { buildTokensCss } from "./tokens-css.js";
export type {
BuildFingerprintViewerHtmlInput,
ViewerArtifactName,
ViewerArtifactState,
ViewerArtifactStatus,
} from "./viewer.js";
export { buildFingerprintViewerHtml } from "./viewer.js";
export type {
ContextFormat,
WriteContextOptions,
Expand Down
Loading