Skip to content
New: Try out our live Agent Demos Try a demo
TEFY Digital
Agents · · TEFY Digital

Write Success and Failure Cases Before You Scope an Agent

Define what an agent must handle, when it must stop, and what counts as failure. Use a one-page brief to agree on the work before asking for a quote.

A one-page checklist on a desk beside printed sample invoices, with a pen marking one item as a success case and another as a failure case

An agent pilot can start with a reasonable goal and still drift. “Help with invoices” sounds clear until someone asks whether that includes matching purchase orders, resolving disputed charges, updating supplier records or approving payments.

One possible source of that drift is a missing agreement: nobody wrote down what good and bad look like.

Before asking for a quote, describe the situations the agent must handle and the mistakes it must avoid. You do not need technical specifications. You need concrete examples that your operations lead, frontline staff and delivery partner can interpret the same way.

A useful starting point is five or six success cases and three or four failure cases. Together, they turn a broad ambition into a workflow that can be scoped and tested.

Start with one job and a clear boundary

Consider a hypothetical accounts payable team. Staff open incoming invoices, compare them with purchase orders and prepare records for approval.

“Automate accounts payable” is too broad for a first pilot. A narrower job would be:

“Read incoming supplier invoices, compare them with the relevant purchase order and prepare a draft for a staff member to approve. Route exceptions to the accounts payable queue.”

Now state what the agent cannot do:

“It must not release payments, change supplier banking details or approve its own drafts.”

That boundary matters as much as the task. Extracting an amount from a document is different from authorizing money to leave an account. Each action brings different access, controls and testing needs.

Also identify the source of truth. In this example, the purchase order system supplies approved quantities and prices. The supplier record supplies existing supplier details. An invoice is a request for payment, not permission to change those records.

Write six observable success cases

Each case should describe an input, an expected action and evidence that the action happened correctly. Avoid phrases such as “handles invoices accurately”. They leave too much open to interpretation.

For the hypothetical invoice pilot, the team could write:

  1. A matching invoice produces a draft. An invoice names a known supplier and matches an open purchase order. The agent captures the invoice reference, date, currency, line items and total, links the purchase order, and prepares a draft for approval.
  1. A price mismatch goes to review. An invoice charges more than the purchase order allows. The agent shows the differing amounts and routes the invoice to staff without treating it as matched.
  1. A missing purchase order stays unresolved. An invoice has no purchase order reference and no confirmed match. The agent flags the missing information rather than choosing a plausible order.
  1. A duplicate is held. An invoice repeats a supplier and invoice reference already recorded. The agent flags a possible duplicate and does not create another payable draft.
  1. An unreadable field is marked for checking. A scan makes the total unclear. The agent identifies the field that needs review rather than supplying a guessed value.
  1. A banking change requires separate verification. An invoice includes new bank details. The agent flags the request for the established verification process and leaves the supplier record unchanged.

Notice that several successes involve stopping. A correct handoff is a successful outcome, not a lesser version of automation.

For each case, collect a representative document and write down the expected result. Use fictional or appropriately prepared examples where necessary. These can become the beginning of an evaluation set, rather than remaining notes from a planning meeting.

Name four failures that must be visible

Success cases explain the intended route. Failure cases make unacceptable behaviour explicit, including behaviour that might otherwise look like a completed task.

For this pilot, write:

  • Invented information: The agent fills in an unreadable amount or missing purchase order reference without evidence.
  • Unauthorized action: The agent releases a payment, approves a draft or changes supplier banking details.
  • Silent processing failure: A connection fails, but the invoice appears complete or disappears from the work queue without an alert.
  • Incorrect approval context: The reviewer sees a draft without the original invoice, matching evidence or unresolved issues needed to make a decision.

These cases should influence the design, not just the final demonstration. Preventing unauthorized actions requires permission controls. Recovering from a failed connection requires visible status and a safe retry process.

Agree on consequences too. Which failures block launch? Which require correction and another test? Do not let an overall accuracy score hide a serious failure involving money or permissions.

TEFY’s agent pilots include defining success and failure cases, building approval flows and logging, and evaluating against an agreed test set before launch.

Put the agreement on one page

Use the following template before requesting a quote. Keep each entry brief and attach sample documents separately.

Agent pilot brief

  • Workflow and owner: What single job is in scope, and who decides whether it works?
  • Current process: What starts the work, which steps staff take, and where it ends.
  • Allowed actions: What the agent may read, draft, update or send.
  • Prohibited actions: What it must never do.
  • Sources of truth: Which records or policies govern its decisions.
  • Success cases, five or six: For each, write “Given this input, it should take this action and show this evidence.”
  • Failure cases, three or four: Name the unacceptable behaviour and how a reviewer would detect it.
  • Human handoff: Who receives exceptions, what they see and what happens while they wait.
  • Launch decision: Which cases must pass, which failures block launch and who signs off.
  • Open dependencies: Missing data, access, policy decisions or system connections.

Consider reviewing the page with someone who does the work as well as someone who manages it. Ask them to bring an ordinary example, an exception and something they would never approve without checking.

This is a practical way to support the discovery step in TEFY’s approach: understand the workflow, users, data and constraints, then test the riskiest assumption before committing budget.

Take the brief into the scope discussion

Your next step is not to specify every possible invoice. It is to agree on enough concrete cases to expose the boundaries, risks and dependencies of one useful pilot.

Share the brief with your delivery partner before the scope discussion. Use it to identify gaps and agree on how each expected behaviour will be demonstrated.

If the team cannot agree on the cases yet, resolve those disagreements before commissioning a build. If the brief is ready, a fit call can help determine whether a scoped agent pilot is the right next step.

Have a related problem? See AI agents or pricing.
Book a fit call