Skip to content
HomePagesHomePages template kit
Menu

Have AI write a slot's content

Have AI write a slot's content.

Have AI write a slot’s content.

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 id
summary: {
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.

None — this is a pure content edit. No CLI command beyond the author loop below.

Verify with the author loop.

  • The schema system — the full fill-spec.ts contract, every decision type, and how produces maps back to produced_by.