howone 0.1.20 → 0.1.23
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/package.json +1 -1
- package/templates/nextjs/lib/sdk.ts +3 -0
- package/templates/vite/.howone/skills/hallmark/LICENSE +21 -0
- package/templates/vite/.howone/skills/hallmark/README.md +147 -0
- package/templates/vite/.howone/skills/hallmark/ROADMAP.md +201 -0
- package/templates/vite/.howone/skills/hallmark/SKILL.md +551 -0
- package/templates/vite/.howone/skills/hallmark/docs/recipes.md +186 -0
- package/templates/vite/.howone/skills/hallmark/docs/screenshots/hero-anya.jpg +0 -0
- package/templates/vite/.howone/skills/hallmark/docs/screenshots/hero-bananastudio.jpg +0 -0
- package/templates/vite/.howone/skills/hallmark/docs/screenshots/hero-hyperlane.jpg +0 -0
- package/templates/vite/.howone/skills/hallmark/docs/screenshots/hero-najm.jpg +0 -0
- package/templates/vite/.howone/skills/hallmark/docs/screenshots/hero-slow-pour.jpg +0 -0
- package/templates/vite/.howone/skills/hallmark/docs/screenshots/hero-soroe.jpg +0 -0
- package/templates/vite/.howone/skills/hallmark/docs/screenshots/hero-tally.jpg +0 -0
- package/templates/vite/.howone/skills/hallmark/docs/screenshots/hero-wayfare.jpg +0 -0
- package/templates/vite/.howone/skills/hallmark/docs/study-examples.md +176 -0
- package/templates/vite/.howone/skills/hallmark/docs/talk-slides.md +364 -0
- package/templates/vite/.howone/skills/hallmark/package.json +36 -0
- package/templates/vite/.howone/skills/hallmark/references/anti-patterns.md +412 -0
- package/templates/vite/.howone/skills/hallmark/references/assets.md +399 -0
- package/templates/vite/.howone/skills/hallmark/references/color.md +95 -0
- package/templates/vite/.howone/skills/hallmark/references/component-cookbook.md +256 -0
- package/templates/vite/.howone/skills/hallmark/references/components/c1-outlined-chip.md +12 -0
- package/templates/vite/.howone/skills/hallmark/references/components/c2-inline-form-as-cta.md +16 -0
- package/templates/vite/.howone/skills/hallmark/references/components/c3-typographic-link.md +8 -0
- package/templates/vite/.howone/skills/hallmark/references/components/c4-sticky-bottom-bar.md +16 -0
- package/templates/vite/.howone/skills/hallmark/references/components/f1-bento-grid.md +20 -0
- package/templates/vite/.howone/skills/hallmark/references/components/f2-sticky-scroll-stack.md +20 -0
- package/templates/vite/.howone/skills/hallmark/references/components/f3-tabular-spec-sheet.md +11 -0
- package/templates/vite/.howone/skills/hallmark/references/components/f4-step-sequence.md +11 -0
- package/templates/vite/.howone/skills/hallmark/references/components/f5-annotated-screenshot.md +11 -0
- package/templates/vite/.howone/skills/hallmark/references/components/f6-product-card-grid.md +41 -0
- package/templates/vite/.howone/skills/hallmark/references/components/ft1-mast-headed.md +13 -0
- package/templates/vite/.howone/skills/hallmark/references/components/ft2-inline-rule-single-line.md +10 -0
- package/templates/vite/.howone/skills/hallmark/references/components/ft3-index-style-category-list.md +12 -0
- package/templates/vite/.howone/skills/hallmark/references/components/ft4-dense-typographic.md +10 -0
- package/templates/vite/.howone/skills/hallmark/references/components/ft5-statement.md +21 -0
- package/templates/vite/.howone/skills/hallmark/references/components/ft6-letter-close.md +19 -0
- package/templates/vite/.howone/skills/hallmark/references/components/ft7-newsletter-first.md +27 -0
- package/templates/vite/.howone/skills/hallmark/references/components/ft8-marquee-scroll.md +25 -0
- package/templates/vite/.howone/skills/hallmark/references/components/h1-marquee.md +15 -0
- package/templates/vite/.howone/skills/hallmark/references/components/h2-split-diptych.md +15 -0
- package/templates/vite/.howone/skills/hallmark/references/components/h3-quote-led.md +11 -0
- package/templates/vite/.howone/skills/hallmark/references/components/h4-stat-led.md +14 -0
- package/templates/vite/.howone/skills/hallmark/references/components/h5-letter-hero.md +11 -0
- package/templates/vite/.howone/skills/hallmark/references/components/h6-photographic-fold.md +16 -0
- package/templates/vite/.howone/skills/hallmark/references/components/h7-demo-video-clipped-by-viewport-edge.md +27 -0
- package/templates/vite/.howone/skills/hallmark/references/components/h8-mockup-split-browser-framed.md +23 -0
- package/templates/vite/.howone/skills/hallmark/references/components/h9-custom-illustration-centerpiece.md +27 -0
- package/templates/vite/.howone/skills/hallmark/references/components/n1-wordmark-2-links.md +12 -0
- package/templates/vite/.howone/skills/hallmark/references/components/n10-floating-on-scroll-morph.md +19 -0
- package/templates/vite/.howone/skills/hallmark/references/components/n2-floating-chip.md +14 -0
- package/templates/vite/.howone/skills/hallmark/references/components/n3-side-rail.md +14 -0
- package/templates/vite/.howone/skills/hallmark/references/components/n4-hidden-behind-k.md +9 -0
- package/templates/vite/.howone/skills/hallmark/references/components/n5-floating-pill.md +28 -0
- package/templates/vite/.howone/skills/hallmark/references/components/n6-newspaper-masthead.md +24 -0
- package/templates/vite/.howone/skills/hallmark/references/components/n7-brutal-slab.md +22 -0
- package/templates/vite/.howone/skills/hallmark/references/components/n8-terminal-command.md +21 -0
- package/templates/vite/.howone/skills/hallmark/references/components/n9-edge-aligned-minimal.md +17 -0
- package/templates/vite/.howone/skills/hallmark/references/components/s1-left-margin-numbered.md +15 -0
- package/templates/vite/.howone/skills/hallmark/references/components/s2-hanging.md +13 -0
- package/templates/vite/.howone/skills/hallmark/references/components/s3-sticky-pinned.md +19 -0
- package/templates/vite/.howone/skills/hallmark/references/components/s4-inline-no-break.md +11 -0
- package/templates/vite/.howone/skills/hallmark/references/components/s5-bottom-anchored.md +13 -0
- package/templates/vite/.howone/skills/hallmark/references/components/t1-pull-quote-with-marginalia.md +12 -0
- package/templates/vite/.howone/skills/hallmark/references/components/t2-logo-wall-hairline.md +19 -0
- package/templates/vite/.howone/skills/hallmark/references/components/t3-single-huge-quote.md +11 -0
- package/templates/vite/.howone/skills/hallmark/references/components/t4-numbered-stat-strip.md +14 -0
- package/templates/vite/.howone/skills/hallmark/references/contract.md +24 -0
- package/templates/vite/.howone/skills/hallmark/references/copy.md +182 -0
- package/templates/vite/.howone/skills/hallmark/references/custom-craft.md +626 -0
- package/templates/vite/.howone/skills/hallmark/references/custom-theme.md +329 -0
- package/templates/vite/.howone/skills/hallmark/references/design-md.md +116 -0
- package/templates/vite/.howone/skills/hallmark/references/export-formats.md +328 -0
- package/templates/vite/.howone/skills/hallmark/references/floating-nav.md +89 -0
- package/templates/vite/.howone/skills/hallmark/references/genres/atmospheric.md +65 -0
- package/templates/vite/.howone/skills/hallmark/references/genres/editorial.md +70 -0
- package/templates/vite/.howone/skills/hallmark/references/genres/modern-minimal.md +67 -0
- package/templates/vite/.howone/skills/hallmark/references/genres/playful.md +65 -0
- package/templates/vite/.howone/skills/hallmark/references/hero-enrichment.md +474 -0
- package/templates/vite/.howone/skills/hallmark/references/imagery-kit.md +170 -0
- package/templates/vite/.howone/skills/hallmark/references/interaction-and-states.md +207 -0
- package/templates/vite/.howone/skills/hallmark/references/layout-and-space.md +111 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/01-bento-grid.md +35 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/02-long-document.md +34 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/03-marquee-hero.md +31 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/04-stat-led.md +32 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/05-workbench.md +32 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/06-conversational-faq.md +33 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/07-manifesto.md +32 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/08-photographic.md +34 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/09-quote-led.md +32 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/10-specimen.md +32 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/11-catalogue.md +23 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/12-letter.md +23 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/13-index-first.md +23 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/14-narrative-workflow.md +23 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/15-split-studio.md +23 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/16-feature-stack.md +23 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/17-type-specimen.md +23 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/18-portfolio-grid.md +23 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/19-map-diagram.md +23 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/20-ecosystem-index.md +23 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures/21-component-playground.md +23 -0
- package/templates/vite/.howone/skills/hallmark/references/macrostructures.md +89 -0
- package/templates/vite/.howone/skills/hallmark/references/microinteractions.md +260 -0
- package/templates/vite/.howone/skills/hallmark/references/motion.md +109 -0
- package/templates/vite/.howone/skills/hallmark/references/preview-examples.md +49 -0
- package/templates/vite/.howone/skills/hallmark/references/responsive.md +138 -0
- package/templates/vite/.howone/skills/hallmark/references/slop-test.md +205 -0
- package/templates/vite/.howone/skills/hallmark/references/structure.md +164 -0
- package/templates/vite/.howone/skills/hallmark/references/study.md +486 -0
- package/templates/vite/.howone/skills/hallmark/references/typography.md +243 -0
- package/templates/vite/.howone/skills/hallmark/references/verbs/audit.md +25 -0
- package/templates/vite/.howone/skills/hallmark/references/verbs/redesign.md +269 -0
- package/templates/vite/.howone/skills/hallmark/site/OG-hallmark.png +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/01-tide-podcast/brief.md +71 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/01-tide-podcast/index.html +64 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/01-tide-podcast/style.css +240 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/02-streampipe-cli/brief.md +65 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/02-streampipe-cli/index.html +105 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/02-streampipe-cli/style.css +250 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/03-maple-bakery/brief.md +64 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/03-maple-bakery/index.html +131 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/03-maple-bakery/style.css +240 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/04-meridian-manifesto/brief.md +67 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/04-meridian-manifesto/index.html +86 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/04-meridian-manifesto/style.css +262 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/05-tracejam-saas/brief.md +63 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/05-tracejam-saas/index.html +167 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/05-tracejam-saas/style.css +457 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/06-anya-portfolio/brief.md +65 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/06-anya-portfolio/index.html +159 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/06-anya-portfolio/style.css +288 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/07-foundry-compliance/brief.md +64 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/07-foundry-compliance/index.html +146 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/07-foundry-compliance/style.css +484 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/08-cohort-courses/brief.md +64 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/08-cohort-courses/index.html +116 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/08-cohort-courses/style.css +354 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/09-slow-pour/index.html +638 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/10-owl-hours/index.html +515 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/11-soroe-ceramics/index.html +515 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/12-loafer/index.html +608 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/13-alma/index.html +587 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/README.md +157 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/BananaStudio-loop.mp4 +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/BananaStudio-still.jpg +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/Hyperlane-example.mp4 +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/Hyperlane-still.jpg +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/Najm-loop.mp4 +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/Najm-still.jpg +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/Podcast-loop.mp4 +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/SaaS-loop.mp4 +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/SaaS-still.jpg +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/Soroe-loop.mp4 +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/Soroe-still.jpg +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/after-quiet-hour.png +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/anya-loop.mp4 +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/anya-still.jpg +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/audit-example.png +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/before-quiet-hour.png +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/example-redesign-uractivation.png +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/slow-pour-loop.mp4 +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/slow-pour-still.jpg +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/study-example.png +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/uractivation-after-loop.mp4 +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/wayfare-loop.mp4 +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/_thumbs/wayfare-still.jpg +0 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/custom/01-coffeebox/index.html +77 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/custom/01-coffeebox/style.css +238 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/custom/02-loop/index.html +110 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/custom/02-loop/style.css +326 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/custom/03-mossroot/index.html +134 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/custom/03-mossroot/style.css +262 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/custom/README.md +30 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/verbs/README.md +17 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/verbs/audit/audit-report.md +56 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/verbs/audit/input.html +160 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/verbs/audit/notes.md +29 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/verbs/redesign/input.html +63 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/verbs/redesign/notes.md +72 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/verbs/redesign/output.html +374 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/verbs/study/diagnosis.md +52 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/verbs/study/input-description.md +29 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/verbs/study/notes.md +61 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/verbs/study/output.css +193 -0
- package/templates/vite/.howone/skills/hallmark/site/_tests/verbs/study/output.html +66 -0
- package/templates/vite/.howone/skills/hallmark/site/css/base.css +194 -0
- package/templates/vite/.howone/skills/hallmark/site/css/components.css +4886 -0
- package/templates/vite/.howone/skills/hallmark/site/css/sections.css +2072 -0
- package/templates/vite/.howone/skills/hallmark/site/css/tokens.css +1129 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/bananastudio/index.html +475 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/bananastudio/styles.css +1584 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/bananastudio/tokens.css +96 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/hyperlane/index.html +344 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/hyperlane/script.js +103 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/hyperlane/styles.css +1103 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/hyperlane/tokens.css +83 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/najm/index.html +368 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/najm/script.js +133 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/najm/styles.css +1062 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/najm/tokens.css +97 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/tally/app.js +84 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/tally/index.html +446 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/tally/styles.css +1087 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/tally/tokens.css +101 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/wayfare/index.html +359 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/wayfare/style.css +1168 -0
- package/templates/vite/.howone/skills/hallmark/site/examples/wayfare/tokens.css +81 -0
- package/templates/vite/.howone/skills/hallmark/site/favicon-dark.svg +5 -0
- package/templates/vite/.howone/skills/hallmark/site/favicon-light.svg +5 -0
- package/templates/vite/.howone/skills/hallmark/site/index.html +1043 -0
- package/templates/vite/.howone/skills/hallmark/site/js/main.js +1175 -0
- package/templates/vite/.howone/skills/hallmark/vercel.json +6 -0
- package/templates/vite/.howone/skills/howone-sdk/01-architect/01-app-generation.md +126 -0
- package/templates/vite/.howone/skills/howone-sdk/{references/08-manifest-codegen.md → 01-architect/02-manifest-codegen.md} +31 -19
- package/templates/vite/.howone/skills/howone-sdk/02-database/01-schema-design.md +147 -0
- package/templates/vite/.howone/skills/howone-sdk/02-database/02-schema-operations.md +96 -0
- package/templates/vite/.howone/skills/howone-sdk/02-database/03-data-access-patterns.md +172 -0
- package/templates/vite/.howone/skills/howone-sdk/{references → 03-sdk}/01-client-setup.md +3 -3
- package/templates/vite/.howone/skills/howone-sdk/{references/04-auth.md → 03-sdk/03-auth.md} +120 -3
- package/templates/vite/.howone/skills/howone-sdk/{references/06-react-integration.md → 03-sdk/04-react-integration.md} +2 -4
- package/templates/vite/.howone/skills/howone-sdk/{references/03-ai-actions.md → 03-sdk/07-ai-action-calls.md} +31 -34
- package/templates/vite/.howone/skills/howone-sdk/04-ai/.gitkeep +1 -0
- package/templates/vite/.howone/skills/howone-sdk/04-ai/01-ai-capability-architecture.md +142 -0
- package/templates/vite/.howone/skills/howone-sdk/04-ai/02-workflow-contract-rules.md +169 -0
- package/templates/vite/.howone/skills/howone-sdk/04-ai/03-ai-sdk-handoff.md +80 -0
- package/templates/vite/.howone/skills/howone-sdk/SKILL.md +118 -93
- package/templates/vite/.howone/skills/howone-sdk/agents/openai.yaml +3 -3
- package/templates/vite/.howone/skills/impeccable/SKILL.md +168 -0
- package/templates/vite/.howone/skills/impeccable/agents/impeccable-asset-producer.md +101 -0
- package/templates/vite/.howone/skills/impeccable/reference/adapt.md +190 -0
- package/templates/vite/.howone/skills/impeccable/reference/animate.md +175 -0
- package/templates/vite/.howone/skills/impeccable/reference/audit.md +133 -0
- package/templates/vite/.howone/skills/impeccable/reference/bolder.md +113 -0
- package/templates/vite/.howone/skills/impeccable/reference/brand.md +118 -0
- package/templates/vite/.howone/skills/impeccable/reference/clarify.md +174 -0
- package/templates/vite/.howone/skills/impeccable/reference/codex.md +105 -0
- package/templates/vite/.howone/skills/impeccable/reference/cognitive-load.md +106 -0
- package/templates/vite/.howone/skills/impeccable/reference/color-and-contrast.md +105 -0
- package/templates/vite/.howone/skills/impeccable/reference/colorize.md +154 -0
- package/templates/vite/.howone/skills/impeccable/reference/craft.md +123 -0
- package/templates/vite/.howone/skills/impeccable/reference/critique.md +273 -0
- package/templates/vite/.howone/skills/impeccable/reference/delight.md +302 -0
- package/templates/vite/.howone/skills/impeccable/reference/distill.md +111 -0
- package/templates/vite/.howone/skills/impeccable/reference/document.md +427 -0
- package/templates/vite/.howone/skills/impeccable/reference/extract.md +69 -0
- package/templates/vite/.howone/skills/impeccable/reference/harden.md +347 -0
- package/templates/vite/.howone/skills/impeccable/reference/heuristics-scoring.md +234 -0
- package/templates/vite/.howone/skills/impeccable/reference/interaction-design.md +195 -0
- package/templates/vite/.howone/skills/impeccable/reference/layout.md +141 -0
- package/templates/vite/.howone/skills/impeccable/reference/live.md +622 -0
- package/templates/vite/.howone/skills/impeccable/reference/motion-design.md +109 -0
- package/templates/vite/.howone/skills/impeccable/reference/onboard.md +234 -0
- package/templates/vite/.howone/skills/impeccable/reference/optimize.md +258 -0
- package/templates/vite/.howone/skills/impeccable/reference/overdrive.md +130 -0
- package/templates/vite/.howone/skills/impeccable/reference/personas.md +179 -0
- package/templates/vite/.howone/skills/impeccable/reference/polish.md +242 -0
- package/templates/vite/.howone/skills/impeccable/reference/product.md +62 -0
- package/templates/vite/.howone/skills/impeccable/reference/quieter.md +99 -0
- package/templates/vite/.howone/skills/impeccable/reference/responsive-design.md +114 -0
- package/templates/vite/.howone/skills/impeccable/reference/shape.md +165 -0
- package/templates/vite/.howone/skills/impeccable/reference/spatial-design.md +100 -0
- package/templates/vite/.howone/skills/impeccable/reference/teach.md +156 -0
- package/templates/vite/.howone/skills/impeccable/reference/typeset.md +124 -0
- package/templates/vite/.howone/skills/impeccable/reference/typography.md +159 -0
- package/templates/vite/.howone/skills/impeccable/reference/ux-writing.md +107 -0
- package/templates/vite/.howone/skills/impeccable/scripts/cleanup-deprecated.mjs +284 -0
- package/templates/vite/.howone/skills/impeccable/scripts/command-metadata.json +94 -0
- package/templates/vite/.howone/skills/impeccable/scripts/critique-storage.mjs +242 -0
- package/templates/vite/.howone/skills/impeccable/scripts/design-parser.mjs +820 -0
- package/templates/vite/.howone/skills/impeccable/scripts/detect-csp.mjs +198 -0
- package/templates/vite/.howone/skills/impeccable/scripts/detect.mjs +21 -0
- package/templates/vite/.howone/skills/impeccable/scripts/impeccable-paths.mjs +110 -0
- package/templates/vite/.howone/skills/impeccable/scripts/is-generated.mjs +69 -0
- package/templates/vite/.howone/skills/impeccable/scripts/live-accept.mjs +595 -0
- package/templates/vite/.howone/skills/impeccable/scripts/live-browser-session.js +123 -0
- package/templates/vite/.howone/skills/impeccable/scripts/live-browser.js +4860 -0
- package/templates/vite/.howone/skills/impeccable/scripts/live-complete.mjs +75 -0
- package/templates/vite/.howone/skills/impeccable/scripts/live-completion.mjs +18 -0
- package/templates/vite/.howone/skills/impeccable/scripts/live-inject.mjs +446 -0
- package/templates/vite/.howone/skills/impeccable/scripts/live-poll.mjs +200 -0
- package/templates/vite/.howone/skills/impeccable/scripts/live-resume.mjs +48 -0
- package/templates/vite/.howone/skills/impeccable/scripts/live-server.mjs +838 -0
- package/templates/vite/.howone/skills/impeccable/scripts/live-session-store.mjs +254 -0
- package/templates/vite/.howone/skills/impeccable/scripts/live-status.mjs +47 -0
- package/templates/vite/.howone/skills/impeccable/scripts/live-wrap.mjs +632 -0
- package/templates/vite/.howone/skills/impeccable/scripts/live.mjs +247 -0
- package/templates/vite/.howone/skills/impeccable/scripts/load-context.mjs +141 -0
- package/templates/vite/.howone/skills/impeccable/scripts/modern-screenshot.umd.js +14 -0
- package/templates/vite/.howone/skills/impeccable/scripts/pin.mjs +214 -0
- package/templates/vite/AGENTS.md +2 -12
- package/templates/vite/package.json +1 -1
- package/templates/vite/src/lib/sdk.ts +3 -0
- /package/templates/vite/.howone/skills/howone-sdk/{references → 03-sdk}/02-entity-operations.md +0 -0
- /package/templates/vite/.howone/skills/howone-sdk/{references → 03-sdk}/05-file-upload.md +0 -0
- /package/templates/vite/.howone/skills/howone-sdk/{references/07-raw-http.md → 03-sdk/06-raw-http.md} +0 -0
package/templates/vite/.howone/skills/howone-sdk/{references/04-auth.md → 03-sdk/03-auth.md}
RENAMED
|
@@ -7,7 +7,7 @@ HowOne has two distinct auth layers:
|
|
|
7
7
|
1. **Client-level auth** (`client.auth.*`) — low-level token management, login/logout redirects.
|
|
8
8
|
2. **HowOne Auth service** (`unifiedAuth`, standalone functions) — headless OTP and OAuth flows for building custom login UIs.
|
|
9
9
|
|
|
10
|
-
For React auth UI, see `
|
|
10
|
+
For React auth UI, see `03-sdk/04-react-integration.md` (`HowOneProvider`, `useHowoneContext`).
|
|
11
11
|
|
|
12
12
|
---
|
|
13
13
|
|
|
@@ -113,6 +113,15 @@ function useCurrentUser() {
|
|
|
113
113
|
|
|
114
114
|
Use `sendEmailVerificationCode` → `loginWithEmailCode` to build a custom email login form.
|
|
115
115
|
|
|
116
|
+
The SDK normalizes HowOne auth envelopes. Both of these backend response shapes are valid:
|
|
117
|
+
|
|
118
|
+
```ts
|
|
119
|
+
{ success: true, token: 'jwt...' }
|
|
120
|
+
{ code: 0, data: { success: true, token: 'jwt...' } }
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
After normalization, read `result.success`, `result.token`, and `result.message` from the top level.
|
|
124
|
+
|
|
116
125
|
### Standalone functions (imported directly)
|
|
117
126
|
|
|
118
127
|
```ts
|
|
@@ -145,7 +154,7 @@ const loginResult = await loginWithEmailCode(
|
|
|
145
154
|
|
|
146
155
|
if (loginResult.success && loginResult.token) {
|
|
147
156
|
howone.auth.setToken(loginResult.token)
|
|
148
|
-
//
|
|
157
|
+
// Persists the token and updates the active SDK client.
|
|
149
158
|
}
|
|
150
159
|
```
|
|
151
160
|
|
|
@@ -423,6 +432,112 @@ async function checkToken(token: string) {
|
|
|
423
432
|
}
|
|
424
433
|
```
|
|
425
434
|
|
|
435
|
+
## Custom Login UI Pattern
|
|
436
|
+
|
|
437
|
+
Use this when the app should show its own login page instead of redirecting to `/howone/auth`.
|
|
438
|
+
|
|
439
|
+
### SDK setup
|
|
440
|
+
|
|
441
|
+
```ts
|
|
442
|
+
// src/lib/sdk.ts
|
|
443
|
+
import { createClient } from '@howone/sdk'
|
|
444
|
+
|
|
445
|
+
const client = createClient({
|
|
446
|
+
projectId: import.meta.env.VITE_HOWONE_PROJECT_ID,
|
|
447
|
+
env: import.meta.env.VITE_HOWONE_ENV,
|
|
448
|
+
auth: { mode: 'managed' },
|
|
449
|
+
})
|
|
450
|
+
|
|
451
|
+
export default client
|
|
452
|
+
```
|
|
453
|
+
|
|
454
|
+
`managed` is still correct for most custom login pages because `howone.auth.setToken(token)`
|
|
455
|
+
persists the token through the SDK auth store. Use `headless` only when an external auth
|
|
456
|
+
provider owns token storage.
|
|
457
|
+
|
|
458
|
+
### Provider setup
|
|
459
|
+
|
|
460
|
+
```tsx
|
|
461
|
+
<HowOneProvider auth="none" brand="hidden">
|
|
462
|
+
<App />
|
|
463
|
+
</HowOneProvider>
|
|
464
|
+
```
|
|
465
|
+
|
|
466
|
+
`auth="none"` disables the provider redirect so the app can render its own login form.
|
|
467
|
+
|
|
468
|
+
### App startup
|
|
469
|
+
|
|
470
|
+
```tsx
|
|
471
|
+
useEffect(() => {
|
|
472
|
+
let cancelled = false
|
|
473
|
+
|
|
474
|
+
howone.me()
|
|
475
|
+
.then((user) => {
|
|
476
|
+
if (!cancelled) setUser(user)
|
|
477
|
+
})
|
|
478
|
+
.catch(() => {
|
|
479
|
+
if (!cancelled) setUser(null)
|
|
480
|
+
})
|
|
481
|
+
.finally(() => {
|
|
482
|
+
if (!cancelled) setLoading(false)
|
|
483
|
+
})
|
|
484
|
+
|
|
485
|
+
return () => {
|
|
486
|
+
cancelled = true
|
|
487
|
+
}
|
|
488
|
+
}, [])
|
|
489
|
+
```
|
|
490
|
+
|
|
491
|
+
Do not use `howone.auth.isAuthenticated()` as the first-load gate for protected UI. It is a
|
|
492
|
+
synchronous token presence check. `howone.me()` verifies/restores the current session and is the
|
|
493
|
+
right source of truth for initial render.
|
|
494
|
+
|
|
495
|
+
### Login success
|
|
496
|
+
|
|
497
|
+
```ts
|
|
498
|
+
const result = await loginWithEmailCode(email, code)
|
|
499
|
+
if (!result.success || !result.token) {
|
|
500
|
+
setError(result.message ?? 'Invalid code')
|
|
501
|
+
return
|
|
502
|
+
}
|
|
503
|
+
|
|
504
|
+
howone.auth.setToken(result.token)
|
|
505
|
+
const user = await howone.me({ refresh: true })
|
|
506
|
+
setUser(user)
|
|
507
|
+
```
|
|
508
|
+
|
|
509
|
+
Use the same pattern for phone OTP and OAuth popup results.
|
|
510
|
+
|
|
511
|
+
### Logout
|
|
512
|
+
|
|
513
|
+
```ts
|
|
514
|
+
const token = howone.auth.getToken()
|
|
515
|
+
if (token) await unifiedAuth.logout(token)
|
|
516
|
+
howone.auth.logout()
|
|
517
|
+
setUser(null)
|
|
518
|
+
```
|
|
519
|
+
|
|
520
|
+
`howone.auth.logout()` clears the SDK token store and active client token.
|
|
521
|
+
|
|
522
|
+
## Headless External Auth Pattern
|
|
523
|
+
|
|
524
|
+
Use `auth.mode = "headless"` only when another auth system owns the token lifecycle.
|
|
525
|
+
|
|
526
|
+
```ts
|
|
527
|
+
const client = createClient({
|
|
528
|
+
projectId: import.meta.env.VITE_HOWONE_PROJECT_ID,
|
|
529
|
+
env: import.meta.env.VITE_HOWONE_ENV,
|
|
530
|
+
auth: {
|
|
531
|
+
mode: 'headless',
|
|
532
|
+
getToken: async () => externalAuth.getJwt(),
|
|
533
|
+
tokenCacheMs: 30_000,
|
|
534
|
+
},
|
|
535
|
+
})
|
|
536
|
+
```
|
|
537
|
+
|
|
538
|
+
Do not invent a second localStorage key for HowOne OTP/OAuth login. Use `howone.auth.setToken`
|
|
539
|
+
unless the user explicitly asks to integrate an external auth provider.
|
|
540
|
+
|
|
426
541
|
---
|
|
427
542
|
|
|
428
543
|
## Logout
|
|
@@ -495,5 +610,7 @@ const client = createClient({
|
|
|
495
610
|
|---|---|
|
|
496
611
|
| Phone number without country code: `'13800138000'` | Use E.164: `'+8613800138000'` |
|
|
497
612
|
| Using `loginWithEmailCode` without first calling `sendEmailVerificationCode` | Always send the code first |
|
|
498
|
-
|
|
|
613
|
+
| Hand-writing a separate localStorage token key for HowOne OTP/OAuth | Use `howone.auth.setToken(token)` |
|
|
614
|
+
| Using `auth.isAuthenticated()` to decide first render after refresh | Use `await howone.me()` |
|
|
615
|
+
| Setting `HowOneProvider auth="required"` with a custom in-app login form | Use `auth="none"` so the provider does not redirect |
|
|
499
616
|
| Calling `unifiedAuth.logout()` without the token argument | Pass `token`: `await unifiedAuth.logout(howone.auth.getToken()!)` |
|
|
@@ -368,10 +368,8 @@ function AIGenerateButton({ topic }: { topic: string }) {
|
|
|
368
368
|
}
|
|
369
369
|
setLoading(true)
|
|
370
370
|
try {
|
|
371
|
-
const
|
|
372
|
-
|
|
373
|
-
setResult((res.finalResult as any).content)
|
|
374
|
-
}
|
|
371
|
+
const output = await howone.ai.generateStory.run({ topic, language: 'en' })
|
|
372
|
+
setResult(output.content)
|
|
375
373
|
} finally {
|
|
376
374
|
setLoading(false)
|
|
377
375
|
}
|
|
@@ -4,24 +4,31 @@
|
|
|
4
4
|
|
|
5
5
|
**`src/lib/sdk.ts` must be generated from `.howone/ai/manifest.json`. Do not write it from memory or from generic examples.**
|
|
6
6
|
|
|
7
|
+
For AI capability and workflow design, read `04-ai/` first. This file is only for app-side SDK
|
|
8
|
+
bindings and runtime calls after the manifest exists.
|
|
9
|
+
|
|
7
10
|
For every capability in `manifest.json`:
|
|
8
11
|
1. Read `name`, `workflowId`, `inputSchema`, `outputSchema`
|
|
9
12
|
2. Generate a zod schema from `inputSchema.properties`
|
|
10
|
-
3.
|
|
13
|
+
3. Generate a zod schema from `outputSchema.properties` when an output schema exists
|
|
14
|
+
4. Call `defineAiAction(name, { workflowId, inputSchema, outputSchema })` — **`workflowId` is mandatory**
|
|
11
15
|
|
|
12
16
|
Without `workflowId`, the SDK falls back to using the action name as the URL segment. Action names are not UUIDs — the EAX server will reject the call with "invalid input syntax for type uuid".
|
|
13
17
|
|
|
18
|
+
Do not mark required manifest output fields as `.optional()` to silence validation. Do not add
|
|
19
|
+
`.passthrough()` as a workaround for execution envelopes. A typed `run()` validates and returns the
|
|
20
|
+
workflow `finalResult` payload, not the raw execution envelope.
|
|
21
|
+
|
|
14
22
|
## When to Write SDK Bindings
|
|
15
23
|
|
|
16
|
-
**Do NOT write `defineAiAction` until `.howone/ai/manifest.json` contains
|
|
24
|
+
**Do NOT write `defineAiAction` until `.howone/ai/manifest.json` contains the workflowId for the capability and the external workflow implementation has been submitted/confirmed by the workflow layer.**
|
|
17
25
|
|
|
18
26
|
Correct sequence:
|
|
19
|
-
1. `
|
|
27
|
+
1. `ai-capability-design` — design the capability contract
|
|
20
28
|
2. `sync_ai_artifacts` — sync manifest to disk
|
|
21
|
-
3. `
|
|
22
|
-
4.
|
|
23
|
-
5. `
|
|
24
|
-
6. Read `.howone/ai/manifest.json` → write `src/lib/sdk.ts` with `workflowId`
|
|
29
|
+
3. `external-ai-capability` — submit workflow create/update to EAX from the synced manifest
|
|
30
|
+
4. Workflow status/background-task layer confirms readiness and captures `workflowConfigID` for future edits
|
|
31
|
+
5. Read `.howone/ai/manifest.json` → write `src/lib/sdk.ts` with `workflowId`
|
|
25
32
|
|
|
26
33
|
Building without errors does **not** mean the AI workflow binding is correct. A missing `workflowId` causes a runtime UUID error at the EAX execution call.
|
|
27
34
|
|
|
@@ -45,7 +52,7 @@ Building without errors does **not** mean the AI workflow binding is correct. A
|
|
|
45
52
|
type AiActionConfig<TInput, TOutput> = {
|
|
46
53
|
workflowId: string // REQUIRED — UUID from manifest.json. Without this, SDK uses action name as URL segment (not a UUID → EAX rejects).
|
|
47
54
|
inputSchema?: z.ZodType<TInput> // validates input before calling the workflow
|
|
48
|
-
outputSchema?: z.ZodType<TOutput> // validates the
|
|
55
|
+
outputSchema?: z.ZodType<TOutput> // validates the workflow finalResult payload for run()
|
|
49
56
|
mode?: 'run' | 'stream' | 'events' // default: supports all three modes
|
|
50
57
|
}
|
|
51
58
|
```
|
|
@@ -120,7 +127,7 @@ export const ai = defineAiActions({
|
|
|
120
127
|
})
|
|
121
128
|
```
|
|
122
129
|
|
|
123
|
-
### Action with typed output
|
|
130
|
+
### Action with typed output
|
|
124
131
|
|
|
125
132
|
```ts
|
|
126
133
|
export const generateStoryOutputSchema = z.object({
|
|
@@ -130,13 +137,11 @@ export const generateStoryOutputSchema = z.object({
|
|
|
130
137
|
})
|
|
131
138
|
export type GenerateStoryOutput = z.infer<typeof generateStoryOutputSchema>
|
|
132
139
|
|
|
133
|
-
// Do NOT put outputSchema in defineAiAction unless it matches the full
|
|
134
|
-
// AiResult envelope. Instead, cast finalResult after run():
|
|
135
140
|
export const ai = defineAiActions({
|
|
136
141
|
generateStory: defineAiAction('generateStory', {
|
|
137
142
|
workflowId: 'd69ab648-2c00-4d94-928e-01bd7b2a5bb2', // ← from manifest.json
|
|
138
143
|
inputSchema: generateStoryInputSchema,
|
|
139
|
-
|
|
144
|
+
outputSchema: generateStoryOutputSchema,
|
|
140
145
|
}),
|
|
141
146
|
})
|
|
142
147
|
```
|
|
@@ -171,25 +176,21 @@ export const ai = defineAiActions({
|
|
|
171
176
|
|
|
172
177
|
## Calling AI Actions
|
|
173
178
|
|
|
174
|
-
### run() —
|
|
179
|
+
### run() — typed action result
|
|
175
180
|
|
|
176
181
|
```ts
|
|
177
182
|
import howone, { type GenerateStoryInput, type GenerateStoryOutput } from '@/lib/sdk'
|
|
178
183
|
|
|
179
184
|
async function generateStory(input: GenerateStoryInput) {
|
|
180
|
-
const
|
|
181
|
-
//
|
|
182
|
-
|
|
183
|
-
if (!result.success) {
|
|
184
|
-
throw new Error(result.errors.join(', '))
|
|
185
|
-
}
|
|
186
|
-
|
|
187
|
-
// Cast finalResult to your output type
|
|
188
|
-
const output = result.finalResult as GenerateStoryOutput
|
|
185
|
+
const output = await howone.ai.generateStory.run(input)
|
|
186
|
+
// output is GenerateStoryOutput when outputSchema is configured.
|
|
189
187
|
return output
|
|
190
188
|
}
|
|
191
189
|
```
|
|
192
190
|
|
|
191
|
+
When an action has `outputSchema`, `run()` returns the validated workflow `finalResult` payload.
|
|
192
|
+
When an action omits `outputSchema`, `run()` returns the raw `AiResult` execution envelope.
|
|
193
|
+
|
|
193
194
|
### run() — with SSE callbacks
|
|
194
195
|
|
|
195
196
|
```ts
|
|
@@ -362,7 +363,7 @@ type SSEExecutionOptions = {
|
|
|
362
363
|
// Called if an error occurs
|
|
363
364
|
onError?: (error: Error) => void
|
|
364
365
|
|
|
365
|
-
// Called when the workflow completes
|
|
366
|
+
// Called when the workflow completes with the raw execution envelope
|
|
366
367
|
onComplete?: (result: AiResult) => void
|
|
367
368
|
|
|
368
369
|
// Abort signal — connect to an AbortController for cancellation
|
|
@@ -406,15 +407,11 @@ When AI-generated content should be saved to an entity:
|
|
|
406
407
|
|
|
407
408
|
```ts
|
|
408
409
|
// 1. Run the AI action
|
|
409
|
-
const
|
|
410
|
+
const output = await howone.ai.generateStory.run({
|
|
410
411
|
topic: 'Dragons and magic',
|
|
411
412
|
ageRange: '6-8',
|
|
412
413
|
})
|
|
413
414
|
|
|
414
|
-
if (!result.success) throw new Error(result.errors.join(', '))
|
|
415
|
-
|
|
416
|
-
const output = result.finalResult as GenerateStoryOutput
|
|
417
|
-
|
|
418
415
|
// 2. Save to entity
|
|
419
416
|
const saved = await howone.entities.Story.create({
|
|
420
417
|
title: output.title,
|
|
@@ -448,9 +445,8 @@ function GenerateStoryButton({ input }: { input: GenerateStoryInput }) {
|
|
|
448
445
|
setLoading(true)
|
|
449
446
|
setError(null)
|
|
450
447
|
try {
|
|
451
|
-
const
|
|
452
|
-
|
|
453
|
-
setResult(res.finalResult as GenerateStoryOutput)
|
|
448
|
+
const output = await howone.ai.generateStory.run(input)
|
|
449
|
+
setResult(output)
|
|
454
450
|
} catch (err) {
|
|
455
451
|
if (err instanceof AiSchemaValidationError) {
|
|
456
452
|
setError(`Validation error: ${err.issues.map(i => i.message).join(', ')}`)
|
|
@@ -522,10 +518,11 @@ function StreamingStoryGenerator({ input }: { input: GenerateStoryInput }) {
|
|
|
522
518
|
| Mistake | Correct Pattern |
|
|
523
519
|
|---|---|
|
|
524
520
|
| `defineAiAction('generateStory', { inputSchema })` — no `workflowId` | Always include `workflowId` from `manifest.json`; SDK falls back to action name, which is not a UUID → EAX rejects |
|
|
525
|
-
| Writing `src/lib/sdk.ts` before `
|
|
521
|
+
| Writing `src/lib/sdk.ts` before `.howone/ai/manifest.json` has a workflowId | Run `ai-capability-design` → `sync_ai_artifacts` → `external-ai-capability`; only write bindings from the synced manifest |
|
|
526
522
|
| Hardcoding `workflowId` from memory or guessing | Always read from `.howone/ai/manifest.json` — copy the exact UUID |
|
|
527
523
|
| `howone.ai.run.generateStory(input)` | `howone.ai.generateStory.run(input)` |
|
|
528
524
|
| Action named `run`, `stream`, or `events` | Rename to e.g. `executeWorkflow`, `streamContent` |
|
|
529
|
-
|
|
|
530
|
-
|
|
|
525
|
+
| Passing raw JSON Schema from manifest into `defineAiAction` | Convert JSON Schema fields to Zod first |
|
|
526
|
+
| Making every output field `.optional()` or adding `.passthrough()` after validation fails | Keep manifest-required output fields required; inspect `AiSchemaValidationError.issues` and fix the contract/workflow mismatch |
|
|
527
|
+
| Reading `raw.finalResult`, `raw.data.result`, or `raw.result` after a typed `.run()` | Use the returned value directly when `outputSchema` is configured |
|
|
531
528
|
| Calling `howone.ai.generateStory.run(input)` inside JSX render | Move to event handler or useEffect |
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
# AI Capability Architecture
|
|
2
|
+
|
|
3
|
+
Use this reference when a HowOne app needs AI generation, editing, analysis, research, or other
|
|
4
|
+
workflow-backed behavior.
|
|
5
|
+
|
|
6
|
+
## Core Split
|
|
7
|
+
|
|
8
|
+
HowOne AI has four separate layers:
|
|
9
|
+
|
|
10
|
+
1. **Capability contract**: `ai-capability-design` owns the name, description, input schema, output
|
|
11
|
+
schema, output entity name, workflow ID, versions, preview, apply, restore, and manifest sync.
|
|
12
|
+
2. **External workflow implementation**: `external-ai-capability` submits create/update operations
|
|
13
|
+
to the workflow service using the synced contract from `.howone/ai/manifest.json`.
|
|
14
|
+
3. **Workflow status/background layer**: status checking, request tracking, completion, failure, and
|
|
15
|
+
durable background-task behavior are handled outside the contract tool. Preserve request IDs and
|
|
16
|
+
workflow config IDs for that layer.
|
|
17
|
+
4. **SDK binding and UI**: `src/lib/sdk.ts` is generated from `.howone/ai/manifest.json`, then the
|
|
18
|
+
app calls `howone.ai.<capability>.run()`, `.stream()`, or `.events()`.
|
|
19
|
+
|
|
20
|
+
Do not collapse these layers. The common failure is putting workflow implementation, persistence,
|
|
21
|
+
and UI details into the capability schema.
|
|
22
|
+
|
|
23
|
+
## Source of Truth
|
|
24
|
+
|
|
25
|
+
```text
|
|
26
|
+
agent proposal != source of truth
|
|
27
|
+
applied AI capability version = source of truth
|
|
28
|
+
.howone/ai/manifest.json = local source for codegen
|
|
29
|
+
src/lib/sdk.ts = generated binding output
|
|
30
|
+
external workflow service = implementation builder/editor
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
The agent proposes a contract. The backend validates and versions it. The sync tool writes the
|
|
34
|
+
manifest. App code is generated from the manifest.
|
|
35
|
+
|
|
36
|
+
## Standard AI Feature Workflow
|
|
37
|
+
|
|
38
|
+
1. Inspect current AI state with `ai-capability-design`.
|
|
39
|
+
2. Design one complete capability patch for the feature.
|
|
40
|
+
3. Preview the patch.
|
|
41
|
+
4. Apply the same operations.
|
|
42
|
+
5. Sync AI artifacts.
|
|
43
|
+
6. Read `.howone/ai/manifest.json`.
|
|
44
|
+
7. Submit external workflow create/update with `external-ai-capability`.
|
|
45
|
+
8. Preserve returned `requestIds` for the status/background-task layer.
|
|
46
|
+
9. Generate or update `src/lib/sdk.ts` from the manifest.
|
|
47
|
+
10. Implement UI calls through `howone.ai.*`.
|
|
48
|
+
11. If generated output must be stored, design database entities after the AI output schema exists.
|
|
49
|
+
|
|
50
|
+
Do not preview a patch and then submit different operations. Do not restate schemas in
|
|
51
|
+
`external-ai-capability`; it loads the manifest.
|
|
52
|
+
|
|
53
|
+
## Unsupported AI Requests
|
|
54
|
+
|
|
55
|
+
If the user explicitly asks for AI capability and the feature cannot be implemented with the
|
|
56
|
+
available workflow service capabilities, stop the AI implementation task and report the gap.
|
|
57
|
+
|
|
58
|
+
Do not:
|
|
59
|
+
|
|
60
|
+
- fake the AI feature with static mock data.
|
|
61
|
+
- implement a frontend-only placeholder that pretends AI works.
|
|
62
|
+
- design a workflow that assumes unavailable tools, providers, APIs, or private datasets.
|
|
63
|
+
- silently drop the AI part and continue building a non-AI version.
|
|
64
|
+
- move forbidden work such as database CRUD, auth, upload handling, payments, or app state into the
|
|
65
|
+
workflow.
|
|
66
|
+
|
|
67
|
+
The correct response is to state which requested AI behavior is unsupported, which capability is
|
|
68
|
+
missing or which rule blocks it, and what narrower supported alternative could be built.
|
|
69
|
+
|
|
70
|
+
Only continue implementation when the remaining feature still satisfies the user's intent after
|
|
71
|
+
the unsupported AI capability is removed or narrowed.
|
|
72
|
+
|
|
73
|
+
## Create vs Update
|
|
74
|
+
|
|
75
|
+
Use `external-ai-capability` with `mode: "create"` when a capability has no external implementation.
|
|
76
|
+
The tool reads `workflowId`, `inputSchema`, `outputSchema`, and `outputEntityName` from the synced
|
|
77
|
+
manifest.
|
|
78
|
+
|
|
79
|
+
Use `mode: "update"` when the external workflow implementation needs to change. Updates require:
|
|
80
|
+
|
|
81
|
+
- `capabilityName`
|
|
82
|
+
- `workflowConfigID`
|
|
83
|
+
- `updatePrompt`
|
|
84
|
+
|
|
85
|
+
`workflowConfigID` must come from a confirmed workflow status result, specifically
|
|
86
|
+
`payload.workflow_details.new_workflow_config_id`. Do not invent it, omit it, or substitute
|
|
87
|
+
`workflowId`.
|
|
88
|
+
|
|
89
|
+
If the input/output schema changes, update the capability contract first, sync the manifest, then
|
|
90
|
+
submit the external workflow update.
|
|
91
|
+
|
|
92
|
+
## Persistence Boundary
|
|
93
|
+
|
|
94
|
+
AI workflows produce outputs. They do not persist app state.
|
|
95
|
+
|
|
96
|
+
Workflow can do:
|
|
97
|
+
|
|
98
|
+
- text generation, summarization, translation, classification, extraction
|
|
99
|
+
- image, video, and audio generation/editing/analysis
|
|
100
|
+
- web research and page crawling
|
|
101
|
+
- financial or academic retrieval
|
|
102
|
+
- file generation or file reading through URLs
|
|
103
|
+
|
|
104
|
+
Workflow must not do:
|
|
105
|
+
|
|
106
|
+
- database create/read/update/delete
|
|
107
|
+
- authentication or session handling
|
|
108
|
+
- upload handling
|
|
109
|
+
- payment processing
|
|
110
|
+
- app state management
|
|
111
|
+
- owner assignment or record permissions
|
|
112
|
+
|
|
113
|
+
If the app saves AI output, derive entity fields from `outputSchema` and add only necessary request
|
|
114
|
+
metadata such as prompt, selected options, status, timestamps, or references.
|
|
115
|
+
|
|
116
|
+
## Workflow Count
|
|
117
|
+
|
|
118
|
+
Default rule: one user-facing AI feature maps to one capability and one workflow.
|
|
119
|
+
|
|
120
|
+
Examples:
|
|
121
|
+
|
|
122
|
+
- Story + illustration generator: one workflow that returns story text and generated image URLs.
|
|
123
|
+
- Image edit feature: one workflow that accepts source image URL and edit instruction, returns
|
|
124
|
+
edited image URL.
|
|
125
|
+
- News briefing: one workflow that searches and summarizes, returns briefing and source links.
|
|
126
|
+
|
|
127
|
+
RAG is the exception:
|
|
128
|
+
|
|
129
|
+
- indexing workflow: ingests documents and creates retrieval/indexing artifacts.
|
|
130
|
+
- query workflow: answers questions from the indexed knowledge base.
|
|
131
|
+
|
|
132
|
+
Do not split normal sequential AI steps into multiple capabilities unless they are independently
|
|
133
|
+
triggered product features.
|
|
134
|
+
|
|
135
|
+
## Capability Naming
|
|
136
|
+
|
|
137
|
+
Use stable JavaScript-safe identifiers for capability names, for example `generateIllustration` or
|
|
138
|
+
`summarizeDocument`. Do not use display labels as identifiers.
|
|
139
|
+
|
|
140
|
+
Avoid names that collide with action methods: `run`, `stream`, `events`.
|
|
141
|
+
|
|
142
|
+
Use `outputEntityName` only when the generated output has a natural persisted record shape.
|
|
@@ -0,0 +1,169 @@
|
|
|
1
|
+
# Workflow Contract Rules
|
|
2
|
+
|
|
3
|
+
Use this reference when designing `inputSchema`, `outputSchema`, and capability descriptions for
|
|
4
|
+
HowOne AI workflows.
|
|
5
|
+
|
|
6
|
+
## Loose JSON Schema
|
|
7
|
+
|
|
8
|
+
Workflow schemas should be loose enough for an AI workflow engine.
|
|
9
|
+
|
|
10
|
+
Rules:
|
|
11
|
+
|
|
12
|
+
- Require only essential inputs.
|
|
13
|
+
- Mark non-essential options optional.
|
|
14
|
+
- Prefer `string` with a clear description over restrictive enums when user values are open-ended.
|
|
15
|
+
- Avoid `minLength`, `maxLength`, `pattern`, and narrow validation unless there is a concrete
|
|
16
|
+
technical reason.
|
|
17
|
+
- Avoid nested objects when a simple described string is enough.
|
|
18
|
+
- Avoid exposing implementation knobs the user does not need.
|
|
19
|
+
|
|
20
|
+
Good:
|
|
21
|
+
|
|
22
|
+
```json
|
|
23
|
+
{
|
|
24
|
+
"tone": {
|
|
25
|
+
"type": "string",
|
|
26
|
+
"description": "Desired writing tone, e.g. formal, casual, humorous, empathetic, professional."
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
Use enums only for truly closed domains.
|
|
32
|
+
|
|
33
|
+
## URLs, Not Raw Files
|
|
34
|
+
|
|
35
|
+
All file exchange uses URLs.
|
|
36
|
+
|
|
37
|
+
Rules:
|
|
38
|
+
|
|
39
|
+
- File inputs are strings with `format: "uri"`, such as `document_url`, `source_image_url`, or
|
|
40
|
+
`audio_file_url`.
|
|
41
|
+
- File outputs are strings with `format: "uri"`, such as `generated_image_url`, `edited_video_url`,
|
|
42
|
+
or `result_pdf_url`.
|
|
43
|
+
- Never use base64, raw bytes, inline file content, or `contentEncoding`.
|
|
44
|
+
- The app uploads user files first, then passes the URL to the workflow.
|
|
45
|
+
|
|
46
|
+
## Output Minimalism
|
|
47
|
+
|
|
48
|
+
The workflow will try to fill every output field. Only ask for fields the product needs.
|
|
49
|
+
|
|
50
|
+
Usually forbidden unless explicitly requested:
|
|
51
|
+
|
|
52
|
+
- timestamps and processing time
|
|
53
|
+
- file size, MIME type, encoding, dimensions, frame rate, bitrate
|
|
54
|
+
- confidence scores and bounding boxes
|
|
55
|
+
- model, provider, version, cost, or internal execution metadata
|
|
56
|
+
- style/tone metadata when the user only asked for an asset
|
|
57
|
+
|
|
58
|
+
Examples:
|
|
59
|
+
|
|
60
|
+
| User Need | Good Output | Avoid |
|
|
61
|
+
|---|---|---|
|
|
62
|
+
| Summarize a document | `summary` | `summary`, `word_count`, `reading_time` |
|
|
63
|
+
| Generate an image | `generated_image_url` | `generated_image_url`, `model_used`, `color_palette` |
|
|
64
|
+
| OCR an image | `extracted_text` | `extracted_text`, `confidence_score`, `bounding_boxes` |
|
|
65
|
+
|
|
66
|
+
## No Input/Output Name Overlap
|
|
67
|
+
|
|
68
|
+
Input and output property names must not overlap. The workflow engine uses a shared parameter
|
|
69
|
+
namespace.
|
|
70
|
+
|
|
71
|
+
Bad:
|
|
72
|
+
|
|
73
|
+
```json
|
|
74
|
+
{
|
|
75
|
+
"inputSchema": { "properties": { "text": { "type": "string" } } },
|
|
76
|
+
"outputSchema": { "properties": { "text": { "type": "string" } } }
|
|
77
|
+
}
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
Good:
|
|
81
|
+
|
|
82
|
+
```json
|
|
83
|
+
{
|
|
84
|
+
"inputSchema": { "properties": { "source_text": { "type": "string" } } },
|
|
85
|
+
"outputSchema": { "properties": { "translated_text": { "type": "string" } } }
|
|
86
|
+
}
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
Common pairs:
|
|
90
|
+
|
|
91
|
+
- `source_text` -> `translated_text`
|
|
92
|
+
- `source_content` -> `summary`
|
|
93
|
+
- `source_image_url` -> `edited_image_url`
|
|
94
|
+
- `description_prompt` -> `generated_image_url`
|
|
95
|
+
|
|
96
|
+
## Output Language
|
|
97
|
+
|
|
98
|
+
Every text output field description must specify the language rule.
|
|
99
|
+
|
|
100
|
+
Use one of these patterns:
|
|
101
|
+
|
|
102
|
+
- fixed: "Summary in English."
|
|
103
|
+
- input-driven: "Translated text in the target language specified by `target_language`."
|
|
104
|
+
- source-driven: "Summary in the same language as the source document."
|
|
105
|
+
- mixed: "Extracted text, which may contain mixed Chinese and English content."
|
|
106
|
+
|
|
107
|
+
Do not write vague descriptions like "The translated text."
|
|
108
|
+
|
|
109
|
+
## Description Says What, Not How
|
|
110
|
+
|
|
111
|
+
`capability.description` describes the user outcome.
|
|
112
|
+
|
|
113
|
+
Do:
|
|
114
|
+
|
|
115
|
+
```json
|
|
116
|
+
{
|
|
117
|
+
"description": "Searches the web for the latest news on a topic and produces a structured briefing with source links."
|
|
118
|
+
}
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
Do not:
|
|
122
|
+
|
|
123
|
+
```json
|
|
124
|
+
{
|
|
125
|
+
"description": "First calls search_web, then summarizes each article with an LLM, then saves JSON."
|
|
126
|
+
}
|
|
127
|
+
```
|
|
128
|
+
|
|
129
|
+
Never mention internal tool names, step sequences, providers, or model names in the capability
|
|
130
|
+
description.
|
|
131
|
+
|
|
132
|
+
## Available Capability Families
|
|
133
|
+
|
|
134
|
+
Design only around capabilities available to the workflow service:
|
|
135
|
+
|
|
136
|
+
- web search and page crawling
|
|
137
|
+
- image generation, editing, analysis, OCR
|
|
138
|
+
- video generation, editing, concatenation, frame extraction
|
|
139
|
+
- audio generation, recognition, merging
|
|
140
|
+
- financial price history retrieval
|
|
141
|
+
- academic paper search and bibliography
|
|
142
|
+
- file storage/read for JSON, YAML, CSV, PDF, Markdown, TXT
|
|
143
|
+
- email sending
|
|
144
|
+
- RSS feed fetching
|
|
145
|
+
- Airbnb search
|
|
146
|
+
- Hacker News search
|
|
147
|
+
|
|
148
|
+
If the requested product needs unavailable functionality, redesign the feature around available
|
|
149
|
+
capabilities or exclude it explicitly.
|
|
150
|
+
|
|
151
|
+
When the user explicitly requires the unavailable AI behavior, terminate the AI task instead of
|
|
152
|
+
building a fake or silently degraded implementation. Report the unsupported requirement and the
|
|
153
|
+
closest supported alternative.
|
|
154
|
+
|
|
155
|
+
## External Data Assumptions
|
|
156
|
+
|
|
157
|
+
Do not assume the user can provide external datasets unless they explicitly say so.
|
|
158
|
+
|
|
159
|
+
For "stock analysis", use a workflow input such as `trading_symbol` and let the workflow retrieve
|
|
160
|
+
history. Do not require `stock_data_csv_url` unless the user says they have a CSV.
|
|
161
|
+
|
|
162
|
+
For "latest news", use web search inside the workflow. Do not ask the user to provide article URLs
|
|
163
|
+
unless that is the product requirement.
|
|
164
|
+
|
|
165
|
+
## MVP Limit
|
|
166
|
+
|
|
167
|
+
Keep AI app generation to at most five core features. Exclude feedback forms, onboarding tutorials,
|
|
168
|
+
notification settings, export, sharing, personalization, and preferences unless the user explicitly
|
|
169
|
+
requests them.
|