@capagents/forgeqe 2.9.2 → 2.9.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (85) hide show
  1. package/dist/docs-site/docs/architecture/index.html +6 -0
  2. package/dist/docs-site/docs/search.js +1 -1
  3. package/dist/docs-site/docs/web-app/index.html +12 -1
  4. package/dist/forgeqe.js +1717 -1677
  5. package/dist/web/assets/{Agent-BFwkMMHm.js → Agent-B6xfobJ9.js} +3 -3
  6. package/dist/web/assets/{ApiTests-Bgt4R_yB.js → ApiTests-BwgezlYi.js} +3 -3
  7. package/dist/web/assets/Browse-DDzk_KTh.js +2 -0
  8. package/dist/web/assets/Chat-BdlfK2ra.js +3 -0
  9. package/dist/web/assets/{CommandPalette-nmLCmEsp.js → CommandPalette-Cla7m818.js} +1 -1
  10. package/dist/web/assets/{Compare-CGcGp9qD.js → Compare-BxUfo0rI.js} +1 -1
  11. package/dist/web/assets/{Cost-BvCShgln.js → Cost-Dpa8aWQG.js} +1 -1
  12. package/dist/web/assets/{Data-3EEe7vIz.js → Data-D_7m2GL6.js} +2 -2
  13. package/dist/web/assets/Desktop-CgslBkAr.js +1 -0
  14. package/dist/web/assets/DesktopReview-CsW65QZz.js +1 -0
  15. package/dist/web/assets/{Evidence-D1HiXQK6.js → Evidence-SYt-mbDx.js} +1 -1
  16. package/dist/web/assets/{Explore-2M7wI0Sf.js → Explore--B18Jvg9.js} +1 -1
  17. package/dist/web/assets/{Features-DmQ5JiMI.js → Features-BerYifH7.js} +1 -1
  18. package/dist/web/assets/{Flags-Bg-l5HxL.js → Flags-ABMq---p.js} +1 -1
  19. package/dist/web/assets/{Flaky-DJlkxmHT.js → Flaky-DKeceXsa.js} +1 -1
  20. package/dist/web/assets/{ForceGraph-B5i3Ewd5.js → ForceGraph-C9HFjZX3.js} +1 -1
  21. package/dist/web/assets/{Impact-huKs-mOc.js → Impact-DQ2c0dTT.js} +1 -1
  22. package/dist/web/assets/{Jobs-BwK79TQ8.js → Jobs-Dy_C2x36.js} +2 -2
  23. package/dist/web/assets/{KindPage-C0MoC9da.js → KindPage-DQzstMyM.js} +4 -4
  24. package/dist/web/assets/{Migration-CTVyQeqW.js → Migration-B4GWsCLR.js} +1 -1
  25. package/dist/web/assets/{Product-BHqJVCMn.js → Product-CgVhHMMY.js} +1 -1
  26. package/dist/web/assets/{Production-GL8lbwxD.js → Production-OdB4gZ3T.js} +1 -1
  27. package/dist/web/assets/{Quality-jI3YgvqZ.js → Quality-DOV4suvD.js} +1 -1
  28. package/dist/web/assets/{Readiness-B3OZ51FG.js → Readiness-DawfUUHc.js} +1 -1
  29. package/dist/web/assets/Record-C9uAKGYM.js +2 -0
  30. package/dist/web/assets/{Regression-v2dpbgs4.js → Regression-DZdddPfI.js} +2 -2
  31. package/dist/web/assets/{Reports-BAat71wo.js → Reports-BHOS6af1.js} +1 -1
  32. package/dist/web/assets/{Response-DjqmewrL.js → Response-qfMk4Nrh.js} +1 -1
  33. package/dist/web/assets/{RunDiff-BbBom2fJ.js → RunDiff-BNywFV7t.js} +1 -1
  34. package/dist/web/assets/{Runs-CIQWWRl3.js → Runs-BJPYXRiB.js} +1 -1
  35. package/dist/web/assets/{Steps-DfNHCe8N.js → Steps-Cdzyueit.js} +1 -1
  36. package/dist/web/assets/{TestCases-8BBW6RSi.js → TestCases-DcYY2l9q.js} +1 -1
  37. package/dist/web/assets/{TestData-BFkACDve.js → TestData-CrzKA3xh.js} +1 -1
  38. package/dist/web/assets/{TestDebt-CUcklHEN.js → TestDebt-CVDJT511.js} +1 -1
  39. package/dist/web/assets/Tosca-CBwGCrbL.js +3 -0
  40. package/dist/web/assets/{WhatsNew-CBS7kmGu.js → WhatsNew-CIOTidx-.js} +1 -1
  41. package/dist/web/assets/{dataParts-B3Fz4S59.js → dataParts-CUb0Q0IZ.js} +1 -1
  42. package/dist/web/assets/{families-BiqSaqoO.js → families-C9MndVzT.js} +1 -1
  43. package/dist/web/assets/filters-Bk7ovF3M.js +1 -0
  44. package/dist/web/assets/{fold-b2g0_ndv.js → fold-97yBCSav.js} +1 -1
  45. package/dist/web/assets/frame-CqWJMIHh.js +4 -0
  46. package/dist/web/assets/index-ASvNRLI7.js +73 -0
  47. package/dist/web/assets/index-B5o9vY-v.css +2 -0
  48. package/dist/web/assets/{logos-DSveGjIW.js → logos-CbNeXLAM.js} +1 -1
  49. package/dist/web/assets/{palette-CF8GLAVN.js → palette-Dg3RS-ff.js} +1 -1
  50. package/dist/web/assets/{parts-D7OvxdrL.js → parts-CPAyV15O.js} +1 -1
  51. package/dist/web/assets/{productParts-BDM3LIjp.js → productParts-BpXw1jMa.js} +1 -1
  52. package/dist/web/assets/{qualityParts-DP09bVel.js → qualityParts-8TPKphgl.js} +1 -1
  53. package/dist/web/assets/recordTest-DvnpHsd2.js +1 -0
  54. package/dist/web/assets/{rows-B0vZ5x5N.js → rows-BdYJLCRD.js} +1 -1
  55. package/dist/web/assets/{segmented-BfWimTC0.js → segmented-DlF5rvSR.js} +1 -1
  56. package/dist/web/assets/{thread-DASfqw-f.js → thread-DlyX7xQt.js} +1 -1
  57. package/dist/web/assets/{usePageChat-BLEUldCJ.js → usePageChat-Dhu3upXA.js} +1 -1
  58. package/dist/web/index.html +4 -4
  59. package/docs/ARCHITECTURE.md +5 -0
  60. package/docs/WEB_APP.md +17 -1
  61. package/forgeqe.example.yaml +1 -0
  62. package/package.json +1 -1
  63. package/py/forgeqe_desktop/agentdesktop_driver.py +69 -0
  64. package/py/forgeqe_desktop/boxes.py +32 -0
  65. package/py/forgeqe_desktop/handhooks.py +55 -5
  66. package/py/forgeqe_desktop/pywinauto_driver.py +25 -0
  67. package/py/forgeqe_desktop/service.py +85 -3
  68. package/py/forgeqe_engine/brand.py +3 -0
  69. package/py/forgeqe_engine/browser.py +46 -6
  70. package/py/forgeqe_engine/cli.py +10 -1
  71. package/py/forgeqe_engine/recordsession.py +92 -2
  72. package/py/forgeqe_engine/video.py +423 -0
  73. package/py/forgeqe_mobile/hyperexecute.py +1 -1
  74. package/py/forgeqe_mobile/maestro.py +1 -1
  75. package/py/forgeqe_tosca/vendored.py +3 -2
  76. package/dist/web/assets/Browse-B3YI1MeV.js +0 -2
  77. package/dist/web/assets/Chat-K3kp-ji2.js +0 -3
  78. package/dist/web/assets/Desktop-Drj-7jBV.js +0 -1
  79. package/dist/web/assets/Record-Yw-SGwQ9.js +0 -2
  80. package/dist/web/assets/Tosca-DTWwUJBW.js +0 -3
  81. package/dist/web/assets/desktopAppPath-CMac6aJ0.js +0 -1
  82. package/dist/web/assets/filters-B4VDnWbr.js +0 -1
  83. package/dist/web/assets/frame-D-hqu7Oi.js +0 -4
  84. package/dist/web/assets/index-CtX74khE.js +0 -45
  85. package/dist/web/assets/index-DUf5ddb0.css +0 -2
@@ -177,6 +177,12 @@
177
177
  <p><strong>Step verdicts.</strong> When the goal came from a test case with steps, <code>CASE_REPORT_INSTRUCTION</code> goes into the system prompt and <code>output_model_schema=CaseReport</code> makes the engine library's <code>done</code> action return <code>{summary, steps: [{step, status, actual}]}</code>; <code>history.structured_output</code> becomes <code>case_report</code> in the result. If the Agent rejects the schema, the run continues without it.</p>
178
178
  <p><strong>Finishing and the judge.</strong> <code>_GOAL_VERIFICATION_SYSTEM_MESSAGE</code> is added to every agent's system prompt: <code>done</code> with success only when every field holds exactly what the goal asked for (pre-filled or extra values in multi-value fields removed), every setting the goal names is applied through the page's own controls and shown by the page, and findings are read from the page, items a list already shows are read from it in one step, and a tab that looks blank right after opening is still loading. The engine library's judge (<code>use_judge</code>) is off by default: <code>browser.judge: true</code> (passed to the engine as its judge setting) or <code>FORGEQE_ENGINE_USE_JUDGE=1</code> turns it on, and it then makes one model call over the steps and screenshots. It was turned off because it failed completed runs whose answer came from one screenshot (five result scores) instead of one step per item, and ForgeQE's agent then retried with ever stricter goals. When the agent says success and the judge's verdict is false, the run fails with the judge's <code>failure_reason</code> ahead of the agent's report; the verdict goes into <code>run.json</code> as <code>judge</code>. A judge call that errors leaves the agent's result as it was.</p>
179
179
  <p><strong>Window and video.</strong> <code>window_launch_kwargs</code> sizes a local browser from <code>browser.viewport</code>: the page when headless, the window with <code>browser.window: viewport</code>. Otherwise a visible window opens screen-sized (the engine library's default) and, before the first page, <code>maximize_window</code> sets <code>windowState: maximized</code> over CDP. With <code>browser.video</code> on (the default), the browser is started before the replay or the agent, and <code>start_video</code> starts the library's recording watchdog on <code>&amp;lt;run&gt;/video.mp4</code>; <code>stop_video</code> finishes it before the browser closes, and <code>run_with_events</code> adds it to the run's files. The watchdog encodes Chrome's screencast frames at 30 fps as they arrive, so the video's timing follows how often the page repaints, not the clock. The encoder (<code>browser-use[video]</code>: imageio with ffmpeg, numpy) is installed with the engine, and added to an engine set up before it. The report lists <code>video.mp4</code> among the run's files and plays it on the Artifacts tab.</p>
180
+ <p><strong>Videos of recordings, replays and desktop runs.</strong> These have no browser-use agent, so <code>py/forgeqe_engine/video.py</code> makes their videos itself, with the ffmpeg that the pinned <code>imageio-ffmpeg</code> ships inside the package. It finds that binary in the package's own <code>binaries</code> folder, never on PATH or through <code>IMAGEIO_FFMPEG_EXE</code>, and starts it with an argument list and system settings only. Frames reach ffmpeg on stdin as raw RGB of a fixed size, letterboxed when a picture's size changes, so nothing a page shows reaches its command line. <code>FrameVideo</code> writes in real time at 5 fps, repeating the latest picture while nothing changes, and stops after an hour. A video that could not be finished is removed.</p>
181
+ <ul>
182
+ <li><em>Recording by hand</em> (<code>browser.video</code>): <code>recordsession.py</code> runs the page's screencast over its own DevTools connection, follows the tester from tab to tab, and holds the video while the recording is paused. The file is <code>&amp;lt;run&gt;/video.mp4</code>. Making a typed value a secret in the review removes the recording's videos, since a value cannot be taken out of a video's pictures.</li>
183
+ <li><em>Replays</em> (the <code>forgeqe code</code> replay check, and a recording's re-runs on the Record page): the Playwright runner keeps screencast frames as <code>&amp;lt;ms&gt;.jpg</code>, at most one per tenth of a second, plus a closing screenshot so the video lasts as long as the replay. <code>python -m forgeqe_engine video</code> turns them into <code>replay/&amp;lt;setup&gt;.mp4</code> (<code>src/engine/video.ts</code>) and the frames are removed. A re-run keeps only its last pass's video, as <code>tries/video.mp4</code>. Steps played in a person's own tab (a block) are never filmed; the recording's own video already shows them.</li>
184
+ <li><em>Desktop runs</em> (<code>desktop.video</code>, default on): <code>serve</code> films the main screen with Pillow's <code>ImageGrab</code> while a replay, explore or recording runs, and finishes <code>&amp;lt;run&gt;/video.mp4</code> before <code>run.json</code> is written, so the desktop report plays it. A computer whose screen cannot be read (no display, or macOS without Screen Recording permission) runs without a video and says so.</li>
185
+ </ul>
180
186
  <p><strong>Browser profile.</strong> At the end of the first step (or before writing a trust-mode replay), <code>browser_profile</code> reads how the browser was set up: the engine's driver, channel and executable, headless, the default switches removed, extra HTTP headers (none), <code>Browser.getVersion</code>, and from the page <code>navigator.userAgent</code>, <code>navigator.webdriver</code>, language, time zone, and viewport. It goes into <code>run.json</code> as <code>browser</code>, and the handoff shows it so the coding agent can compare its test's browser with it.</p>
181
187
  <p><strong>Timeline.</strong> <code>build_timeline</code> writes <code>steps.json</code> from the history (and the replayed steps): URL, title, the model's evaluation, memory and next goal, each action with its error, start time (<code>t0</code>) and duration, the part of it spent waiting for the model (<code>model_ms</code>, from wrapping <code>llm.ainvoke</code> and overlapping the calls with the step's <code>step_start_time</code>/<code>step_end_time</code>), and a JPEG of the page (max 1280 wide) under <code>steps/</code>, subject to <code>report.screenshots</code>. Each action on an element carries <code>box</code>: the element's <code>absolute_position</code> from the DOM snapshot the model saw, minus the page's scroll, as fractions of the viewport, so the report can outline it on that step's screenshot. Timeouts, stops, and crashes still write it from the partial history.</p>
182
188
  <p><strong>Diagnostics.</strong> <code>Diagnostics</code> registers <code>Runtime.consoleAPICalled</code>, <code>Runtime.exceptionThrown</code> and <code>Log.entryAdded</code> on the engine library's CDP client (cdp-use allows one handler per event, and the engine library's own watchdogs don't use these three; <code>Network.responseReceived</code> belongs to the downloads watchdog, so failed and slow requests come from the page's resource timing entries, <code>responseStatus</code> and duration, at each sample). It samples at every step start and end and after each replayed step. Each new page (by URL without the hash, up to 25) is checked once: <code>Accessibility.getFullAXTree</code> for unnamed buttons, links, fields and images, heading order and the document title, plus a page script for <code>lang</code>, text contrast (WCAG ratios, skipping text over images) and zoom-blocking viewports, with up to five examples each from <code>DOM.getOuterHTML</code>. A request counts as slow from 3 s. <code>assign_problems</code> attaches each event to the step it happened in (by <code>t0</code>), at most 25 per step; <code>run.json</code> gets the totals as <code>diagnostics</code>, and the pages go to <code>accessibility.json</code>. <code>report.accessibility: false</code> skips the page checks.</p>