@nebutra/brand-genesis 0.2.1 → 0.2.3
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/CHANGELOG.md +33 -0
- package/LICENSE +21 -676
- package/README.md +1 -1
- package/dist/{chunk-K3P6F3LB.js → chunk-2UQ5N3IJ.js} +2 -2
- package/dist/chunk-2UQ5N3IJ.js.map +1 -0
- package/dist/cli.js +1 -1
- package/dist/index.js +1 -1
- package/package.json +26 -16
- package/.nebutra/debug/brand-genesis.jsonl +0 -6
- package/.nebutra/debug/content-store.jsonl +0 -6
- package/.nebutra/debug/event-log.jsonl +0 -1
- package/.turbo/turbo-build.log +0 -22
- package/.turbo/turbo-test.log +0 -15
- package/.turbo/turbo-typecheck.log +0 -4
- package/dist/chunk-K3P6F3LB.js.map +0 -1
- package/examples/brand-context-only.ts +0 -9
- package/examples/doctor.ts +0 -11
- package/examples/quickstart.ts +0 -27
- package/plays/brand_film_60s/SKILL.md +0 -84
- package/plays/brand_film_60s/fixtures/input_1.json +0 -5
- package/plays/brand_film_60s/fixtures/input_2.json +0 -5
- package/plays/brand_film_60s/fixtures/input_3.json +0 -5
- package/plays/brand_film_60s/templates/BRAND.md.tmpl +0 -29
- package/plays/brand_film_60s/templates/palette.json.tmpl +0 -4
- package/src/cli.ts +0 -64
- package/src/index.test.ts +0 -123
- package/src/index.ts +0 -513
- package/tsconfig.json +0 -9
- package/tsup.config.ts +0 -11
package/README.md
CHANGED
|
@@ -6,7 +6,7 @@ Status: **WIP**
|
|
|
6
6
|
company idea into a `BrandContext`, writes `company/BRAND.md`, then delegates
|
|
7
7
|
asset generation to existing media capabilities.
|
|
8
8
|
|
|
9
|
-
It intentionally does not own image, video, audio, voice, mesh, or landing
|
|
9
|
+
It intentionally does not own image, video, audio, voice, mesh, or landing
|
|
10
10
|
generation primitives.
|
|
11
11
|
|
|
12
12
|
```ts
|
|
@@ -23,7 +23,7 @@ var CHECKPOINTS = [
|
|
|
23
23
|
"final_compose"
|
|
24
24
|
];
|
|
25
25
|
function normalizeBrandId(name) {
|
|
26
|
-
return name.toLowerCase().replace(/[^a-z0-9]
|
|
26
|
+
return name.slice(0, 200).toLowerCase().replace(/[^a-z0-9]{1,200}/g, "_").replace(/^_{1,200}|_{1,200}$/g, "").slice(0, 32);
|
|
27
27
|
}
|
|
28
28
|
function pickName(idea) {
|
|
29
29
|
const called = idea.match(/\bcalled\s+([A-Z][a-zA-Z0-9]*(?:\s+[A-Z][a-zA-Z0-9]*)?)/);
|
|
@@ -392,4 +392,4 @@ export {
|
|
|
392
392
|
BrandGenesis,
|
|
393
393
|
readBrandGenesisDebug
|
|
394
394
|
};
|
|
395
|
-
//# sourceMappingURL=chunk-
|
|
395
|
+
//# sourceMappingURL=chunk-2UQ5N3IJ.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/index.ts"],"sourcesContent":["import { mkdir } from \"node:fs/promises\";\nimport { dirname, join } from \"node:path\";\nimport { type MeshAsset, MeshPipeline } from \"@nebutra/3d-pipeline\";\nimport { type AudioAsset, AudioPipeline } from \"@nebutra/audio-pipeline\";\nimport { requireCapabilityTenant } from \"@nebutra/capability-kit\";\nimport { appendCapabilityDebug, readCapabilityDebug } from \"@nebutra/capability-kit/debug\";\nimport { ContentStore, serializeContentFrontmatter } from \"@nebutra/content-store\";\nimport { CapabilityError } from \"@nebutra/errors\";\nimport { EventLog } from \"@nebutra/event-log\";\nimport {\n assetId,\n type BrandColor,\n type BrandContext,\n type VisualStyle,\n} from \"@nebutra/generation-context\";\nimport { type ImageAsset, ImagePipeline } from \"@nebutra/image-pipeline\";\nimport { type Storyboard, type VideoAsset, VideoPipeline } from \"@nebutra/video-pipeline\";\nimport { type VoiceAsset, VoiceRealtime } from \"@nebutra/voice-realtime\";\n\nexport type VisualDirectionHint =\n | \"cyberpunk\"\n | \"minimal\"\n | \"organic\"\n | \"playful\"\n | \"corporate\"\n | \"retro\"\n | \"futurist\";\n\nexport interface BrandFilmInput {\n readonly tenantId?: string;\n readonly idea: string;\n readonly founderVoiceId?: string;\n readonly visualDirectionHint?: VisualDirectionHint;\n}\n\nexport interface BrandIdentityDraft {\n readonly name: string;\n readonly oneLiner: string;\n readonly tagline: string;\n readonly targetAudience: string;\n readonly toneKeywords: readonly string[];\n readonly differentiation: string;\n readonly visualStyle: VisualStyle;\n}\n\nexport interface BrandPackage {\n readonly tenantId: string;\n readonly play: \"brand_film_60s\";\n readonly brand: BrandContext;\n readonly draft: BrandIdentityDraft;\n readonly brandMdPath: string;\n readonly palettePath: string;\n readonly landingPath: string;\n readonly logo: ImageAsset;\n readonly hero: ImageAsset;\n readonly icon: ImageAsset;\n readonly mesh: MeshAsset;\n readonly storyboard: Storyboard;\n readonly film: VideoAsset;\n readonly bgm: AudioAsset;\n readonly narration: VoiceAsset;\n readonly eventId: string;\n readonly checkpoints: readonly string[];\n}\n\nexport interface BrandGenesisDoctorReport {\n readonly capability: \"brand-genesis\";\n readonly ok: boolean;\n readonly checkedAt: string;\n readonly play: {\n readonly ok: boolean;\n readonly name: \"brand_film_60s\";\n readonly requiredSkills: readonly string[];\n };\n readonly media: {\n readonly image: readonly unknown[];\n readonly video: readonly unknown[];\n readonly audio: readonly unknown[];\n readonly voice: readonly unknown[];\n readonly mesh: readonly unknown[];\n };\n readonly suggestion?: string;\n}\n\nexport interface BrandGenesisOptions {\n readonly tenantId?: string;\n readonly root?: string;\n readonly debugRoot?: string;\n readonly contentStore?: ContentStore;\n readonly eventLog?: EventLog;\n readonly imagePipeline?: ImagePipeline;\n readonly videoPipeline?: VideoPipeline;\n readonly audioPipeline?: AudioPipeline;\n readonly voiceRealtime?: VoiceRealtime;\n readonly meshPipeline?: MeshPipeline;\n}\n\nconst PLAY_NAME = \"brand_film_60s\" as const;\nconst CHECKPOINTS = [\n \"brand_distillation\",\n \"visual_direction\",\n \"assets_generated\",\n \"video_rendered\",\n \"final_compose\",\n] as const;\n\nfunction normalizeBrandId(name: string): string {\n return name\n .slice(0, 200)\n .toLowerCase()\n .replace(/[^a-z0-9]{1,200}/g, \"_\")\n .replace(/^_{1,200}|_{1,200}$/g, \"\")\n .slice(0, 32);\n}\n\nfunction pickName(idea: string): string {\n const called = idea.match(/\\bcalled\\s+([A-Z][a-zA-Z0-9]*(?:\\s+[A-Z][a-zA-Z0-9]*)?)/);\n if (called?.[1]) return called[1].trim();\n const capitalized = [...idea.matchAll(/\\b[A-Z][a-zA-Z0-9]{2,}\\b/g)]\n .map((match) => match[0])\n .filter((value) => ![\"AI\", \"SaaS\", \"API\"].includes(value));\n return capitalized.at(-1) ?? \"Venture\";\n}\n\nfunction paletteFor(hint: VisualDirectionHint | undefined): readonly BrandColor[] {\n switch (hint) {\n case \"cyberpunk\":\n case \"futurist\":\n return [\n { name: \"electric cyan\", hex: \"#00D4FF\", role: \"primary\" },\n { name: \"carbon black\", hex: \"#111318\", role: \"background\" },\n { name: \"signal amber\", hex: \"#F3C14B\", role: \"accent\" },\n ];\n case \"organic\":\n return [\n { name: \"moss\", hex: \"#3D7A57\", role: \"primary\" },\n { name: \"paper\", hex: \"#F7F4EA\", role: \"background\" },\n { name: \"clay\", hex: \"#C86B4A\", role: \"accent\" },\n ];\n case \"playful\":\n return [\n { name: \"coral\", hex: \"#FF6B6B\", role: \"primary\" },\n { name: \"ink\", hex: \"#202124\", role: \"neutral\" },\n { name: \"mint\", hex: \"#7CE2C6\", role: \"accent\" },\n ];\n case \"corporate\":\n return [\n { name: \"trust blue\", hex: \"#2454D6\", role: \"primary\" },\n { name: \"slate\", hex: \"#202A36\", role: \"neutral\" },\n { name: \"clear sky\", hex: \"#E8F0FF\", role: \"background\" },\n ];\n case \"retro\":\n return [\n { name: \"oxide\", hex: \"#B95F3B\", role: \"primary\" },\n { name: \"night ink\", hex: \"#18202A\", role: \"neutral\" },\n { name: \"cream light\", hex: \"#F8E7C9\", role: \"background\" },\n ];\n default:\n return [\n { name: \"graphite\", hex: \"#1F2933\", role: \"primary\" },\n { name: \"white\", hex: \"#FFFFFF\", role: \"background\" },\n { name: \"signal green\", hex: \"#00A693\", role: \"accent\" },\n ];\n }\n}\n\nfunction styleFor(hint: VisualDirectionHint | undefined): VisualStyle {\n const name = hint ?? \"minimal\";\n const keywordsByHint: Record<VisualDirectionHint, readonly string[]> = {\n cyberpunk: [\"electric\", \"terminal-native\", \"high-contrast\"],\n minimal: [\"calm\", \"precise\", \"spacious\"],\n organic: [\"warm\", \"natural\", \"human\"],\n playful: [\"bright\", \"friendly\", \"kinetic\"],\n corporate: [\"credible\", \"structured\", \"clear\"],\n retro: [\"nostalgic\", \"tactile\", \"characterful\"],\n futurist: [\"clean\", \"technical\", \"forward\"],\n };\n return {\n name,\n keywords: keywordsByHint[name],\n avoid: [\"generic stock\", \"dark horror\", \"visual clutter\"],\n };\n}\n\nexport function distillBrandIdea(input: BrandFilmInput): BrandIdentityDraft {\n const idea = input.idea.trim();\n if (idea.length === 0) {\n throw new CapabilityError(\"brand-genesis\", \"Brand idea is empty\", {\n suggestion: \"Pass a one-sentence company idea before running Brand Genesis.\",\n statusCode: 400,\n });\n }\n const name = pickName(idea);\n const devAudience = /\\bdev|debug|code|developer|engineering/i.test(idea);\n const audience = devAudience\n ? \"Independent developers and small engineering teams shipping software quickly\"\n : \"Early-stage founders validating a focused product wedge\";\n const toneKeywords = devAudience\n ? [\"technical\", \"direct\", \"warm\"]\n : [\"clear\", \"confident\", \"useful\"];\n return {\n name,\n oneLiner: idea,\n tagline: devAudience ? \"Debug like it is a conversation\" : `${name} turns intent into launch`,\n targetAudience: audience,\n toneKeywords,\n differentiation: devAudience\n ? \"Understands the full production context instead of treating each error as an isolated message\"\n : \"Combines brand, execution, and company memory in one repeatable workflow\",\n visualStyle: styleFor(input.visualDirectionHint),\n };\n}\n\nexport function brandContextFromDraft(\n draft: BrandIdentityDraft,\n tenantId: string,\n sourcePath = \"company/BRAND.md\",\n palette = paletteFor(draft.visualStyle.name as VisualDirectionHint),\n): BrandContext {\n return {\n tenantId,\n brandId: normalizeBrandId(draft.name),\n name: draft.name,\n palette,\n typography: {\n heading: draft.visualStyle.name === \"cyberpunk\" ? \"Geist Mono\" : \"Geist Sans\",\n body: \"Geist Sans\",\n accent: \"Geist Mono\",\n },\n visualStyle: draft.visualStyle,\n referenceImages: [],\n forbidden: draft.visualStyle.avoid ?? [],\n toneKeywords: draft.toneKeywords,\n sourcePath,\n };\n}\n\nexport function renderBrandMarkdown(draft: BrandIdentityDraft, brand: BrandContext): string {\n return serializeContentFrontmatter(\n {\n type: \"brand_profile\",\n brand_id: brand.brandId,\n name: brand.name,\n },\n [\n `# ${brand.name}`,\n \"\",\n draft.oneLiner,\n \"\",\n \"## Tagline\",\n \"\",\n draft.tagline,\n \"\",\n \"## Audience\",\n \"\",\n draft.targetAudience,\n \"\",\n \"## Tone\",\n \"\",\n brand.toneKeywords.join(\", \"),\n \"\",\n \"## Visual Direction\",\n \"\",\n `${brand.visualStyle.name}: ${brand.visualStyle.keywords.join(\", \")}`,\n \"\",\n \"## Differentiation\",\n \"\",\n draft.differentiation,\n \"\",\n ].join(\"\\n\"),\n );\n}\n\nfunction renderLandingManifest(draft: BrandIdentityDraft, brand: BrandContext): string {\n return [\n \"<!doctype html>\",\n '<html lang=\"en\">',\n \"<head>\",\n ' <meta charset=\"utf-8\" />',\n ` <title>${brand.name}</title>`,\n \"</head>\",\n \"<body>\",\n ` <main data-brand-id=\"${brand.brandId}\">`,\n ` <h1>${brand.name}</h1>`,\n ` <p>${draft.tagline}</p>`,\n ` <p>${draft.oneLiner}</p>`,\n \" </main>\",\n \"</body>\",\n \"</html>\",\n \"\",\n ].join(\"\\n\");\n}\n\nexport class BrandGenesis {\n readonly #tenantId: string | undefined;\n readonly #root: string;\n readonly #debugRoot: string;\n readonly #contentStore: ContentStore;\n readonly #eventLog: EventLog;\n readonly #image: ImagePipeline;\n readonly #video: VideoPipeline;\n readonly #audio: AudioPipeline;\n readonly #voice: VoiceRealtime;\n readonly #mesh: MeshPipeline;\n\n private constructor(\n options: BrandGenesisOptions & { contentStore: ContentStore; eventLog: EventLog },\n ) {\n this.#tenantId = options.tenantId;\n this.#root = options.root ?? join(process.cwd(), \".nebutra\", \"brand-genesis\");\n this.#debugRoot = options.debugRoot ?? process.cwd();\n this.#contentStore = options.contentStore;\n this.#eventLog = options.eventLog;\n this.#image = options.imagePipeline ?? new ImagePipeline({ root: this.#root });\n this.#video = options.videoPipeline ?? new VideoPipeline({ root: this.#root });\n this.#audio = options.audioPipeline ?? new AudioPipeline({ root: this.#root });\n this.#voice = options.voiceRealtime ?? new VoiceRealtime({ root: this.#root });\n this.#mesh = options.meshPipeline ?? new MeshPipeline({ root: this.#root });\n }\n\n static async open(\n root = \".nebutra/brand-genesis\",\n options: Omit<BrandGenesisOptions, \"root\" | \"contentStore\" | \"eventLog\"> = {},\n ): Promise<BrandGenesis> {\n const tenantId = options.tenantId ?? \"local\";\n await mkdir(root, { recursive: true });\n const contentStore = await ContentStore.open(join(root, \"content\"), { tenantId });\n const eventLog = await EventLog.open(join(root, \"event-log\"), { tenantId });\n return new BrandGenesis({ ...options, tenantId, root, contentStore, eventLog });\n }\n\n async run(input: BrandFilmInput): Promise<BrandPackage> {\n const tenantId = requireCapabilityTenant({\n explicit: input.tenantId,\n fallback: this.#tenantId,\n onMissing: () =>\n new CapabilityError(\"brand-genesis\", \"Brand Genesis requires tenant context\", {\n suggestion: \"Pass tenantId on the input or construct BrandGenesis with tenantId.\",\n statusCode: 400,\n }),\n });\n const draft = distillBrandIdea(input);\n const brand = brandContextFromDraft(draft, tenantId);\n const brandMarkdown = renderBrandMarkdown(draft, brand);\n await this.#contentStore.write(brand.sourcePath, brandMarkdown);\n const palettePath = \"company/assets/palette.json\";\n await this.#contentStore.write(\n palettePath,\n `${JSON.stringify({ brandId: brand.brandId, colors: brand.palette }, null, 2)}\\n`,\n );\n await this.#debug({\n type: \"checkpoint\",\n step: CHECKPOINTS[0],\n tenantId,\n brandId: brand.brandId,\n });\n await this.#debug({\n type: \"checkpoint\",\n step: CHECKPOINTS[1],\n tenantId,\n brandId: brand.brandId,\n });\n\n const [logo, hero, icon] = await Promise.all([\n this.#image.generate({ type: \"logo\", company: brand.name, oneLiner: draft.oneLiner }, brand),\n this.#image.generate({ type: \"hero\", headline: draft.tagline }, brand),\n this.#image.generate({ type: \"icon\", subject: brand.name }, brand),\n ]);\n const mesh = await this.#mesh.fromImage(logo, brand);\n await this.#debug({\n type: \"checkpoint\",\n step: CHECKPOINTS[2],\n tenantId,\n brandId: brand.brandId,\n });\n\n const storyboard = await this.#video.plan(\n { type: \"brand-film\", durationS: 60, theme: draft.tagline },\n brand,\n );\n const rendered = await this.#video.render(storyboard, brand);\n await this.#debug({\n type: \"checkpoint\",\n step: CHECKPOINTS[3],\n tenantId,\n brandId: brand.brandId,\n });\n\n const bgm = await this.#audio.generate(\n { type: \"bgm\", durationS: rendered.durationS, mood: brand.toneKeywords.join(\" \") },\n brand,\n true,\n );\n const narration = await this.#voice.synthesizeNarration(\n {\n script: `${draft.tagline}. ${draft.oneLiner}. ${draft.differentiation}.`,\n targetDurationS: Math.max(8, Math.min(20, rendered.durationS - 3)),\n ...(input.founderVoiceId !== undefined ? { voiceProfileId: input.founderVoiceId } : {}),\n },\n brand,\n );\n const film = await this.#video.compose({\n videoTrack: [rendered],\n audioTrack: [bgm],\n voiceTrack: [narration],\n captionTrack: [{ startS: 0, endS: narration.durationS, text: narration.transcript }],\n });\n const landingPath = \"company/landing/index.html\";\n await this.#contentStore.write(landingPath, renderLandingManifest(draft, brand));\n await this.#debug({\n type: \"checkpoint\",\n step: CHECKPOINTS[4],\n tenantId,\n brandId: brand.brandId,\n });\n\n const eventId = await this.#eventLog.commit({\n traceId: assetId(\"brand_genesis\", brand.brandId),\n kind: \"content_write\",\n affected: [\n brand.sourcePath,\n palettePath,\n landingPath,\n logo.path,\n hero.path,\n icon.path,\n film.path,\n ],\n parent: null,\n snapshot: {\n [brand.sourcePath]: brandMarkdown,\n [palettePath]: JSON.stringify({ brandId: brand.brandId, colors: brand.palette }, null, 2),\n [landingPath]: renderLandingManifest(draft, brand),\n },\n });\n\n const result: BrandPackage = {\n tenantId,\n play: PLAY_NAME,\n brand,\n draft,\n brandMdPath: brand.sourcePath,\n palettePath,\n landingPath,\n logo,\n hero,\n icon,\n mesh,\n storyboard,\n film,\n bgm,\n narration,\n eventId,\n checkpoints: CHECKPOINTS,\n };\n await this.#debug({ type: \"run\", tenantId, brandId: brand.brandId, eventId });\n return result;\n }\n\n async doctor(): Promise<BrandGenesisDoctorReport> {\n const [image, video, audio, rawVoice, mesh] = await Promise.all([\n this.#image.doctor(),\n this.#video.doctor(),\n this.#audio.doctor(),\n this.#voice.doctor(),\n this.#mesh.doctor(),\n ]);\n const voice = [{ provider: \"narration-local\", ok: true }, ...rawVoice];\n const localOk = [image, video, audio, voice, mesh].every((checks) =>\n checks.some((check) => Boolean((check as { ok?: boolean }).ok)),\n );\n return {\n capability: \"brand-genesis\",\n ok: localOk,\n checkedAt: new Date().toISOString(),\n play: {\n ok: true,\n name: PLAY_NAME,\n requiredSkills: [\n \"image_pipeline.generate\",\n \"video_pipeline.plan\",\n \"video_pipeline.render\",\n \"video_pipeline.compose\",\n \"audio_pipeline.generate\",\n \"voice_realtime.synthesize_narration\",\n \"mesh_pipeline.from_image\",\n \"content_store.write\",\n ],\n },\n media: { image, video, audio, voice, mesh },\n ...(!localOk\n ? {\n suggestion:\n \"Run the individual media doctor commands and configure missing local or remote providers.\",\n }\n : {}),\n };\n }\n\n async close(): Promise<void> {\n await this.#contentStore.close();\n }\n\n async #debug(entry: Record<string, unknown>): Promise<void> {\n await mkdir(dirname(join(this.#debugRoot, \".nebutra\", \"debug\", \"brand-genesis.jsonl\")), {\n recursive: true,\n });\n await appendCapabilityDebug(\"brand-genesis\", entry, { root: this.#debugRoot });\n }\n}\n\nexport async function readBrandGenesisDebug(root = process.cwd(), limit = 20): Promise<unknown[]> {\n return readCapabilityDebug(\"brand-genesis\", { root, limit });\n}\n"],"mappings":";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ACA;AAAA,UACA;AAAA,UACA;AAAA,QACF;AAAA,MACF;AAAA,MACA,OAAO,EAAE,OAAO,OAAO,OAAO,OAAO,KAAK;AAAA,MAC1C,GAAI,CAAC,UACD;AAAA,QACE,YACE;AAAA,MACJ,IACA,CAAC;AAAA,IACP;AAAA,EACF;AAAA,EAEA,MAAM,QAAuB;AAC3B,UAAM,KAAK,cAAc,MAAM;AAAA,EACjC;AAAA,EAEA,MAAM,OAAO,OAA+C;AAC1D,UAAM,MAAM,QAAQ,KAAK,KAAK,YAAY,YAAY,SAAS,qBAAqB,CAAC,GAAG;AAAA,MACtF,WAAW;AAAA,IACb,CAAC;AACD,UAAM,sBAAsB,iBAAiB,OAAO,EAAE,MAAM,KAAK,WAAW,CAAC;AAAA,EAC/E;AACF;AAEA,eAAsB,sBAAsB,OAAO,QAAQ,IAAI,GAAG,QAAQ,IAAwB;AAChG,SAAO,oBAAoB,iBAAiB,EAAE,MAAM,MAAM,CAAC;AAC7D;","names":[]}
|
package/dist/cli.js
CHANGED
package/dist/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nebutra/brand-genesis",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.3",
|
|
4
4
|
"description": "BrandContext-first flagship play for creating a complete brand package from one idea",
|
|
5
5
|
"private": false,
|
|
6
6
|
"license": "MIT",
|
|
@@ -25,26 +25,30 @@
|
|
|
25
25
|
"category": "ai",
|
|
26
26
|
"summary": "Flagship play that distills an idea into BrandContext and orchestrates lower generation capabilities"
|
|
27
27
|
},
|
|
28
|
-
"main": "./
|
|
29
|
-
"types": "./
|
|
28
|
+
"main": "./dist/index.js",
|
|
29
|
+
"types": "./dist/index.d.ts",
|
|
30
30
|
"exports": {
|
|
31
|
-
".":
|
|
31
|
+
".": {
|
|
32
|
+
"types": "./dist/index.d.ts",
|
|
33
|
+
"import": "./dist/index.js",
|
|
34
|
+
"default": "./dist/index.js"
|
|
35
|
+
}
|
|
32
36
|
},
|
|
33
37
|
"dependencies": {
|
|
34
|
-
"@nebutra/
|
|
35
|
-
"@nebutra/
|
|
36
|
-
"@nebutra/
|
|
37
|
-
"@nebutra/content-store": "0.1.
|
|
38
|
-
"@nebutra/errors": "0.1.
|
|
39
|
-
"@nebutra/event-log": "0.1.
|
|
40
|
-
"@nebutra/generation-context": "0.1.
|
|
41
|
-
"@nebutra/image-pipeline": "0.1.
|
|
42
|
-
"@nebutra/
|
|
43
|
-
"@nebutra/
|
|
44
|
-
"@nebutra/
|
|
38
|
+
"@nebutra/audio-pipeline": "0.1.3",
|
|
39
|
+
"@nebutra/capability-kit": "0.2.4",
|
|
40
|
+
"@nebutra/3d-pipeline": "0.1.3",
|
|
41
|
+
"@nebutra/content-store": "0.1.4",
|
|
42
|
+
"@nebutra/errors": "0.1.2",
|
|
43
|
+
"@nebutra/event-log": "0.1.4",
|
|
44
|
+
"@nebutra/generation-context": "0.1.3",
|
|
45
|
+
"@nebutra/image-pipeline": "0.1.3",
|
|
46
|
+
"@nebutra/video-pipeline": "0.1.3",
|
|
47
|
+
"@nebutra/voice-realtime": "0.1.3",
|
|
48
|
+
"@nebutra/play-loader": "0.1.3"
|
|
45
49
|
},
|
|
46
50
|
"devDependencies": {
|
|
47
|
-
"@types/node": "^
|
|
51
|
+
"@types/node": "^25.9.1",
|
|
48
52
|
"tsup": "^8.5.1",
|
|
49
53
|
"tsx": "^4.21.0",
|
|
50
54
|
"typescript": "^5.9.3",
|
|
@@ -62,6 +66,12 @@
|
|
|
62
66
|
"publishConfig": {
|
|
63
67
|
"access": "public"
|
|
64
68
|
},
|
|
69
|
+
"files": [
|
|
70
|
+
"dist",
|
|
71
|
+
"README.md",
|
|
72
|
+
"LICENSE",
|
|
73
|
+
"CHANGELOG.md"
|
|
74
|
+
],
|
|
65
75
|
"scripts": {
|
|
66
76
|
"build": "tsup",
|
|
67
77
|
"test": "vitest run",
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
{"at":"2026-05-19T08:15:34.452Z","type":"checkpoint","step":"brand_distillation","tenantId":"tenant_a","brandId":"loop"}
|
|
2
|
-
{"at":"2026-05-19T08:15:34.452Z","type":"checkpoint","step":"visual_direction","tenantId":"tenant_a","brandId":"loop"}
|
|
3
|
-
{"at":"2026-05-19T08:15:34.469Z","type":"checkpoint","step":"assets_generated","tenantId":"tenant_a","brandId":"loop"}
|
|
4
|
-
{"at":"2026-05-19T08:15:34.471Z","type":"checkpoint","step":"video_rendered","tenantId":"tenant_a","brandId":"loop"}
|
|
5
|
-
{"at":"2026-05-19T08:15:34.579Z","type":"checkpoint","step":"final_compose","tenantId":"tenant_a","brandId":"loop"}
|
|
6
|
-
{"at":"2026-05-19T08:15:34.620Z","type":"run","tenantId":"tenant_a","brandId":"loop","eventId":"e166fc7be4195c10110a51efee24e78a66bd8da8ed577986050b54962af71b80"}
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
{"at":"2026-05-19T08:15:34.411Z","type":"reindex","tenantId":"tenant_a","files":0}
|
|
2
|
-
{"at":"2026-05-19T08:15:34.443Z","type":"write","tenantId":"tenant_a","path":"company/BRAND.md"}
|
|
3
|
-
{"at":"2026-05-19T08:15:34.449Z","type":"write","tenantId":"tenant_a","path":"company/assets/palette.json"}
|
|
4
|
-
{"at":"2026-05-19T08:15:34.578Z","type":"write","tenantId":"tenant_a","path":"company/landing/index.html"}
|
|
5
|
-
{"at":"2026-05-19T08:15:34.698Z","type":"reindex","tenantId":"local","files":0}
|
|
6
|
-
{"at":"2026-05-19T08:15:34.834Z","type":"reindex","tenantId":"tenant_a","files":0}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"at":"2026-05-19T08:15:34.612Z","traceId":"brand_genesis_loop_mpccyncj","kind":"content_write","affected":["company/BRAND.md","company/assets/palette.json","company/landing/index.html","/tmp/brand-genesis-07d5Z1/.nebutra/generated/image-pipeline/image_logo_loop_ai_debugging_for_indie_devs_ca_mpccyn91.svg","/tmp/brand-genesis-07d5Z1/.nebutra/generated/image-pipeline/image_hero_debug_like_it_is_a_conversation_mpccyn91.svg","/tmp/brand-genesis-07d5Z1/.nebutra/generated/image-pipeline/image_icon_loop_mpccyn91.svg","/tmp/brand-genesis-07d5Z1/.nebutra/generated/video-pipeline/composition_video_storyboard_brand_film_loop_mpccyn9_mpccyncd.compose.json"],"parent":null,"snapshot":{"company/BRAND.md":"---\nbrand_id: loop\nname: Loop\ntype: brand_profile\n---\n# Loop\n\nAI debugging for indie devs called Loop\n\n## Tagline\n\nDebug like it is a conversation\n\n## Audience\n\nIndependent developers and small engineering teams shipping software quickly\n\n## Tone\n\ntechnical, direct, warm\n\n## Visual Direction\n\ncyberpunk: electric, terminal-native, high-contrast\n\n## Differentiation\n\nUnderstands the full production context instead of treating each error as an isolated message\n","company/assets/palette.json":"{\n \"brandId\": \"loop\",\n \"colors\": [\n {\n \"name\": \"electric cyan\",\n \"hex\": \"#00D4FF\",\n \"role\": \"primary\"\n },\n {\n \"name\": \"carbon black\",\n \"hex\": \"#111318\",\n \"role\": \"background\"\n },\n {\n \"name\": \"signal amber\",\n \"hex\": \"#F3C14B\",\n \"role\": \"accent\"\n }\n ]\n}","company/landing/index.html":"<!doctype html>\n<html lang=\"en\">\n<head>\n <meta charset=\"utf-8\" />\n <title>Loop</title>\n</head>\n<body>\n <main data-brand-id=\"loop\">\n <h1>Loop</h1>\n <p>Debug like it is a conversation</p>\n <p>AI debugging for indie devs called Loop</p>\n </main>\n</body>\n</html>\n"},"id":"e166fc7be4195c10110a51efee24e78a66bd8da8ed577986050b54962af71b80","tenantId":"tenant_a","summary":"content_write touched 7 path(s)","objectHashes":["214176d31137be38d254248f03bf7946f73e60c33f10aca626d3c8262eb81796","871042e6396b84e849e13122ce60392a98cd9108875d882103534c1abffe83ef","425de019a39993cdcc61c233a5e54625dbd4d5a99eb79275f4642f1cda210d33"]}
|
package/.turbo/turbo-build.log
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
> @nebutra/brand-genesis@0.2.1 build /home/runner/work/Nebutra-Sailor/Nebutra-Sailor/packages/ai/brand-genesis
|
|
3
|
-
> tsup
|
|
4
|
-
|
|
5
|
-
[34mCLI[39m Building entry: src/cli.ts, src/index.ts
|
|
6
|
-
[34mCLI[39m Using tsconfig: tsconfig.json
|
|
7
|
-
[34mCLI[39m tsup v8.5.1
|
|
8
|
-
[34mCLI[39m Using tsup config: /home/runner/work/Nebutra-Sailor/Nebutra-Sailor/packages/ai/brand-genesis/tsup.config.ts
|
|
9
|
-
[34mCLI[39m Target: es2022
|
|
10
|
-
[34mCLI[39m Cleaning output folder
|
|
11
|
-
[34mESM[39m Build start
|
|
12
|
-
[32mESM[39m [1mdist/cli.js [22m[32m2.22 KB[39m
|
|
13
|
-
[32mESM[39m [1mdist/chunk-K3P6F3LB.js [22m[32m12.92 KB[39m
|
|
14
|
-
[32mESM[39m [1mdist/index.js [22m[32m300.00 B[39m
|
|
15
|
-
[32mESM[39m [1mdist/cli.js.map [22m[32m4.04 KB[39m
|
|
16
|
-
[32mESM[39m [1mdist/index.js.map [22m[32m71.00 B[39m
|
|
17
|
-
[32mESM[39m [1mdist/chunk-K3P6F3LB.js.map [22m[32m25.88 KB[39m
|
|
18
|
-
[32mESM[39m ⚡️ Build success in 19ms
|
|
19
|
-
[34mDTS[39m Build start
|
|
20
|
-
[32mDTS[39m ⚡️ Build success in 2193ms
|
|
21
|
-
[32mDTS[39m [1mdist/cli.d.ts [22m[32m13.00 B[39m
|
|
22
|
-
[32mDTS[39m [1mdist/index.d.ts [22m[32m3.63 KB[39m
|
package/.turbo/turbo-test.log
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
> @nebutra/brand-genesis@0.2.1 test /home/runner/work/Nebutra-Sailor/Nebutra-Sailor/packages/ai/brand-genesis
|
|
3
|
-
> vitest run
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
[1m[30m[46m RUN [49m[39m[22m [36mv4.1.4 [39m[90m/home/runner/work/Nebutra-Sailor/Nebutra-Sailor/packages/ai/brand-genesis[39m
|
|
7
|
-
|
|
8
|
-
[32m✓[39m src/index.test.ts [2m([22m[2m5 tests[22m[2m)[22m[33m 693[2mms[22m[39m
|
|
9
|
-
[33m[2m✓[22m[39m runs the brand_film_60s play through lower capabilities and writes checkpoints [33m 388[2mms[22m[39m
|
|
10
|
-
|
|
11
|
-
[2m Test Files [22m [1m[32m1 passed[39m[22m[90m (1)[39m
|
|
12
|
-
[2m Tests [22m [1m[32m5 passed[39m[22m[90m (5)[39m
|
|
13
|
-
[2m Start at [22m 08:15:32
|
|
14
|
-
[2m Duration [22m 2.86s[2m (transform 1.20s, setup 0ms, import 1.52s, tests 693ms, environment 0ms)[22m
|
|
15
|
-
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/index.ts"],"sourcesContent":["import { mkdir } from \"node:fs/promises\";\nimport { dirname, join } from \"node:path\";\nimport { type MeshAsset, MeshPipeline } from \"@nebutra/3d-pipeline\";\nimport { type AudioAsset, AudioPipeline } from \"@nebutra/audio-pipeline\";\nimport { requireCapabilityTenant } from \"@nebutra/capability-kit\";\nimport { appendCapabilityDebug, readCapabilityDebug } from \"@nebutra/capability-kit/debug\";\nimport { ContentStore, serializeContentFrontmatter } from \"@nebutra/content-store\";\nimport { CapabilityError } from \"@nebutra/errors\";\nimport { EventLog } from \"@nebutra/event-log\";\nimport {\n assetId,\n type BrandColor,\n type BrandContext,\n type VisualStyle,\n} from \"@nebutra/generation-context\";\nimport { type ImageAsset, ImagePipeline } from \"@nebutra/image-pipeline\";\nimport { type Storyboard, type VideoAsset, VideoPipeline } from \"@nebutra/video-pipeline\";\nimport { type VoiceAsset, VoiceRealtime } from \"@nebutra/voice-realtime\";\n\nexport type VisualDirectionHint =\n | \"cyberpunk\"\n | \"minimal\"\n | \"organic\"\n | \"playful\"\n | \"corporate\"\n | \"retro\"\n | \"futurist\";\n\nexport interface BrandFilmInput {\n readonly tenantId?: string;\n readonly idea: string;\n readonly founderVoiceId?: string;\n readonly visualDirectionHint?: VisualDirectionHint;\n}\n\nexport interface BrandIdentityDraft {\n readonly name: string;\n readonly oneLiner: string;\n readonly tagline: string;\n readonly targetAudience: string;\n readonly toneKeywords: readonly string[];\n readonly differentiation: string;\n readonly visualStyle: VisualStyle;\n}\n\nexport interface BrandPackage {\n readonly tenantId: string;\n readonly play: \"brand_film_60s\";\n readonly brand: BrandContext;\n readonly draft: BrandIdentityDraft;\n readonly brandMdPath: string;\n readonly palettePath: string;\n readonly landingPath: string;\n readonly logo: ImageAsset;\n readonly hero: ImageAsset;\n readonly icon: ImageAsset;\n readonly mesh: MeshAsset;\n readonly storyboard: Storyboard;\n readonly film: VideoAsset;\n readonly bgm: AudioAsset;\n readonly narration: VoiceAsset;\n readonly eventId: string;\n readonly checkpoints: readonly string[];\n}\n\nexport interface BrandGenesisDoctorReport {\n readonly capability: \"brand-genesis\";\n readonly ok: boolean;\n readonly checkedAt: string;\n readonly play: {\n readonly ok: boolean;\n readonly name: \"brand_film_60s\";\n readonly requiredSkills: readonly string[];\n };\n readonly media: {\n readonly image: readonly unknown[];\n readonly video: readonly unknown[];\n readonly audio: readonly unknown[];\n readonly voice: readonly unknown[];\n readonly mesh: readonly unknown[];\n };\n readonly suggestion?: string;\n}\n\nexport interface BrandGenesisOptions {\n readonly tenantId?: string;\n readonly root?: string;\n readonly debugRoot?: string;\n readonly contentStore?: ContentStore;\n readonly eventLog?: EventLog;\n readonly imagePipeline?: ImagePipeline;\n readonly videoPipeline?: VideoPipeline;\n readonly audioPipeline?: AudioPipeline;\n readonly voiceRealtime?: VoiceRealtime;\n readonly meshPipeline?: MeshPipeline;\n}\n\nconst PLAY_NAME = \"brand_film_60s\" as const;\nconst CHECKPOINTS = [\n \"brand_distillation\",\n \"visual_direction\",\n \"assets_generated\",\n \"video_rendered\",\n \"final_compose\",\n] as const;\n\nfunction normalizeBrandId(name: string): string {\n return name\n .toLowerCase()\n .replace(/[^a-z0-9]+/g, \"_\")\n .replace(/^_+|_+$/g, \"\")\n .slice(0, 32);\n}\n\nfunction pickName(idea: string): string {\n const called = idea.match(/\\bcalled\\s+([A-Z][a-zA-Z0-9]*(?:\\s+[A-Z][a-zA-Z0-9]*)?)/);\n if (called?.[1]) return called[1].trim();\n const capitalized = [...idea.matchAll(/\\b[A-Z][a-zA-Z0-9]{2,}\\b/g)]\n .map((match) => match[0])\n .filter((value) => ![\"AI\", \"SaaS\", \"API\"].includes(value));\n return capitalized.at(-1) ?? \"Venture\";\n}\n\nfunction paletteFor(hint: VisualDirectionHint | undefined): readonly BrandColor[] {\n switch (hint) {\n case \"cyberpunk\":\n case \"futurist\":\n return [\n { name: \"electric cyan\", hex: \"#00D4FF\", role: \"primary\" },\n { name: \"carbon black\", hex: \"#111318\", role: \"background\" },\n { name: \"signal amber\", hex: \"#F3C14B\", role: \"accent\" },\n ];\n case \"organic\":\n return [\n { name: \"moss\", hex: \"#3D7A57\", role: \"primary\" },\n { name: \"paper\", hex: \"#F7F4EA\", role: \"background\" },\n { name: \"clay\", hex: \"#C86B4A\", role: \"accent\" },\n ];\n case \"playful\":\n return [\n { name: \"coral\", hex: \"#FF6B6B\", role: \"primary\" },\n { name: \"ink\", hex: \"#202124\", role: \"neutral\" },\n { name: \"mint\", hex: \"#7CE2C6\", role: \"accent\" },\n ];\n case \"corporate\":\n return [\n { name: \"trust blue\", hex: \"#2454D6\", role: \"primary\" },\n { name: \"slate\", hex: \"#202A36\", role: \"neutral\" },\n { name: \"clear sky\", hex: \"#E8F0FF\", role: \"background\" },\n ];\n case \"retro\":\n return [\n { name: \"oxide\", hex: \"#B95F3B\", role: \"primary\" },\n { name: \"night ink\", hex: \"#18202A\", role: \"neutral\" },\n { name: \"cream light\", hex: \"#F8E7C9\", role: \"background\" },\n ];\n default:\n return [\n { name: \"graphite\", hex: \"#1F2933\", role: \"primary\" },\n { name: \"white\", hex: \"#FFFFFF\", role: \"background\" },\n { name: \"signal green\", hex: \"#00A693\", role: \"accent\" },\n ];\n }\n}\n\nfunction styleFor(hint: VisualDirectionHint | undefined): VisualStyle {\n const name = hint ?? \"minimal\";\n const keywordsByHint: Record<VisualDirectionHint, readonly string[]> = {\n cyberpunk: [\"electric\", \"terminal-native\", \"high-contrast\"],\n minimal: [\"calm\", \"precise\", \"spacious\"],\n organic: [\"warm\", \"natural\", \"human\"],\n playful: [\"bright\", \"friendly\", \"kinetic\"],\n corporate: [\"credible\", \"structured\", \"clear\"],\n retro: [\"nostalgic\", \"tactile\", \"characterful\"],\n futurist: [\"clean\", \"technical\", \"forward\"],\n };\n return {\n name,\n keywords: keywordsByHint[name],\n avoid: [\"generic stock\", \"dark horror\", \"visual clutter\"],\n };\n}\n\nexport function distillBrandIdea(input: BrandFilmInput): BrandIdentityDraft {\n const idea = input.idea.trim();\n if (idea.length === 0) {\n throw new CapabilityError(\"brand-genesis\", \"Brand idea is empty\", {\n suggestion: \"Pass a one-sentence company idea before running Brand Genesis.\",\n statusCode: 400,\n });\n }\n const name = pickName(idea);\n const devAudience = /\\bdev|debug|code|developer|engineering/i.test(idea);\n const audience = devAudience\n ? \"Independent developers and small engineering teams shipping software quickly\"\n : \"Early-stage founders validating a focused product wedge\";\n const toneKeywords = devAudience\n ? [\"technical\", \"direct\", \"warm\"]\n : [\"clear\", \"confident\", \"useful\"];\n return {\n name,\n oneLiner: idea,\n tagline: devAudience ? \"Debug like it is a conversation\" : `${name} turns intent into launch`,\n targetAudience: audience,\n toneKeywords,\n differentiation: devAudience\n ? \"Understands the full production context instead of treating each error as an isolated message\"\n : \"Combines brand, execution, and company memory in one repeatable workflow\",\n visualStyle: styleFor(input.visualDirectionHint),\n };\n}\n\nexport function brandContextFromDraft(\n draft: BrandIdentityDraft,\n tenantId: string,\n sourcePath = \"company/BRAND.md\",\n palette = paletteFor(draft.visualStyle.name as VisualDirectionHint),\n): BrandContext {\n return {\n tenantId,\n brandId: normalizeBrandId(draft.name),\n name: draft.name,\n palette,\n typography: {\n heading: draft.visualStyle.name === \"cyberpunk\" ? \"Geist Mono\" : \"Geist Sans\",\n body: \"Geist Sans\",\n accent: \"Geist Mono\",\n },\n visualStyle: draft.visualStyle,\n referenceImages: [],\n forbidden: draft.visualStyle.avoid ?? [],\n toneKeywords: draft.toneKeywords,\n sourcePath,\n };\n}\n\nexport function renderBrandMarkdown(draft: BrandIdentityDraft, brand: BrandContext): string {\n return serializeContentFrontmatter(\n {\n type: \"brand_profile\",\n brand_id: brand.brandId,\n name: brand.name,\n },\n [\n `# ${brand.name}`,\n \"\",\n draft.oneLiner,\n \"\",\n \"## Tagline\",\n \"\",\n draft.tagline,\n \"\",\n \"## Audience\",\n \"\",\n draft.targetAudience,\n \"\",\n \"## Tone\",\n \"\",\n brand.toneKeywords.join(\", \"),\n \"\",\n \"## Visual Direction\",\n \"\",\n `${brand.visualStyle.name}: ${brand.visualStyle.keywords.join(\", \")}`,\n \"\",\n \"## Differentiation\",\n \"\",\n draft.differentiation,\n \"\",\n ].join(\"\\n\"),\n );\n}\n\nfunction renderLandingManifest(draft: BrandIdentityDraft, brand: BrandContext): string {\n return [\n \"<!doctype html>\",\n '<html lang=\"en\">',\n \"<head>\",\n ' <meta charset=\"utf-8\" />',\n ` <title>${brand.name}</title>`,\n \"</head>\",\n \"<body>\",\n ` <main data-brand-id=\"${brand.brandId}\">`,\n ` <h1>${brand.name}</h1>`,\n ` <p>${draft.tagline}</p>`,\n ` <p>${draft.oneLiner}</p>`,\n \" </main>\",\n \"</body>\",\n \"</html>\",\n \"\",\n ].join(\"\\n\");\n}\n\nexport class BrandGenesis {\n readonly #tenantId: string | undefined;\n readonly #root: string;\n readonly #debugRoot: string;\n readonly #contentStore: ContentStore;\n readonly #eventLog: EventLog;\n readonly #image: ImagePipeline;\n readonly #video: VideoPipeline;\n readonly #audio: AudioPipeline;\n readonly #voice: VoiceRealtime;\n readonly #mesh: MeshPipeline;\n\n private constructor(\n options: BrandGenesisOptions & { contentStore: ContentStore; eventLog: EventLog },\n ) {\n this.#tenantId = options.tenantId;\n this.#root = options.root ?? join(process.cwd(), \".nebutra\", \"brand-genesis\");\n this.#debugRoot = options.debugRoot ?? process.cwd();\n this.#contentStore = options.contentStore;\n this.#eventLog = options.eventLog;\n this.#image = options.imagePipeline ?? new ImagePipeline({ root: this.#root });\n this.#video = options.videoPipeline ?? new VideoPipeline({ root: this.#root });\n this.#audio = options.audioPipeline ?? new AudioPipeline({ root: this.#root });\n this.#voice = options.voiceRealtime ?? new VoiceRealtime({ root: this.#root });\n this.#mesh = options.meshPipeline ?? new MeshPipeline({ root: this.#root });\n }\n\n static async open(\n root = \".nebutra/brand-genesis\",\n options: Omit<BrandGenesisOptions, \"root\" | \"contentStore\" | \"eventLog\"> = {},\n ): Promise<BrandGenesis> {\n const tenantId = options.tenantId ?? \"local\";\n await mkdir(root, { recursive: true });\n const contentStore = await ContentStore.open(join(root, \"content\"), { tenantId });\n const eventLog = await EventLog.open(join(root, \"event-log\"), { tenantId });\n return new BrandGenesis({ ...options, tenantId, root, contentStore, eventLog });\n }\n\n async run(input: BrandFilmInput): Promise<BrandPackage> {\n const tenantId = requireCapabilityTenant({\n explicit: input.tenantId,\n fallback: this.#tenantId,\n onMissing: () =>\n new CapabilityError(\"brand-genesis\", \"Brand Genesis requires tenant context\", {\n suggestion: \"Pass tenantId on the input or construct BrandGenesis with tenantId.\",\n statusCode: 400,\n }),\n });\n const draft = distillBrandIdea(input);\n const brand = brandContextFromDraft(draft, tenantId);\n const brandMarkdown = renderBrandMarkdown(draft, brand);\n await this.#contentStore.write(brand.sourcePath, brandMarkdown);\n const palettePath = \"company/assets/palette.json\";\n await this.#contentStore.write(\n palettePath,\n `${JSON.stringify({ brandId: brand.brandId, colors: brand.palette }, null, 2)}\\n`,\n );\n await this.#debug({\n type: \"checkpoint\",\n step: CHECKPOINTS[0],\n tenantId,\n brandId: brand.brandId,\n });\n await this.#debug({\n type: \"checkpoint\",\n step: CHECKPOINTS[1],\n tenantId,\n brandId: brand.brandId,\n });\n\n const [logo, hero, icon] = await Promise.all([\n this.#image.generate({ type: \"logo\", company: brand.name, oneLiner: draft.oneLiner }, brand),\n this.#image.generate({ type: \"hero\", headline: draft.tagline }, brand),\n this.#image.generate({ type: \"icon\", subject: brand.name }, brand),\n ]);\n const mesh = await this.#mesh.fromImage(logo, brand);\n await this.#debug({\n type: \"checkpoint\",\n step: CHECKPOINTS[2],\n tenantId,\n brandId: brand.brandId,\n });\n\n const storyboard = await this.#video.plan(\n { type: \"brand-film\", durationS: 60, theme: draft.tagline },\n brand,\n );\n const rendered = await this.#video.render(storyboard, brand);\n await this.#debug({\n type: \"checkpoint\",\n step: CHECKPOINTS[3],\n tenantId,\n brandId: brand.brandId,\n });\n\n const bgm = await this.#audio.generate(\n { type: \"bgm\", durationS: rendered.durationS, mood: brand.toneKeywords.join(\" \") },\n brand,\n true,\n );\n const narration = await this.#voice.synthesizeNarration(\n {\n script: `${draft.tagline}. ${draft.oneLiner}. ${draft.differentiation}.`,\n targetDurationS: Math.max(8, Math.min(20, rendered.durationS - 3)),\n ...(input.founderVoiceId !== undefined ? { voiceProfileId: input.founderVoiceId } : {}),\n },\n brand,\n );\n const film = await this.#video.compose({\n videoTrack: [rendered],\n audioTrack: [bgm],\n voiceTrack: [narration],\n captionTrack: [{ startS: 0, endS: narration.durationS, text: narration.transcript }],\n });\n const landingPath = \"company/landing/index.html\";\n await this.#contentStore.write(landingPath, renderLandingManifest(draft, brand));\n await this.#debug({\n type: \"checkpoint\",\n step: CHECKPOINTS[4],\n tenantId,\n brandId: brand.brandId,\n });\n\n const eventId = await this.#eventLog.commit({\n traceId: assetId(\"brand_genesis\", brand.brandId),\n kind: \"content_write\",\n affected: [\n brand.sourcePath,\n palettePath,\n landingPath,\n logo.path,\n hero.path,\n icon.path,\n film.path,\n ],\n parent: null,\n snapshot: {\n [brand.sourcePath]: brandMarkdown,\n [palettePath]: JSON.stringify({ brandId: brand.brandId, colors: brand.palette }, null, 2),\n [landingPath]: renderLandingManifest(draft, brand),\n },\n });\n\n const result: BrandPackage = {\n tenantId,\n play: PLAY_NAME,\n brand,\n draft,\n brandMdPath: brand.sourcePath,\n palettePath,\n landingPath,\n logo,\n hero,\n icon,\n mesh,\n storyboard,\n film,\n bgm,\n narration,\n eventId,\n checkpoints: CHECKPOINTS,\n };\n await this.#debug({ type: \"run\", tenantId, brandId: brand.brandId, eventId });\n return result;\n }\n\n async doctor(): Promise<BrandGenesisDoctorReport> {\n const [image, video, audio, rawVoice, mesh] = await Promise.all([\n this.#image.doctor(),\n this.#video.doctor(),\n this.#audio.doctor(),\n this.#voice.doctor(),\n this.#mesh.doctor(),\n ]);\n const voice = [{ provider: \"narration-local\", ok: true }, ...rawVoice];\n const localOk = [image, video, audio, voice, mesh].every((checks) =>\n checks.some((check) => Boolean((check as { ok?: boolean }).ok)),\n );\n return {\n capability: \"brand-genesis\",\n ok: localOk,\n checkedAt: new Date().toISOString(),\n play: {\n ok: true,\n name: PLAY_NAME,\n requiredSkills: [\n \"image_pipeline.generate\",\n \"video_pipeline.plan\",\n \"video_pipeline.render\",\n \"video_pipeline.compose\",\n \"audio_pipeline.generate\",\n \"voice_realtime.synthesize_narration\",\n \"mesh_pipeline.from_image\",\n \"content_store.write\",\n ],\n },\n media: { image, video, audio, voice, mesh },\n ...(!localOk\n ? {\n suggestion:\n \"Run the individual media doctor commands and configure missing local or remote providers.\",\n }\n : {}),\n };\n }\n\n async close(): Promise<void> {\n await this.#contentStore.close();\n }\n\n async #debug(entry: Record<string, unknown>): Promise<void> {\n await mkdir(dirname(join(this.#debugRoot, \".nebutra\", \"debug\", \"brand-genesis.jsonl\")), {\n recursive: true,\n });\n await appendCapabilityDebug(\"brand-genesis\", entry, { root: this.#debugRoot });\n }\n}\n\nexport async function readBrandGenesisDebug(root = process.cwd(), limit = 20): Promise<unknown[]> {\n return readCapabilityDebug(\"brand-genesis\", { root, limit });\n}\n"],"mappings":";AAAA,SAAS,aAAa;AACtB,SAAS,SAAS,YAAY;A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AAO,OAAO,OAAO,OAAO,KAAK;AAAA,MAC1C,GAAI,CAAC,UACD;AAAA,QACE,YACE;AAAA,MACJ,IACA,CAAC;AAAA,IACP;AAAA,EACF;AAAA,EAEA,MAAM,QAAuB;AAC3B,UAAM,KAAK,cAAc,MAAM;AAAA,EACjC;AAAA,EAEA,MAAM,OAAO,OAA+C;AAC1D,UAAM,MAAM,QAAQ,KAAK,KAAK,YAAY,YAAY,SAAS,qBAAqB,CAAC,GAAG;AAAA,MACtF,WAAW;AAAA,IACb,CAAC;AACD,UAAM,sBAAsB,iBAAiB,OAAO,EAAE,MAAM,KAAK,WAAW,CAAC;AAAA,EAC/E;AACF;AAEA,eAAsB,sBAAsB,OAAO,QAAQ,IAAI,GAAG,QAAQ,IAAwB;AAChG,SAAO,oBAAoB,iBAAiB,EAAE,MAAM,MAAM,CAAC;AAC7D;","names":[]}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { brandContextFromDraft, distillBrandIdea, renderBrandMarkdown } from "../src";
|
|
2
|
-
|
|
3
|
-
const draft = distillBrandIdea({
|
|
4
|
-
idea: "Customer support copilot for solo founders called Harbor",
|
|
5
|
-
visualDirectionHint: "minimal",
|
|
6
|
-
});
|
|
7
|
-
const brand = brandContextFromDraft(draft, "tenant_demo");
|
|
8
|
-
|
|
9
|
-
process.stdout.write(renderBrandMarkdown(draft, brand));
|
package/examples/doctor.ts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { BrandGenesis } from "../src";
|
|
2
|
-
|
|
3
|
-
const genesis = await BrandGenesis.open(".nebutra/brand-genesis-doctor", {
|
|
4
|
-
tenantId: "tenant_demo",
|
|
5
|
-
});
|
|
6
|
-
|
|
7
|
-
try {
|
|
8
|
-
process.stdout.write(`${JSON.stringify(await genesis.doctor(), null, 2)}\n`);
|
|
9
|
-
} finally {
|
|
10
|
-
await genesis.close();
|
|
11
|
-
}
|
package/examples/quickstart.ts
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { BrandGenesis } from "../src";
|
|
2
|
-
|
|
3
|
-
const genesis = await BrandGenesis.open(".nebutra/brand-genesis-example", {
|
|
4
|
-
tenantId: "tenant_demo",
|
|
5
|
-
});
|
|
6
|
-
|
|
7
|
-
try {
|
|
8
|
-
const result = await genesis.run({
|
|
9
|
-
idea: "AI debugging for indie devs called Loop",
|
|
10
|
-
visualDirectionHint: "cyberpunk",
|
|
11
|
-
});
|
|
12
|
-
|
|
13
|
-
process.stdout.write(
|
|
14
|
-
`${JSON.stringify(
|
|
15
|
-
{
|
|
16
|
-
brand: result.brand.name,
|
|
17
|
-
brandMd: result.brandMdPath,
|
|
18
|
-
film: result.film.path,
|
|
19
|
-
eventId: result.eventId,
|
|
20
|
-
},
|
|
21
|
-
null,
|
|
22
|
-
2,
|
|
23
|
-
)}\n`,
|
|
24
|
-
);
|
|
25
|
-
} finally {
|
|
26
|
-
await genesis.close();
|
|
27
|
-
}
|
|
@@ -1,84 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: brand_film_60s
|
|
3
|
-
kind: play
|
|
4
|
-
version: 1.0.0
|
|
5
|
-
description: From one idea to a brand system, generated assets, narration, and a 60s film manifest
|
|
6
|
-
inputs:
|
|
7
|
-
idea:
|
|
8
|
-
type: string
|
|
9
|
-
max_length: 500
|
|
10
|
-
description: One-sentence company idea
|
|
11
|
-
founder_voice_id:
|
|
12
|
-
type: string
|
|
13
|
-
optional: true
|
|
14
|
-
description: Enrolled voice profile for narration
|
|
15
|
-
visual_direction_hint:
|
|
16
|
-
type: enum
|
|
17
|
-
options: [cyberpunk, minimal, organic, playful, corporate, retro, futurist]
|
|
18
|
-
optional: true
|
|
19
|
-
outputs:
|
|
20
|
-
brand_md: { type: file, path: company/BRAND.md, mime: text/markdown }
|
|
21
|
-
logo: { type: file, path: company/assets/logo.svg, mime: image/svg+xml }
|
|
22
|
-
palette: { type: file, path: company/assets/palette.json, mime: application/json }
|
|
23
|
-
film: { type: file, path: company/film_60s.mp4, mime: video/mp4 }
|
|
24
|
-
landing: { type: file, path: company/landing/index.html, mime: text/html }
|
|
25
|
-
bgm: { type: file, path: company/audio/bgm.wav, mime: audio/wav }
|
|
26
|
-
budget:
|
|
27
|
-
duration_s: 300
|
|
28
|
-
cost_usd: 5
|
|
29
|
-
alert_at_pct: 80
|
|
30
|
-
required_skills:
|
|
31
|
-
- image_pipeline.generate
|
|
32
|
-
- video_pipeline.plan
|
|
33
|
-
- video_pipeline.render
|
|
34
|
-
- video_pipeline.compose
|
|
35
|
-
- audio_pipeline.generate
|
|
36
|
-
- voice_realtime.synthesize_narration
|
|
37
|
-
- mesh_pipeline.from_image
|
|
38
|
-
- content_store.write
|
|
39
|
-
required_plays:
|
|
40
|
-
- one_pager
|
|
41
|
-
sub_agents:
|
|
42
|
-
- role: brand_strategist
|
|
43
|
-
allowed_skills: [llm_gateway.complete, content_store.write]
|
|
44
|
-
- role: visual_designer
|
|
45
|
-
allowed_skills: [image_pipeline.generate, mesh_pipeline.from_image, content_store.write]
|
|
46
|
-
- role: video_director
|
|
47
|
-
allowed_skills: [video_pipeline.plan, video_pipeline.render, video_pipeline.compose]
|
|
48
|
-
- role: music_composer
|
|
49
|
-
allowed_skills: [audio_pipeline.generate]
|
|
50
|
-
- role: narrator
|
|
51
|
-
allowed_skills: [voice_realtime.synthesize_narration]
|
|
52
|
-
- role: web_builder
|
|
53
|
-
allowed_skills: [play_loader.run]
|
|
54
|
-
depends_on_plays: []
|
|
55
|
-
checkpoints:
|
|
56
|
-
- after_step: brand_distillation
|
|
57
|
-
- after_step: visual_direction
|
|
58
|
-
- after_step: assets_generated
|
|
59
|
-
- after_step: video_rendered
|
|
60
|
-
- after_step: final_compose
|
|
61
|
-
---
|
|
62
|
-
|
|
63
|
-
## What this play does
|
|
64
|
-
|
|
65
|
-
Creates a first brand package from one short company idea. The Play must first
|
|
66
|
-
materialize `company/BRAND.md`; every downstream media call reads the resulting
|
|
67
|
-
BrandContext instead of inventing its own style.
|
|
68
|
-
|
|
69
|
-
## Steps
|
|
70
|
-
|
|
71
|
-
1. Distill the idea into a compact brand identity.
|
|
72
|
-
2. Choose one visual direction and write `company/BRAND.md`.
|
|
73
|
-
3. Generate independent visual assets in parallel.
|
|
74
|
-
4. Plan the storyboard before any video rendering.
|
|
75
|
-
5. Render video, then generate music and narration with the final timing.
|
|
76
|
-
6. Compose the film manifest and write a landing handoff manifest.
|
|
77
|
-
7. Commit the resulting paths to the event log.
|
|
78
|
-
|
|
79
|
-
## Anti-patterns
|
|
80
|
-
|
|
81
|
-
- Do not generate assets without BrandContext.
|
|
82
|
-
- Do not define image, video, audio, voice, or mesh generation logic here.
|
|
83
|
-
- Do not skip storyboard planning.
|
|
84
|
-
- Do not hardcode one visual style across all companies.
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
type: brand_profile
|
|
3
|
-
brand_id: {{brand_id}}
|
|
4
|
-
name: {{name}}
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
# {{name}}
|
|
8
|
-
|
|
9
|
-
{{one_liner}}
|
|
10
|
-
|
|
11
|
-
## Tagline
|
|
12
|
-
|
|
13
|
-
{{tagline}}
|
|
14
|
-
|
|
15
|
-
## Audience
|
|
16
|
-
|
|
17
|
-
{{target_audience}}
|
|
18
|
-
|
|
19
|
-
## Tone
|
|
20
|
-
|
|
21
|
-
{{tone_keywords}}
|
|
22
|
-
|
|
23
|
-
## Visual Direction
|
|
24
|
-
|
|
25
|
-
{{visual_style}}
|
|
26
|
-
|
|
27
|
-
## Differentiation
|
|
28
|
-
|
|
29
|
-
{{differentiation}}
|
package/src/cli.ts
DELETED
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
import { mkdir, rm, stat } from "node:fs/promises";
|
|
2
|
-
import { join } from "node:path";
|
|
3
|
-
import { BrandGenesis, readBrandGenesisDebug } from "./index";
|
|
4
|
-
|
|
5
|
-
const command = process.argv[2] ?? "doctor";
|
|
6
|
-
const root = process.env.BRAND_GENESIS_ROOT ?? ".nebutra/brand-genesis";
|
|
7
|
-
const tenantId = process.env.NEBUTRA_TENANT_ID ?? "local";
|
|
8
|
-
|
|
9
|
-
async function sleep(ms: number): Promise<void> {
|
|
10
|
-
await new Promise((resolve) => setTimeout(resolve, ms));
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
async function acquireCliLock(rootPath: string): Promise<() => Promise<void>> {
|
|
14
|
-
const lockPath = join(rootPath, ".cli.lock");
|
|
15
|
-
await mkdir(rootPath, { recursive: true });
|
|
16
|
-
for (let attempt = 0; attempt < 40; attempt += 1) {
|
|
17
|
-
try {
|
|
18
|
-
await mkdir(lockPath);
|
|
19
|
-
return async () => {
|
|
20
|
-
await rm(lockPath, { recursive: true, force: true });
|
|
21
|
-
};
|
|
22
|
-
} catch (error) {
|
|
23
|
-
const code = (error as NodeJS.ErrnoException).code;
|
|
24
|
-
if (code !== "EEXIST") throw error;
|
|
25
|
-
const lockStat = await stat(lockPath).catch(() => ({ mtimeMs: Date.now() }));
|
|
26
|
-
if (Date.now() - lockStat.mtimeMs > 30_000) {
|
|
27
|
-
await rm(lockPath, { recursive: true, force: true });
|
|
28
|
-
continue;
|
|
29
|
-
}
|
|
30
|
-
await sleep(50);
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
throw new Error("brand-genesis CLI is busy. Suggestion: wait a moment and retry the command.");
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
if (command === "doctor") {
|
|
37
|
-
const releaseLock = await acquireCliLock(root);
|
|
38
|
-
const genesis = await BrandGenesis.open(root, { tenantId });
|
|
39
|
-
try {
|
|
40
|
-
process.stdout.write(`${JSON.stringify(await genesis.doctor(), null, 2)}\n`);
|
|
41
|
-
} finally {
|
|
42
|
-
await genesis.close();
|
|
43
|
-
await releaseLock();
|
|
44
|
-
}
|
|
45
|
-
} else if (command === "quickstart") {
|
|
46
|
-
const idea = process.argv.slice(3).join(" ") || "AI debugging for indie devs called Loop";
|
|
47
|
-
const releaseLock = await acquireCliLock(root);
|
|
48
|
-
const genesis = await BrandGenesis.open(root, { tenantId });
|
|
49
|
-
try {
|
|
50
|
-
process.stdout.write(
|
|
51
|
-
`${JSON.stringify({ capability: "brand-genesis", result: await genesis.run({ idea }) }, null, 2)}\n`,
|
|
52
|
-
);
|
|
53
|
-
} finally {
|
|
54
|
-
await genesis.close();
|
|
55
|
-
await releaseLock();
|
|
56
|
-
}
|
|
57
|
-
} else if (command === "debug") {
|
|
58
|
-
process.stdout.write(
|
|
59
|
-
`${JSON.stringify({ capability: "brand-genesis", entries: await readBrandGenesisDebug() }, null, 2)}\n`,
|
|
60
|
-
);
|
|
61
|
-
} else {
|
|
62
|
-
process.stderr.write(`Unknown brand-genesis command: ${command}\n`);
|
|
63
|
-
process.exitCode = 1;
|
|
64
|
-
}
|