howone 0.1.31 → 0.1.32

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 (19) hide show
  1. package/package.json +1 -1
  2. package/templates/vite/.howone/skills/howone/01-architect/01-app-generation.md +33 -27
  3. package/templates/vite/.howone/skills/howone/01-architect/02-manifest-codegen.md +2 -2
  4. package/templates/vite/.howone/skills/howone/02-entity-schema/01-schema-design.md +9 -29
  5. package/templates/vite/.howone/skills/howone/02-entity-schema/02-schema-operations.md +166 -235
  6. package/templates/vite/.howone/skills/howone/02-entity-schema/03-access-models.md +151 -0
  7. package/templates/vite/.howone/skills/howone/02-entity-schema/04-query-contracts.md +123 -0
  8. package/templates/vite/.howone/skills/howone/02-entity-schema/05-ai-persistence-patterns.md +84 -201
  9. package/templates/vite/.howone/skills/howone/03-ai-capabilities/01-ai-capability-architecture.md +37 -32
  10. package/templates/vite/.howone/skills/howone/03-ai-capabilities/02-workflow-contract-rules.md +5 -4
  11. package/templates/vite/.howone/skills/howone/03-ai-capabilities/04-workflow-operations.md +89 -204
  12. package/templates/vite/.howone/skills/howone/03-ai-capabilities/05-ai-feature-playbooks.md +8 -29
  13. package/templates/vite/.howone/skills/howone/04-app-sdk/01-client-setup.md +1 -2
  14. package/templates/vite/.howone/skills/howone/04-app-sdk/07-ai-action-calls.md +2 -2
  15. package/templates/vite/.howone/skills/howone/04-app-sdk/08-ai-manifest-handoff.md +6 -5
  16. package/templates/vite/.howone/skills/howone/04-app-sdk/09-extension-boundaries.md +1 -1
  17. package/templates/vite/.howone/skills/howone/{02-entity-schema/03-data-access-patterns.md → 04-app-sdk/11-entity-data-access-patterns.md} +4 -4
  18. package/templates/vite/.howone/skills/howone/{02-entity-schema/04-query-dsl-and-responses.md → 04-app-sdk/12-query-dsl-and-responses.md} +1 -1
  19. package/templates/vite/.howone/skills/howone/SKILL.md +112 -75
@@ -1,110 +1,147 @@
1
1
  ---
2
2
  name: howone
3
- description: HowOne generated app platform. Scope follows the user request. Load for architecture; add entity-schema, ai-capabilities, or app-sdk tracks only when those surfaces are needed.
3
+ description: 'Use when the task touches HowOne platform contracts or app runtime: designing/changing backend dynamic entity schemas, public/private access, Mongo-backed persisted data, AI capabilities/workflows, external-ai workflow create/update/status, syncing .howone manifests, generating src/lib/sdk.ts, auth/uploads, or app code that calls @howone/sdk/howone.*. Also use when files mention backend-api-design, ai-capability-design, sync_schema_artifacts, sync_ai_artifacts, external-ai-capability, .howone/database, or .howone/ai. Do not use for UI-only edits with no HowOne data, AI, auth, upload, manifest, or SDK surface.'
4
4
  ---
5
5
 
6
- # HowOne Skill
6
+ # HowOne
7
7
 
8
- HowOne apps may be frontend-only, full-stack without AI, AI without custom backend, or full-stack
9
- with AI and persisted data. **Scope always follows the user's request.** This file is the index;
10
- processors defer here.
8
+ HowOne builds generated full-stack AI apps. Platform contracts are separate from app implementation:
11
9
 
12
- ## Mandatory flow
10
+ - Backend: dynamic entity contracts backed by HowOne's MongoDB runtime.
11
+ - AI: capability contracts and external workflow generation/editing.
12
+ - SDK: app-side runtime bindings and calls after manifests are synced.
13
13
 
14
- 1. `skill(name="howone")`
15
- 2. `skill_read "01-architect/01-app-generation.md"` — always, before any platform design write
16
- 3. `skill_read` the smallest set from the track index below that architect routing selects
17
- 4. Platform design tools → sync → `{appRoot}/src/lib/sdk.ts` / app code — only for surfaces in scope
14
+ Load only the track needed for the user's request. Do not read SDK files while designing backend or AI contracts unless the task has reached manifest-to-code implementation.
18
15
 
19
- Inspect-only platform calls do not replace step 2 before the first design write.
16
+ ## Trigger Preconditions
20
17
 
21
- ## Tracks
18
+ Use this skill before work when any condition is true:
22
19
 
23
- | Track | When needed | Design vs implement |
24
- |---|---|---|
25
- | `01-architect/` | Always (scope, feasibility, posture, order) | Plan |
26
- | `02-entity-schema/` | User needs HowOne persisted data | Design contracts |
27
- | `03-ai-capabilities/` | User needs HowOne AI | Design contracts |
28
- | `04-app-sdk/` | User calls HowOne via SDK after sync | Implement |
20
+ - The user asks for persisted app data, backend schema, entity fields, access, indexes, public pages, private history, or Mongo-backed records.
21
+ - The user asks for HowOne AI behavior, capability contracts, workflow generation/update/status, or `external-ai`.
22
+ - The work reads or writes `.howone/database/*`, `.howone/ai/*`, `src/lib/sdk.ts`, or app code using `@howone/sdk` / `howone.*`.
23
+ - The selected tool is `backend-api-design`, `ai-capability-design`, `sync_schema_artifacts`, `sync_ai_artifacts`, or `external-ai-capability`.
24
+ - The implementation needs HowOne auth, upload URLs, public/private entity access, or manifest-to-SDK bindings.
29
25
 
30
- ## Platform boundary (read architect for detail)
26
+ Skip this skill only when the task is purely UI/static code and does not touch HowOne data, AI,
27
+ auth, upload, manifests, or SDK calls.
31
28
 
32
- HowOne platform work must map to **contract evidence**: database manifest, AI manifest, AI service
33
- catalog, platform tool schemas, or a documented `04-app-sdk/` reference.
29
+ ## First Decision
34
30
 
35
- | Class | Meaning | Agent action |
36
- |---|---|---|
37
- | Platform in scope | Ask is expressible through the surfaces above | Use matching track + design tools |
38
- | App-owned | User's own ops stack, services, or infra (any technology) | Implement in `{appRoot}` app code/config; do not block |
39
- | Platform gap | User wants a **platform** feature with no contract evidence | Stop platform path; explain missing surface; Support Policy if needed |
31
+ Classify the request before tool writes:
40
32
 
41
- Do not treat unrelated user infrastructure (orchestration, custom servers, third-party products, etc.) as platform stop-loss. Do not model app-owned systems as fake HowOne entities or AI capabilities.
33
+ | User need | Track | Tools/files |
34
+ |---|---|---|
35
+ | Persist HowOne app data | Backend | `backend-api-design`, `sync_schema_artifacts`, backend files under `02-entity-schema/` |
36
+ | Add/change HowOne AI behavior | AI | `ai-capability-design`, `sync_ai_artifacts`, `external-ai-capability`, `03-ai-capabilities/*` |
37
+ | Call HowOne from generated app code | SDK | `src/lib/sdk.ts`, synced manifests, `04-app-sdk/*` |
38
+ | UI only, no HowOne data or AI | None | edit app code only |
39
+ | User-owned external services | App-owned | integrate in app code/config; do not fake platform contracts |
42
40
 
43
- ## Track index (skill_read paths)
41
+ If multiple tracks apply, process them in dependency order:
44
42
 
45
- Read only files required for the current request.
43
+ ```text
44
+ architect -> backend contract and/or AI contract -> sync manifests -> SDK bindings -> UI
45
+ ```
46
46
 
47
- ### `01-architect/`
47
+ ## Mandatory Reads
48
48
 
49
- | File | Use for |
50
- |---|---|
51
- | `01-app-generation.md` | Scope, platform vs app-owned, feasibility, data/auth posture, workflows, checklist |
52
- | `02-manifest-codegen.md` | Generate `src/lib/sdk.ts` from synced manifests |
49
+ Always read `01-architect/01-app-generation.md` before the first write to a HowOne platform contract or SDK binding.
53
50
 
54
- ### `02-entity-schema/`
51
+ Then read the minimum track files:
55
52
 
56
- | File | Use for |
53
+ | Track | Required before writes |
57
54
  |---|---|
58
- | `01-schema-design.md` | Entity contract shape, fields, access, indexes |
59
- | `02-schema-operations.md` | Preview/apply schema patches, versions |
60
- | `03-data-access-patterns.md` | Public/private/own access, sharing |
61
- | `04-query-dsl-and-responses.md` | Filters, sort, pagination, response mapping |
62
- | `05-ai-persistence-patterns.md` | Storing AI results in entities |
55
+ | Backend contract | `02-entity-schema/01-schema-design.md`, `02-entity-schema/02-schema-operations.md` |
56
+ | AI contract | `03-ai-capabilities/01-ai-capability-architecture.md`, `03-ai-capabilities/02-workflow-contract-rules.md`, `03-ai-capabilities/03-service-capability-catalog.md` |
57
+ | External AI workflow submit/update | `03-ai-capabilities/04-workflow-operations.md` |
58
+ | SDK binding/code | `01-architect/02-manifest-codegen.md` plus the relevant `04-app-sdk/` file |
59
+ | AI output persistence | Backend required reads plus `02-entity-schema/05-ai-persistence-patterns.md` after AI output schema is known |
63
60
 
64
- ### `03-ai-capabilities/`
61
+ Do not load all references preemptively.
65
62
 
66
- | File | Use for |
67
- |---|---|
68
- | `01-ai-capability-architecture.md` | Layers, boundaries, feature flow |
69
- | `02-workflow-contract-rules.md` | Input/output JSON schemas for capabilities |
70
- | `03-service-capability-catalog.md` | What the workflow service supports (feasibility) |
71
- | `04-workflow-operations.md` | External workflow create/update/status |
72
- | `05-ai-feature-playbooks.md` | Recurring product patterns |
63
+ ## Tool Flow
73
64
 
74
- ### `04-app-sdk/`
65
+ Backend contract:
75
66
 
76
- | File | Use for |
77
- |---|---|
78
- | `01-client-setup.md` | `createClient`, env, provider |
79
- | `02-entity-operations.md` | `howone.entities` / public namespace |
80
- | `03-auth.md` | Login, session, custom auth |
81
- | `04-react-integration.md` | `HowOneProvider`, hooks |
82
- | `05-file-upload.md` | Uploads |
83
- | `06-raw-http.md` | Typed escape hatch |
84
- | `07-ai-action-calls.md` | `howone.ai.*` runtime calls |
85
- | `08-ai-manifest-handoff.md` | AI manifest → `src/lib/sdk.ts` |
86
- | `09-extension-boundaries.md` | Adapters, extension rules |
87
- | `10-workflow-execute-sse.md` | Documented workflow status/streaming wire format |
67
+ ```text
68
+ get_current_schema -> apply_schema_patch -> sync_schema_artifacts -> read .howone/database/manifest.json
69
+ ```
88
70
 
89
- ## Routing
71
+ AI contract:
90
72
 
91
- All surface classification and minimum reads live in `01-architect/01-app-generation.md`. This
92
- skill index lists files; architect decides which apply.
73
+ ```text
74
+ get_current_ai_capabilities -> apply_capability_patch -> sync_ai_artifacts -> external-ai-capability -> read .howone/ai/manifest.json
75
+ ```
93
76
 
94
- Mixed scope: read at least one file per touched track before writing.
77
+ No contract dry-run step. Normal generation applies one well-formed patch directly. For destructive,
78
+ narrowing, or public-access-expanding changes, stop for user alignment first, then apply the exact
79
+ approved patch.
95
80
 
96
- ## Design order
81
+ SDK/code:
97
82
 
98
83
  ```text
99
- architect (optional) entity-schema and/or ai-capabilities sync app-sdk → UI
84
+ read synced manifests -> update src/lib/sdk.ts -> implement UI/server code using src/lib/sdk.ts imports
100
85
  ```
101
86
 
102
- Skip tracks the user did not require.
87
+ ## Source Of Truth
103
88
 
104
- ## Rules
89
+ - Backend fields/access/indexes: `{appRoot}/.howone/database/manifest.json` after sync.
90
+ - AI names/workflow IDs/schemas: `{appRoot}/.howone/ai/manifest.json` after sync.
91
+ - App runtime entry: `{appRoot}/src/lib/sdk.ts`.
92
+ - Do not handwrite `.howone/` metadata.
93
+ - Do not infer contract identifiers from prompts, memory, or dependency source.
105
94
 
106
- - When platform contracts apply: synced `{appRoot}/.howone/database/manifest.json` and/or
107
- `{appRoot}/.howone/ai/manifest.json` plus tool results are source of truth.
108
- - `.howone/` holds manifests only—not generated app source.
109
- - Do not invent platform schemas, APIs, or identifiers absent from contracts/catalog/tools.
110
- - Platform stop-loss: architect. User-owned external systems: integrate in app code.
95
+ ## Track Index
96
+
97
+ ### Architect
98
+
99
+ | File | Use |
100
+ |---|---|
101
+ | `01-architect/01-app-generation.md` | Scope classification, platform boundary, ordering |
102
+ | `01-architect/02-manifest-codegen.md` | Synced manifests to `src/lib/sdk.ts` |
103
+
104
+ ### Backend
105
+
106
+ | File | Use |
107
+ |---|---|
108
+ | `02-entity-schema/01-schema-design.md` | Entity fields, access, indexes |
109
+ | `02-entity-schema/02-schema-operations.md` | Patch/apply/sync/version rules |
110
+ | `02-entity-schema/03-access-models.md` | Backend authenticated/public access models |
111
+ | `02-entity-schema/04-query-contracts.md` | Backend filter/sort/pagination/index contracts |
112
+ | `02-entity-schema/05-ai-persistence-patterns.md` | Saving AI results into entities |
113
+
114
+ ### AI
115
+
116
+ | File | Use |
117
+ |---|---|
118
+ | `03-ai-capabilities/01-ai-capability-architecture.md` | AI layers and design order |
119
+ | `03-ai-capabilities/02-workflow-contract-rules.md` | Capability JSON schema rules |
120
+ | `03-ai-capabilities/03-service-capability-catalog.md` | Supported workflow families |
121
+ | `03-ai-capabilities/04-workflow-operations.md` | External workflow create/update/status |
122
+ | `03-ai-capabilities/05-ai-feature-playbooks.md` | Reusable AI product patterns |
123
+
124
+ ### SDK
125
+
126
+ | File | Use |
127
+ |---|---|
128
+ | `04-app-sdk/01-client-setup.md` | `createClient`, env, provider |
129
+ | `04-app-sdk/02-entity-operations.md` | `howone.entities` and public namespace |
130
+ | `04-app-sdk/03-auth.md` | Login/session/custom auth |
131
+ | `04-app-sdk/04-react-integration.md` | Provider and hooks |
132
+ | `04-app-sdk/05-file-upload.md` | Upload URLs/files |
133
+ | `04-app-sdk/06-raw-http.md` | Typed escape hatch |
134
+ | `04-app-sdk/07-ai-action-calls.md` | `howone.ai.*` runtime calls |
135
+ | `04-app-sdk/08-ai-manifest-handoff.md` | AI manifest to SDK bindings |
136
+ | `04-app-sdk/09-extension-boundaries.md` | Adapter/extension boundaries |
137
+ | `04-app-sdk/10-workflow-execute-sse.md` | Workflow run/stream wire format |
138
+ | `04-app-sdk/11-entity-data-access-patterns.md` | App entity access calls from synced manifest |
139
+ | `04-app-sdk/12-query-dsl-and-responses.md` | App query/filter/sort/pagination calls |
140
+
141
+ ## Hard Rules
142
+
143
+ - Backend and AI design references must not include SDK implementation work.
144
+ - SDK references must not invent backend or AI contracts; they consume synced manifests.
145
+ - AI workflows must not perform database CRUD; persistence is app code through entities.
146
+ - User-owned infrastructure is app code, not a platform gap.
147
+ - Platform gap means missing HowOne contract/tool/catalog support, not an unsupported technology name.