mirror of
https://github.com/morluto/rea.git
synced 2026-10-27 01:45:32 +00:00
* feat: add FreeBuff agent support for REA setup Register FreeBuff as a supported setup client using the shared user agents directory (~/.agents/mcp.json with mcpServers, skills in ~/.agents/skills), which matches what FreeBuff Desktop loads. Adds the client definition, boundary tests, supported-agent docs, and the skill reference client list. * fix(freebuff): detect FreeBuff from its profile directory, not shared .agents The ~/.agents marker made FreeBuff appear installed for any home where REA had installed shared skills (the default skill destination, also Gemini CLI's), producing false doctor failures. Detect FreeBuff from its own fixed profile directory ~/.config/freebuff-desktop instead, and add a regression test covering a home with only the shared agents skill directory. * fix(setup): require product evidence for FreeBuff discovery Address review findings at their producing boundaries and preserve directly affected consumers. Source inspection and git diff --check completed. Tests and automated checks were not run at the user’s explicit request. * fix(uninstall): retain unverified shared client configuration * fix(clients): preserve scoped removal evidence * fix(doctor): omit undefined selectedClientIds under exactOptionalPropertyTypes Passing selectedClientIds explicitly as undefined fails typecheck on this branch (TS2379), which blocks the focused test workflow before any test can run. Spread the option only when defined. * fix(update): separate ownership evidence from product applicability rea update's maintenance scope inspected only product applicability evidence, so when a FreeBuff profile was absent but REA already owned a version-pinned row in the shared ~/.agents/mcp.json, the plan omitted freebuff and left the integration stale. FreeBuff now declares its registration storage as shared, which proves ownership of an owned row but never product applicability, and maintenance requests ownership evidence through that declaration instead of reinterpreting the shared paths. Doctor and setup keep readiness evidence, foreign rows stay out of maintenance, and the Doctor exactOptionalPropertyTypes fix makes the focused test workflow runnable. * test(dotnet): split oversized operand extent diagnostics describe The describe callback reached 162 lines (max 150), failing max-lines-per-function and blocking the pre-push check for this branch. Move the single-case extent scenarios into their own describe; no test content or order changes. * fix(update): preserve ZCode's disabled shared registration during maintenance The shared user agents file doubles as ZCode's fallback, where `enable: false` disables the registration. Ownership-based maintenance read that row as a FreeBuff registration, whose format does not recognize the flag, so the row was selected and the emitted setup command rewrote it, dropping the flag and silently re-enabling a registration the user had disabled. registrationActivation now honors `enable: false` for any client whose registration storage is shared, because the activation fact binds every reader of that storage. Maintenance leaves such rows out; doctor reports them as stale, matching ZCode's own treatment. * fix(doctor): let explicit client selection authorize the config read When an ACL or an inaccessible shared parent made every access probe fail, a client selected by name was omitted before the configuration read could return its unreadable-config detail, so doctor reported it as not detected with installation remediation: an unresolved selected path collapsed to absence. An explicit selection now authorizes the read outright and the probes serve automatic discovery only. A selected client with an unreadable config reports invalid with the read failure; one with no config reports missing; automatic discovery still probes before inspecting. * fix(uninstall): share shared-storage checks between ZCode and FreeBuff clients() queued ~/.agents/mcp.json twice: once as zcode_fallback and once as freebuff. ZCode has no discoveryPaths, so its strict read still blocked uninstall on malformed shared text, despite FreeBuff's new retain-and-continue behavior. For a valid owned entry, ZCode removed it first, so FreeBuff reported skipped rather than removed. Make the shared file's checks and removal one shared decision: - Add zcodeDiscoveryPaths to ZCode so it has its own applicability evidence. - Gate zcode_fallback push on applicable, not just zcodeFallbackPath presence. - Report shared storage ownership as one decision for both clients: FreeBuff and ZCode now use clientOwnershipEvidencePaths together, so a recognizable REA-owned row proves ownership once for the shared storage, and both clients report the same result consistently. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * fix(uninstall): merge duplicated host and prove shared ownership from owned rows Uninstall.ts declared systemUninstallHost twice, preventing module load, with the exported copy returning only clients and the second copy missing clientWriteBlocker. Merge into one exported host carrying both blockers. hasOwnershipEvidence used access() existence, so an unrelated malformed ~/.agents/mcp.json established ownership and blocked every removal. Ownership now requires a readable, recognizable REA-owned row via the injected filesystem, so unrelated shared data stays retained. Also cover ZCode discoveryPaths in its path test. * fix(uninstall): keep denied product-local configurations fail-closed Unproven product applicability marked every configuration path of that client unverified, so a denied ZCode profile turned an unreadable product-local config into a retained item: uninstall continued and could report complete with REA still registered. The retain-and-continue exception now applies only to storage REA does not own, classified once by clientSharedRegistrationPaths (shared configuration plus another product's same-scope fallback). Covers the Greptile P1 on Uninstall.ts. Validation: the new test fails on the pre-fix Uninstall and passes after it; freebuff/zcode/updateMaintenance/bom/dsh suites green; clientLifecycle, clientRegistrationStatus and claudeDesktop keep the same 8 host failures as the pre-merge baseline (symlink EPERM, stale-vs-aligned on Windows). * fix(update): retain FreeBuff when ZCode reads the shared fallback Maintenance deduplicated clients on the path each inspection read, so ZCode's fallback view of ~/.agents/mcp.json marked that file "covered" and dropped FreeBuff from the scope. ZCode setup writes ~/.zcode/cli/config.json and deliberately leaves the fallback untouched (docs/client-configuration.md), so the emitted command refreshed only ZCode while the shared row both products load stayed pinned to the old package version. Each setup action rewrites only its own configuration path and no other action rewrites the shared row, so every selected client keeps its own maintenance action; the read-path covered/deduped filter is removed. Covers the Codex P2 on UpdateMaintenance.ts:104. Validation: the new regression fails one2fdec384with {clients:["zcode"]} and passes with {clients:["freebuff","zcode"]}; updateMaintenance 31/31, setupClientConfigCleanupOwnership, cliUpdateAlias, updateOutput, cliStartupImports green; tsc --noEmit, oxlint (0 errors) and oxfmt --check clean; clientRegistrationStatus keeps the same 4 symlink/stale-vs-aligned failures this Windows host has on basee2fdec384(verified by stashing the change). 🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com> * fix(uninstall): preserve completed reads as shared ownership evidence hasOwnershipEvidence caught every read failure and kept scanning, so a handle-close failure after a successful read — a RegularFileCleanupFailure whose completed outcome still contains the exact shared-file text — was discarded as "no proof". FreeBuff's applicability-unverified storage therefore never got its ownership fact, and once the retained handle blocked later reads, readClientConfiguration downgraded them to retained: inspection passed, removals soft-failed, and runUninstall(true) could purge REA data while the active shared registration remained. The catch now parses the completed outcome for the ownership text while missing or unreadable storage and malformed data keep their proves-nothing semantics, so ownership holds and every later read failure stays blocking. Covers the Codex P2 on Uninstall.ts:252. Validation: the new regression fails on4dbfdf1a9(freebuff reports no blocking failure while the poisoned-scope error lands on claude_code) and passes after; setupClientConfigCleanupOwnership 25/25; the other 21 Uninstall-consumer suites are byte-identical to base4dbfdf1a9(61 pre-existing Windows-host failures: symlink EPERM, stale-vs-aligned); tsc --noEmit, oxlint (0 errors, same 6 warnings) and oxfmt --check clean. 🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com> * fix(uninstall): keep owned-row proof through removal refusals hasOwnershipEvidence treated any clientRegistrationRemoval refusal as no ownership: an effective REA-owned rea member shadowed by an earlier foreign duplicate (shadowed_unowned_member), or an owned native row beside a foreign V1 fallback (foreign_legacy_fallback), discarded the already-parsed positive row fact. With FreeBuff unverified and close failures recurring on the preflight/removal rereads, those failures were then downgraded to retained, so runUninstall(true) removed the skill and purged REA data while the active owned row remained. The refusal now carries the owned rows that motivated it — the refusal only refuses the edit — and hasOwnershipEvidence evaluates that fact on both paths; preflight and removal keep refusing the unsafe edit exactly as before. Covers the Codex P2 on Uninstall.ts:269. Validation: the new regression fails on225cb214a(freebuff reports no blocking failure while the poisoned-scope error lands on claude_code) and passes after; setupClientConfigCleanupOwnership 26/26; the 21 Uninstall-consumer suites are byte-identical to the recorded225cb214abaseline (61 pre-existing Windows-host failures: symlink EPERM, stale-vs-aligned); tsc --noEmit, oxlint (0 errors, same 6 warnings) and oxfmt --check clean. 🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com> * fix(uninstall): keep unresolved discovery probes from softening shared failures The discovery probe swallowed every stat failure, so a FreeBuff profile denied with EACCES/EIO was indistinguishable from an absent profile: shared storage was marked applicability-unverified and, when ~/.agents/mcp.json also remained unreadable, the ownership and removal reads softened to retained. runUninstall(true) then removed the skill and purged REA data while an installed FreeBuff could still hold an active registration — the regression even reports complete. Absence (ENOENT) is now the only state that leaves shared paths unverified; any other probe failure leaves applicability unresolved, and shared-config failures stay blocking. Covers the Codex P2 on Uninstall.ts:318. Validation: the new regression fails on7572a7082with status complete and purged data and passes after; freebuffClientConfiguration 13/13; the Uninstall-consumer batches are byte-identical to the recorded baselines (61 pre-existing Windows-host failures: symlink EPERM, stale-vs-aligned); tsc --noEmit, oxlint (0 errors, same warning rules) and oxfmt --check clean. 🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com> * fix(uninstall): retain completed configuration reads as removal evidence A close failure after a completed read discarded the text that read produced, so an owned registration row the text proves softened to retained. The completed text now drives removal, keeping shared-config failures blocking when ownership evidence exists. Co-Authored-By: Anthropic <noreply@anthropic.com> * fix(uninstall): stop removal when a cleanup retry leaves a handle unreleased A completed reread whose handle the cleanup retry cannot release now fails blockingly instead of serving the text: with no owned row, the soft path let removeAll purge managed data before close() reported the incomplete cleanup. The completed text is served only after the retry releases the handle; an unreleased handle is REA's own failure, never applicability uncertainty, so it bypasses the retained softening. Co-Authored-By: Anthropic <noreply@anthropic.com> * fix(uninstall): keep the ZCode fallback when its profile probe is unresolved A denied or failed profile probe leaves ZCode's applicability unresolved, never absent, but the fallback branch dropped the shared row on applicability alone: with the native config and FreeBuff's profile both absent, an installed ZCode kept its uninspected registration while uninstall purged skill and data. Unresolved probes now keep the fallback in scope with the same fail-closed treatment as other unresolved shared paths; definitive absence still keeps ZCode out of another product's primary storage. Co-Authored-By: Anthropic <noreply@anthropic.com> * fix(setup): preserve a shared row's enable:false during FreeBuff repair The shared agents file doubles as ZCode's fallback, so its `enable: false` binds every reader: doctor now reports the disabled row as stale for FreeBuff, but following that remediation rebuilt the generic JSON entry without the flag and silently re-enabled a registration ZCode disabled. Repairs of shared storage now carry the activation fact forward, while a client's own native storage keeps its established single-reader repair contract; the denied-profile uninstall regression also pins the fallback's new fail-closed inspection beside the denied read. Co-Authored-By: Anthropic <noreply@anthropic.com> * test(uninstall): retarget the completed-reread regression to a released retry The concurrent-writer regression held the reread handle open forever, which the fail-closed path now serves: it duplicated the unreleased-handle regression while documenting the opposite contract. The fixture's close spy gains a failure limit so the cleanup retry releases the handle, and the test again proves the completed text drives removal of the concurrently added owned row, with purge verified against the cache layout purge actually removes. Co-Authored-By: Anthropic <noreply@anthropic.com> * fix(doctor): report a preserved shared disable as a manual conflict Preserving a shared row's enable:false left doctor recommending a setup run that registrationCurrent correctly treats as already current, so the scoped doctor returned needs_human forever. The shared-enable interpretation now has one owner, sharedEnableFlagBinds, used by both the activation rule and the remediation: a row disabled through the shared flag reports the manual conflict and states that rea setup will not change it, instead of an endlessly ineffective repair. Co-Authored-By: Anthropic <noreply@anthropic.com> * fix(doctor): keep a native ZCode disable on the setup repair path The manual-conflict remediation matched a native zcode row through sharedEnableFlagBinds, but setup drops enable:false on single-reader storage, so a native disabled registration was told setup would not change it. The remediation now reads setup's own writer rule, exported as setupPreservesDisabledActivation: shared storage and the zcode fallback view keep the manual-conflict message, while a native row keeps the working rea setup instruction. Regressions pin both remediations. 🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com> * revert: drop the unrelated managed-CIL describe split The split does not belong to FreeBuff client support and only widens this PR's diff. 🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com> * fix(uninstall): remove the shared agent registration once for both clients ZCode's ~/.agents/mcp.json fallback and FreeBuff's own configuration queued the same physical file twice, so ZCode removed the row and FreeBuff then reported it absent, losing the outcome for the client that owns the file. Resolve every configuration path to one owner -- the client whose configuration it is -- and project that single inspection and removal to each client that loads it. A fallback reader still contributes its discovery probe, so an installed or unresolved reader keeps the shared file fail-closed. Discovery also accepted a dangling ~/.config/freebuff-desktop link, which setup and doctor reject because they follow the target, so an unrelated malformed shared file blocked every other removal. Resolve the link before treating the profile as installation evidence, keeping lstat for removal safety. Also date the FreeBuff release wording against the published 6.7.0 package. * fix(uninstall): keep a row per client when two clients own one file OPENCODE_CONFIG can point OpenCode at FreeBuff's configuration file, where OpenCode writes `mcp.rea` and FreeBuff writes `mcpServers.rea`. Grouping by filename gave that path a single owner, so uninstall removed only OpenCode's row, reported that removal for FreeBuff, and could purge managed data with FreeBuff's registration still active. Share the decision only through a fallback view of another client's row: every client that declares the path as its own configuration keeps its own inspection and removal, and the fallback reader reports each of them. * fix(clients): preserve discovery and fallback registration identity Follow product discovery link targets without losing configuration entry presence or explicitly selected inspections. Associate fallback readers with the format owner's registration table and project outcomes by owner and path, so OpenCode removal cannot be reported as a ZCode fallback removal. All three new boundary regressions fail against the previous source and pass with the fixes. Validation: check:fast; 217 focused tests passed; the two changed test files were rerun with 50 passing tests. No installed FreeBuff client was launched. --------- Co-authored-by: morluto <76467478+morluto@users.noreply.github.com> Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com> Co-authored-by: Kaoru0822 <208281322+kaoru0822-kitauji@users.noreply.github.com> Co-authored-by: Codebuff <noreply@codebuff.com>
604 lines
39 KiB
Markdown
604 lines
39 KiB
Markdown
# Client and agent verification
|
|
|
|
FreeBuff MCP loading and personal skill discovery are currently unverified with
|
|
an installed native client/version. Its temporary-filesystem coverage verifies
|
|
REA's configuration and applicability boundaries only; it does not establish
|
|
that FreeBuff consumes the written registration or skill.
|
|
|
|
Use these optional lanes to verify an installed client or evaluate an agent's
|
|
REA workflow. [Testing REA](testing.md) provides the normal development commands
|
|
and provider lanes. Each record below states its host, client version, model
|
|
fixture, and remaining coverage; a native-client run with a loopback model does
|
|
not establish live model-service acceptance.
|
|
|
|
## Published Pi code-mode renderer limit
|
|
|
|
A separate probe of the published `@earendil-works/pi-codemode` 1.1.0 and 1.2.0
|
|
declaration renderers rendered the full `compare_web_captures` input as
|
|
`args: unknown`: its generated TypeScript type exceeds Pi's 16,000-character
|
|
default. REA keeps the full advertisement's fields by inlining references when
|
|
the shared form would exceed Pi's 32-reference expansion limit; retaining that
|
|
shared form would leave later fields unknown instead. The existing
|
|
`REA_MCP_INPUT_SCHEMA_PROFILE=compact` profile lets callers stay below
|
|
its character limit by advertising reduced nested validation structure, while
|
|
REA continues to validate calls against the complete canonical input schema.
|
|
Compact is the default for the server's advertised inputs; an explicit `full`
|
|
choice is preserved. See the [compact input schema profile](mcp-contracts.md#compact-input-schema-profile)
|
|
for details of its reduced forms.
|
|
|
|
Custom renderer hosts can raise `inputMaxChars` through `renderToolSignature` or
|
|
`renderToolSample`; `renderDeclarations` does not expose that override. The
|
|
probe exercised the published renderer code, not a native Pi host or model, and
|
|
does not establish broader Pi compatibility. See the pinned upstream
|
|
[`declarations.ts`](https://github.com/earendil-works/pi/blob/b45e0ebcc5ae2fc42a6f2f23104d10e656e6bedb/packages/codemode/src/declarations.ts)
|
|
and [renderer usage notes](https://github.com/earendil-works/pi/blob/b45e0ebcc5ae2fc42a6f2f23104d10e656e6bedb/packages/codemode/README.md#declarations-for-the-model).
|
|
|
|
## End-to-end, integration and golden evidence
|
|
|
|
The optional `verify:qwen-client`, `verify:pi-client`, and `verify:hermes-client`
|
|
lanes require an installed native client. Select its executable with
|
|
`REA_VERIFY_QWEN_COMMAND`, `REA_VERIFY_PI_COMMAND`, or `REA_VERIFY_HERMES_COMMAND`.
|
|
They configure disposable profiles through the public REA CLI, preserve caller
|
|
settings and backups, and exercise real stdio MCP calls and skill loading. The
|
|
`call` mode checks complete catalog discovery and actual JavaScript Evidence;
|
|
pass `-- chat` to check plain chat with REA enabled. Qwen also reads the full
|
|
result that its client offloads, and Pi exercises default codemode execution.
|
|
Use `REA_VERIFY_RUNTIME_ROOT` to select a production-only installed REA package.
|
|
Receipts retain client versions, result digests, host coverage and owned-process
|
|
cleanup. These lanes use a deterministic loopback model and do not prove live
|
|
model-provider compatibility. Pi and Hermes remain POSIX-only. Qwen, Pi and Hermes
|
|
bind both `HOME` and `USERPROFILE` to the disposable account. Qwen and Pi discover
|
|
the shared personal skill through their default search paths without an explicit
|
|
skill setting; Hermes discovers it through the selected `HERMES_HOME`.
|
|
Set `REA_VERIFY_HERMES_STICKY_PROFILE=1` to exercise native Hermes selection of
|
|
a named sticky profile with `HERMES_HOME` still pointing to its root.
|
|
|
|
The Qwen lane also supports native Windows (verified with Qwen Code 0.25.1 and
|
|
Node 24.19.0 for both `chat` and `call`). With Node 24.18.0, the same `call`
|
|
journey reached full Evidence readback but the client aborted during exit with
|
|
`UV_HANDLE_CLOSING`; that run remains a failure, not a compatibility claim.
|
|
Select the npm install's
|
|
`node_modules/@qwen-code/qwen-code/cli-entry.js` with `REA_VERIFY_QWEN_COMMAND`,
|
|
because `execFile` cannot launch the `qwen.cmd` shim directly. A selected `.js`,
|
|
`.mjs` or `.cjs` entry point runs under the verifier's Node. Windows path checks
|
|
use native separators; persisted output is read through Qwen's real shell tool
|
|
with a shell-independent encoded Node payload. Windows receipts report process
|
|
lineage as unavailable when the verifier has no retained native Job Object lease.
|
|
|
|
`verify:gemini-client` requires an installed Gemini CLI (verified with
|
|
`@google/gemini-cli@0.63.0` on POSIX and native Windows); select it with
|
|
`REA_VERIFY_GEMINI_COMMAND`. A selected `.js`, `.mjs` or `.cjs` entry point runs
|
|
under the verifier's Node. On Windows, select the npm install's
|
|
`node_modules/@google/gemini-cli/bundle/gemini.js`, because only a `gemini.cmd`
|
|
shim reaches `PATH`.
|
|
The optional lane uses native `GEMINI_CLI_HOME` discovery in an isolated
|
|
Git project, checks setup plans, backups and idempotence, activates the installed
|
|
personal skill, validates all forwarded input JSON Schemas against their declared
|
|
dialect, forwards the complete REA catalog and checks full JavaScript
|
|
Evidence for a Unicode path. Use `-- chat` for ordinary chat with REA enabled,
|
|
or `REA_VERIFY_RUNTIME_ROOT` for a production-only installed REA package.
|
|
The local fixture exercises the real Gemini API adapter, including its
|
|
`untrusted_context` tool-result envelope. Token counts are synthetic; live
|
|
Google API compatibility remains unverified. The lane disables
|
|
the client's memory-based relaunch to preserve the caller's Node heap budget.
|
|
|
|
`verify:opencode-client` requires an installed OpenCode (verified with
|
|
`opencode-ai@1.18.35`); select it with `REA_VERIFY_OPENCODE_COMMAND`.
|
|
The optional POSIX lane configures isolated XDG roots and `OPENCODE_CONFIG_DIR`,
|
|
checks setup plans, backups, preserved JSONC comments and idempotence, activates
|
|
the installed skill, validates all forwarded input schemas and verifies complete
|
|
JavaScript Evidence for a Unicode path. JSONC is the default fixture; set
|
|
`REA_VERIFY_OPENCODE_CONFIG_FORMAT=json` for JSON. Use `-- chat` for ordinary
|
|
chat or `REA_VERIFY_RUNTIME_ROOT` for a production-only installed package.
|
|
The native core runs with external plugins disabled through `OPENCODE_PURE`;
|
|
the local OpenAI-compatible fixture has a caller-declared one-million-token
|
|
context and synthetic usage. Skills use an explicit isolated `skills.paths`
|
|
directory, so default OS-home discovery remains unverified. Live model APIs and
|
|
native Windows are also unverified.
|
|
|
|
`verify:claude-client` requires installed Claude Code (verified with
|
|
`@anthropic-ai/claude-code@2.1.296` on POSIX and native Windows); select it
|
|
with `REA_VERIFY_CLAUDE_COMMAND`. On Windows, select
|
|
`claude.exe`: npm installs put only a `claude.cmd` shim on `PATH`, and the real
|
|
executable is under `node_modules/@anthropic-ai/claude-code/bin`.
|
|
The optional lane uses native `CLAUDE_CONFIG_DIR` discovery, an independent
|
|
Git workspace, user settings and default built-in tools. It preserves caller
|
|
preferences and backups, checks idempotent setup, waits through the native
|
|
`WaitForMcpServers` tool when discovery is pending, and validates the complete
|
|
catalog and forwarded input schemas. Call mode loads the personal skill through
|
|
native `Skill`, checks its full body and verifies named-schema JavaScript Evidence
|
|
for a Unicode path. Use `-- chat` for ordinary chat with REA enabled, or
|
|
`REA_VERIFY_RUNTIME_ROOT` for a production-only installed package. The local
|
|
Anthropic Messages/SSE fixture preserves native resource-hint envelopes in its
|
|
request artifacts. Usage is synthetic; live Anthropic API and bare-mode
|
|
personal-skill activation remain unverified by this lane.
|
|
|
|
`verify:copilot-client` requires installed GitHub Copilot CLI (verified with
|
|
`@github/copilot@1.0.95`); select it with `REA_VERIFY_COPILOT_COMMAND`.
|
|
The optional POSIX lane uses native `COPILOT_HOME` discovery, an independent
|
|
Git workspace, guarded setup plans, preserved registrations, backups and
|
|
idempotence. Native `skill add` registers the isolated installed skill; call
|
|
mode loads its full body, validates all forwarded input schemas and checks
|
|
named-schema JavaScript Evidence for a Unicode path. When Copilot spills a
|
|
large MCP result, the model requests native `view` with `forceReadLargeFiles`
|
|
and validates the complete returned Evidence rather than its preview.
|
|
Use `-- chat` for ordinary
|
|
chat or `REA_VERIFY_RUNTIME_ROOT` for a production-only installed package.
|
|
The native offline BYOK adapter uses a loopback OpenAI completions/SSE fixture
|
|
and `gpt-5.4` model metadata; model inference and token usage are synthetic.
|
|
Set `REA_VERIFY_COPILOT_MODEL` to examine another client model ID and
|
|
`REA_VERIFY_COPILOT_WIRE_MODEL` for its backend model name (defaults to the client
|
|
ID). Every actual HTTP request's model is checked and recorded separately.
|
|
Both `HOME` and `USERPROFILE` point to the disposable account; native `skill add`
|
|
still selects the installed skill directory explicitly.
|
|
|
|
The same native client passed full-profile chat and analysis with the actual
|
|
wire model `gpt-4.1` under a distinct BYOK model ID:
|
|
|
|
```bash
|
|
REA_VERIFY_COPILOT_MODEL=rea-gpt-4.1 REA_VERIFY_COPILOT_WIRE_MODEL=gpt-4.1 npm run verify:copilot-client -- chat
|
|
REA_VERIFY_COPILOT_MODEL=rea-gpt-4.1 REA_VERIFY_COPILOT_WIRE_MODEL=gpt-4.1 npm run verify:copilot-client -- call
|
|
```
|
|
|
|
These runs retain full canonical input/output schemas, all tools, installed-skill
|
|
loading and complete Evidence readback. They use the fixture's requested
|
|
one-million-token BYOK prompt setting; effective capacity and live API acceptance
|
|
remain unknown. With the built-in `gpt-4.1` model ID, the verified client still
|
|
blocks the full input-schema profile before HTTP with
|
|
`compaction_static_context_blocked`, even when requesting a larger BYOK prompt
|
|
capacity. The effective capacity is unknown. The default verifier preserves
|
|
the complete catalog and full schemas. To verify the existing compact profile:
|
|
|
|
```bash
|
|
REA_VERIFY_COPILOT_MODEL=gpt-4.1 REA_VERIFY_COPILOT_SCHEMA_PROFILE=compact npm run verify:copilot-client -- chat
|
|
REA_VERIFY_COPILOT_MODEL=gpt-4.1 REA_VERIFY_COPILOT_SCHEMA_PROFILE=compact npm run verify:copilot-client -- call
|
|
```
|
|
|
|
The verifier explicitly writes either selected profile into its disposable
|
|
registration and compares the input schemas forwarded by Copilot with that
|
|
profile's advertised schemas. A run must not infer `full` from an unset setting:
|
|
REA's runtime default is now `compact`. The recorded client results above remain
|
|
scoped to their executed revisions; this verifier correction is not a new client run.
|
|
|
|
Both native workflows passed with the complete tool inventory. The verifier selects the
|
|
profile only in its disposable Copilot registration and records it in the
|
|
receipt. Compact advertisements can reduce nested validation structure; the
|
|
server still validates complete canonical inputs. This is a tested alternate
|
|
workflow, not a fix for the full-profile client/model limit tracked in #1554.
|
|
Live model APIs, native Windows and default OS-home skill discovery remain
|
|
unverified.
|
|
|
|
`verify:grok-client` requires installed Grok Build (verified with the official
|
|
Linux x64 1.0.50 binary); select it with `REA_VERIFY_GROK_COMMAND`. This optional
|
|
POSIX lane isolates `GROK_HOME`, an independent Git workspace and additional
|
|
skill roots, disables foreign configuration discovery, guards setup writes,
|
|
preserves unrelated registrations/backups and checks idempotence. Call mode
|
|
loads the full skill through native `read_file`, queries all REA names and input
|
|
schemas through native `search_tool`, and calls analysis through `use_tool`.
|
|
If discovery reports `partial`, the native agent diagnoses REA registration and
|
|
retries discovery. No startup-timeout override or fixed readiness delay is used.
|
|
A larger Unicode-path fixture exercises native result offloading: the full
|
|
retained Evidence is validated against its named schema, then native terminal
|
|
queries recover the selected export facts, subject and full artifact digest in
|
|
the next model request. This verifies useful artifact recovery without claiming
|
|
that every offloaded graph fact enters model context. Native line-number and
|
|
truncation envelopes remain in the request artifacts. Use `-- chat` for ordinary
|
|
chat, or `REA_VERIFY_RUNTIME_ROOT` for a production-only installed package.
|
|
The loopback OpenAI completions/SSE custom model declares a one-million-token
|
|
context and synthetic usage. Live xAI APIs, native Windows and default OS-home
|
|
skill discovery remain unverified.
|
|
|
|
`verify:commandcode-client` requires installed Command Code (verified with npm
|
|
1.79.2); select it with `REA_VERIFY_COMMANDCODE_COMMAND`. Auth, MCP tokens and
|
|
sessions use the actual OS home, so provision a disposable POSIX account rather
|
|
than overriding `HOME`. Set `REA_VERIFY_COMMANDCODE_ACCOUNT_HOME` to that account's
|
|
actual home and create `.rea-client-verification` there with exactly
|
|
`Disposable REA client verification account` followed by a newline. The lane
|
|
owns that account's `.commandcode` configuration and shared REA skill. Build the
|
|
runtime as the checkout owner, then run `node scripts/verify-commandcode-client.mjs`
|
|
as the disposable account; the npm shortcut also needs a writable checkout.
|
|
The verifier does not create accounts or install clients. It guards setup
|
|
targets, preserves an unrelated registration and backups, checks idempotence,
|
|
and verifies native default shared-skill discovery and complete activation.
|
|
Default deferred-schema delivery stays enabled: the native prompt advertises
|
|
every REA tool, exact-name `search_tools` returns every input schema, and a native
|
|
shell query recovers the saved catalog's count and digest when the client spills
|
|
it. Actual analysis of a Unicode-path fixture delivers full named-schema Evidence
|
|
to the next model request. Use `-- chat` for ordinary chat or
|
|
`REA_VERIFY_RUNTIME_ROOT` for a production-only installed package. The loopback
|
|
OpenAI completions/SSE model is a keyless BYOK endpoint declaring a million-token
|
|
context with synthetic usage. A synthetic account-key value satisfies the
|
|
client's print-mode gate; native local-only mode refuses hosted API calls.
|
|
Updates, telemetry and cron are disabled. Hosted authentication, live models
|
|
and Windows remain unverified.
|
|
|
|
`verify:omp-client` requires installed OMP (verified with the official Linux x64
|
|
18.8.7 binary); select it with `REA_VERIFY_OMP_COMMAND`. This optional POSIX lane
|
|
isolates the default agent, global config and XDG roots, guards setup targets,
|
|
preserves unrelated registrations and backups, and checks idempotence. It
|
|
compares native rejection of an invalid profile with REA's refusal to plan
|
|
fallback writes. OMP's default `xd://` interface mounts the complete REA catalog
|
|
as devices: call mode reads the complete installed skill and tool documentation,
|
|
then dispatches analysis through native `write`. It checks full named-schema
|
|
JavaScript Evidence with a Unicode path in the next model request. Device
|
|
metadata and documentation are distinct from forwarding all JSON schemas as
|
|
model functions. Native print-mode MCP readiness uses its defaults.
|
|
Use `-- chat` for ordinary chat or `REA_VERIFY_RUNTIME_ROOT` for a production-only
|
|
installed package. The loopback OpenAI completions/SSE model fixture declares a
|
|
one-million-token context and synthetic usage. Live model APIs, native Windows,
|
|
named-profile native execution and default OS-home skill discovery are
|
|
unverified; skill discovery uses an explicit isolated custom directory.
|
|
|
|
`verify:deepseek-client` requires an installed DeepSeek Harness (`dsh`;
|
|
verified with `@deepseek-ai/dsh@0.2.0-rc.2`) and Git. Set
|
|
`REA_VERIFY_DEEPSEEK_COMMAND` to select its executable. This optional POSIX lane
|
|
seeds caller model settings and a stale Cordis registration in an isolated
|
|
`DSH_HOME`, then runs public `setup --client dsh` dry-run, setup, repeated setup,
|
|
and scoped doctor. It checks the backup and unrelated patches before booting
|
|
Harness with the generated registration. After native execution it uninstalls
|
|
through the public CLI and checks that only caller patches remain. `HOME` and
|
|
`USERPROFILE` point to the disposable account. The native default
|
|
`~/.agents/skills` search path discovers
|
|
the installed skill without a `DSH_AGENTS_HOME` override. A separate Git root prevents inherited project skills from
|
|
masking a missing installation. The default `call` mode checks skill loading,
|
|
complete catalog discovery, the actual forwarded input schemas and regexes,
|
|
and full JavaScript Evidence for a Unicode path. Use `-- chat` for ordinary
|
|
chat with REA enabled, or `REA_VERIFY_RUNTIME_ROOT` for an installed package.
|
|
The fixture uses Harness's custom OpenAI adapter and the one-million-token
|
|
context capacity declared by its default DeepSeek Flash model; it does not
|
|
establish live DeepSeek API or native Windows coverage. Receipts include
|
|
request artifacts, result digests and owned-process lineage.
|
|
|
|
The DSH acceptance journey also exercises public setup, approval, doctor,
|
|
generated-launcher MCP startup and uninstall without an installed Harness.
|
|
That journey proves REA workflow behavior, not native Cordis expression
|
|
evaluation. Filesystem regressions retain tagged values and unrelated rows
|
|
across alias dependencies and check refusal of unsafe YAML without mutation.
|
|
|
|
Full E2E tests invoke the production command dispatcher and real providers,
|
|
without fake launchers, runners or responses. `verify:keyed-archive` writes
|
|
Foundation binary, XML, and integer archives using one run-owned Swift module
|
|
cache. It checks CLI and separate stdio MCP parity, pagination, escaping-path
|
|
rejection, an XML graph golden, and numeric meaning for safe controls, unsafe
|
|
integers, boxed numbers, and integral-valued reals. `verify:asset-catalog`
|
|
compiles source-owned colors with
|
|
`actool`, invokes real `assetutil`, then checks CLI/MCP results, exact catalog
|
|
digest, every raw metadata field, pagination and malformed input rejection.
|
|
Neither artifact workflow requires Hopper or launches it. Both run in macOS CI.
|
|
`verify:macos-bundle` needs only macOS with Command Line Tools. It compiles a
|
|
source-owned app with `clang`: a versioned framework, XPC services, an app
|
|
extension, a login item, a privileged helper, launchd plists, and a helper tool,
|
|
signed ad hoc. It packs the app as a directory, a `ditto` ZIP, and an APFS DMG,
|
|
then checks that `inspect-artifact` plus `project-apple-application-graph`
|
|
report the same bundle anatomy for all three through the CLI, with stdio MCP
|
|
parity. It also checks that the DMG is detached afterwards. The same app
|
|
covers `trace-dylib-resolution`:
|
|
|
|
- each resolution status and finding, with CLI/MCP parity;
|
|
- for every traced image, dependencies, rpaths, and install names equal to
|
|
`otool -l`;
|
|
- for the main executable and an XPC service, a predicted load order equal to
|
|
the images dyld actually loads under `DYLD_PRINT_LIBRARIES`.
|
|
|
|
The lane also compiles executable/library pairs with empty embedded directory,
|
|
versioned-path, and suffix settings. It checks present and removed dependencies
|
|
through CLI and MCP, and compares actual `DYLD_PRINT_SEARCHING` diagnostics for
|
|
root-level candidates. These cases distinguish an empty search directory from
|
|
an empty versioned scan or a suffix that only repeats the original path.
|
|
|
|
It runs in macOS CI.
|
|
|
|
Prepare the native inspector before cases that measure producer output or exit
|
|
behavior; keep startup deadlines and cancellation in distinct cases. Run real
|
|
process-capture verification separately from package or build checks. On macOS,
|
|
new npm processes can become token-unreadable after changing their display
|
|
title and prevent verified cleanup during a capture's ownership sweep.
|
|
|
|
MCP SDK transport tests with recording providers remain integration tests.
|
|
They are useful for schema drift and failure projection but do not prove that
|
|
Hopper, Ghidra or another substituted engine works. `verify:package` proves
|
|
packaging/install behavior and fake-provider integration; use the corresponding
|
|
real-provider lanes for engine claims. Packed-bridge checks verify shipped files and Python syntax.
|
|
Real Apple dispatch and Interface
|
|
Builder verifiers currently prove format integration through production readers.
|
|
|
|
`verify:hopper` exercises an installed Hopper through the production stdio MCP
|
|
server and CLI. It checks source-owned call chains, CFG edges, references and
|
|
complete large inventories, then probes unnamed bookmarks, annotation clearing,
|
|
batch validation before mutation, malformed addresses and regexes, segment-end
|
|
partial reads, and synthetic file-offset rejection. Advertised schemas are
|
|
validated in their JSON Schema dialect and successful replies are checked against
|
|
their advertised output schemas. Navigation checks cover interior-object cursor
|
|
readback and mapped-memory boundaries. Annotation probes verify invalid native
|
|
text and duplicate destinations/names before mutation, preserve unselected label
|
|
owners, and exercise explicit batch label swaps. Function locals retain observed
|
|
names and stack displacements. Graph probes check symbol/interior-address parity
|
|
and a source-owned recursive cycle; literal tracing preserves complete queries
|
|
and whitespace. Disposable binary copies prove that switching and closing
|
|
actually removes the native document, and that CLI byte, function-dossier,
|
|
literal-trace results and invalid-address diagnostics agree with MCP.
|
|
No provider is mocked in this lane.
|
|
Real search probes cover Unicode names, literal metacharacters, case and regex
|
|
modes, annotation cache invalidation, complete native fragments of long literals
|
|
checked against byte reads, escaped UTF-8/control text, byte-preserving Latin-1
|
|
decoding, and Hopper's UTF-16 symbol-name truncation boundary. It verifies native
|
|
CallReference classifications across reference and dossier results, retains long
|
|
string fragment metadata in dossiers, and exercises pathological regex deadline
|
|
and cancellation followed by successful requests in the same native session. When the macOS
|
|
Objective-C fixture is present, the lane also verifies native UTF-16 string objects
|
|
and their inferred encodings against their actual bytes. Native terminal calls
|
|
are checked across reference, instruction, assembly, block-range and procedure-length
|
|
projections; block endpoints are normalized using actual native membership.
|
|
Exact Objective-C names also exercise named CLI selectors for function, instruction,
|
|
decompilation, reference and search operations. A literal `--help` trace query proves
|
|
that selector data is preserved independently of global CLI flags.
|
|
Unmapped annotation destinations and
|
|
oversized later batch names fail before any earlier edit is applied.
|
|
|
|
`verify:hopper:deadlines` checks the native client's optional request deadlines
|
|
on macOS with an owned source-built fixture. Zero and elapsed deadlines must
|
|
leave native comments unchanged, including when a synchronous progress observer
|
|
delays timer dispatch. It also observes a short analysis deadline and verifies
|
|
subsequent wire recovery and clean shutdown. Caller timeout does not interrupt
|
|
Hopper's synchronous native operation. Socket boundary tests deterministically
|
|
cover active and queued expiry, late replies and timer cleanup.
|
|
|
|
The Linux demo lane remains a separate `verify:hopper:linux` command. Hopper
|
|
6.4.2's ELF loader did not recognize the original 4,119-byte literal or three
|
|
non-ASCII byte strings in the measured fixtures. The lane retains complete raw
|
|
byte checks for those literals through source-owned symbols. Recognition of the
|
|
original full-length literal is bound to its exact source address; its decoded
|
|
object coverage remains explicitly unverified on Linux even when recognized.
|
|
Absent non-ASCII recognition also reports decoded-object coverage as unverified.
|
|
Recognized non-ASCII and control-text objects must still match their source
|
|
bytes, encoding, filters and searches.
|
|
A separate 548-byte ASCII literal requires native fragmentation, shortened
|
|
provider display, complete decoded fragments and dossier provenance on Linux;
|
|
the macOS lane retains the original full-length recognition requirement. These
|
|
are observed fixture/build capabilities, not universal Hopper length limits.
|
|
Its lifecycle checks attempt competing CLI launches for the active target and a
|
|
different target, requiring rejection before either can change the owning
|
|
MCP session's documents or procedures. Lease boundary tests also preserve
|
|
unresponsive or malformed live endpoints while allowing confirmed stale
|
|
sockets to recover.
|
|
|
|
`verify:setup:linux` exercises installation on a clean supported Linux runner as
|
|
root. Use a disposable VM: this lane installs Hopper and its Linux runtime
|
|
dependencies through the system package manager. Set `REA_VERIFY_SERVER_COMMAND`
|
|
to the CLI entrypoint being verified. The command builds and checks source-owned
|
|
ELF fixtures before testing the read-only Hopper setup plan, approved
|
|
installation, scoped doctor, real CLI/MCP analysis, rejection of a modified
|
|
launcher, idempotent setup without requesting a reinstall, and owned child
|
|
cleanup. Before installation and after teardown, a clean-runner process scan
|
|
also rejects surviving Hopper demo helpers or Xvfb groups, including orphans
|
|
whose launcher exited. This scan observes processes without signaling them.
|
|
Hopper detection compares executable file identity through `/proc`, covering
|
|
alternate or configured launcher paths even after an invoked symlink is removed.
|
|
The dedicated runner must have no unrelated Hopper/Xvfb sessions. It requires
|
|
the repository's pinned development toolchain and an
|
|
existing host C compiler, `file`, `nm`, and `strings`. Use `verify:hopper:linux`
|
|
instead when Hopper is already installed.
|
|
|
|
`verify:hopper:fat` is a separate macOS lane requiring installed Hopper and the
|
|
existing Xcode clang/lipo toolchain. It compiles arm64/x86-64 thin executables and
|
|
one- and two-slice FAT32 containers, verifies exact/interior address mappings
|
|
against bytes in the original files, checks CLI/MCP parity, and checks owned
|
|
runtime cleanup. Source byte changes, removal, permission denial (for non-root
|
|
callers), and nonregular replacement must retain native partial mapping facts,
|
|
reject unverified original-file coordinates,
|
|
and recover after restoration. Single-slice FAT cases also relocate the slice
|
|
without changing its loaded bytes. `verify:hopper:fat64` additionally checks
|
|
FAT64 preparation through Hopper's native Mach-O loader, source-container
|
|
mappings, profile identity,
|
|
malformed and ambiguous slice rejection, and temporary-image lifetime. Both
|
|
lanes have been verified on Hopper 6.1.0-demo; this establishes REA's prepared
|
|
FAT64 workflow, not native FAT64-loader support.
|
|
Cross-architecture fixture compilation is not required by `verify:hopper`.
|
|
|
|
Golden tests use immutable captured text inputs with producer/source provenance
|
|
under `tests/fixtures/golden/`. Expected results are reviewed for the semantic
|
|
claim; capture commands do not automatically approve new expected outputs.
|
|
Do not call handcrafted utility output or synthetic binary builders real-data
|
|
goldens. Keep unsupported binary layouts and malformed boundaries as targeted
|
|
regressions until a real fixture establishes equivalent coverage.
|
|
|
|
`verify:browser` exercises source-map failure isolation and expanded-output limits through the compiled CLI and stdio MCP with real Chrome. It also submits five 2 MiB source-map annotations, checks retained script identities and explicit map omissions, and closes its owned fixture target. Replacement and document-reset behavior has separate producer-boundary coverage.
|
|
|
|
The raw Chrome fixture launchers use `--password-store=basic` so Linux startup
|
|
does not wait for an unlock prompt from a reachable but locked desktop keyring.
|
|
Such a stall leaves the initial page unloaded with empty or placeholder CDP URLs;
|
|
it does not establish permission to capture that page. See
|
|
[the keyring diagnosis](https://github.com/morluto/rea/issues/1384#issuecomment-6093781686).
|
|
|
|
On Windows, browser verifier lanes that launch an owned fixture require a
|
|
standard, non-elevated caller token. They inspect the verifier caller before
|
|
allocating fixture resources and refuse elevated or unobservable tokens; they do
|
|
not change caller authority or claim to inspect the browser process token.
|
|
|
|
`verify:browser` also captures a source-owned noise canvas as a real PNG above
|
|
8 MiB through the CLI and stdio MCP, with complete byte/digest parity and real PNG
|
|
decoding. Its SDK client explicitly permits the larger inline JSON response;
|
|
this lane does not establish large image-comparison request transport coverage.
|
|
|
|
The scenario checks read locale, timezone, device scale and viewport dimensions
|
|
from actual page JavaScript through CLI and stdio MCP DOM captures. They also
|
|
verify that attached-page emulation is released after success, initialization
|
|
failure, action failure and cancellation while the external target stays open.
|
|
|
|
`verify:browser:network` is a focused real-browser lane for transaction identity,
|
|
selected request/response bytes, binary and compressed responses, duplicate
|
|
headers, credential and declared-secret redaction, redirects, streaming cutoff,
|
|
CLI/MCP parity, and owned-profile cleanup. Set `REA_BROWSER_EXECUTABLE` to an
|
|
installed Chrome-family browser. An optional script argument selects an already
|
|
installed package's `scripts/rea.mjs` entry point for packaged-artifact checks.
|
|
The complete `verify:browser` lane includes these same checks.
|
|
|
|
After building, `verify:browser:dom` checks empty and HTML-whitespace form
|
|
destinations against a native Chrome DOM-property oracle through CLI and stdio
|
|
MCP. It requires `REA_BROWSER_EXECUTABLE` and accepts an optional installed REA
|
|
entrypoint. The full browser lane includes the same public-adapter assertions
|
|
before other fixtures navigate the selected page.
|
|
|
|
`verify:browser:scripts` checks active script capture → exact-byte export →
|
|
existing static JavaScript analysis through CLI and stdio MCP, including
|
|
manifest readback, competing query variants, and resolved relative imports.
|
|
It uses an installed browser and accepts an optional installed REA entrypoint.
|
|
The complete `verify:browser` lane also exercises passive script export through
|
|
both public adapters. See [website script export](website-script-export.md).
|
|
|
|
`verify:browser:modules` compares CLI and stdio MCP traces against an independent
|
|
real Chromium module-loading fixture: import-map scopes, package prefixes,
|
|
null/backtracking rejection, query/fragment identities, repeated module instances,
|
|
lazy and computed unknowns, exact source/map identities and no implicit refetch.
|
|
Set `REA_BROWSER_EXECUTABLE`; the optional script argument selects an installed
|
|
package entrypoint. The complete `verify:browser` lane and existing conditional
|
|
Chrome CI include this verifier. See [module relationships](website-module-trace.md).
|
|
|
|
## Agent evaluation and conformance records
|
|
|
|
Evaluate native, JavaScript, managed and browser investigation tasks through a
|
|
real local Codex CLI with:
|
|
|
|
```bash
|
|
npm run verify:agent
|
|
```
|
|
|
|
The verifier's scenarios, transcript scoring, fixture rubrics, and report gates
|
|
are development verification code under `tests/evaluation/model-evals/`. The
|
|
source-owned evaluator runs alongside the compiled REA tools; it is excluded
|
|
from the shipped runtime package.
|
|
|
|
The lane runs scenarios sequentially in standalone Codex (`--no-daemon`) with a
|
|
disposable HOME and CODEX_HOME under `~/.cache/rea-agent-evaluations/`. Set
|
|
`REA_AGENT_EVAL_ROOT` to choose another parent directory outside the OS temporary
|
|
directory: current Codex refuses helper aliases under `/tmp`, preventing shell
|
|
commands and skill reads even if MCP works. Each owned run directory is removed
|
|
after verification unless fixture retention is requested. Commands share the
|
|
owned-process supervisor: native ownership preparation has its own bounded
|
|
deadline before each short command budget, and timeouts join bounded process-tree
|
|
and output cleanup before returning. If cleanup remains incomplete, the lane retries its retained
|
|
owner and preserves the run directory (including disposable auth) rather than
|
|
removing files still in use; the error retains ownership and recovery details.
|
|
Command stderr is limited to 32 KiB and combined version output to 8 KiB;
|
|
exceeding these diagnostic budgets fails explicitly. Scenario JSON events stream
|
|
to the evaluator without retaining a second raw stdout copy. Cleanup attempts the
|
|
remaining run tree even if auth removal fails, and reports unresolved cleanup
|
|
together with the original verification failure. The lane
|
|
installs the packaged skill and MCP registration through public `rea setup`,
|
|
rather than copying a skill into a project that also inherits the caller's
|
|
skills and configuration. Only authentication is copied, when present, and it
|
|
is removed after confirmed process cleanup even with
|
|
`REA_AGENT_EVAL_KEEP_FIXTURES=true`. No user configuration,
|
|
rules, plugins or history is copied; shell snapshots and additional agents are
|
|
disabled. Existing API-key environment authentication remains available.
|
|
The native provider scenario preapproves only `open_binary` and
|
|
`close_binary` in the disposable client so it reaches REA's actual provider
|
|
boundary instead of stopping at Codex approval. Its scenario contract accepts
|
|
one `provider_unavailable` open refusal without a close, or one successful open
|
|
followed by a successful close. Other errors, an unclosed session, and a close
|
|
without acquisition fail. These outcomes and the prompt are owned together in
|
|
`tests/evaluation/model-evals/AgentEvaluationScenarios.ts`; generic successful-tool sequences
|
|
still apply to scenarios that require them. The provider scenario checks routing,
|
|
reported limitations, and cleanup; free-form answer correctness remains
|
|
unassessed. It does not validate a real native engine or authorize runtime execution.
|
|
|
|
Select a smaller run with `REA_AGENT_EVAL_SCENARIOS`, a comma-separated list of
|
|
scenario IDs. `asar-zh` exercises the packaged desktop rubric from a Chinese
|
|
request. `javascript-module-view` exercises summary analysis, module paging and
|
|
item inspection in a tree with unrelated modules; its routing and text checks
|
|
remain heuristic, so review the retained transcript for selector choice and
|
|
coverage claims. Set `REA_CODEX_CLI` to an installed Codex executable and
|
|
`REA_AGENT_EVAL_MODEL` to an account-supported model. Use an external resource
|
|
limit for the whole process tree when testing on a constrained host; a Node
|
|
heap limit alone does not bound client and child-process memory.
|
|
|
|
`missing-target` leaves desktop fixtures visible without selecting one in the
|
|
request. It requires zero REA calls and a JSON-only request for an app name or
|
|
artifact path, with no preceding prose or Markdown fences. Its prompt and
|
|
whole-answer validator are defined together in `AgentEvaluationScenarios.ts`.
|
|
Its `expectedFirstTool` is `null`, and
|
|
`targetClarificationPassed` grades that limited routing outcome independently
|
|
of analysis prose heuristics. Analyzing a nearby example cannot pass this case.
|
|
|
|
The packaged desktop, parser-comparison, and managed scenarios assess a closed set of
|
|
known fixture claims. Each final answer must be a strict JSON manifest containing
|
|
exactly the requested claim IDs, values, Evidence IDs, and Evidence authority and
|
|
confidence. Golden values are not included in the prompt. The evaluator checks
|
|
exact values against both the fixture oracle and authenticated successful REA
|
|
results; an Evidence ID by itself is insufficient. Missing, duplicate, extra,
|
|
contradictory, incorrectly sourced, or unsupported claims fail the scenario.
|
|
|
|
The desktop rubric covers the exposed bridge API and members, renderer and main
|
|
IPC operations, and the resolved preload. It binds its Evidence to the exact
|
|
packaged artifact path and SHA-256. The parser rubric checks the precise heading
|
|
depth addition, discriminant, complete comparison counts, and the explicit limit
|
|
on runtime semantics. Its comparison must link to the two delivered source
|
|
analyses and use the requested module and export selectors. Boundary tests package
|
|
the same source-owned desktop fixture and compare the same source-owned parser
|
|
files through actual MCP tool results, then verify that fabricated answers fail.
|
|
|
|
The managed rubric checks the exact public top-level type set and the CLI entry
|
|
point's declaring type and method name. The exact type-set claim requires an
|
|
unfiltered member inventory: `selection` must be null and the Evidence parameters
|
|
must omit `type_names`. A selected inventory can still ground the entry-point
|
|
claim. Both inspections must describe the freshly built DLL's SHA-256. Entry-point
|
|
resolution additionally requires complete artifact and member metadata, matching
|
|
non-null module MVIDs, and a unique method at the header's metadata token. These are
|
|
static metadata claims, not runtime behavior;
|
|
compiler-generated member counts, token values, and MVIDs are not golden answers.
|
|
|
|
Per-scenario `factualCorrectness` is `passed`, `failed`, or `not_assessed` within
|
|
the `configured_fixture_claims` scope. A pass establishes only the configured
|
|
claims, not unrestricted factual correctness. Native, browser,
|
|
navigation-context, and address-context scenarios have no factual rubric and
|
|
remain `not_assessed`.
|
|
|
|
The closed factual scenarios request complete producer Evidence on the initial
|
|
inspection or analysis so their source selectors can authenticate all configured facts.
|
|
Summary/page/item workflows are exercised separately by `javascript-module-view`;
|
|
its heuristic gate does not establish full-producer factual correctness.
|
|
|
|
All scenarios retain routing, workflow, validation, repetition, process-exit,
|
|
and token-use gates. Configured factual scenarios additionally require a factual
|
|
pass. Their answer-text heuristics are diagnostic and do not affect the gate.
|
|
Validation counts include complete text-only REA `invalid_request` envelopes
|
|
and failed SDK calls whose arguments violate the named current REA contract.
|
|
Client approval rejections and provider unavailability remain distinct failures;
|
|
truncated JSON previews are not parsed into invented error codes.
|
|
Repeated `binary_session` observations separated by a successful `open_binary`
|
|
or `close_binary` are treated as lifecycle verification. An unchanged retry,
|
|
including one after a failed lifecycle call, still counts as repetition.
|
|
Scenarios without a rubric retain the legacy text-heuristic gate.
|
|
`answerTermCoverageMet` checks case-insensitive substrings,
|
|
`epistemicCuePresent` checks keywords, and `finalCitesEvidence` checks only an ID's
|
|
presence. These metrics can still accept fabricated prose and must not be read
|
|
as factual assessments. Set `REA_AGENT_EVAL_TRANSCRIPT_DIR` to retain complete
|
|
tool results and final answers for review.
|
|
|
|
Report schema version 4 adds negative routing scenarios with nullable
|
|
`expectedFirstTool` and a `targetClarificationPassed` outcome. Consumers must
|
|
allow an expected absence of REA calls; this does not make an analysis scenario
|
|
pass without its required tools. Native provider records additionally report
|
|
`scenarioOutcome` (`provider-unavailable`, `opened-and-closed`, or `failed`) and
|
|
`scenarioOutcomePassed`; a failed outcome fails the gate independently of prose
|
|
heuristics. Version 3 changed the top-level
|
|
`factualCorrectness` from a constant
|
|
string to an assessment summary with status, scope, and assessed/passed/failed/
|
|
not-assessed scenario counts. Scenario records include the factual assessment and
|
|
configured claim IDs. The evaluation scope is
|
|
`routing_workflow_and_configured_fixture_claims`. Update report consumers for
|
|
these changes. The narrower heuristic field names introduced in version 2 remain:
|
|
`answerHeuristicsMet`, `epistemicCuePresent`, `answerTermCoverageMet`, and
|
|
`requiredAnswerTermGroups`.
|
|
|
|
Regenerate the managed conformance manifest and Evidence completion ledger from
|
|
live verification results, or check them for drift:
|
|
|
|
```bash
|
|
npm run evidence:generate
|
|
npm run evidence:check
|
|
```
|
|
|
|
The records preserve unsupported and unverified coverage as explicit unknowns.
|
|
Run the matching real-tool prerequisites described in this guide.
|