@phnx-labs/artifacts-cli 0.8.1 → 0.8.3-pre.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/CHANGELOG.md +47 -1
  2. package/README.md +33 -122
  3. package/package.json +20 -3
package/CHANGELOG.md CHANGED
@@ -1,6 +1,52 @@
1
1
  # Changelog
2
2
 
3
- ## Unreleased
3
+ ## 0.8.3-pre.1 — 2026-10-08
4
+
5
+ - **Releases publish from GitHub, with no npm token.** A release is a PR from a branch
6
+ named `release/v<version>` (`x.y.z`, or `x.y.z-pre.n` for npm `next`) that bumps
7
+ `package.json` and `CHANGELOG.md`; CI checks the three agree. Merging it runs the new
8
+ Release workflow, which publishes through `scripts/release.sh` using npm trusted
9
+ publishing (npm trusts the workflow's GitHub identity) and tags `v<version>`.
10
+ `release.sh` gains that auth mode and requires npm 11.5.1 or later for it. A release
11
+ that changes the share Worker template stops in CI with the command to run from a
12
+ machine set up with `artifacts share`. `package.json` gains `repository`, which npm
13
+ matches against the publishing workflow.
14
+
15
+ ## 0.8.2 — 2026-10-08
16
+
17
+ - **The `artifacts` command survives publishing.** `bin` points at `dist/cli.js`
18
+ instead of `./dist/cli.js`; npm 11.6 to 11.13 rewrote the old form by deleting the
19
+ command from the published package. The release dry run now runs
20
+ `npm publish --dry-run` and stops if npm would rewrite `package.json`, and a
21
+ release checks the npm token with `npm whoami` before publishing instead of
22
+ failing with npm's misleading 404.
23
+
24
+ - **A README and npm page for someone deciding whether to try it.** The README is
25
+ short now: the promise, a picture, three commands to try, the reasons to use it,
26
+ and a link to https://artifacts-cli.sh. Its images load from artifacts-cli.sh, so
27
+ they show on npm too (the relative paths rendered as broken images there). The npm
28
+ page gains a homepage link and keywords. The command table and full feature list
29
+ live in `artifacts --help` and `docs/reference.md`; building and releasing moved
30
+ unchanged to `docs/development.md`.
31
+
32
+ - **The sky on artifacts-cli.sh is the visitor's own.** The site's Worker now
33
+ answers `GET /__sky` with Cloudflare's location for the connection (rounded
34
+ to 0.1 degree) and the cloud cover and humidity there from MET Norway,
35
+ fetched by the Worker and cached per location, so no third party sees the
36
+ visitor. The page draws that sun and those clouds; the time zone stands in
37
+ until it answers. `?clouds=0..100` previews a cover. Every other path is
38
+ still a plain static-asset hit.
39
+ - **artifacts-cli.sh sits on the living sky.** The landing page drops the navy
40
+ palette (retired in the Phoenix design system) for the sky getrush.ai uses:
41
+ colors solved from the visitor's sun, drifting clouds, the sun's disc, stars
42
+ after dark, and a descent to the horizon as you scroll. Day or Altitude now
43
+ follows the sun instead of the OS setting; `?sky=dawn|day|dusk|night` previews
44
+ a moment. The 404 page drops navy too.
45
+ - **The page tells the whole loop.** The hero shows a conversation condensing
46
+ into the artifact it produced. Two new scenes follow the human half: answer a
47
+ worksheet field and leave a note, export, and watch `artifacts answers` and
48
+ `artifacts notes` hand them to the agent; then drag through revisions with the
49
+ matching `artifacts history` listing.
4
50
 
5
51
  ## 0.8.1 — 2026-10-07
6
52
 
package/README.md CHANGED
@@ -1,146 +1,57 @@
1
- # artifacts
1
+ # Artifacts
2
2
 
3
- **Your agent writes Markdown. Your readers get a polished page.**
3
+ **The chat ends. The artifact stays.**
4
4
 
5
- `artifacts` compiles agent-authored Markdown into self-contained HTML (diagrams,
6
- charts, drill-downs, diffs, forms) and publishes it as a link you can send.
5
+ Your coding agent writes a short Markdown file. `artifacts` turns it into one polished
6
+ HTML page, with diagrams, charts, drill-downs and diffs, that you can read, mark up and
7
+ share as a link.
7
8
 
8
9
  <picture>
9
- <source media="(prefers-color-scheme: dark)" srcset="docs/assets/hero-dark.png">
10
- <img alt="A short plan.md on the left; on the right, the rendered page with a branded cover and an interactive explorer" src="docs/assets/hero-light.png">
10
+ <source media="(prefers-color-scheme: dark)" srcset="https://artifacts-cli.sh/assets/hero-dark.png">
11
+ <img alt="A short plan.md on the left; on the right, the rendered page with a branded cover and an interactive explorer" src="https://artifacts-cli.sh/assets/hero-light.png">
11
12
  </picture>
12
13
 
13
- ## Gallery
14
-
15
- These are real renders of the files in [`examples/`](examples). Each one is a
16
- single HTML file that works offline, in light and dark.
17
-
18
- <picture>
19
- <source media="(prefers-color-scheme: dark)" srcset="docs/assets/gallery-dark.png">
20
- <img alt="Rendered components: SVG diagram, explorer, bar chart, source excerpt, diff, worksheet, stat panels and a harness cover" src="docs/assets/gallery-light.png">
21
- </picture>
22
-
23
- ## Why
24
-
25
- - **About 90% fewer tokens.** The agent writes content, not CSS. The
26
- [example plan](examples/plan.md) is 2,391 tokens of Markdown against 25,028
27
- tokens of equivalent HTML.
28
- - **One look across every agent.** Claude, Codex and Gemini all render through
29
- the same design. Set your palette once in `DESIGN.md`.
30
- - **Components from plain fences.** `explorer`, `bar-chart`, `diff`, `excerpt`
31
- and `field` take JSON or tables. You don't write any HTML for them.
32
- - **Built for reading.** Contents rail, collapsible sections, link previews, a
33
- generated references list, highlights and notes.
34
- - **Share in one command.** Get a public, org-only or private link with an
35
- unfurl card. Re-sharing keeps the same URL and saves the old version.
36
- - **Safe by default.** Embedded HTML and SVG are sanitized. Before publishing,
37
- the file is scanned for emails and credentials.
38
-
39
- ## How it works
40
-
41
- **The agent writes the content. The renderer writes the page.** The agent never
42
- writes component HTML, CSS or JavaScript. It learns the format from the
43
- `artifacts` skill and `artifacts components --json`. `artifacts check` reports
44
- mistakes by line number until the source is valid. The renderer then adds the
45
- layout, theme, components, code highlighting and provenance, and writes one
46
- self-contained `.html` file.
47
-
48
- <img alt="How artifacts-cli works: the agent reads the skill and component catalogue and writes plan.md; artifacts check sends errors back; artifacts render combines the Markdown with components, DESIGN.md and git into one HTML file, which is previewed locally, saved to history, or shared as a link" src="docs/assets/how-it-works.png">
49
-
50
- This is everything the agent writes for an interactive drill-down:
51
-
52
- ````markdown
53
- ---
54
- kind: visual
55
- title: Where the dead code is
56
- summary: Two services carry most of the dead code.
57
- ---
58
-
59
- ## Story
60
-
61
- Most of the removable code sits in two services.
62
-
63
- ## Figure
64
-
65
- ```explorer
66
- { "title": "Removable code", "metric": {"label": "Removable", "unit": "%", "max": 100},
67
- "items": [{ "label": "Web", "value": 25 }, { "label": "API", "value": 10 }] }
68
- ```
69
- ````
14
+ ## Try it
70
15
 
71
16
  ```bash
72
- artifacts render cleanup.md --open # live preview, re-renders on save
73
- artifacts share cleanup.md # https://share.getrush.ai/<you>/where-the-dead-code-is
74
- ```
75
-
76
- The `.html` file is written next to its Markdown, usually in
77
- `.agents/artifacts/<date>/` inside your repository. Every render is also saved
78
- to local history, so earlier versions can be reopened.
79
-
80
- ## Commands
81
-
82
- | Command | What it does |
83
- | --- | --- |
84
- | `artifacts new <plan\|report\|visual\|worksheet\|design>` | Scaffold an artifact with provenance filled in |
85
- | `artifacts render file.md [--open]` | Compile to self-contained HTML, optionally serve and watch |
86
- | `artifacts check file.md` | Validate without rendering |
87
- | `artifacts components [name]` | List components and their input contracts |
88
- | `artifacts share file.md [--visibility me\|org] [--unlisted]` | Publish a link (managed, or your own Cloudflare) |
89
- | `artifacts share list \| revisions \| visibility \| open` | Manage what you've published |
90
- | `artifacts unshare <slug>` | Take a page down and verify it 404s |
91
- | `artifacts comments plan.md [--json]` | Read, reply to and resolve a shared page's review threads as your agent |
92
- | `artifacts answers ws.md` | Read or merge worksheet answers |
93
- | `artifacts list [--favorites]` | Artifacts known to this machine |
17
+ npm i -g @phnx-labs/artifacts-cli # Node 20 or later
94
18
 
95
- Run `artifacts <command> --help` for the workflow and flags. Theming,
96
- components, embedded HTML classes, sharing, self-hosting the Worker and local
97
- history are all covered in the [full reference](docs/reference.md).
98
-
99
- ## Install
100
-
101
- ```bash
102
- npm i -g @phnx-labs/artifacts-cli # installs the `artifacts` command (Node 20+)
103
- artifacts auth login # optional, enables managed sharing
19
+ artifacts new report --out report.md # a starter file
20
+ artifacts render report.md --open # the page, re-rendered on every save
104
21
  ```
105
22
 
106
- Give your agents the authoring skill through
107
- [agents-cli](https://github.com/phnx-labs/agents-cli):
23
+ Then give your agents the skill, so they write artifacts for you:
108
24
 
109
25
  ```bash
110
26
  agents skills add gh:phnx-labs/artifacts-cli --names artifacts --agents claude,codex -y
111
27
  ```
112
28
 
113
- PDF export is optional and needs `playwright`.
29
+ (That uses [agents-cli](https://agi-cli.sh). Run `artifacts auth login` once to share
30
+ pages as links with `artifacts share report.md`.)
114
31
 
115
- ## Develop
116
-
117
- ```bash
118
- bun install
119
- bun run test
120
- scripts/build.sh
121
- ```
32
+ ## Why
122
33
 
123
- Releases go through `scripts/release.sh`, which dry-runs unless you pass `--confirm`:
34
+ - **About 90% fewer tokens.** The agent writes content, not HTML and CSS. A plan that
35
+ takes 25,028 tokens as HTML takes 2,391 as Markdown.
36
+ - **Real components from plain text.** Charts, drill-downs, diffs and forms come from a
37
+ few lines of JSON or a table.
38
+ - **The page talks back.** Readers highlight, leave notes and answer worksheet questions
39
+ on the page; your agent reads them with `artifacts notes` and `artifacts answers`.
40
+ - **Every version stays.** Each render is saved locally, so earlier versions reopen with
41
+ `artifacts history`.
42
+ - **One file, safe to send.** The HTML works offline, in light and dark. Embedded HTML is
43
+ sanitized, and a page is checked for credentials before it is shared.
124
44
 
125
- ```bash
126
- scripts/release.sh 1.2.3 # dry run
127
- secrets exec npmjs.com -- scripts/release.sh 1.2.3 --confirm # stable
128
- secrets exec npmjs.com -- scripts/release.sh 1.2.3-pre.1 --confirm # pre-release
129
- ```
45
+ <picture>
46
+ <source media="(prefers-color-scheme: dark)" srcset="https://artifacts-cli.sh/assets/gallery-dark.png">
47
+ <img alt="Rendered components: SVG diagram, explorer, bar chart, source excerpt, diff, worksheet, stat panels and a harness cover" src="https://artifacts-cli.sh/assets/gallery-light.png">
48
+ </picture>
130
49
 
131
- | | `1.2.3` | `1.2.3-pre.1` |
132
- | --- | --- | --- |
133
- | npm tag | `latest` | `next` (`npm i -g` keeps installing the stable version) |
134
- | git tag | `v1.2.3`, pushed right after publishing | `v1.2.3-pre.1` |
135
- | Share Worker | redeployed when its template changed | skipped unless `--deploy-worker=on` |
136
- | artifacts-cli.sh | redeployed | skipped unless `--deploy-website=on` |
50
+ ## Learn more
137
51
 
138
- `--deploy-worker=auto|on|off` and `--deploy-website=on|off` override either
139
- default. If a deploy fails after publishing, the script prints the command that
140
- finishes it. To change only the landing page, run
141
- `secrets exec cloudflare.com -- scripts/deploy-website.sh`. See
142
- [CHANGELOG.md](CHANGELOG.md).
52
+ See the whole loop at **[artifacts-cli.sh](https://artifacts-cli.sh)**. Every command
53
+ explains itself with `artifacts <command> --help`.
143
54
 
144
55
  ## License
145
56
 
146
- [Apache-2.0](LICENSE)
57
+ Apache-2.0
package/package.json CHANGED
@@ -1,10 +1,27 @@
1
1
  {
2
2
  "name": "@phnx-labs/artifacts-cli",
3
- "version": "0.8.1",
4
- "description": "Render Markdown artifacts into polished HTML and publish them as shareable links.",
3
+ "version": "0.8.3-pre.1",
4
+ "description": "Your coding agent writes Markdown; artifacts turns it into one polished HTML page you can read, mark up and share as a link.",
5
+ "homepage": "https://artifacts-cli.sh",
6
+ "repository": {
7
+ "type": "git",
8
+ "url": "git+https://github.com/phnx-labs/artifacts-cli.git"
9
+ },
10
+ "keywords": [
11
+ "ai-agents",
12
+ "coding-agents",
13
+ "claude-code",
14
+ "codex",
15
+ "markdown",
16
+ "html",
17
+ "artifacts",
18
+ "reports",
19
+ "diagrams",
20
+ "cli"
21
+ ],
5
22
  "type": "module",
6
23
  "bin": {
7
- "artifacts": "./dist/cli.js"
24
+ "artifacts": "dist/cli.js"
8
25
  },
9
26
  "files": [
10
27
  "dist",