@genui/a3-create 0.1.36

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 (91) hide show
  1. package/README.md +123 -0
  2. package/dist/index.js +684 -0
  3. package/package.json +52 -0
  4. package/template/.cursor/rules/example-app.mdc +9 -0
  5. package/template/CLAUDE.md +121 -0
  6. package/template/README.md +20 -0
  7. package/template/_gitignore +36 -0
  8. package/template/app/ThemeProvider.tsx +17 -0
  9. package/template/app/agents/age.ts +25 -0
  10. package/template/app/agents/greeting.ts +30 -0
  11. package/template/app/agents/index.ts +57 -0
  12. package/template/app/agents/onboarding/index.ts +15 -0
  13. package/template/app/agents/onboarding/prompt.ts +59 -0
  14. package/template/app/agents/registry.ts +17 -0
  15. package/template/app/agents/state.ts +10 -0
  16. package/template/app/api/agui/route.ts +56 -0
  17. package/template/app/api/chat/route.ts +35 -0
  18. package/template/app/api/stream/route.ts +57 -0
  19. package/template/app/apple-icon-dark.png +0 -0
  20. package/template/app/apple-icon.png +0 -0
  21. package/template/app/components/atoms/AgentNode.tsx +56 -0
  22. package/template/app/components/atoms/AppLogo.tsx +44 -0
  23. package/template/app/components/atoms/ChatContainer.tsx +13 -0
  24. package/template/app/components/atoms/ChatHeader.tsx +49 -0
  25. package/template/app/components/atoms/MarkdownRenderer.tsx +134 -0
  26. package/template/app/components/atoms/MessageBubble.tsx +21 -0
  27. package/template/app/components/atoms/TransitionEdge.tsx +49 -0
  28. package/template/app/components/atoms/index.ts +7 -0
  29. package/template/app/components/molecules/ChatInput.tsx +94 -0
  30. package/template/app/components/molecules/ChatMessage.tsx +45 -0
  31. package/template/app/components/molecules/index.ts +2 -0
  32. package/template/app/components/organisms/AgentGraph.tsx +75 -0
  33. package/template/app/components/organisms/AguiChat.tsx +133 -0
  34. package/template/app/components/organisms/Chat.tsx +88 -0
  35. package/template/app/components/organisms/ChatMessageList.tsx +35 -0
  36. package/template/app/components/organisms/ExamplePageLayout.tsx +118 -0
  37. package/template/app/components/organisms/OnboardingChat.tsx +24 -0
  38. package/template/app/components/organisms/Sidebar.tsx +147 -0
  39. package/template/app/components/organisms/SidebarLayout.tsx +58 -0
  40. package/template/app/components/organisms/StateViewer.tsx +126 -0
  41. package/template/app/components/organisms/StreamChat.tsx +173 -0
  42. package/template/app/components/organisms/index.ts +10 -0
  43. package/template/app/constants/chat.ts +52 -0
  44. package/template/app/constants/paths.ts +1 -0
  45. package/template/app/constants/ui.ts +61 -0
  46. package/template/app/examples/agui/page.tsx +26 -0
  47. package/template/app/examples/chat/page.tsx +26 -0
  48. package/template/app/examples/page.tsx +106 -0
  49. package/template/app/examples/stream/page.tsx +26 -0
  50. package/template/app/favicon-dark.ico +0 -0
  51. package/template/app/favicon.ico +0 -0
  52. package/template/app/icon.svg +13 -0
  53. package/template/app/layout.tsx +36 -0
  54. package/template/app/lib/actions/restartSession.ts +10 -0
  55. package/template/app/lib/getAgentGraphData.ts +43 -0
  56. package/template/app/lib/getGraphLayout.ts +99 -0
  57. package/template/app/lib/hooks/useRestart.ts +33 -0
  58. package/template/app/lib/parseTransitionTargets.ts +140 -0
  59. package/template/app/lib/providers/anthropic.ts +12 -0
  60. package/template/app/lib/providers/bedrock.ts +12 -0
  61. package/template/app/lib/providers/openai.ts +10 -0
  62. package/template/app/onboarding/page.tsx +21 -0
  63. package/template/app/page.tsx +16 -0
  64. package/template/app/styled.d.ts +6 -0
  65. package/template/app/theme.ts +22 -0
  66. package/template/docs/A3-README.md +121 -0
  67. package/template/docs/API-REFERENCE.md +85 -0
  68. package/template/docs/ARCHITECTURE.md +84 -0
  69. package/template/docs/CORE-CONCEPTS.md +347 -0
  70. package/template/docs/CUSTOM_LOGGING.md +36 -0
  71. package/template/docs/CUSTOM_PROVIDERS.md +642 -0
  72. package/template/docs/CUSTOM_STORES.md +228 -0
  73. package/template/docs/PROVIDER-ANTHROPIC.md +45 -0
  74. package/template/docs/PROVIDER-BEDROCK.md +45 -0
  75. package/template/docs/PROVIDER-OPENAI.md +47 -0
  76. package/template/docs/PROVIDERS.md +124 -0
  77. package/template/docs/QUICK-START-EXAMPLES.md +197 -0
  78. package/template/docs/RESILIENCE.md +226 -0
  79. package/template/docs/TRANSITIONS.md +245 -0
  80. package/template/docs/WIDGETS.md +331 -0
  81. package/template/docs/contributing/LOGGING.md +104 -0
  82. package/template/docs/designs/a3-gtm-strategy.md +280 -0
  83. package/template/docs/designs/a3-platform-vision.md +276 -0
  84. package/template/next-env.d.ts +6 -0
  85. package/template/next.config.mjs +15 -0
  86. package/template/package.json +41 -0
  87. package/template/public/android-chrome-192x192.png +0 -0
  88. package/template/public/android-chrome-512x512.png +0 -0
  89. package/template/public/site.webmanifest +11 -0
  90. package/template/scripts/dev.mjs +29 -0
  91. package/template/tsconfig.json +47 -0
@@ -0,0 +1,280 @@
1
+ # Design: A3 GTM Strategy — From Framework to Repeatable Motion
2
+
3
+ Generated by /office-hours on 2026-03-19
4
+ Branch: main
5
+ Repo: generalui/a3
6
+ Status: APPROVED
7
+ Mode: Intrapreneurship
8
+ Promoted: 2026-03-19
9
+ See also: docs/designs/a3-platform-vision.md (CEO scope expansion review)
10
+
11
+ ---
12
+
13
+ ## Product Vision
14
+
15
+ A3's core thesis: **the best agentic applications are specifically defined, trustworthy, governable,
16
+ and reliable** — not open-ended do-everything assistants that may or may not do the right thing.
17
+
18
+ The platonic ideal is the optimal combination of:
19
+
20
+ - **Deterministic code** for structured, critical, compliance-sensitive actions (forms, payments,
21
+ routing decisions, data writes) — places where LLM unpredictability is unacceptable
22
+ - **Agentic flexibility** for natural language understanding, intent classification, fluid conversation,
23
+ and handling unpredictable situations within a bounded scope
24
+
25
+ Most agentic frameworks default to "let the LLM decide everything." A3's thesis is that this is
26
+ wrong for production systems. In healthcare, commerce, finance, and any regulated or high-stakes
27
+ context: **the LLM should handle what humans are naturally good at (conversation, nuance, ambiguity)
28
+ and structured code should handle everything else.**
29
+
30
+ This is not a limitation of A3 — it IS A3. The Care Agent hybrid (deterministic UI components for
31
+ intake/payments/forms, conversational agents for triage and routing) is the pattern, not an edge case.
32
+
33
+ ---
34
+
35
+ ## Problem Statement
36
+
37
+ A3 is a production-grade, open-source TypeScript framework for multi-agent AI orchestration.
38
+ The framework is built and proven in production (Experity: 2,000+ clinics, 3.5M sessions, 68% discharge automation).
39
+ The challenge is NOT product/market fit — it's turning one enterprise win into a repeatable GTM motion,
40
+ and anchoring that motion to the core product thesis (governed, trustworthy, deterministic+agentic hybrid)
41
+ rather than generic "agentic AI" positioning.
42
+
43
+ A3 serves two audiences simultaneously:
44
+
45
+ 1. **Developers** — as an open-source package to adopt and build with
46
+ 2. **Enterprise buyers** — as the engine GenUI uses to automate their manual workflows
47
+
48
+ The current positioning (landing copy, comparison tables, framework-vs-framework framing) is optimized
49
+ for audience #1. But the warm pipeline and the most compelling demand signal are coming from audience #2 —
50
+ and in both cases, the core differentiator is the **governed hybrid architecture**, not the feature list.
51
+
52
+ ---
53
+
54
+ ## Demand Evidence
55
+
56
+ - **Experity/Care Agent**: 2,000+ urgent care clinics, ~1M patients, 3.5M+ sessions, 68% of patient
57
+ discharge interactions automated. Jonathan Moss (EVP, Experity): "Staff is doing the work that
58
+ improves experience and throughput rather than repeating administrative tasks."
59
+ - **Warm pipeline**: One specific prospect — real person, identified role, real professional stakes
60
+ tied to solving this problem. Has not yet signed, but the conversation is active.
61
+ - **OSS signals**: Community / developer signals exist but are not the primary growth lever right now.
62
+
63
+ The most important demand signal in this session: **the competition is human labor, not LangChain.**
64
+ These prospects don't have an agentic workflow at all — they have staff doing repetitive,
65
+ multi-step tasks. A3 replaces the task, not the framework.
66
+
67
+ ---
68
+
69
+ ## Status Quo
70
+
71
+ The warm pipeline prospect's current workflow is staffed — humans handling a repetitive, high-volume,
72
+ multi-step process with no agentic version in existence. "Inefficient and painful" was the description.
73
+
74
+ This is the pattern: the ROI story for A3 in enterprise is not "switch frameworks" —
75
+ it's "automate what your staff is doing manually right now."
76
+
77
+ Real cost of the status quo:
78
+
79
+ - Staff time spent on workflows that don't require human judgment
80
+ - Error rates from manual, repetitive processes
81
+ - Inability to scale without proportionally growing headcount
82
+
83
+ ---
84
+
85
+ ## Target User & Narrowest Wedge
86
+
87
+ **The developer audience:**
88
+
89
+ - TypeScript engineers building multi-agent AI products
90
+ - Attracted via OSS: GitHub, docs, DX quality, community
91
+ - Acquisition channel: organic / developer word-of-mouth
92
+
93
+ **The enterprise buyer (primary GTM focus right now):**
94
+
95
+ - Ops executives, VPs of Growth/Operations, CTOs at companies with high-volume, multi-step
96
+ manual workflows in regulated or high-stakes environments
97
+ - Attracted via: Experity case study, direct outreach, partner referrals
98
+ - What gets them to sign: a bounded pilot that automates one specific workflow end-to-end
99
+ with measurable before/after (time saved, FTE cost, throughput)
100
+
101
+ **Narrowest wedge:** One workflow, fully automated, measurable ROI.
102
+ Not the platform. Not the full skills architecture.
103
+ The single workflow that hurts the most and maps cleanest to what A3 can do.
104
+
105
+ ---
106
+
107
+ ## Constraints
108
+
109
+ - GenUI is a development consultancy + framework publisher — not a pure-play sales org
110
+ - A3 must serve both developers (OSS) and enterprises (GenUI clients) — dual-track messaging required
111
+ - No dedicated sales team; GTM runs through the same people who build
112
+ - The CoBuilder Partner Program exists but needs a proven sales motion before it can create leverage
113
+ - The observation gap: GenUI has not yet watched the warm pipeline prospect's manual workflow in detail
114
+
115
+ ---
116
+
117
+ ## Premises
118
+
119
+ 1. **The real competition is human labor, not other frameworks** — for enterprise buyers,
120
+ A3 is competing against staffed workflows, not LangChain. The comparison table on the
121
+ landing page is aimed at the wrong buyer. *(agreed)*
122
+
123
+ 2. **The economic buyer is not the developer** — developers are influencers and implementers,
124
+ but the person who signs is an ops exec measuring FTE cost and automation rate.
125
+ Two different conversations, two different messages. *(agreed)*
126
+
127
+ 3. **The CoBuilder Partner Program is premature (for now)** — partners need a repeatable sales
128
+ motion to execute. Until GenUI has proven the second enterprise win, the partner program
129
+ creates overhead without leverage. *(agreed)*
130
+
131
+ 4. **Healthcare is a wedge, not a destination** — Experity is in healthcare, but "regulated
132
+ workflows" as the primary positioning limits the TAM unnecessarily. The pattern
133
+ (manual, high-volume, multi-step workflows) exists in commerce, ops, HR tech,
134
+ logistics, insurance. *(agreed)*
135
+
136
+ ---
137
+
138
+ ## Approaches Considered
139
+
140
+ ### Approach A: Land the Second Client First
141
+
142
+ Focus 100% on converting the warm pipeline to a paid pilot.
143
+ Nothing else until there is a second reference customer.
144
+
145
+ - **Effort:** S
146
+ - **Risk:** Low
147
+ - **Pros:** Real person, real stakes, real problem. Forces the "watch the workflow" step.
148
+ Second client makes the partner program real.
149
+ - **Cons:** One-at-a-time; doesn't scale. OSS adoption continues to stagnate in parallel.
150
+
151
+ ### Approach B: Two Tracks in Parallel
152
+
153
+ Run OSS developer community growth (docs, DX, GitHub) alongside enterprise outreach
154
+ (vertical playbooks, warm pipeline). Separate messaging for each audience.
155
+
156
+ - **Effort:** L
157
+ - **Risk:** Med (split focus on a lean team)
158
+ - **Pros:** Covers both audiences. Community builds long-term moat; enterprise funds now.
159
+ - **Cons:** Two buyers, two messages, one team. Easy to be mediocre at both.
160
+ OSS is a 12-18 month compounding game.
161
+
162
+ ### Approach C: Vertical Playbook — One More, Done Right
163
+
164
+ Pick one adjacent vertical. Build a specific playbook: 5 manual workflows that map to A3,
165
+ ROI calculator, reference architecture, pitch narrative. Use it to close the warm pipeline
166
+ AND recruit one anchor partner.
167
+
168
+ - **Effort:** M
169
+ - **Risk:** Med
170
+ - **Pros:** Builds repeatable sales infrastructure. Gives the CoBuilder Program something
171
+ concrete to sell.
172
+ - **Cons:** Requires real vertical expertise. Wrong vertical choice = wasted effort.
173
+
174
+ ---
175
+
176
+ ## Recommended Approach: A then C
177
+
178
+ **Sequence matters.** Close the warm pipeline first (Approach A), then build the vertical
179
+ playbook (Approach C). The second enterprise client teaches you what the playbook should say.
180
+ Building the playbook before you've lived through a second deal is writing fiction.
181
+
182
+ **How the sequence plays out:**
183
+
184
+ 1. **Now:** Watch the workflow. Sit with the warm pipeline prospect's team and observe the
185
+ manual process they want to automate — without helping, without guiding. What happens?
186
+ What's surprising? That observation shapes the pilot scope.
187
+
188
+ 2. **Next 30 days:** Scope and propose a bounded pilot. One workflow, fully automated,
189
+ measurable before/after. Get it signed.
190
+
191
+ 3. **During the pilot:** Document everything — the workflow map, the handoff points,
192
+ the schema design, the session state choices. This becomes Playbook Template v1.
193
+
194
+ 4. **Post-pilot:** Turn the second case study + the documentation into the vertical playbook.
195
+ NOW activate the CoBuilder Partner Program with that playbook as the sales tool.
196
+
197
+ **For the developer/OSS track (parallel, but lower priority):**
198
+
199
+ - Improve docs and quickstart experience (already in progress per git log)
200
+ - The Experity case study is the most powerful dev community signal — make it findable
201
+ - Don't split messaging: "A3 is what GenUI uses to build Care Agent-scale systems" is a
202
+ better dev pitch than "A3 vs LangGraph feature comparison"
203
+
204
+ ---
205
+
206
+ ## Open Questions
207
+
208
+ 1. **What vertical is the warm pipeline in?** If it's healthcare again, the second client
209
+ confirms a vertical thesis. If it's different, it expands the positioning story.
210
+
211
+ 2. **What does the pilot pricing look like?** Is this a consulting engagement where GenUI
212
+ builds the automation, or a framework licensing play where the client's team builds with
213
+ A3 + GenUI support? The answer changes the GTM motion significantly.
214
+
215
+ 3. **Who inside GenUI owns the "watch the workflow" step?** This is not a sales task —
216
+ it's a product/design research task. Someone needs to go observe before the pilot scope
217
+ is written.
218
+
219
+ 4. **Is the developer OSS track meant to generate enterprise leads, or is it a separate
220
+ community-building goal?** If devs are meant to become enterprise champions (bottom-up),
221
+ the DX and docs investment is justified. If the two tracks are genuinely separate, they
222
+ need separate owners.
223
+
224
+ ---
225
+
226
+ ## Success Criteria
227
+
228
+ - **30 days:** Warm pipeline pilot scoped, proposal sent, response received
229
+ - **60 days:** Second enterprise client signed (or clear reason it didn't close)
230
+ - **90 days:** Second case study drafted + one vertical playbook document complete
231
+ - **6 months:** CoBuilder Partner Program has one active partner using the playbook
232
+ - **OSS:** A3 GitHub repo has a clear "here's what this looks like in production" section
233
+ linking to Experity + second case study
234
+
235
+ ---
236
+
237
+ ## Dependencies
238
+
239
+ - Warm pipeline: the specific person needs to agree to a workflow observation session
240
+ - GenUI leadership: alignment that "land the second client" is the priority before partner
241
+ program scaling
242
+ - Experity: permission to use the case study in new vertical outreach (already in A3_overview.md)
243
+
244
+ ---
245
+
246
+ ## The Assignment
247
+
248
+ **This week:** Ask the warm pipeline contact for a 90-minute session where you can watch
249
+ their team do the workflow you're proposing to automate. Don't demo A3. Don't pitch.
250
+ Just watch. Take notes. What are the steps? Where does information move between people?
251
+ Where does something get looked up? Where does judgment get applied vs. where is it rote?
252
+
253
+ That observation session is the foundation of a pilot scope that actually fits the problem.
254
+ Without it, you're scoping from assumptions.
255
+
256
+ ---
257
+
258
+ ## What I noticed about how you think
259
+
260
+ - You said the competition is "humans — the agentic version of the workflow doesn't exist."
261
+ That's the clearest GTM insight in the whole session, and you said it like it was obvious.
262
+ It's not obvious. Most framework builders never get there because they're talking to
263
+ developers, not operators.
264
+
265
+ - When I challenged the premises, you agreed with all four AND corrected me with new
266
+ information ("dual-purpose OSS + enterprise"). That's not compliance — that's a
267
+ well-formed mental model of a hard trade-off. You know what you're holding.
268
+
269
+ - You chose "A then C" immediately. No hedging, no "it depends." That's the right call
270
+ and it was fast. People who've thought about sequencing are faster at this question
271
+ than people who haven't.
272
+
273
+ - "One specific workflow automated end-to-end" — you didn't say "a demo" or "a proof of
274
+ concept." You said the thing you'd actually ship. That matters.
275
+
276
+ - When you pushed back on the design doc, you didn't say "I want to change the strategy."
277
+ You said "we're missing the core thesis." That's product thinking, not marketing thinking.
278
+ The governed hybrid architecture — deterministic where it matters, agentic where it helps —
279
+ is a genuine product insight that most AI framework builders don't have because they're
280
+ optimizing for demos, not production systems. You named it precisely.
@@ -0,0 +1,276 @@
1
+ # A3 Platform Vision — From Framework to Governed Agentic Standard
2
+
3
+ Generated by /plan-ceo-review on 2026-03-19
4
+ Branch: main | Mode: Scope Expansion
5
+ Status: ACTIVE
6
+
7
+ ---
8
+
9
+ ## Vision
10
+
11
+ ### The 10x Version
12
+
13
+ A3 becomes what WordPress became for websites — the default stack for deploying production
14
+ agentic workflows.
15
+ Every serious enterprise implementing agentic AI in healthcare, regulated industries, or
16
+ high-volume commerce uses A3.
17
+ When a developer at a 500-person company needs to automate a patient discharge workflow,
18
+ they find A3, run `npx create-a3-app --template=patient-discharge`, and have a running
19
+ prototype in 45 minutes.
20
+
21
+ GenUI operates at three tiers:
22
+
23
+ 1. **Framework publisher** — open source, community, standards
24
+ 2. **Premium agent publisher** — `@genui/agent-patient-intake`, `@genui/agent-retail-returns`, etc.
25
+ 3. **Enterprise integrator** — for organizations that want help through complex implementations
26
+ 4. **Certification authority** — "A3 Certified" developer credential for agencies and partners
27
+
28
+ Revenue compounds: self-serve (product) → partner-built (CoBuilder) → GenUI-built (enterprise).
29
+
30
+ ### Platonic Ideal
31
+
32
+ **Sarah, VP of Patient Experience at a 200-clinic urgent care chain:**
33
+ Her CTO Googles "A3 agentic framework," finds a site that says "Build what Experity built.
34
+ Here's how."
35
+ He runs `npx create-a3-app --template=patient-discharge`.
36
+ Working prototype in one hour, deployed to their AWS account, demoing to front-desk staff
37
+ two weeks later.
38
+ The feeling: "I didn't need to wait 18 months. I built it in a weekend."
39
+
40
+ **Marcus, developer at a digital agency with healthcare clients:**
41
+ He takes the A3 certification course (4 hours), becomes "A3 Certified."
42
+ He finds two pre-built `@genui/agent-*` packages that cover 80% of what his clients need.
43
+ GenUI is on the other end of a Slack channel for the remaining 20%.
44
+ The feeling: "I can offer this to my clients, and I'm not alone when it gets hard."
45
+
46
+ ---
47
+
48
+ ## Core Product Thesis
49
+
50
+ > A3's thesis: the best agentic applications are specifically defined, trustworthy,
51
+ > governable, and reliable — not open-ended do-everything assistants.
52
+
53
+ The platonic ideal combines:
54
+
55
+ - **Deterministic code** for structured, critical, compliance-sensitive actions (forms, payments,
56
+ routing decisions, data writes) — where LLM unpredictability is unacceptable
57
+ - **Agentic flexibility** for natural language understanding, intent classification, fluid
58
+ conversation, and handling unpredictable situations within a bounded scope
59
+
60
+ This is A3's permanent differentiator vs. LangChain, LangGraph, and general-purpose AI frameworks.
61
+ They optimize for capability.
62
+ A3 optimizes for governability.
63
+
64
+ ---
65
+
66
+ ## Accepted Scope — This Initiative
67
+
68
+ ### 1. Use-Case Templates
69
+
70
+ Extend the `create` CLI to support `--template` flags:
71
+
72
+ ```bash
73
+ npx create-a3-app --template=patient-discharge
74
+ npx create-a3-app --template=retail-returns
75
+ npx create-a3-app --template=staff-onboarding
76
+ ```
77
+
78
+ Each template ships pre-wired agent configurations, Zod schemas matching that domain,
79
+ API integration stubs, and `complianceSurface` defaults where applicable.
80
+ Framing: **workflow-first, not industry-first** (like WordPress themes, not industry verticals).
81
+
82
+ Effort: S (CC: ~4h)
83
+
84
+ ### 2. Analytics / Observability Layer
85
+
86
+ A3 sessions already have state, schema-validated outputs, agent handoffs, and timestamps.
87
+ Ship a structured analytics events interface with first-class adapters for OpenTelemetry,
88
+ Datadog, and Grafana.
89
+ For deployments without existing observability infra: include a reference dashboard in the
90
+ example app.
91
+ An ops exec should be able to see their own "68% automated" number from their own deployment.
92
+
93
+ Effort: S–M (CC: ~3h)
94
+
95
+ ### 3. `complianceSurface` Configuration
96
+
97
+ A configuration flag that activates a bundle of production defaults appropriate for a
98
+ given compliance surface:
99
+
100
+ ```typescript
101
+ createChatSession({
102
+ complianceSurface: 'hipaa', // or 'soc2', 'gdpr'
103
+ provider,
104
+ store,
105
+ })
106
+ ```
107
+
108
+ Activates: PII detection and redaction, audit-trail logging with tamper-evident timestamps,
109
+ configurable data retention TTLs, encrypted session state.
110
+
111
+ **Critical framing:** "This configures A3's defaults for the HIPAA compliance surface.
112
+ It does not certify your application as HIPAA compliant."
113
+ Requires legal review of the API and documentation before shipping.
114
+
115
+ Effort: M (CC: ~6h)
116
+
117
+ ### 4. A3 Advisor Agents (First `@genui/agent-*` Packages)
118
+
119
+ A3 ships with a suite of purpose-built advisor agents — published as installable npm packages.
120
+ These become the first `@genui/agent-*` reference implementations.
121
+ A3 uses A3 to teach A3.
122
+
123
+ - **`@genui/agent-a3-guide`** — conversational A3 tutorial with codebase context. Ask it
124
+ "how do I set up routing?" and it walks you through it with examples from your project.
125
+ - **`@genui/agent-a3-deployment`** — helps you choose provider, infrastructure config, and
126
+ compliance surface for your use case.
127
+ - **`@genui/agent-a3-compliance`** — explains what each `complianceSurface` setting does,
128
+ what it doesn't cover, and what additional organizational steps are required.
129
+ - **`@genui/agent-a3-audit`** — reads your `a3 audit export` output and explains it in plain
130
+ language for a non-technical compliance officer or auditor.
131
+
132
+ Each use-case template (above) ships with `@genui/agent-a3-guide` pre-wired.
133
+ Each agent demonstrates the governed hybrid thesis: specific job, bounded scope, validated output.
134
+
135
+ Effort: S (CC: ~4h)
136
+
137
+ ### 5. `a3 doctor` — Configuration Linter
138
+
139
+ A CLI command that analyzes your agent configuration before it hits production:
140
+
141
+ ```bash
142
+ a3 doctor
143
+ # ✓ No circular routing detected
144
+ # ✓ All agents have terminal paths
145
+ # ⚠ agent 'intake': outputSchema has 12 required fields — consider reducing
146
+ # ✗ complianceSurface: 'hipaa' set but phone number field has no PII redaction
147
+ ```
148
+
149
+ Flags: circular routing risks, missing fallback/terminal agents, schema fields likely to
150
+ confuse the LLM, and `complianceSurface`-specific warnings.
151
+ Runs in CI; catches architecture problems at build time.
152
+
153
+ Effort: S (CC: ~2h)
154
+
155
+ ### 6. `a3 audit export` — Compliance Artifact Generator
156
+
157
+ A CLI command that generates a structured, timestamped audit report for a session:
158
+
159
+ ```bash
160
+ a3 audit export --session=SESSION_ID --format=hipaa
161
+ # → ./audit-2026-03-19-SESSION_ID.pdf
162
+ # → ./audit-2026-03-19-SESSION_ID.json
163
+ ```
164
+
165
+ The PDF is **human-readable and user-friendly** — designed to be handed to an auditor or
166
+ compliance officer without embarrassment.
167
+ Layout: summary page first (session overview, outcome, violation count), then per-turn
168
+ detail (agent name, action, data extracted with PII masked, routing decision).
169
+ Signed with a tamper-evident hash.
170
+
171
+ Effort: S (CC: ~2h)
172
+
173
+ ### 7. `a3` CLI Consolidation
174
+
175
+ The `create` package evolves into the unified `a3` CLI:
176
+
177
+ ```text
178
+ @genui/a3-cli (was: @genui/a3-create)
179
+ ├── a3 create --template=<use-case> # scaffold a new project
180
+ ├── a3 doctor # analyze agent config, flag issues
181
+ └── a3 audit export --session=<id> # generate compliance artifact
182
+ ```
183
+
184
+ **One-way door warning:** once the CLI API is published, command signatures create
185
+ user expectations.
186
+ Design the command surface carefully before 1.0.
187
+ Decide now: does `a3` CLI version independently of `@genui/a3` core?
188
+
189
+ ---
190
+
191
+ ## Architecture Diagram
192
+
193
+ ```text
194
+ @genui/a3-cli
195
+ ├── a3 create --template=<name>
196
+ ├── a3 doctor
197
+ └── a3 audit export
198
+
199
+ @genui/a3 (core, extended)
200
+ ├── complianceSurface config
201
+ ├── Analytics events interface
202
+ │ ├── OTel adapter
203
+ │ ├── Datadog adapter
204
+ │ └── Grafana adapter
205
+ └── Audit trail emission
206
+
207
+ @genui/agent-* (Advisor Agents + future domain agents)
208
+ ├── @genui/agent-a3-guide
209
+ ├── @genui/agent-a3-deployment
210
+ ├── @genui/agent-a3-compliance
211
+ └── @genui/agent-a3-audit
212
+
213
+ create-a3-app templates/
214
+ ├── templates/default/ (existing)
215
+ ├── templates/patient-discharge/
216
+ ├── templates/retail-returns/
217
+ └── templates/staff-onboarding/
218
+
219
+ example/ (Next.js app — ships reference dashboard)
220
+ ```
221
+
222
+ ---
223
+
224
+ ## Platform Flywheel (18-Month Vision)
225
+
226
+ ```text
227
+ Templates → Developers adopt A3 → Need more agents → @genui/agent-* fills gaps
228
+ ↑ |
229
+ └──── Community publishes their own agents ←──────────────┘
230
+ (agent package registry / marketplace)
231
+ ```
232
+
233
+ This initiative establishes the foundation.
234
+ The marketplace comes when the community exists.
235
+
236
+ ---
237
+
238
+ ## NOT in Scope (Deferred)
239
+
240
+ - Full agent package registry / marketplace — 18-month horizon; needs community first
241
+ - GenUI Managed A3 / hosted SaaS offering — requires significant infrastructure
242
+ - A3 certification program — needs a developer community to certify
243
+ - Agent routing live visualizer — Phase 2 delight item
244
+ - `A3 Compatibility Badge` npm interface standard — needs ecosystem participants
245
+
246
+ ---
247
+
248
+ ## Strategic Premises
249
+
250
+ From the office-hours GTM session (see `docs/designs/a3-gtm-strategy.md`):
251
+
252
+ - **Competition is human labor, not other frameworks** — enterprise buyers aren't choosing
253
+ between A3 and LangChain; they're choosing between automated workflows and staffed workflows
254
+ - **Economic buyer is an ops exec, not a developer** — developers influence; ops execs sign
255
+ - **`complianceSurface` (not "compliance mode")** — signals tuning, not certification; legally safer
256
+ - **A3 is taking over the GenUI identity** — the GenUI site is being rebuilt around A3
257
+ as a first-class citizen
258
+ - **Use-case templates (not verticals)** — workflow-first framing matches the WordPress mental model
259
+
260
+ ---
261
+
262
+ ## Open Questions (Resolve Before Implementation)
263
+
264
+ 1. **`a3 doctor` analysis mode:** Static analysis (parse TypeScript source files) vs. runtime
265
+ introspection (spin up a test A3 instance)? Static works in CI without side effects;
266
+ runtime is more accurate.
267
+ 2. **`@genui/agent-*` pricing:** Free OSS, freemium, or premium for domain-specific agents?
268
+ Affects positioning and the CoBuilder partner value prop.
269
+ 3. **`complianceSurface` legal review:** Get legal/compliance sign-off on the API design and
270
+ documentation framing before shipping.
271
+ 4. **PDF audit export persona:** Primary reader is compliance officer or auditor — not a
272
+ developer. Design review required for the PDF layout before implementation.
273
+ 5. **Template selection:** Which 2-3 templates ship first? Should match the warm pipeline
274
+ vertical — don't build `patient-discharge` if the second client is in commerce.
275
+ 6. **`a3` CLI versioning:** Does the CLI version independently of `@genui/a3` core?
276
+ What's the compatibility matrix?
@@ -0,0 +1,6 @@
1
+ /// <reference types="next" />
2
+ /// <reference types="next/image-types/global" />
3
+ import "./.next/types/routes.d.ts";
4
+
5
+ // NOTE: This file should not be edited
6
+ // see https://nextjs.org/docs/app/api-reference/config/typescript for more information.
@@ -0,0 +1,15 @@
1
+ import fs from 'node:fs'
2
+ import path from 'node:path'
3
+
4
+ // Check if we are running in the GenUI A3 monorepo
5
+ const isMonorepo = fs.existsSync(path.join(import.meta.dirname, '..', 'a3.code-workspace'))
6
+
7
+ /** @type {import('next').NextConfig} */
8
+ const nextConfig = {
9
+ reactStrictMode: true,
10
+ turbopack: {
11
+ root: isMonorepo ? path.join(import.meta.dirname, '..') : import.meta.dirname,
12
+ },
13
+ }
14
+
15
+ export default nextConfig
@@ -0,0 +1,41 @@
1
+ {
2
+ "name": "@genui/example",
3
+ "version": "0.1.0",
4
+ "scripts": {
5
+ "build": "next build",
6
+ "dev": "node scripts/dev.mjs",
7
+ "start": "next start"
8
+ },
9
+ "dependencies": {
10
+ "@ag-ui/client": "0.0.45",
11
+ "@ag-ui/encoder": "0.0.45",
12
+ "@emotion/react": "11.14.0",
13
+ "@emotion/styled": "11.14.1",
14
+ "@genui/a3": "latest",
15
+ "@genui/a3-anthropic": "latest",
16
+ "@genui/a3-bedrock": "latest",
17
+ "@genui/a3-openai": "latest",
18
+ "@mui/icons-material": "7.3.7",
19
+ "@mui/material": "7.3.7",
20
+ "next": "16.1.7",
21
+ "react": "19.2.4",
22
+ "react-dom": "19.2.4",
23
+ "react-markdown": "10.1.0",
24
+ "react-syntax-highlighter": "15.6.1",
25
+ "remark-gfm": "4.0.1",
26
+ "@dagrejs/dagre": "2.0.4",
27
+ "@xyflow/react": "12.10.1",
28
+ "styled-components": "6.3.8",
29
+ "zod": "4.3.6"
30
+ },
31
+ "devDependencies": {
32
+ "@types/node": "20.19.0",
33
+ "@types/react": "19.2.10",
34
+ "@types/react-dom": "19.2.3",
35
+ "@types/react-syntax-highlighter": "15.5.13",
36
+ "typescript": "5.9.3"
37
+ },
38
+ "overrides": {
39
+ "fast-xml-parser": "5.5.6"
40
+ }
41
+ }
@@ -0,0 +1,11 @@
1
+ {
2
+ "name": "A3 Core Example",
3
+ "short_name": "A3 Example",
4
+ "icons": [
5
+ { "src": "/android-chrome-192x192.png", "sizes": "192x192", "type": "image/png" },
6
+ { "src": "/android-chrome-512x512.png", "sizes": "512x512", "type": "image/png" }
7
+ ],
8
+ "theme_color": "#ffffff",
9
+ "background_color": "#ffffff",
10
+ "display": "standalone"
11
+ }
@@ -0,0 +1,29 @@
1
+ import { exec, spawn } from 'node:child_process'
2
+
3
+ function openBrowser(url) {
4
+ const quoted = encodeURI(url)
5
+ const cmd =
6
+ process.platform === 'win32'
7
+ ? `cmd.exe /c start ${quoted}`
8
+ : process.platform === 'darwin'
9
+ ? `open '${quoted}'`
10
+ : `xdg-open '${quoted}'`
11
+ exec(cmd)
12
+ }
13
+
14
+ const child = spawn('next', ['dev'], {
15
+ stdio: ['inherit', 'pipe', 'inherit'],
16
+ shell: process.platform === 'win32', // required for Windows PATH resolution
17
+ })
18
+
19
+ function onData(data) {
20
+ process.stdout.write(data)
21
+ const match = data.toString().match(/Local:\s+(https?:\/\/localhost:\d+)/)
22
+ if (match) {
23
+ child.stdout.off('data', onData)
24
+ openBrowser(match[1])
25
+ }
26
+ }
27
+
28
+ child.stdout.on('data', onData)
29
+ child.on('exit', (code) => process.exit(code ?? 0))