Have AI write a slot's content
Have AI write a slot's content.
Have AI write a slot’s content.
The delta
Section titled “The delta”Add a decisions entry to fill-spec.ts and point the slot’s produced_by
at its id — the same pattern the starter’s blurb slot already uses. The
text-block type is the common case: it fills a text slot with generated
prose.
// fill-spec.ts — a text-block decision, same shape as the starter's blurb_text{ id: "summary_text", type: "text-block", produces: ["summary"], length_cap: 200, // `structure` enum is single_sentence | paragraph | bullet_list. structure: "paragraph", perspective: "third", voice_prompt: "Write a warm, concrete paragraph a buyer would want to read.", content_prompt: "Summarize the property's standout feature in 1–2 sentences.",},// schema.ts — the slot names the decision by idsummary: { type: "text", size: "long", editable_by_user: true, required: true, produced_by: "summary_text", display_name: "Summary",},text-block is one of several decision types — the others are image-assign,
image-collection, video-assign, video-collection, text-seed,
list-extract, and structured-list, each producing a differently-shaped slot
value. This recipe covers the common text case; see the schema
system for the
full decision-type contract before reaching for one of the others, and
Video slots for what the video-* pair
deliberately does not take.
Commands
Section titled “Commands”None — this is a pure content edit. No CLI command beyond the author loop below.
Verify
Section titled “Verify”Verify with the author loop.
See also
Section titled “See also”- The schema system —
the full
fill-spec.tscontract, every decision type, and howproducesmaps back toproduced_by.