Skip to content
News

How to test an AI agent without touching production

Give an AI agent a realistic test job with fictional data, separate credentials and a destination you can inspect before granting production access.

A large tidal turbine rests on a dry service cradle overlooking a green fjord.

Suppose a customer success team wants an AI agent to prepare renewal emails. In one case, the account record gives a September renewal date, while a signed amendment moves it to November. A useful trial will show whether the agent finds the later date, whether it explains which document it relied on, and what it does when the evidence is incomplete. The team can learn all of that without putting a real customer's email address within reach.

Start by giving the agent a test destination that can receive the result and test credentials that cannot reach the live one. Use sample data that includes the awkward cases the team actually sees. Then inspect what changed at the destination as well as what the agent told you. These steps apply whether you're trying a new tool or introducing an unfamiliar workflow to an agent you already use.

Decide what the trial needs to prove

For this example, the agent should identify the renewal date, draft a notice and show the source it used. A reviewer should be able to check those choices without reopening the agent's chat. Sending customer email is outside the trial, so the team removes the production mail connector from the test setup. If the team later wants to check how sending behaves, it can add a test mail service or an isolated mailbox that only accepts test recipients.

If the draft belongs in a test CRM, give the agent an account that can save drafts there. Then open the CRM yourself and check that the draft is there, that it names the correct renewal date and source, and that it's waiting for review.

Rectangular equipment and service walkways fill a pale industrial hall.

Separate execution, credentials and project access

People often use AI agent sandbox to describe an isolated place for commands or code to run. Docker's sandbox guide illustrates how an execution environment can control filesystem sharing and network access. For a tool that can run commands, identify what directories are mounted and what hosts or services are reachable. If the workflow is entirely inside a managed AI app, inspect the tools and service accounts available to that app as well.

An agent running in a sandbox can still write to the live CRM if its connector can reach the service and has permission to write there. Remove the production connector from the trial, use credentials issued for the test CRM, and check which service the account can actually reach before you let the agent save anything.

Put the fictional accounts, contract amendments and review criteria in a private Swarm Space. In Swarm Connect, give the agent read access to that Space. Add work access if you want it to save a draft or review note there. Those permissions apply to Swarm records, so check the CRM connection separately. Swarm's project access guide shows how to verify which Spaces the agent can open.

Give the agent cases with different right answers

Use a few fictional accounts where you already know what should happen. Keep each account's source documents small enough that a reviewer can read them in full.

CaseWhat the reviewer should find
A signed amendment moves renewal from September to November.The draft uses November and cites the signed amendment.
An unsigned amendment proposes a date, with no signed agreement on file.The agent flags the proposal and leaves the date unresolved.
An account is marked as needing account owner review before a notice is prepared.The agent saves a note for the account owner and leaves the notice unwritten, as specified in the trial brief.
The same test request comes through a second time.The expected duplicate behavior is explicit. If the workflow should leave one draft per account and renewal date, the reviewer finds one draft.

The last case tests the workflow's handling of a repeat, including anything the destination itself does to prevent duplicate records. Give each attempt a case identifier and keep the expected result separate from the materials the agent reads. When a draft is wrong, note which source or rule it missed, what it actually saved and whether an effect occurred. If another team wants to try the same workflow, give them a way to run it on their own cases before they take responsibility for the result.

Two samples sit in separate glass channels on an optical inspection bench.

Review the result before broadening access

Open the test destination first. Verify the expected draft count, the records themselves and whether any test mail was sent. In Swarm, keep the brief, reviewer notes and relevant outputs together. If there is a Run, check its available trace and artifacts against the destination. A recorded approval of the draft remains separate from permission to send it.

When something fails, repeat the specific case after you change the workflow. If the team can't explain why a wrong date made it through, giving the same agent more accounts will make the review harder. If the issue is permissions, fix the connection or test account before doing another write. After a promising trial, the next step could be a small production pilot with permission to prepare drafts for named accounts and a human still responsible for sending.

Evergreen plants surround a light stone cultivation structure on an old lava field.

One Space, three fictional accounts and a test CRM are enough to start. Before giving the agent access to real accounts, ask the reviewer to open the test records and show what the agent did in each case. If they can't explain a result from the records, you have something to fix before the pilot.

Swarm | How to test an AI agent without touching production