Xera Docs

Instructions

Define system prompts, guardrails, and context so agents act predictably.

Last updated: September 2025

Overview

Instructions control agent behavior: tone, objectives, boundaries, and policies. Combine static guidance with dynamic variables and project context.

System prompt

  • Describe the agent’s role, outputs, and decision criteria.
  • List non‑negotiable rules and safety boundaries.
  • Provide formatting requirements for structured outputs.

Guardrails

  • Scope tools to allowed domains and data sets.
  • Require confirmation before destructive actions.
  • Set max steps, cost ceilings, and timeouts per run.

Variables and templating

  • Inject run‑time variables like project name, user persona, or task goals.
  • Use placeholders that resolve from forms, triggers, or API calls.
  • Keep prompts deterministic by constraining free‑form inputs.

Context and memory

  • Attach knowledge base sources to ground answers with citations.
  • Persist short‑term memory within a project thread.
  • Reset memory on schedule for compliance or testing.

Best practices

  • Prefer explicit checklists; avoid ambiguous directives.
  • Constrain output schemas (JSON, tables) for reliable automation.
  • Test with edge cases and validate outputs in tooling.