Skip to main content

Intro

This article explains the difference between the Role and Instructions fields when creating an agent in Domo, and how to use each field effectively. They serve distinct purposes and work best when they stay focused on their respective jobs.

Understand Each Field

Role

Role defines who the agent is. It sets the agent’s persona, specialty, and point of view. Think of it as the job title and character description — a single sentence or short paragraph that tells the agent what kind of expert it should embody. The Role is applied as a framing prefix on every user message, so it continuously reinforces the agent’s identity throughout a conversation. What belongs here:
  • The agent’s area of expertise or domain
  • The agent’s perspective or professional lens
  • A brief statement of primary purpose
What does NOT belong here:
  • Numbered steps or procedures (use Instructions)
  • Rules about tone or formatting (use Instructions)
  • Conditional logic or tool guidance (use Instructions)

Instructions

Instructions define how the agent operates. This is the agent’s operating manual: the steps it should follow, the rules it must respect, and the behaviors it should exhibit when responding. Instructions are injected into the agent’s system context — the foundational layer that governs every response. What belongs here:
  • Step-by-step workflows (e.g., “First check X, then summarize Y”)
  • Tone and formatting rules (e.g., “Always respond in bullet points”)
  • Guardrails and constraints (e.g., “Only answer questions related to sales data”)
  • Tool usage guidance (e.g., “Use the CRM tool before answering pipeline questions”)
  • Template variables for dynamic content (e.g., ${userName}, ${fiscalYear})
What does NOT belong here:
  • The agent’s persona or identity (use Role)

Compare Role and Instructions

Use the Templates

Role Template

Example:

Instructions Template

Example:

Follow Best Practices

Keep Role short. One to three sentences is enough. The agent’s identity should be clear at a glance. If you find yourself writing a paragraph of instructions inside the Role field, move that content to Instructions. Make Instructions actionable. Vague guidance like “be helpful” does not constrain behavior. Concrete rules like “always cite the data source in your response” do. Use numbered steps for workflows. If the agent should follow a sequence of actions, a numbered list is easier for the model to follow than a prose description. Use template variables for context injection. If your agent needs to know the current user, fiscal year, or other runtime values, use template variables in Instructions rather than hardcoding them. Contact your Domo administrator for the variables available in your environment. Test both fields together. Role and Instructions interact. A highly specific Role combined with overly broad Instructions can produce conflicting behavior. Test edge cases — especially questions that are adjacent to but outside the agent’s intended scope — to verify guardrails work as expected. Separate identity from procedure. A common mistake is writing the entire agent configuration inside a single field. Keeping them separate makes the agent easier to tune: adjusting tone or workflow steps doesn’t require rewriting the persona, and vice versa.

Avoid Common Mistakes