@agent-native/core 0.41.1 → 0.42.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.
Files changed (97) hide show
  1. package/dist/action.d.ts +13 -1
  2. package/dist/action.d.ts.map +1 -1
  3. package/dist/action.js.map +1 -1
  4. package/dist/agent/production-agent.d.ts +8 -0
  5. package/dist/agent/production-agent.d.ts.map +1 -1
  6. package/dist/agent/production-agent.js +93 -0
  7. package/dist/agent/production-agent.js.map +1 -1
  8. package/dist/cli/app-skill.d.ts +16 -0
  9. package/dist/cli/app-skill.d.ts.map +1 -1
  10. package/dist/cli/app-skill.js +33 -3
  11. package/dist/cli/app-skill.js.map +1 -1
  12. package/dist/cli/pr-visual-recap-workflow.d.ts +1 -1
  13. package/dist/cli/pr-visual-recap-workflow.d.ts.map +1 -1
  14. package/dist/cli/pr-visual-recap-workflow.js +1 -1
  15. package/dist/cli/pr-visual-recap-workflow.js.map +1 -1
  16. package/dist/cli/recap.d.ts.map +1 -1
  17. package/dist/cli/recap.js +14 -3
  18. package/dist/cli/recap.js.map +1 -1
  19. package/dist/cli/skills.d.ts +34 -3
  20. package/dist/cli/skills.d.ts.map +1 -1
  21. package/dist/cli/skills.js +172 -48
  22. package/dist/cli/skills.js.map +1 -1
  23. package/dist/client/AssistantChat.d.ts.map +1 -1
  24. package/dist/client/AssistantChat.js +2 -2
  25. package/dist/client/AssistantChat.js.map +1 -1
  26. package/dist/client/agent-chat-adapter.d.ts.map +1 -1
  27. package/dist/client/agent-chat-adapter.js +172 -5
  28. package/dist/client/agent-chat-adapter.js.map +1 -1
  29. package/dist/client/blocks/library/AnnotatedCodeBlock.d.ts +19 -0
  30. package/dist/client/blocks/library/AnnotatedCodeBlock.d.ts.map +1 -1
  31. package/dist/client/blocks/library/AnnotatedCodeBlock.js +5 -57
  32. package/dist/client/blocks/library/AnnotatedCodeBlock.js.map +1 -1
  33. package/dist/client/blocks/library/ApiEndpointBlock.d.ts.map +1 -1
  34. package/dist/client/blocks/library/ApiEndpointBlock.js +116 -7
  35. package/dist/client/blocks/library/ApiEndpointBlock.js.map +1 -1
  36. package/dist/client/blocks/library/DataModelBlock.d.ts.map +1 -1
  37. package/dist/client/blocks/library/DataModelBlock.js +75 -9
  38. package/dist/client/blocks/library/DataModelBlock.js.map +1 -1
  39. package/dist/client/blocks/library/DiffBlock.d.ts +1 -1
  40. package/dist/client/blocks/library/DiffBlock.d.ts.map +1 -1
  41. package/dist/client/blocks/library/DiffBlock.js +195 -34
  42. package/dist/client/blocks/library/DiffBlock.js.map +1 -1
  43. package/dist/client/blocks/library/HighlightedCode.d.ts +1 -1
  44. package/dist/client/blocks/library/HighlightedCode.js +1 -1
  45. package/dist/client/blocks/library/HighlightedCode.js.map +1 -1
  46. package/dist/client/blocks/library/annotation-rail.d.ts +96 -0
  47. package/dist/client/blocks/library/annotation-rail.d.ts.map +1 -0
  48. package/dist/client/blocks/library/annotation-rail.js +120 -0
  49. package/dist/client/blocks/library/annotation-rail.js.map +1 -0
  50. package/dist/client/blocks/library/api-endpoint.config.d.ts +31 -6
  51. package/dist/client/blocks/library/api-endpoint.config.d.ts.map +1 -1
  52. package/dist/client/blocks/library/api-endpoint.config.js +30 -6
  53. package/dist/client/blocks/library/api-endpoint.config.js.map +1 -1
  54. package/dist/client/blocks/library/code.d.ts.map +1 -1
  55. package/dist/client/blocks/library/code.js +32 -15
  56. package/dist/client/blocks/library/code.js.map +1 -1
  57. package/dist/client/blocks/library/columns.d.ts.map +1 -1
  58. package/dist/client/blocks/library/columns.js +56 -35
  59. package/dist/client/blocks/library/columns.js.map +1 -1
  60. package/dist/client/blocks/library/data-model.config.d.ts +17 -0
  61. package/dist/client/blocks/library/data-model.config.d.ts.map +1 -1
  62. package/dist/client/blocks/library/data-model.config.js +15 -0
  63. package/dist/client/blocks/library/data-model.config.js.map +1 -1
  64. package/dist/client/blocks/library/diff.config.d.ts +28 -6
  65. package/dist/client/blocks/library/diff.config.d.ts.map +1 -1
  66. package/dist/client/blocks/library/diff.config.js +30 -6
  67. package/dist/client/blocks/library/diff.config.js.map +1 -1
  68. package/dist/client/blocks/types.d.ts +2 -2
  69. package/dist/client/blocks/types.d.ts.map +1 -1
  70. package/dist/client/blocks/types.js.map +1 -1
  71. package/dist/client/rich-markdown-editor/DragHandle.d.ts.map +1 -1
  72. package/dist/client/rich-markdown-editor/DragHandle.js +75 -9
  73. package/dist/client/rich-markdown-editor/DragHandle.js.map +1 -1
  74. package/dist/client/rich-markdown-editor/RegistryBlockNode.d.ts +25 -1
  75. package/dist/client/rich-markdown-editor/RegistryBlockNode.d.ts.map +1 -1
  76. package/dist/client/rich-markdown-editor/RegistryBlockNode.js +29 -6
  77. package/dist/client/rich-markdown-editor/RegistryBlockNode.js.map +1 -1
  78. package/dist/client/rich-markdown-editor/SharedRichEditor.d.ts +8 -1
  79. package/dist/client/rich-markdown-editor/SharedRichEditor.d.ts.map +1 -1
  80. package/dist/client/rich-markdown-editor/SharedRichEditor.js +5 -1
  81. package/dist/client/rich-markdown-editor/SharedRichEditor.js.map +1 -1
  82. package/dist/extensions/actions.d.ts.map +1 -1
  83. package/dist/extensions/actions.js +159 -12
  84. package/dist/extensions/actions.js.map +1 -1
  85. package/dist/extensions/store.d.ts +21 -0
  86. package/dist/extensions/store.d.ts.map +1 -1
  87. package/dist/extensions/store.js +33 -1
  88. package/dist/extensions/store.js.map +1 -1
  89. package/dist/server/recap-image-route.d.ts.map +1 -1
  90. package/dist/server/recap-image-route.js +12 -3
  91. package/dist/server/recap-image-route.js.map +1 -1
  92. package/dist/templates/workspace-core/.agents/skills/extensions/SKILL.md +30 -5
  93. package/docs/content/plan-plugin.md +107 -0
  94. package/docs/content/skills-guide.md +8 -0
  95. package/docs/content/visual-plans.md +2 -0
  96. package/package.json +1 -1
  97. package/src/templates/workspace-core/.agents/skills/extensions/SKILL.md +30 -5
@@ -0,0 +1,107 @@
1
+ ---
2
+ title: "Plan plugin & marketplace"
3
+ description: "Install the Agent-Native Plan skills (/visual-plan, /visual-recap, /ui-plan, /prototype-plan, /plan-design, /visual-questions) plus the hosted Plan MCP connector as a Claude Code or Codex plugin, or with the universal CLI. How updates work and whether you need to submit anything."
4
+ ---
5
+
6
+ # Plan plugin & marketplace
7
+
8
+ The Agent-Native **Plan** app ships as one installable bundle. A single install adds all six Plan slash-command skills **and** wires up the hosted Plan MCP connector, so the agent can generate plans and the skills can publish them straight into the Plan app.
9
+
10
+ ## What you get {#what-you-get}
11
+
12
+ One install gives you:
13
+
14
+ - **Six skills** — `/visual-plan` (the canonical entry point), `/visual-recap`, `/ui-plan`, `/prototype-plan`, `/plan-design`, and `/visual-questions`.
15
+ - **The Plan MCP connector** — registered against the hosted app at `https://plan.agent-native.com` (MCP endpoint `https://plan.agent-native.com/_agent-native/mcp`, server name `agent-native-plans`).
16
+
17
+ All six skills **always publish to the hosted Plan app** — they create a plan via the MCP connector and hand you a link or inline plan to review. They never dump an inline Markdown/ASCII plan into chat as the deliverable. If a Plan tool returns `needs auth`, `Unauthorized`, or `Session terminated`, authenticate the connector (see each route below) instead of falling back to inline output.
18
+
19
+ > The plugin (`agent-native-visual-plans`) carries app id `visual-plans`, which is why the Claude Code plugin name and Codex plugin name are both `agent-native-visual-plans`. The Plan app's display name is "Agent-Native Plan".
20
+
21
+ ## Install routes {#install}
22
+
23
+ There are three ways in. The **universal CLI route** is the one we recommend by default, because it installs the skills **and** registers and authenticates the MCP connector in a single step. The plugin routes are for hosts with a first-class plugin/marketplace system.
24
+
25
+ ### Universal skill route (any MCP host) {#universal}
26
+
27
+ Works for any host — Claude Code, Codex, Cursor, Cline, Goose, ChatGPT custom MCP apps, Claude Cowork, and anything else MCP-compatible. The Agent-Native CLI installs the six skills, registers the hosted Plan MCP connector, **and authenticates it in the same step**, so your first tool call does not hit an OAuth wall:
28
+
29
+ ```bash
30
+ npx @agent-native/core@latest skills add visual-plan
31
+ # or, if the CLI is already on PATH:
32
+ agent-native skills add visual-plan
33
+ ```
34
+
35
+ This installs `visual-plan` plus the companion `visual-recap`, `visual-questions`, `ui-plan`, `prototype-plan`, and `plan-design` skills, then registers the `agent-native-plans` connector and runs auth (OAuth prompt for hosted/account-backed sharing). Useful flags:
36
+
37
+ - `--client codex|claude-code|claude-code-cli|cowork|all` — which local agents to write the MCP config for (default `codex`).
38
+ - `--no-connect` — register the connector without authenticating; run `agent-native connect https://plan.agent-native.com` later.
39
+ - `--mcp-url <url>` — point the connector at a custom origin (an ngrok tunnel, a local dev server, or a self-hosted deployment) instead of the hosted default.
40
+ - `--with-github-action` — also write the PR Visual Recap GitHub Action (see [PR Visual Recap](/docs/pr-visual-recap)).
41
+
42
+ After it finishes, restart or reload the agent client so the new skills and tools load, then run `/visual-plan`.
43
+
44
+ > Note: the bare `npx skills add BuilderIO/agent-native --skill visual-plan` (Vercel/open Skills CLI) installs **instructions only** — it does not register the MCP connector. Use the Agent-Native CLI above when you want the connector wired up too.
45
+
46
+ ### Claude Code (plugin) {#claude-code}
47
+
48
+ The public `BuilderIO/agent-native` repo is itself a Claude Code plugin marketplace, so you add it directly — no build step. Inside Claude Code:
49
+
50
+ ```text
51
+ /plugin marketplace add BuilderIO/agent-native
52
+ /plugin install agent-native-visual-plans@agent-native-apps
53
+ /reload-plugins
54
+ /mcp # authenticate the Plan connector (one OAuth approval)
55
+ ```
56
+
57
+ `/plugin install` adds the six Plan skills and a **URL-only** MCP config (no secrets in the package); `/mcp` → **Authenticate** completes the OAuth handshake.
58
+
59
+ > The marketplace catalog is named `agent-native-apps` and the Plan plugin is `agent-native-visual-plans`, so the install target is always `agent-native-visual-plans@agent-native-apps`.
60
+
61
+ ### Codex (plugin) {#codex}
62
+
63
+ The same repo is a Codex plugin marketplace. Add it, install the plugin, then authenticate the connector:
64
+
65
+ ```bash
66
+ codex plugin marketplace add BuilderIO/agent-native
67
+ codex plugin add agent-native-visual-plans@agent-native-apps
68
+ codex mcp login agent-native-plans # OAuth in the browser
69
+ ```
70
+
71
+ After install, **start a new Codex thread** so the skills and MCP tools load into the session. The plugin ships a URL-only connector (`[mcp_servers.agent-native-plans]` → `https://plan.agent-native.com/_agent-native/mcp`); `codex mcp login` runs the OAuth flow. The universal CLI route above also works for Codex (`agent-native skills add visual-plan --client codex`) if you prefer one command that installs and authenticates together.
72
+
73
+ ## Updates {#updates}
74
+
75
+ The plugin routes auto-update — you do not re-pack or re-add the marketplace for routine skill changes:
76
+
77
+ - **Claude Code** — the marketplace entry sets `autoUpdate: true` and the plugin uses commit-SHA versioning, so Claude Code pulls new versions from the repo at startup; run `/reload-plugins` to activate. Every push to the repo's default branch reaches installed users automatically.
78
+ - **Codex** — the plugin `version` embeds a content hash of the bundled skills and MCP endpoint (e.g. `1.0.0+codex.<hash>`), so any skill or endpoint change yields a new version. Codex's startup auto-upgrade re-installs configured git marketplaces on its own; just **start a new thread** to pick up the change. No manual `codex plugin marketplace upgrade` is needed for routine updates.
79
+ - **Universal CLI route** — re-run `npx @agent-native/core@latest skills add visual-plan` to refresh the skills and re-register the connector. `@latest` always pulls the current skills from the published `@agent-native/core` package.
80
+
81
+ The connector points at a **hosted** app, so the Plan app's actions and live tool surface always reflect the deployed version regardless of when you installed; only the bundled skill instructions follow the update mechanisms above.
82
+
83
+ > **Maintainers:** the marketplace bundle (`.claude-plugin/`, `.agents/plugins/`) is generated from the canonical plan skills by `pnpm sync:plan-marketplace` and verified in CI by `pnpm guard:plan-marketplace`, so the published marketplace always matches the canonical skills. Edit the skill, run `pnpm sync:plan-marketplace`, and commit.
84
+
85
+ ## Do you need to submit anything? {#submission}
86
+
87
+ **No submission or review is required to distribute or install this.** `BuilderIO/agent-native` is a self-hosted, public git marketplace, so users add it directly with the commands above on **both Claude Code and Codex** — no application or approval. The universal CLI route needs no marketplace at all.
88
+
89
+ Optional discoverability, if you want a public listing:
90
+
91
+ - **Claude Code** has a community marketplace you can _optionally_ submit to for listing (submission plus an automated review). The official, Anthropic-curated marketplace is listed at Anthropic's discretion — there is no open self-serve application. Neither is required to use the install commands above.
92
+ - **Codex** has an OpenAI-curated plugin catalog (a closed allow-list, sourced as a partnership rather than a self-serve submission). Self-hosted git marketplaces and the CLI route need no submission to work.
93
+
94
+ In short: ship it as a self-hosted/public git marketplace and users install directly; submit to a curated catalog only if you want it listed for discovery.
95
+
96
+ ## Plugin vs. skill {#plugin-vs-skill}
97
+
98
+ A **skill** is a single `SKILL.md` instruction file the agent reads when a task matches. A **plugin** (Claude Code marketplace plugin or Codex plugin) is a package that bundles one or more skills **plus** an MCP connector and metadata, so a host can install everything in one step.
99
+
100
+ Under the hood, all three routes are produced from the same source by the `agent-native app-skill` CLI: `app-skill pack` builds the marketplace/plugin adapters, and `skills add` is the friendly one-step installer that also registers and authenticates the MCP connector. See [Skills Guide](/docs/skills-guide) for the app-skill manifest format, and [External Agents](/docs/external-agents) for connecting any MCP host and the `agent-native connect` flow.
101
+
102
+ ## What's next {#whats-next}
103
+
104
+ - [**Visual Plans**](/docs/visual-plans) — what the skills do and how to use them
105
+ - [**PR Visual Recap**](/docs/pr-visual-recap) — run `/visual-recap` automatically on every pull request
106
+ - [**Skills Guide**](/docs/skills-guide) — app-backed skills and the manifest format
107
+ - [**External Agents**](/docs/external-agents) — connect any MCP host and round-trip artifacts
@@ -124,6 +124,14 @@ plugin directory containing `skills/<name>/SKILL.md` and `.mcp.json`. In Claude
124
124
  Code, add the marketplace, install `agent-native-assets@agent-native-apps`,
125
125
  reload plugins, then authenticate the URL-only MCP connector from `/mcp`.
126
126
 
127
+ Generated plugin manifests are set up to auto-update: the Claude Code
128
+ marketplace entry sets `autoUpdate: true` (with commit-SHA versioning) and the
129
+ Codex plugin `version` embeds a content hash of the bundled skills and MCP
130
+ endpoint, so installed plugins pick up skill changes without re-packing. The
131
+ Plan app is published this way as a ready-to-add marketplace at the repo root —
132
+ see [Plan plugin & marketplace](/docs/plan-plugin) for the end-to-end install
133
+ and auto-update flow.
134
+
127
135
  ## Creating custom skills {#creating-skills}
128
136
 
129
137
  Create a skill when:
@@ -22,6 +22,8 @@ agent-native skills add visual-plan
22
22
 
23
23
  Authentication is a one-time browser sign-in at setup — this is intended, and it is what lets the agent persist and share the plans it generates. This also installs the companion `/visual-recap` command for reviewing changes that already landed (see [Invoking the skill](#invoke)).
24
24
 
25
+ > **Prefer a one-install plugin?** Claude Code and Codex can add `BuilderIO/agent-native` directly as a plugin marketplace, which bundles the six Plan skills _and_ the connector in one install and auto-updates as the skills improve — see [Plan plugin & marketplace](/docs/plan-plugin).
26
+
25
27
  What the auth step does depends on your client:
26
28
 
27
29
  - **OAuth-capable hosts** (Claude Code) get a URL-only MCP entry plus a prompt to run `/mcp` and choose **Authenticate**.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agent-native/core",
3
- "version": "0.41.1",
3
+ "version": "0.42.0",
4
4
  "type": "module",
5
5
  "engines": {
6
6
  "node": ">=22"
@@ -133,14 +133,39 @@ POST /_agent-native/extensions
133
133
 
134
134
  The action accepts:
135
135
 
136
- | Field | Type | Required | Purpose |
137
- | ------------- | -------- | -------- | ----------------------------- |
138
- | `name` | `string` | yes | Display name of the extension |
139
- | `description` | `string` | no | Short summary |
140
- | `content` | `string` | yes | Alpine.js HTML body |
136
+ | Field | Type | Required | Purpose |
137
+ | ---------------------- | -------- | -------- | -------------------------------------------------- |
138
+ | `name` | `string` | yes | Display name of the extension |
139
+ | `description` | `string` | no | Short summary |
140
+ | `content` | `string` | yes\* | Alpine.js HTML body (\*unless `contentFromAttachment`) |
141
+ | `contentFromAttachment`| `string` | no | Host a pasted/attached file verbatim, by reference |
142
+ | `icon` | `string` | no | Icon name or short label |
141
143
 
142
144
  See `references/examples.md` for full, runnable `content` bodies.
143
145
 
146
+ ### Hosting a pasted file (by reference)
147
+
148
+ When the user **pastes a large file** (e.g. a finished HTML/Alpine app) and asks
149
+ you to host it as an extension, do NOT copy that file into the `content`
150
+ argument. A big paste shows up in your context as a
151
+ `<attachment name="pasted-text-…">` block; re-typing it as a tool argument burns
152
+ thousands of output tokens and frequently gets cut off mid-stream, stalling the
153
+ turn.
154
+
155
+ Instead, leave `content` empty and pass `contentFromAttachment` set to that
156
+ attachment's `name` — or the literal string `"latest"` for the most recent
157
+ pasted block. The server reads the attachment verbatim and stores it as the
158
+ extension content:
159
+
160
+ ```json
161
+ { "name": "My Dashboard", "contentFromAttachment": "latest" }
162
+ ```
163
+
164
+ `update-extension` accepts the same `contentFromAttachment` for full-body
165
+ replacement. Inline `content` still works for everything you author yourself —
166
+ use `contentFromAttachment` only to avoid regurgitating something the user
167
+ already pasted.
168
+
144
169
  ## Editing an extension
145
170
 
146
171
  Use the `update-extension` action. Prefer granular `edits` for surgical