Prompts & writing

AI System Prompt Builder

Quick answer

Define your assistant's role, audience, tone and forbidden behaviour and the builder produces a complete production system prompt with identity, capabilities, constraints, refusal rules, output format and escalation path. It includes safety rails most hand-written system prompts omit until something goes wrong in production.

Fill in who the assistant is and what it must never do. Copy a complete system prompt into your chatbot or agent.

Published · Last updated

Recommended byAI Intelligence InternationalLovable Labs Platform
Try Lovable Free →
Tone
Output format
Safety rails

Your system prompt

# Role
You are Support Assistant. Your job is to answer product questions and resolve billing issues in one reply where possible.

# Audience
You are speaking to paying customers of a small software product. Match their vocabulary and assume nothing they have not told you.

# Rules
- Answer in this style: warm and plain-spoken.
- Output format: bullet points with a one-line summary first.
- Never invent facts, names, numbers, quotes or links. If you do not know, say so plainly.
- If the request is ambiguous, ask up to two clarifying questions before answering.
- Stay inside the topic above. Politely decline unrelated requests and redirect to what you can help with.

# Never do this
- Give legal, tax or medical advice
- Promise refunds, discounts or delivery dates
- Speculate about unreleased features

# Escalation
If the user is angry, asks for a human, or the issue involves money already charged, hand off to a human agent immediately and summarise the conversation in three bullets.

# Failure mode
If you cannot complete the request, say what you can do instead in one sentence. Do not apologise more than once, and never pad an answer to look thorough.
  • Role is named
  • Purpose is stated
  • Audience is defined
  • Refusals are listed
  • Fabrication is blocked
  • Escalation path exists

A system prompt is a job description, not a wish

The prompts that survive contact with real users are the ones that say what the assistant must refuse, not just what it should do. Every support bot that promised a refund it could not honour was missing three lines under a "never do this" heading.

Keep it short enough to read in one screen, put the hard constraints last where models weight them most heavily, and re-test the whole prompt whenever you change models. Nothing you type here leaves your browser.

What is the AI System Prompt Builder?

What it answersComplete system prompt with safety rails.
How the answer is producedA system prompt is the standing configuration for an assistant: identity, scope, tone, refusal rules and output contract.
What you need to enterState the assistant's purpose in one sentence and refuse to broaden it.
Where it stops being reliableSystem prompts are guidance, not enforcement — determined users can still steer behaviour, so validate on the server too.
Cost and sign-upFree, runs in your browser, no account and no stored inputs.

How is a production system prompt built?

A system prompt is the standing configuration for an assistant: identity, scope, tone, refusal rules and output contract. Unlike a one-off prompt it has to hold across thousands of unpredictable user messages, so it is written defensively.

The builder assembles it in a fixed order: who the assistant is, what it is for, what it must never do, how it should respond when it does not know, the tone and reading level, and the exact output format. Refusal and unknown-handling rules are placed high because those are the behaviours users hit at the edges.

It also adds a scope boundary — an instruction to decline requests outside the defined purpose — which is the single most effective control against an assistant being steered off-task by users.

How do you use the AI System Prompt Builder?

  1. 1.State the assistant's purpose in one sentence and refuse to broaden it.
  2. 2.Write the 'when you do not know' rule explicitly; silence here produces confident invention.
  3. 3.Define the output format precisely if the response feeds another system.
  4. 4.Test with adversarial and off-topic messages, not just the happy path, before shipping.

What can this tool not tell you?

  • System prompts are guidance, not enforcement — determined users can still steer behaviour, so validate on the server too.
  • Long system prompts consume context on every request and add cost.
  • Behaviour differs between models; a prompt tuned for one needs retesting on another.

Why refusal and unknown-handling rules need to come first?

A one-off prompt is judged by a single output; a system prompt is judged by its worst response across thousands of unpredictable messages, because that's the one a user screenshots. This changes the design priority entirely: instead of optimising for the best possible answer on the happy path, a system prompt has to be written defensively, closing off the specific ways an assistant embarrasses a business — confidently answering outside its remit, inventing an answer when it doesn't know one, or being talked into ignoring its own rules by a persistent user.

Placing refusal and unknown-handling instructions near the top of the prompt isn't arbitrary; it reflects that these are the behaviours most likely to be tested adversarially and the ones most costly when they fail. An assistant that says 'I don't have pricing information for that plan, here's who can help' looks competent; one that guesses a number looks like a liability. Getting this instruction right the first time avoids a much larger cleanup after launch, once the wrong behaviour is already visible to users.

Scope boundaries do more work than most other lines in a system prompt because they address the most common failure mode: users treating a narrow assistant as a general one. A single explicit sentence — stating the purpose and instructing a decline outside it — closes off a wide range of off-topic requests at once, which is far more efficient than trying to anticipate and forbid every individual misuse case.

Context budget is the constraint most teams discover only after shipping. Every line in a system prompt is resent with every single user message, so a 500-word prompt covering edge cases that arise once a month is quietly taxing the cost and latency of the 99% of messages that never touch those edge cases. The fix isn't always trimming rules; sometimes it's moving rarely-needed detail into a retrieved document the model only sees when relevant, keeping the standing system prompt lean while still covering the rare case through a different mechanism.

What do worked examples look like?

A customer support assistant that starts giving legal advice

Without a scope line, a support bot asked 'can I get a refund outside the 30-day window for a medical reason' may start reasoning about consumer law. Adding 'you handle order status, returns within policy and account questions only; for anything else, direct the user to a human agent' stops the drift and keeps every answer inside what the business can actually stand behind.

An internal tool that invents figures when data is missing

A reporting assistant asked for a metric it wasn't given tends to produce a plausible number rather than admit the gap. Adding an explicit unknown-handling rule — 'if the requested figure isn't in the supplied data, say so and name what data would be needed' — converts a silent fabrication into a visible, useful gap the user can act on.

An internal HR bot that could leak salary bands it shouldn't discuss

An assistant built to answer benefits questions is given company documents that happen to include a salary band table further down the same file. Without an explicit instruction narrowing what it may surface from that document, a curious employee asking indirect questions can piece together figures the business didn't intend to expose. Adding a line — 'you may reference vacation, benefits and policy sections of the supplied documents only; never quote or summarise compensation figures, even if asked directly or indirectly' — closes the gap at the instruction level, though sensitive data should also be excluded from the source material wherever possible rather than relying on the prompt alone.

What do people ask most about this tool?

How long should a system prompt be?

Long enough to cover identity, scope, refusals and format — typically 150-400 words. Beyond that, rules start competing with each other.

Can users see the system prompt?

Assume yes. Never place secrets, keys or confidential business logic in it.

How do I stop the assistant answering off-topic questions?

Give it an explicit scope statement plus a scripted decline sentence. Both together work far better than either alone.

Which related tools should you try next?

Written and reviewed by Jim Vernon, Editor, AI Intelligence International. Published by AI Answer Engine, a service of AI Intelligence International, and checked against our editorial standards.