Platform / Spec2RunAI / User guide / Autonomous Tuning

Spec2RunAI user guide · updated 22 October 2026

Autonomous Tuning

Tests go stale. A button gets relabeled, a link moves, wording drifts away from the application it describes — and the script that used to be accurate quietly stops being so. Autonomous Tuning finds that drift and offers you the correction, with the evidence behind it.

It does two distinct things, and the difference matters when you read a report:

  • Steps that failed on their stored wording are rewritten against the live screen, checked for semantic equivalence, and re-run in place. If the rewritten step then passes every check, the run continues.
  • Steps that passed while quoting wording the page no longer has are flagged, not rewritten. Nothing failed, so nothing was retried — but the script carries a latent defect. This is the script-defect advisory described above.

Arming a run

Tick Autonomous Tuning on the New Execution page. It is per-run and off by default. Rewriting a failed step costs extra AI engagements; detecting drift on a step that passed costs nothing at all, and happens on every run whether or not the box is ticked.

The four run verdicts

Open Autonomous Tuning in the sidebar and pick a completed run. Every test case lands in exactly one pile:

VerdictMeaningWhat to do
CleanPassed untouched. Nothing was rewritten and no drift was found.Nothing.
TunedA step failed, was rewritten, and the rewritten step then satisfied every original expected result.Read the before and after. Approve it into your script if you agree.
DriftedA step passed while quoting a label the page no longer has. The engine found the right control anyway.Apply the suggested wording, or dismiss it if the wording is fine as it stands.
FailedThe test case failed. Either the failure was not a wording problem, so tuning had no lever on it — or a rewrite was attempted and the step still did not pass.Read the failure triage.

Clean, Tuned and Failed partition your test cases — every case is in one of them. Drifted is counted separately, because a test case can pass cleanly and still carry a drifted step.

Verified Rewrite

A drifted step was never re-executed, so the suggested wording has not been proved by running it. Instead it is checked directly against the page the step left behind: the engine counts how many controls carry the resolved label.

ResultWhat it means
Verified rewriteExactly one control on the live page carries that label, and it is the control the step used.
UnverifiedThe label matched several controls, or the page had moved on and the check could not run. The advisory still stands — the script is still stale — but read the before and after yourself.

This check involves no AI call and costs nothing. It proves the wording identifies one control and no other. It does not prove the rewritten step passes end to end — though the original just did, on that same element.

Runs on a local agent detect drift but do not verify it — the uniqueness check is a cloud engine feature. Local advisories therefore always show as Unverified, and automatic application never applies to them.

Why a drifted step is not simply re-run Re-running it would replay every earlier step to reach that state, and then repeat an action that already succeeded. Clicking "Add to cart" twice adds two items. The verification would corrupt the run it reports on.

Reviewing and deciding

Each card shows what your script says, what the engine suggests, why, and the screenshot that justified it. Two actions:

  • Approve into script writes the new wording into your stored test case. It takes effect on the next run.
  • Not a defect dismisses the suggestion. Use it when the current wording is deliberate and you do not want to be told again.

A dismissal is remembered against that specific suggestion, not against the step. Dismiss 'Purchase Item' → 'Add to cart' and it stays dismissed; if the same step later drifts to 'Buy now', that is a different suggestion and it will surface as new. Dismissals survive reloads, and Undo dismiss brings one back.

Expected results are never rewritten Tuning changes the wording of an action and nothing else. Your acceptance criteria are untouched, and a tuned step still has to satisfy exactly the same check as any other step. This holds however a rewrite is applied — by your click, or automatically.

Applying verified rewrites automatically

The checkbox at the top of the Autonomous Tuning page turns on automatic application. When it is on, a rewrite is written into your stored script the first time a completed run's results are read — including runs triggered from CI/CD, which nobody may be watching.

It is deliberately narrow:

  • Only verified rewrites are applied. Unverified and ambiguous suggestions always wait for a person. This is not configurable.
  • A dismissed suggestion is never applied.
  • Expected results are never touched.
  • Each rewrite is applied once, and the test case's edit history records that it was applied automatically rather than by a person — including the wording it replaced.
This setting is organization-wide It applies to every run in your organization, not just the one on screen, and it is the one place where a change reaches your stored scripts without anyone clicking. Leave it off if you would rather read every suggestion first.
Try it on your own tests

Ten test cases. Untouched. We run them and send the evidence report.