OptionalactionsMJ Actions to expose as tools to the controller LLM (resolved by MJComputerUseEngine)
OptionalagentAgent run ID to link prompt runs to (optional, typically set at runtime)
OptionalappApp-specific readiness/busy signals for the adaptive settle loop
. Optional — the driver applies MJ-Explorer-sensible defaults (a
[data-mj-ready="true"] readiness beacon and MJ loading-spinner markers)
when omitted. Provide to override when the target app under test isn't MJ
Explorer, or to tune settle timing.
Optionalauth?: { identityProviderPatterns?: string[]; maxDetours?: number }Auth-detour watchdog. When the session is invalidated mid-run
and the page bounces to an identity provider, the watchdog recovers it
(re-auth + re-navigate) without charging the agent a step, and after
maxDetours ends the run as an infrastructure AuthDetour instead of
grading the agent on it. Defaults to MJ's providers (Auth0 + Entra);
pass identityProviderPatterns: [] to disable.
OptionalidentityProviderPatterns?: string[]Case-insensitive URL substrings marking an identity-provider bounce.
OptionalmaxDetours?: numberTerminate as AuthDetour after this many detours (default 2).
OptionalbusyMarkers?: string[]Additional busy-marker CSS selectors (merged with the engine's app-neutral defaults).
OptionalreadinessBeacon?: stringCSS selector for the app's readiness beacon (polled first; wins over heuristics).
Optionalsettle?: {Settle-loop timing overrides.
OptionalvolatileParams?: string[]Query-param names carrying a per-visit value. They are stripped before
a URL is matched against a recorded pattern and before it forms a loop
state signature — so a one-time login token can't make a recorded step
unmatchable, and can't disguise a repeated page as a new one. Defaults
to MJ's identity-provider tokens (state, code, nonce); pass []
to compare URLs verbatim.
OptionalbrowserAdditional Chromium launch arguments (e.g., ["--unsafely-treat-insecure-origin-as-secure=http://example:4200"])
OptionalbrowserBrowser session strategy. Controls how the browser context is managed.
"new" — Fresh context every test (default for sequential execution)"shared:suite" — Shared context per suite run + worker (default for parallel execution)"shared:global" — Shared context globally per workerWhen running in parallel (workerIndex is set on context), defaults to "shared:suite" so that auth state persists between tests in the same worker.
OptionalconnectAttach to an already-running browser instead of launching one. Auto-detects the connect method from the URL scheme:
http(s)://… → Chrome DevTools Protocol (chromium.connectOverCDP)ws(s)://… → Playwright browser server (chromium.connect)When set, the test driver does NOT close the browser at shutdown — the
caller owns its lifecycle. headless is ignored (the external browser
already decided).
In parallel-worker test runs, HeadlessBrowserEngine is a process-global
singleton — the first worker to initialize wins. All workers in a suite
must agree on this endpoint or behavior is undefined.
OptionalconnectForce the connect method. A raw CDP websocket also uses ws://, which
auto-detect would treat as a Playwright server; set 'cdp' to override.
Defaults to 'auto' (scheme-based detection). Ignored when connect is unset.
OptionalcontrollerDirect model override for controller (bypasses auto-select and prompt lookup)
OptionalcontrollerMJ AI Prompt entity name for controller
OptionalelementElement-grounded perception. When true, each step the engine extracts the page's interactive elements into an indexed list, renders it into the controller prompt, and lets the controller act by index (ClickElement/TypeIntoElement) with locator actionability auto-wait instead of estimating coordinates. Default true: a coordinate click cannot be recorded or replayed, so grounding is the precondition for the replay tier. Set false to fall back to coordinate/vision mode.
OptionalforceForce a replay tier for this test (canary override), bypassing
decideReplayTier. 'llm' runs the full agent (the rerun-failures --llm
/ canary escape hatch); 'replay' / 'replay-with-heal' force the
deterministic tier when a script exists (no script ⇒ still falls to LLM).
Unset (default) ⇒ the tier is decided per build/goal/heal-rate.
OptionalgateWhen true, the inline criteria verdict gates Passed/Failed. Otherwise that verdict is advisory and only the configured oracles gate.
OptionalgenerationPer-test controller generation overrides — determinism knobs
threaded into the controller prompt. temperature (e.g. 0 for pinned
regression runs) and effortLevel (1–100). Judge generation is unaffected.
OptionalheadlessRun browser in headless mode (default: true)
OptionaljudgeJudge evaluation frequency. Formats: "EveryStep", "EveryNSteps:N", "OnStagnation:N"
OptionaljudgeDirect model override for judge
OptionaljudgeMJ AI Prompt entity name for judge
OptionalmaxMaximum execution time in milliseconds (default: 300000 / 5 min)
OptionalmaxMaximum number of controller loop steps (default: 30)
OptionaloraclesOracles to run for evaluation
OptionalrecordWhether a green, recordable LLM run writes its replay script back to the test row. Default true. Set false to run the agent tier without ever storing a script — useful while a test is still being authored, and for a run whose trajectory should not become the baseline others replay.
Independent of elementGrounding: a grounded run still produces the indexed element list the DOM oracles assert over, it simply is not stored.
OptionalreplayHow far a diverged replay step may be repaired. Default 'llm'.
'llm' — role+name re-resolution, escalating an ambiguous or failed
match to a focused model call.'deterministic' — role+name re-resolution only; never calls a model.'off' — no repair; the first failed guard diverges.Use 'off' once a script is trusted as the contract: any deviation is the
finding, and a heal would hide the UI change the test exists to catch.
With AllowLLMFallback: false the run then has no model in it at all — it
passes by executing exactly what was recorded, or it fails.
OptionalreuseWhen attached, reuse the running browser's first existing context so its
cookies / auth / session are shared, instead of creating a fresh isolated
context. Defaults to false. Breaks per-test isolation. Ignored when
connect is unset.
Only honored on the engine.Run() path (sequential / "new-clean" strategy).
The parallel path (HeadlessBrowserEngine.GetIsolated/GetRecycled)
always creates its own contexts under the attached browser.
OptionalscoringScoring weights by oracle type
OptionalscreenshotNumber of recent screenshots to include in controller context
OptionaltraceFailure-artifact trace policy. When enabled, the run records a
Playwright trace (DOM snapshots + network + console) viewable at
trace.playwright.dev, retained per this policy as a File TestRunOutput:
off (default) — no trace, zero overhead.retain-on-failure — trace every run, keep it only when the test fails.on — trace every run, always keep it.
Tracing carries ~5–15% per-run overhead; measure on a smoke test before
enabling suite-wide (hence the default is off).OptionalviewportBrowser viewport height (default: 720)
OptionalviewportBrowser viewport width (default: 1280)
The Computer Use driver's slice of
Test.Configuration.Two properties in that same JSON are framework-level, not driver-level, and are deliberately absent here:
ReplayScript(the recorded replay script) andAllowLLMFallback. Both are typed by the entity's own JSONType and read through the generatedMJTestEntity.ConfigurationObjectaccessor inscript-store.ts, so they stay strongly typed without this driver restating them. Do not add copies here — two declarations of one field is how they drift.