Instructions
Standing rules that are always applied. An instruction is prepended to an agent's system prompt on every run. Define it once and attach it to as many agent blueprints as you like — change the rule in one place and every agent follows it.
Create an instruction
Instructions are platform-scoped — you create them once on your Theazo platform, then attach them to agent blueprints.
import { Theazo } from 'theazo'
const theazo = new Theazo({ apiKey: process.env.THEAZO_API_KEY })
const instruction = await theazo.instructions.create({
name: 'Support tone',
body: 'Always respond in a warm, concise, professional tone. Never make promises about refunds.',
priority: 10, // lower runs first when several are attached
})| Field | Type | Required | Description |
|---|---|---|---|
name | string | yes | Human label, unique within (platform, kind). |
description | string | — | Label; for skills this is the runtime gate (required there). |
enabled | boolean | — | Default true. |
body | string | yes | Markdown/plaintext prepended to the system prompt. |
priority | integer | — | Lower runs first when several attach. Default 0. |
Attach it to an agent
Attach an instruction to an agent blueprint. Every agent created from that blueprint picks it up.
await theazo.agents.attach(agentDefinitionId, {
customizationId: instruction.id,
})
// List everything attached to a blueprint (grouped by kind)
const attachments = await theazo.agents.attachments(agentDefinitionId)
// Detach later
await theazo.agents.detach(agentDefinitionId, instruction.id)How it runs
At run time, every enabled instruction attached to the agent's blueprint is prepended to the system prompt, ordered by priority (lowest first). Disabled instructions stay attached but are skipped. Set enabled: false to turn one off without detaching it.
SDK methods
theazo.instructions.create(opts)InstructionCreate an instruction.theazo.instructions.list()Instruction[]List all instructions on the platform.theazo.instructions.get(id)InstructionFetch one by id.theazo.instructions.update(id, opts)InstructionUpdate fields (name, body, priority, enabled).theazo.instructions.delete(id)voidDelete. Blocked (409) if still attached — detach first.