Deliver reliable sourced material checkpoints #193

Merged
weichen merged 75 commits from feature/fast-slow-u2-u3 into main 2026-10-19 09:26:50 +00:00
Owner

Summary

Uploaded materials get immediate fast-channel feedback and one background task card. The r0.4 path asks the material worker to publish one sourced fact first, searches only the current task's exact attachments when needed, and shows a deliverable choice only after a completed result has real suggestions. Incomplete tool streams fail safely. The follow-up 0637547 correction persists returned Usage on a failed child run, including a missing-total terminal after earlier turns.

Evidence

  • Mechanism: Backend 0637547 passed run 3079 (vet-and-test, trusted home-runner, all steps). The independent accounting review references read-only mixed-turn and SQLite replay; local red/green receipts remain in the task card.
  • Real-model quality: The single authorized r0.4 A01 at fixed Dev d38dbdc / Backend 37e2cb7 used two paid run IDs and 29,062 returned Usage tokens. The child tool stream was rejected before any tool or checkpoint was saved; no final organized answer exists. The fast response also asserted an unsupported dependency-to-phase relationship. Quality FAIL. The original SQLite/result underreported the failed child's 7,148 tokens; the later code fix does not rewrite that sample or establish model quality on the new head.

Merge Danger

Door: two-way

Blast Radius: material workflow and Usage accounting

Keep this PR draft. The A01 failure requires a reviewed design correction and a separately authorized new model trial; stage-7 acceptance and merge are not complete. See Dev PR #512, Documents PR #95, Agent-Native PR #46, and Agent-Squad PR #53.

## Summary Uploaded materials get immediate fast-channel feedback and one background task card. The r0.4 path asks the material worker to publish one sourced fact first, searches only the current task's exact attachments when needed, and shows a deliverable choice only after a completed result has real suggestions. Incomplete tool streams fail safely. The follow-up `0637547` correction persists returned Usage on a failed child run, including a missing-total terminal after earlier turns. ## Evidence - **Mechanism:** Backend `0637547` passed [run 3079](https://git-home.u1680832.nyat.app:30319/weichen/Agent-System-Backend/actions/runs/3079) (`vet-and-test`, trusted home-runner, all steps). The [independent accounting review](https://git-home.u1680832.nyat.app:30319/weichen/Agent-System-Dev/src/branch/feature/fast-slow-u2-u3-plan/.task/feature-fast-slow-u2-u3-plan.md) references read-only mixed-turn and SQLite replay; local red/green receipts remain in the task card. - **Real-model quality:** The single authorized r0.4 A01 at fixed Dev `d38dbdc` / Backend `37e2cb7` used two paid run IDs and 29,062 returned Usage tokens. The child tool stream was rejected before any tool or checkpoint was saved; no final organized answer exists. The fast response also asserted an unsupported dependency-to-phase relationship. **Quality FAIL.** The original SQLite/result underreported the failed child's 7,148 tokens; the later code fix does not rewrite that sample or establish model quality on the new head. ## Merge Danger **Door:** two-way **Blast Radius:** material workflow and Usage accounting Keep this PR draft. The A01 failure requires a reviewed design correction and a separately authorized new model trial; stage-7 acceptance and merge are not complete. See [Dev PR #512](https://git-home.u1680832.nyat.app:30319/weichen/Agent-System-Dev/pulls/512), [Documents PR #95](https://git-home.u1680832.nyat.app:30319/weichen/Agent-System-Documents/pulls/95), [Agent-Native PR #46](https://git-home.u1680832.nyat.app:30319/weichen/Agent-Native/pulls/46), and [Agent-Squad PR #53](https://git-home.u1680832.nyat.app:30319/weichen/Agent-Squad/pulls/53).
weichen added 22 commits 2026-10-13 06:40:20 +00:00
Why: compile the work projection against the reviewed Core vocabulary.

Evidence: exact local Core task commit materialized; no backend behavior changed in this dependency step.

Impact: Core gitlink only.

Refs: U2/U3 Task1
Why: equal-length edits and parser changes must not reuse prior results.

Evidence: content identity and provided-source tests RED to GREEN; backend suite recorded through evidence.

Impact: trusted optional document origins, content keys and source catalog; no new routing or DB schema.

Refs: U2/U3 Task2
Why: Background work needs consistent cards, events, and user reading state.

Evidence: SELF make evidence records SQLite rollback, projection, pin, and regression checks; PostgreSQL replay is pending the composition gate.

Impact: Adds an optional atomic task path and a consistent card replay cursor without schema changes.

Refs: Agent-System-Dev fast-slow-u2-u3 plan Task 3
Why: Queued work and completed results need stable identity, execution fencing, and honest recovery.

Evidence: SELF make evidence records four-task promotion, restart reconciliation, stale-executor fencing, and existing material/notice tests.

Impact: Uses namespaced existing execution leases and canonical atomic task updates; legacy results require trusted input bindings before reuse.

Refs: fast-slow-u2-u3 Tasks 2 and 4
Why: Real source-backed discoveries should reach the same task card before the slow channel completes.

Evidence: SELF receipts record runtime and manager checkpoint red-green tests, scoped source/version checks, privacy filtering, quota corrections, and SQLite/PG regressions; fixed composition and live comparison follow.

Impact: Adds a local material-only checkpoint sink with no summary model calls, uses version witnesses for source commits, and preserves existing reading and notification paths.

Refs: fast-slow-u2-u3 Tasks 6 and 7; test-only live HTTP harness bounds shared provider requests without approving HITL
Why: The live harness must use the actual client constructor and preserve MiniMax reasoning separation.

Evidence: SELF live-tag compilation passes without provider calls.

Impact: Test harness only; no production route changes.

Refs: fast-slow-u2-u3 Task 7
Why: Updated or missing sources must remain visible as limitations, and comparison calls need stable prompt grouping.

Evidence: SELF card/server suites and live-tag compilation pass.

Impact: Adds neutral source limitations and refines test-only provider accounting.

Refs: fast-slow-u2-u3 Tasks 6 and 7
Why: Baseline and candidate must exercise their actual default prompts with identical route and resource limits.

Evidence: SELF live-tag compilation passes.

Impact: Evaluation harness only; normal automatic notice quality remains outside the controlled comparison.

Refs: fast-slow-u2-u3 Task 7
Why: Opening a processed source must not show changed current bytes as the quoted version.

Evidence: SELF TaskSourceContent regression fails before and passes after expected-hash enforcement; artifact regressions and live compilation pass.

Impact: Optional content hash narrows the existing authorized artifact read; controlled fixtures select a genuinely provided quotation.

Refs: fast-slow-u2-u3 source-version acceptance
Why: Text with short attachments previously completed without starting the intended background material task.

Evidence: SELF real HTTP/browser reproduction shows the absent second task; runtime, manager and server regressions pass with the existing optional port connected.

Impact: Preserves dispatch timing and makes deferred intake observable; comparison records the baseline gap without rerunning a sample.

Refs: fast-slow-u2-u3 A02 and reading acceptance
Why: Delayed notices, plugin name collisions and startup recovery exposed stale sources or silently created new attempts; deletion lost search index cleanup.

Evidence: Meaningful red regressions and the corrected complete Backend suite passed; production startup was exercised through an isolated subprocess.

Impact: Revalidate notices at delivery, retain plugin dispatch, restore index cleanup and complete all service wiring before recovery and public intake. Scope fixture processes and wait for owned transcript writes.

Refs: Agent-System-Dev feature-fast-slow-u2-u3-plan; independent review findings 1-3 and startup supplement
Why: The first real-model sample batched discoveries, overcalled scope differences and exposed process chatter as a terminal conclusion.

Evidence: Preserve the failed A01 sample; process-text regression failed before the fix, then complete Backend and focused runtime checks passed.

Impact: Bump recipe identity, qualify quantities and approvals, exclude Process parts from canonical results and capture independent historical evaluation snapshots.

Refs: Approved U2/U3 plan; independent model review and native SELF receipts
Why: Authentic quotes do not establish an unstated approval, and the evaluation wrapper must honor tighter production output limits.

Evidence: Approval-overstatement and 780-token-cap regressions failed first; complete Backend suite and fixture cap checks now pass.

Impact: Render material records from trusted labels and validated quotations, reserve interpretation for explicit finding kinds, bump recipe identity and cap the fixture without overriding smaller limits.

Refs: Approved R05; independent model assessment; original failed samples preserved
Why: A budget-stopped task retained a promise to generate a final result, while readable card errors need the full diagnosis in the execution record.

Evidence: Continuation-promise and missing-error-record regressions failed on the prior implementation; the full Backend suite now passes.

Impact: Terminal next steps require user action, stopped work has clear labels, and precise subagent errors persist outside the default task summary.

Refs: Independent A04 model assessment; approved R08 and R10
Why: A reconciled task must not retain the old queue or running next step after becoming interrupted.

Evidence: Owned queue recovery failed before the fix; RunMgr, actual App startup and evaluation output-cap checks now pass.

Impact: Recovery uses the stopped-task next step, and the mechanism fixture quotes the actual acceptance source text.

Refs: Approved recovery contract; independent terminal-state review
Why: The user approved one additional A01 sample after the original six-case batch failed its quality gate.

Evidence: Live fixture tests preserve the production output cap and reject paid requests when a third actual run exists.

Impact: Evaluation-only case selection and resource guard; no production behavior changes, no automatic replay.

Refs: User approval 2026-10-13; reported token target 60000
Why: The failed extra A01 had no accepted findings but claimed saved discoveries and future progress.

Evidence: The zero-findings regression failed before the fix; full RunMgr tests now pass.

Impact: Use truthful conclusion, remaining and next-step text while retaining strict source validation.

Refs: Independent extra A01 assessment; approved R08
Why: Resolve the component conflict using the tested combined Core lineage.

Evidence: Both exact Core histories are included in beafd753; no source conflict in App or Server.

Impact: Preserve TaskSnapshot and upstream managed settings/session checks; composition replay follows.

Refs: Core beafd753; Backend main 741da4a0
Why: Upstream now reserves model and mock settings for system authority.

Evidence: Complete merged Backend suite and live resource/cap guards pass.

Impact: Fixture-only startup configuration, same effective route and profile; no further paid calls.

Refs: Upstream scoped settings contract; U2/U3 evaluation
Merge current account hardening into work checkpoint branch
ci / vet-and-test (pull_request) Successful in 46s
0bc4b0f794
Why: Preserve the newest protected main for the combined review candidate.

Evidence: Exact incoming object fetched; affected checks will replay.

Impact: Retain both histories without relaxing source or task authority.

Refs: Dev main aa6364f
weichen added 2 commits 2026-10-13 06:53:57 +00:00
Why: Retain the newest protected Backend main alongside the approved work branch.

Evidence: Exact upstream object fetched; affected checks follow.

Impact: Preserve both histories and review the new model-tool guidance as a separate delta.

Refs: Agent-System-Dev U2/U3 delivery
Guide smaller source-literal checkpoint publications
ci / vet-and-test (pull_request) Successful in 52s
e1c994c60c
Why: The bounded A01 model call produced a five-finding malformed payload and an abbreviated quote that strict validation correctly rejected.

Evidence: Full Backend suite passed; original paid failure and rejected source citations remain unchanged.

Impact: Advertise one to three findings per publication and continuous literal quotes, bumping material recipe identity to v7; Core authority and budget remain unchanged.

Refs: U2/U3 failed A01 assessment and proposed bounded follow-up
weichen added 1 commit 2026-10-13 07:20:30 +00:00
Bound the approved follow-up A01 evaluation
ci / vet-and-test (pull_request) Successful in 50s
7f8674fe68
Why: The prior one-shot A01 result failed and its resource approval is exhausted.

Evidence: Follow-up authorization tests failed before the change and pass after; full Backend suite passes.

Impact: Only live evaluation harness gains a separate one-shot result and 30000-token run budget; production validation remains strict.

Refs: Agent-System-Backend#193; Agent-System-Dev#512
weichen added 1 commit 2026-10-13 07:42:18 +00:00
Count persisted checkpoints in live evaluation
ci / vet-and-test (pull_request) Successful in 51s
51d7c6ab87
Why: A 250ms card poll missed a checkpoint saved about one millisecond before failure.

Evidence: The persistence regression failed before the fix, passed afterward, and independent read-only replay isolated the current conversation and running state.

Impact: Evaluation reads committed card events without changing model output or re-running the paid sample; U3 quality remains failed.

Refs: Agent-System-Backend#193; Agent-System-Dev#512
weichen added 1 commit 2026-10-13 08:02:16 +00:00
Stop live evaluation after rejected checkpoints
ci / vet-and-test (pull_request) Successful in 49s
71fc384154
Why: An approved one-shot sample continued to a paid model call after a nonliteral quote was rejected, contrary to its stop rule.

Evidence: A zero-paid provider fixture failed before the guard and passed afterward; the original 14231-token deviation remains recorded.

Impact: Future controlled evaluations refuse subsequent provider requests after a checkpoint tool error; this does not reclassify the failed sample.

Refs: Agent-System-Backend#193; Agent-System-Dev#512
weichen added 1 commit 2026-10-13 08:13:33 +00:00
Enforce the evaluation stop rule across runs
ci / vet-and-test (pull_request) Successful in 2m26s
f74f6a010e
Why: A rejected checkpoint did not stop a later paid request, and a history-only fix could miss JSON errors or other active runs.

Evidence: Source and JSON rejection fixtures failed before the instance-level guard, then passed with fail-closed and unrelated-tool checks; independent replay matched both real failed databases.

Impact: Read-only event correlation blocks future provider requests after a checkpoint rejection; original sample failure and stop-rule deviation remain recorded.

Refs: Agent-System-Backend#193; Agent-System-Dev#512
weichen added 6 commits 2026-10-13 11:00:49 +00:00
Why: The old source index repeated most of a three-document input and its test fixture depended on that duplicate layout.

Evidence: Source prefix, ID scope, parser revision, table, truncation and mechanism tests failed before the change and pass after; full runmgr tests pass.

Impact: Compact the material prompt without widening quote authority, and version the recipe so old results are not reused.

Refs: Agent-System-Backend#193; Agent-System-Dev#512
Why: A source-valid analysis in the approved A01 sample promoted a requirement into an approved decision.

Evidence: The observed claim and six display fields failed before the guard, then passed with negative/question and mixed-clause regressions; full runmgr tests passed.

Impact: Keep exact material records while rejecting model-authored affirmative approval assertions before persistence; final model quality remains unverified.

Refs: Agent-System-Backend#193; Agent-System-Dev#512
Why: Material runs could spend the remaining budget on checkpoints and leave no final response.

Evidence: go test ./... -count=1; go test -race ./internal/runtime -run TestMaterialFinalReserve -count=1; offline replay of the prior A01 usage boundary.

Impact: Material subagents enter final-only mode or stop before another provider request; ordinary subagents retain their existing behavior.

Refs: U3 quality revision r0.2, Task 4
Why: Main advanced its account search and embedded Core contracts while the U3 candidate remained in review.

Evidence: go test ./... -count=1 on the merged working tree; Core, UI and Frontend merged tests passed separately.

Impact: Preserve the U3 work and account search while pinning the merged Core contract.

Refs: U3 quality revision r0.2, Dev task-sync conflict
Why: The isolated fixture passed integer settings to a float64-only reader, so the intended output cap and retry policy were ineffective.

Evidence: numeric-settings regression failed before and passed after; go test ./... -count=1 and live-tag fixture tests passed.

Impact: Mechanism and future explicitly approved model evaluations use their stated per-call output cap and disabled retries.

Refs: U3 quality revision r0.2, browser mechanism failure
Preserve valid checkpoint claims and evaluator run identity
ci / vet-and-test (pull_request) Successful in 45s
9126daed90
Why: Independent review found false approval rejections, duplicate checkpoint counting and final-only reminder changes to evaluator grouping.

Evidence: Three focused regressions failed before fixes and passed after; go test ./... -count=1, race and live-tag fixture checks passed.

Impact: Valid questions and denials persist, only distinct checkpoint IDs count, and final-only requests keep their original run fingerprint.

Refs: U3 quality revision r0.2, independent final review
weichen changed title from [WIP] Persist source-bound work through recovery and result delivery to [WIP] Persist sourced work and reserve a final answer 2026-10-13 11:03:11 +00:00
weichen added 1 commit 2026-10-13 11:11:25 +00:00
Reserve a distinct one-shot A01 evaluation label
ci / vet-and-test (pull_request) Successful in 45s
d89c72e018
Why: Reusing an exhausted authorization label would overwrite or misattribute the next controlled quality sample.

Evidence: New label/output and 30000-token guarded-run tests failed before implementation and passed after; full Backend Go suite passed.

Impact: The r0.2 A01 harness can be used only after separate resource approval, with an independent output name and existing two-run guard.

Refs: U3 quality implementation plan r0.2, Task 6 preparation
weichen added 1 commit 2026-10-13 15:29:20 +00:00
Bind evaluation budgets to actual run IDs
ci / vet-and-test (pull_request) Successful in 1m2s
062b6f5af5
Why: One paid A01 run split into multiple prompt-fingerprint groups, and persisted Usage omitted real checkpoint tool calls.

Evidence: Stable-run grouping, missing-ID refusal and tool-call usage regressions failed before and passed after; full Go, race and live-fixture checks passed.

Impact: Future controlled evaluations count per-run calls and deadlines by host run identity and persist tool-call usage. The failed r0.2 A01 record is unchanged.

Refs: U3 r0.2 A01 independent replay, Task 6
weichen added 11 commits 2026-10-13 18:08:45 +00:00
Why: The current main adds private project member event handling that must coexist with U3 task projections.

Evidence: Resolved cardsvc and SSE conflicts; corrected atomic project-event proof placement after a compile RED; go test ./... -count=1 passed.

Impact: Preserve both private project visibility and task checkpoint behavior; no real-model rerun.

Refs: Backend PR #193; Dev task feature/fast-slow-u2-u3-plan
Why: The r0.2 model sample assigned interface-dependent requirements to a phase without source support.

Evidence: New source-count and set-bound tests failed before implementation; budget-item and internal-size regressions failed then passed; go test ./... -count=1 passed.

Impact: Add a pure, conservative normalizer and pin Core c722c16; no checkpoint submission or provider behavior changes yet.

Refs: Dev task feature/fast-slow-u2-u3-plan; r0.3 evidence implementation plan Task 2
Why: Valid but underdetermined model claims must become pending without losing the batch or leaking unsupported status text.

Evidence: Mixed-batch, source-input binding, approval-status, tool-receipt and prompt regressions failed before changes; go test ./... -count=1 and selected live-tag fake-provider tests passed.

Impact: Validate all task-bound sources, normalize once, return a safe receipt, and version material processing as v9; no extra provider call.

Refs: Dev task feature/fast-slow-u2-u3-plan; r0.3 evidence implementation plan Task 3
Why: The generated TypeScript mirror must keep evidence helpers private to the module.

Evidence: Backend go test ./... -count=1 passed with Core b474394; frontend knip fix verification follows after regeneration.

Impact: Nested Core gitlink only; no runtime semantic change.

Refs: Backend PR #193; Dev task feature/fast-slow-u2-u3-plan
Why: Browser-level U3 validation must render a real host-normalized needs_user finding, not only source records.

Evidence: The new Playwright assertion failed against the previous fixture; selected live-tag mechanism and stop-rule tests pass.

Impact: Test-only fake stream adds an unsupported membership claim with source-indexed premises; no provider call.

Refs: Dev task feature/fast-slow-u2-u3-plan; r0.3 plan Task 4
Why: Independent review found negated short quotes, cross-project counts and unstructured batch placement could be shown as facts.

Evidence: Each counterexample failed before repair; Backend go test ./... -count=1 and selected live-tag mechanism/stop tests passed after repair.

Impact: Require unambiguous source sentence context and matching explicit scopes, keep only cautious ordinary analysis without structured evidence, neutralize unsafe status text.

Refs: Dev task feature/fast-slow-u2-u3-plan; r0.3 review P1 findings
Why: Independent re-review found single-word decision quotes, project-prefix scope mixing, revoked totals and approval status bypasses.

Evidence: Each new counterexample failed before repair; Backend go test ./... -count=1 and selected live-tag fake-stream tests passed after.

Impact: Display complete visible source sentences, parse only bounded positive count clauses, and set material progress text from the host phase.

Refs: Dev task feature/fast-slow-u2-u3-plan; r0.3 second review Important findings
Why: Independent review showed a truncated visible prefix, revised count and same-source shortcut could still produce unsupported claims.

Evidence: Each counterexample failed before repair; positive same-named scope, Backend go test ./... -count=1 and live-tag fake-stream tests passed after.

Impact: Require a visible sentence boundary or complete block, reject unrecognized count/revision segments, and require explicit common scope for unique membership.

Refs: Dev task feature/fast-slow-u2-u3-plan; r0.3 third review Important findings
Why: The fourth independent review found extra short quotes in direct relations and stale counts revised with an unfamiliar unit.

Evidence: Both inputs failed before repair; Backend full Go and selected no-paid live-tag mechanism tests passed after.

Impact: Direct relations accept one complete source, and count proof rejects unsupported numeric segments while preserving the bounded A01 grammar.

Refs: Dev task feature/fast-slow-u2-u3-plan; r0.3 fourth review Important findings
Why: A model could put an affirmative approval before a late caution word and have the unsupported claim shown as analysis.

Evidence: Approval-behind-caution and task-prompt tests failed before repair; Backend full Go and no-paid live-tag mechanism suites passed after.

Impact: Keep a small set of cautious qualitative findings, replace all other free analysis with pending, clear model ancillary prose and bump material recipe to v10.

Refs: Dev task feature/fast-slow-u2-u3-plan; r0.3 fifth review Important finding
Reserve a distinct r0.3 A01 evaluation entry
ci / vet-and-test (pull_request) Successful in 45s
5f834544b0
Why: A future separately approved model trial must not reuse the consumed r0.2 label or overwrite its raw result.

Evidence: New label/output and 30000-token guard tests failed before implementation, then selected live-tag tests and Backend full Go suite passed.

Impact: Zero-paid evaluation entry only; its name does not grant resource approval or issue provider requests.

Refs: Dev task feature/fast-slow-u2-u3-plan; r0.3 plan Task 5
weichen changed title from [WIP] Persist sourced work and reserve a final answer to [WIP] Verify source-backed stage judgments before publication 2026-10-13 18:20:36 +00:00
weichen added 5 commits 2026-10-14 03:12:33 +00:00
Why: wrapper-side tool deltas raced with serialized run events and could disappear under load.

Evidence: TestToolCallDeltaBeforeExecution race reproduced on the old path, then passed ten race runs with Agent-Native e86e74b; full Backend vet and tests pass.

Impact: one owner emits conversation events; Backend pins the Agent-Native event identity contract.

Refs: Agent-Native PR #46; internal/runtime/llm_direct.go
Why: combined filename and Chinese-keyword queries returned no hits even when the uploaded material was present, delaying useful background findings.

Evidence: combined-query, owner/project, duplicate, resource-policy, version-drift and excerpt RED→GREEN tests; SQLite and isolated PostgreSQL pass; Backend full vet and tests pass with the Agent-Native pin.

Impact: only a no-hit material subagent query may read a verified current-task attachment snapshot; general knowledge retrieval remains unchanged.

Refs: U3 r0.4 design; internal/runmgr/material_retrieve.go
Why: the background model spent its first turns searching already provided text and failed before saving any staged finding.

Evidence: first-finding and two-phase RED→GREEN tests; SQLite and isolated PostgreSQL pass; full Backend vet and tests pass; v11 prompt grew 337 UTF-8 bytes in the fixed fixture.

Impact: material recipe v11 asks for one short sourced fact before optional search without changing the checkpoint schema or adding a separate model call.

Refs: U3 r0.4 design; internal/runmgr/material.go
Why: failed or ungrounded material notices still asked nontechnical users to choose deliverables and could act on invented model options.

Evidence: failure, partial, no-suggestion, forged-marker, source-drift, reload and host-option RED→GREEN tests; race, isolated PostgreSQL, full Backend vet and tests pass.

Impact: only a completed source-bound result with 3-4 bounded suggestions can offer a choice; failed or stale notices preserve truthful status and block unsolicited delegation.

Refs: U3 r0.4 design; internal/runmgr/material_notice.go; internal/runtime/material_choice_notice.go
Stop evaluation after an incomplete provider terminal
ci / vet-and-test (pull_request) Successful in 53s
efed68ca2c
Why: the controlled A01 wrapper still allowed another paid request after a malformed tool terminal with returned Usage.

Evidence: local SSE RED→GREEN tests cover invalid JSON, missing DONE, late errors, missing Usage, rejected checkpoints, cross-run stop and record-write failure; live-tag fake tests and full Backend vet/tests pass.

Impact: diagnostic metadata and batch-wide fail-closed stop only; no new paid authorization or production route change.

Refs: U3 r0.4 design; internal/server/work_checkpoint_eval_test.go
weichen added 1 commit 2026-10-14 03:24:38 +00:00
Align Agent-Squad dependency with stream guard
ci / vet-and-test (pull_request) Successful in 50s
8ea9a6e788
Why: The Dev pin gate requires every Agent-Native consumer to use the same exact commit; Agent-Squad now pins the U3 r0.4 stream guard.

Evidence: GOWORK=off go vet ./... && GOWORK=off go test -count=1 ./... passed with this pin.

Impact: Backend dependency gitlink only; no source or public contract change.

Refs: Agent-Squad PR #53; U3 r0.4 Task 6
weichen added 1 commit 2026-10-14 03:34:29 +00:00
Exercise material notice outcomes in the browser fixture
ci / vet-and-test (pull_request) Successful in 1m3s
726e4a6d2e
Why: The task-owned mechanism must reproduce stage progress, partial and empty failures, and source-bound choices without a paid provider call.

Evidence: Backend vet/full Go tests and live-tag terminal tests passed; six task-owned HTTP/Playwright cases passed with this fixture.

Impact: Evaluation fixture only; model comparison still disables notice turns unless the explicit mechanism browser flag is set.

Refs: U3 r0.4 Task 6
weichen added 1 commit 2026-10-14 03:57:34 +00:00
Close U3 review gaps before provider continuation
ci / vet-and-test (pull_request) Successful in 50s
583c074aa4
Why: Missing Usage must stop a paid sequence before a tool terminal is executable; exact attachment names and host-owned choices must also remain reliable.

Evidence: Each reported behavior had a failing regression before its fix. Full Backend vet/Go tests, live-tag budget tests, ten race replays, and six task-owned HTTP/Playwright scenarios passed with the aligned Agent-Native and Agent-Squad pins.

Impact: Evaluation terminal accounting becomes durable before delivery; material fallback matches bounded filenames; ready choices use host options without redundant model fields. No new model calls or budget authorization.

Refs: U3 r0.4 independent review Critical 1 and Important 3-4
weichen changed title from [WIP] Verify source-backed stage judgments before publication to [WIP] Deliver reliable sourced material checkpoints 2026-10-14 04:00:56 +00:00
weichen added 1 commit 2026-10-14 04:12:41 +00:00
Pin the complete stream terminal guard
ci / vet-and-test (pull_request) Successful in 45s
e8cd0a45d7
Why: Backend and Agent-Squad must consume the Agent-Native revision that rejects empty tool_calls and function_call terminals.

Evidence: Full Backend vet and Go test suite passed with both exact gitlinks.

Impact: Dependency gitlinks only; no Backend source change.

Refs: Agent-Native PR #46; Agent-Squad PR #53; U3 r0.4 review closure
weichen added 1 commit 2026-10-14 05:05:02 +00:00
Merge current Backend main into U3 candidate
ci / vet-and-test (pull_request) Successful in 46s
549798c0a0
Why: Preserve the accepted U7 account transaction and identity safeguards while retaining U3 material checkpoint startup ordering and runtime fixes.

Evidence: The shared app.go edits are in separate startup/account-maintenance sections; full Go and parent composition checks will be rerun after this merge.

Impact: Includes mainline account changes without changing U3 public contracts or model-call budget.

Refs: U3 r0.4 resource-preparation sync; Dev main 05b997b
weichen added 1 commit 2026-10-14 05:23:57 +00:00
Add one-shot U3 r0.4 A01 evaluation label
ci / vet-and-test (pull_request) Successful in 46s
37e2cb7adb
Why: The separately approved r0.4 trial must use its own bounded authorization label and output file, without reusing exhausted r0.3 artifacts.

Evidence: Both new label tests failed before the change and passed afterward; full Backend vet/Go suite and selected zero-paid live-tag budget/evaluation tests passed. No real provider call was made.

Impact: Evaluation-only selector and output name; production model routing, budgets and runtime behavior unchanged. Trial remains gated on fixed Dev CI and preflight.

Refs: U3 r0.4 one-time A01 resource approval in this conversation; Dev PR #512
weichen added 1 commit 2026-10-14 05:48:08 +00:00
Account failed subagent terminal usage
ci / vet-and-test (pull_request) Successful in 52s
61625c609f
Why: A01 returned paid Usage on a rejected tool terminal, but the failed child run persisted zero because the runtime did not emit message_end.

Evidence: RED then GREEN for failed-terminal and persisted-child regression tests; SELF receipt /tmp/fast-slow-u3-r04-20261014/usage-fix-backend-verification.json records vet, full tests, and zero-paid live-tag checks.

Impact: Reconcile the returned cumulative Usage before persisting a failed child run; preserve actual tool-call counts. The original A01 quality result remains FAIL.

Refs: U3 r0.4 A01; /tmp/fast-slow-u3-r04-20261014/A01-independent-assessment.md
weichen added 1 commit 2026-10-14 05:54:46 +00:00
Count omitted totals after successful subagent turns
ci / vet-and-test (pull_request) Successful in 47s
0637547cc5
Why: A failed terminal without total_tokens can follow a successful tool turn, leaving the cumulative reported total stale even though prompt and completion include both turns.

Evidence: Mixed-turn persisted child test failed before the correction and passed after; SELF receipts usage-fix-mixed-turn-red-diagnostic.json, usage-fix-mixed-turn-green.json, and usage-fix-mixed-turn-full.json.

Impact: Reconcile against the larger of cumulative total or prompt-plus-completion while preserving cache and tool counts. No real-model sample was rerun.

Refs: U3 r0.4 A01; independent review /tmp/fast-slow-u3-r04-20261014/usage-fix-independent-review.md
weichen added 2 commits 2026-10-14 08:29:36 +00:00
Why: The first material reply could stream an unsupported numeric relationship before the sourced background card had any verified finding.

Evidence: Task 2 red/green SQLite run tests cover parent provider suppression, queue/reuse, completed source binding, focus retention, squad entry, failed/unknown state, and attempt ordering; full Backend vet/Go/race SELF receipt /tmp/fast-slow-u3-r05-task2-backend-final-v2.json exited 0.

Impact: Prestarted material sends receive one server-owned status message with zero parent model calls; small-text and explicit completed follow-up paths retain their existing runner. No public contract or model budget increases.

Refs: U3 r0.5 approved design and plan; Backend PR #193
Persist content-free model terminal evidence
ci / vet-and-test (pull_request) Successful in 1m11s
4790e8c260
Why: The controlled A01 record retained raw prompt/tool payload while lacking enough transport classification to explain the rejected tool terminal.

Evidence: TestEvaluationRecordsContentFreeTerminal and error-bearing terminal regressions failed before the change and passed after; full Backend vet/Go and selected zero-paid live-tag SELF receipt /tmp/fast-slow-u3-r05-task3-backend-full.json exited 0.

Impact: Pin Agent-Native 6a1dcdd, retain per-call Usage and safe terminal facts, remove future raw messages/tool declarations/terminal snapshots, and clear tools on an error terminal before forwarding. Historical trial artifacts remain untouched.

Refs: U3 r0.5 approved design and plan; Backend PR #193
weichen added 1 commit 2026-10-14 08:40:30 +00:00
Hold first checkpoint in browser timing fixture
ci / vet-and-test (pull_request) Successful in 4m14s
d862372efe
Why: The safe acknowledgement must be observed before fake findings arrive.

Evidence: Dev evidence receipt for ten browser scenarios and isolated PostgreSQL/Redis tests.

Impact: Changes only the task-owned zero-paid fixture delay.

Refs: U3 r0.5 implementation plan Task 4
weichen added 1 commit 2026-10-14 08:42:12 +00:00
Align Backend Squad pin with terminal observation contract
ci / vet-and-test (pull_request) Successful in 4m20s
bd41302310
Why: The Backend composition must use the same Agent-Native revision through Squad.

Evidence: Dev task receipt for full Backend vet and Go test with pinned dependencies.

Impact: Updates only the Agent-Squad gitlink.

Refs: U3 r0.5 implementation plan Task 5
weichen added 1 commit 2026-10-14 09:07:10 +00:00
Bound provider terminal labels in evaluation records
ci / vet-and-test (pull_request) Successful in 53s
8f5e32dca1
Why: A provider-controlled finish reason could leak arbitrary content into the supposed content-free audit file.

Evidence: Red then green terminal-label regression and full Backend vet/Go test in Dev receipts.

Impact: Only evaluation records map unknown terminal labels to a finite class; tool execution rules are unchanged.

Refs: U3 r0.5 independent review finding
weichen added 1 commit 2026-10-14 09:13:19 +00:00
Exercise queued and failed material intake through HTTP
ci / vet-and-test (pull_request) Successful in 49s
c23239ebae
Why: The stage-6 browser proof must cover the real queued and failed-start user states.

Evidence: Two Playwright paths failed before fixture support, then passed; full Backend vet and Go tests passed.

Impact: Adds only task-owned mechanism fixture behavior under the live test tag.

Refs: U3 r0.5 independent review finding
weichen added 1 commit 2026-10-14 09:28:45 +00:00
weichen added 2 commits 2026-10-19 03:32:52 +00:00
Merge feature/fast-slow-u2-u3 history after syncing with main
governance / governance (pull_request) Successful in 12s
ci / vet-and-test (pull_request) Successful in 1m8s
63c2c227b6
weichen added 1 commit 2026-10-19 03:38:20 +00:00
agent-exec transport ed0695ad06374fcfa0dcd0d20527bd22/94d5f91fcaed
governance / governance (pull_request) Successful in 18s
ci / vet-and-test (pull_request) Successful in 1m26s
611cf1b0f7
weichen added 1 commit 2026-10-19 03:44:39 +00:00
agent-exec transport 3f843a59bf0ba67b5da8afc678b2ae58/c62ed6222ef4
governance / governance (pull_request) Successful in 32s
ci / vet-and-test (pull_request) Successful in 1m41s
5ffbd5c17e
weichen added 1 commit 2026-10-19 03:54:12 +00:00
agent-exec transport ef2206bd1920ebcee5b2c856f366584d/92d3eda9d0d8
governance / governance (pull_request) Successful in 12s
ci / vet-and-test (pull_request) Successful in 1m10s
9bcf1b5efb
weichen added 1 commit 2026-10-19 05:23:59 +00:00
agent-exec transport e9d8f561ca338eeee85c28d94f01421d/875286e54f44
ci / vet-and-test (pull_request) Successful in 1m37s
governance / governance (pull_request) Successful in 19s
f24a6108c0
weichen added 2 commits 2026-10-19 09:25:02 +00:00
Merge feature/fast-slow-u2-u3 history after syncing main
governance / governance (pull_request) Successful in 13s
ci / vet-and-test (pull_request) Successful in 1m11s
f010af2ff4
weichen marked the pull request as ready for review 2026-10-19 09:26:46 +00:00
weichen merged commit 1e019a684f into main 2026-10-19 09:26:50 +00:00
Sign in to join this conversation.
No Reviewers
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: weichen/Agent-System-Backend#193