austere-axi 0.1.0 → 0.2.0
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.
- package/README.md +51 -7
- package/dist/austere.js +505 -134
- package/dist/cli.mjs +3424 -126
- package/dist/prompt.md +18 -9
- package/dist/spec.json +1 -1
- package/package.json +2 -1
- package/skills/austere/SKILL.md +2 -0
package/README.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# austere-axi
|
|
2
2
|
|
|
3
|
+
[](https://www.npmjs.com/package/austere-axi)
|
|
4
|
+
[](https://www.npmjs.com/package/austere-axi)
|
|
5
|
+
[](https://www.jsdelivr.com/package/npm/austere-axi)
|
|
6
|
+
[](https://skills.sh/mandalorianbatman/austere-axi)
|
|
7
|
+
[](https://github.com/MandalorianBatman/austere-axi/actions/workflows/ci.yml)
|
|
8
|
+
[](https://www.npmjs.com/package/austere-axi)
|
|
9
|
+
[](LICENSE)
|
|
10
|
+
|
|
3
11
|
Review artifacts for coding agents, written in [OpenUI Lang](https://github.com/thesysdev/openui) instead of hand-written HTML.
|
|
4
12
|
|
|
5
13
|
The agent writes a short program: one named statement per line, built from a fixed set of components. The reviewer opens it in the browser, points at anything, and the agent gets the feedback back addressed by statement name. To revise, the agent edits only the statements the feedback names, and the page updates in place.
|
|
@@ -11,15 +19,19 @@ root = Stack([intro, flow, options, decide], "column", "l")
|
|
|
11
19
|
intro = Card([CardHeader("Session storage migration", "Redis → Postgres"), introText])
|
|
12
20
|
introText = MarkDownRenderer("Sessions are lost on failover. **Goal:** durable sessions, no forced logout.")
|
|
13
21
|
flow = Card([CardHeader("Request path"), flowDiagram])
|
|
14
|
-
flowDiagram =
|
|
15
|
-
|
|
22
|
+
flowDiagram = Architecture([client, api, pg], [toApi, toPg])
|
|
23
|
+
client = Node("Client", "external")
|
|
24
|
+
api = Node("API", "backend", "Node :8080")
|
|
25
|
+
pg = Node("Postgres", "database", "sessions table", "new")
|
|
26
|
+
toApi = Edge(client, api, "HTTPS", "emphasis")
|
|
27
|
+
toPg = Edge(api, pg, "SQL")
|
|
16
28
|
options = Card([CardHeader("Rollout options"), optionTable])
|
|
17
29
|
optionTable = Table([Col("Option", ["Big bang", "Dual-write"]), Col("Risk", [Tag("high", null, "sm", "danger"), Tag("low", null, "sm", "success")])])
|
|
18
30
|
decide = Form("rollout", Buttons([Button("Send decision", @ToAssistant("Decision: rollout"), "primary")]), [strategyField])
|
|
19
31
|
strategyField = FormControl("Rollout", RadioGroup("strategy", [RadioItem("Big bang", "", "bigbang"), RadioItem("Dual-write", "", "dualwrite")]))
|
|
20
32
|
```
|
|
21
33
|
|
|
22
|
-
[`examples/session-migration.html`](examples/session-migration.html) is a full page: a KPI row, a diagram, a table, a chart, a diff, and a decision form. The whole file is about
|
|
34
|
+
[`examples/session-migration.html`](examples/session-migration.html) is a full page: a KPI row, a diagram, a table, a chart, a diff, and a decision form. The whole file is about 1,000 tokens.
|
|
23
35
|
|
|
24
36
|
## Why
|
|
25
37
|
|
|
@@ -47,18 +59,50 @@ agent edits statements ◄── austere-axi poll plan.html ◄─┘ (long-pol
|
|
|
47
59
|
```
|
|
48
60
|
|
|
49
61
|
- **An artifact is a plain `.html` file.** It contains one `<script>` tag for the runtime and one `<script type="text/openui">` block holding the program. Opened directly, it renders from the CDN. Under review, the server points that tag at a local copy.
|
|
50
|
-
- **The runtime** bundles the OpenUI React renderer with a curated component library: 58 of the stock components, plus `Mermaid`, `Diff` and `FileTree`. Every rendered statement is tagged with its name.
|
|
62
|
+
- **The runtime** bundles the OpenUI React renderer with a curated component library: 58 of the stock components, plus `Architecture` (with `Node`, `Edge` and `Group`), `Mermaid`, `Diff` and `FileTree`. Every rendered statement is tagged with its name.
|
|
63
|
+
- **Architecture diagrams** are laid out automatically ([dagre](https://github.com/dagrejs/dagre)): the agent writes nodes, edges and groups as statements and never a coordinate. Each node and edge is its own click target, so feedback on a diagram arrives as `annotation: api (Node)` with its line. The layout runs across when that stays legible at the page width and down otherwise, so a phone gets a tall diagram. For a system split by owner or tier, `lanes` turns each group into a column with right-angle lines between them (stacked as bands on a phone); `tone` tints a box or line to mark risk or a store family. Mermaid stays for sequences, state machines, ER and gantt.
|
|
51
64
|
- **Annotations** resolve to the innermost named statement. They also carry precise detail where it exists: table row and column, `file:+line` for diff lines, the label of a diagram node, or the selected text. The popover shows the parent chain, so the reviewer can retarget a note to an enclosing section.
|
|
52
65
|
- **Buttons and forms** are feedback channels. `@ToAssistant("…")` queues a message along with the form's values. A button with no action sends its label.
|
|
53
66
|
- **Remote review.** When Tailscale is running, the server also listens on this machine's tailnet IP, and `open` prints a phone link. The review UI has a mobile layout with a conversation sheet.
|
|
54
67
|
|
|
55
68
|
## Install
|
|
56
69
|
|
|
70
|
+
Requires Node.js 20 or later.
|
|
71
|
+
|
|
72
|
+
**Run it without installing** (what agents use):
|
|
73
|
+
|
|
74
|
+
```sh
|
|
75
|
+
npx -y austere-axi --help
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
`npx` downloads the package into npm's cache and runs it. `-y` skips the install prompt, so a non-interactive agent never stalls on it. Prefix every command below the same way: `npx -y austere-axi spec`, `npx -y austere-axi plan.html`, and so on.
|
|
79
|
+
|
|
80
|
+
**Or install the command globally:**
|
|
81
|
+
|
|
82
|
+
```sh
|
|
83
|
+
npm install -g austere-axi
|
|
84
|
+
austere-axi --help
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
A global install stays on the version you installed until `npm update -g austere-axi`. Mixing the two is fine: a newer CLI replaces an older background server automatically.
|
|
88
|
+
|
|
89
|
+
**Agent skill (optional):**
|
|
90
|
+
|
|
57
91
|
```sh
|
|
58
92
|
npx skills add MandalorianBatman/austere-axi --skill austere
|
|
59
93
|
```
|
|
60
94
|
|
|
61
|
-
The skill is a stub that sends the agent to `npx -y austere-axi --help` and `spec
|
|
95
|
+
The skill tells an agent when a page beats prose and adds an `/austere <request>` command. It is a stub that sends the agent to `npx -y austere-axi --help` and `spec`, so an installed copy cannot go stale. Agents that can run shell commands do not need it.
|
|
96
|
+
|
|
97
|
+
## Quick start
|
|
98
|
+
|
|
99
|
+
```sh
|
|
100
|
+
npx -y austere-axi spec # component reference for the agent (read once per session)
|
|
101
|
+
npx -y austere-axi plan.html # validate and open the page for review
|
|
102
|
+
npx -y austere-axi poll plan.html # wait for the reviewer to press Send
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
`--help` prints the file skeleton and the full review loop.
|
|
62
106
|
|
|
63
107
|
## CLI
|
|
64
108
|
|
|
@@ -70,7 +114,7 @@ austere-axi reply <file> post a reply without polling
|
|
|
70
114
|
austere-axi end <file> end the review as the agent
|
|
71
115
|
austere-axi check <file> validate the program (no browser)
|
|
72
116
|
austere-axi patch <file> merge statements from stdin into the program
|
|
73
|
-
austere-axi spec [group...] component reference (~
|
|
117
|
+
austere-axi spec [group...] component reference (~6.5k tokens; groups narrow it)
|
|
74
118
|
austere-axi export <file> one self-contained HTML file, works offline
|
|
75
119
|
austere-axi stop stop the background server
|
|
76
120
|
```
|
|
@@ -130,7 +174,7 @@ node dist/cli.mjs examples/session-migration.html
|
|
|
130
174
|
|
|
131
175
|
| Path | Contents |
|
|
132
176
|
|---|---|
|
|
133
|
-
| `src/runtime/components/` | Custom components (`Diff`, `Mermaid`, `FileTree`), one self-describing file each, collected automatically |
|
|
177
|
+
| `src/runtime/components/` | Custom components (`Architecture` family, `Diff`, `Mermaid`, `FileTree`), one self-describing file each, collected automatically |
|
|
134
178
|
| `src/runtime/stock.js` | Which stock OpenUI components ship, their prompt groups, renderer overrides |
|
|
135
179
|
| `src/runtime/` | Library assembly, annotation layer, review bridge, styles |
|
|
136
180
|
| `src/chrome/` | Review UI around the artifact iframe |
|