Skip to main content

Prompt and Policy Changes

Version prompts and agent skills like code, with comparison evidence and clear rollback rules.

4 min readStarter1 of 2 in Change discipline

Changing a prompt or skill changes how your agent behaves. Treat that edit with the same discipline as a code change.

Write down what you expect to improve, test against fixed cases, inspect the diff, and agree on rollback conditions before shipping.

Key question
Does this instruction edit improve the target behavior without causing regressions elsewhere?
Change one thing at a time and test it against the current version on the same cases.

What to keep fixed

Put these checks in place before you run or compare results.

Contract
Define the contract first
An order-status agent needs an order number before it can check a shipment. Write a rule that a reviewer can check in one reply.
“If a customer asks about delivery without an order number, ask for the number before checking the shipment.”
Test with “Has my order shipped?”
A reply that asks for the number passes. A reply that invents a delivery date fails.
Evidence
Separate instructions from untrusted data
Keep user input, retrieved documents, and tool output clearly fenced off from system rules.
Use explicit delimiters
Scope tool permissions tightly
Test prompt-injection edge cases
Review
Keep edits small
Change one instruction per comparison. If the scores are close, repeat the runs before attributing a difference to the edit.
Target one behavior per revision
Keep model settings constant
Save the exact diff
Decision
Tie every decision to evidence
Keep both shipped and rejected revisions along with their comparison runs.
Inspect every newly failing case
Name who approved the change
Keep the rollback trigger handy

Step-by-step workflow

Follow each step in order, and pause if a required input or baseline is missing.

1
Write your hypothesis
State what should get better and what could break.
2
Pin the baseline
Save the current prompt or skill text and its content hash.
3
Assemble the test cases
Pull representative inputs plus the failures you want to fix.
4
Make one focused edit
Change only the instruction needed to test your hypothesis.
5
Run baseline and candidate
Compare both on the same cases, model, tools, and graders.
6
Record the call
Ship, hold, or gather more evidence with a clear owner.

Evidence to record

Keep enough detail that another engineer can repeat your comparison and reach the same call.

RecordWhat to saveWarning sign
HypothesisExpected improvement and riskEdit has no clear goal
VersionsExact text, content hash, and authorUnclear which revision was tested
CasesFixed case IDs and versionsBaseline and candidate ran on different inputs
ResultsPer-group scores and changed failuresOnly an overall average was saved
DecisionOwner, reason, and rollback triggerNo record of why the edit shipped

Scope and boundaries

  • Do not prompt models to expose hidden reasoning or private chain-of-thought.
  • Do not let untrusted input override system instructions or tool permissions.
  • Do not ship an edit just because a single manual spot check looked better.
  • Do not overwrite the previous version or discard its evaluation record.

Using this on Versalist

Build your evaluation contract
Set up the cases and graders before comparing prompt or skill edits.
Read Agent Evaluation
Package a reusable skill
Turn proven instructions into a versioned skill bundle that works across agents.
Read Skills docs
Before you ship
Make the release call explicit
Ship only when the fixed comparison backs your hypothesis and your rollback rule is in place.
More guides

Keep reading

Track: Change discipline