feat(desktop): integrate compiled React Desktop 2.0 - #776
Open
abraxas914 wants to merge 6 commits into
Open
Conversation
Contributor
|
没有移动数据目录的功能。 |
abraxas914
marked this pull request as ready for review
August 21, 2026 12:04
abraxas914
marked this pull request as draft
August 21, 2026 15:35
abraxas914
force-pushed
the
codex/react-desktop-v2-upstream-final
branch
from
August 22, 2026 11:35
0692c3f to
1d90e27
Compare
abraxas914
marked this pull request as ready for review
August 22, 2026 11:43
abraxas914
force-pushed
the
codex/react-desktop-v2-upstream-final
branch
from
August 22, 2026 19:10
1d90e27 to
aa89f26
Compare
Co-authored-by: yiqi-017 <22300246009@m.fudan.edu.cn>
abraxas914
force-pushed
the
codex/react-desktop-v2-upstream-final
branch
from
August 23, 2026 10:19
aa89f26 to
dbdc63c
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR integrates GenericAgent React Desktop 2.0 as a compiled-only upstream delivery. It is not a
front-end-only change: it submits the generated renderer together with the Desktop-specific bridge, conductor
model routing, usage ledger, transactional data backup, Tauri bootstrap and permissions, packaging, tests, and
quality gates needed to run and ship it. It does not submit the React development tree and does not change
GenericAgent's Agent/LLM/Harness business core.
The public React source of truth and contribution home is
abraxas914/GenericAgent. The submitted renderer was rebuilt fromaccepted fork
maincommit21f12f6dfe57ada8572bb21fe6604caac230b1cf.Core boundary:
agentmain.py,llmcore.py/llmcore/**, the Agent/LLM/Harness execution core, inference,tool calling, and memory scheduling have zero diff from upstream. The independent legacy
frontends/desktop/static/**Desktop v1 tree also has zero diff.What changes
Compiled renderer and provenance
frontends/desktop/dist/**is the production renderer consumed directly by Tauri, including independentloading, setup/recovery, and dependency-free fallback entries.
README.mdandbuild-provenance.json, which are intentionally excluded from the content manifest. The generated manifestSHA-256 is
7ed4bd56d50919d1ea6f92f60658403f19a93f117612704252f6e154ba39f92e.THIRD_PARTY_NOTICES.txthas SHA-2562acf865e87e59090121369aac0575467067fdd7999923a70d785a46ceae3330f. Root.gitattributespins the sourceand delivered notice paths to LF; source
public/**remains excluded. Every platform builder runs the bytecontract immediately before Tauri embeds
dist.contributions, and complete Semi Design attribution for the nine bundled
@douyinfe/*packages at2.101.0,including the project, website, Copyright (c) 2021 DouyinFE, MIT, and the complete notice alongside it.
reproducible.
Desktop runtime integration and data semantics
frontends/desktop_bridge.pyprovides the local HTTP/WebSocket adapter for models, sessions, prompts andstreaming, cancellation/recovery, attachments, services/logs, usage, diagnostics, source switching, and data
import/export.
frontends/conductor.pyapplies the current Desktop-selected model at each new task boundary after the priorqueue is truly idle. Missing model configuration is reported without wedging the runner, and later configuration
can recover the next task.
on production port
8900is surfaced as a port conflict, is never counted as an owned running extra, and is neverstopped. The alternate conductor port is strictly E2E-scoped; the production renderer/CSP contract remains 8900.
frontends/cost_tracker.pysupplies the persistent Desktop ledger. It is initialized only by the Desktop bridge;existing TUI and conductor processes retain their previous in-memory accounting hot path.
frontends/data_backup.pyvalidates backup contents before activation. Import first creates a complete durablebackup of destination
memory/**, then applies source-wins memory files. Model responses are add-only, andDesktop sessions are de-duplicated by session ID across current and legacy stores. Activation is staged and
rolls back on failure.
TUI/CLI/automation processes are outside that in-process gate and must be stopped by the user before import;
this PR does not claim cross-process strong consistency.
Tauri bootstrap, settings, renderer security, and runtime refresh
frontends/desktop/src-tauri/**adds packaged resource/Python discovery, bridge identity and ownership checks,progress/retry/recovery, external-root switching with rollback, native pickers, path reveal, shortcut,
window/tray behavior, and scoped capabilities.
preserve model/shortcut/override/unknown siblings, and fail closed on malformed JSON.
legacy versioned runtime is migrated once; configuration, memory, responses, sessions, and token ledger data are
preserved, while migration or activation failure rolls back.
cross-site/null/lookalike/wrong-port/preflight/WebSocket requests are rejected before route handling, and native
no-Origin probes remain supported. WebDriver permission exists only in the E2E configuration.
introduced nor fixed here; this PR does not treat it as a new delivery blocker or claim an OS policy change.
Packaging and release safety
@tauri-apps/cli2.11.4withnpm install --package-lock=false, assert that no source lockfile was created, and never invoke Vite.workflow_dispatchpackage runs create candidate artifacts only; the publisher is skipped.desktop-portable-*tag starts exactly three platform builders. Each hascontents: read, disables persistedcheckout credentials, validates the renderer/notice immediately before embedding, and uploads only its candidate
and checksum. No builder can create or edit a Release.
contents: write, waits for all three builders, validates exactly six files and theirchecksums, creates one invisible draft containing the complete set, verifies the remote asset set, and only then
exposes the entry as a prerelease. Tag input reaches the shell through an environment variable and is validated
with a fail-closed allowlist before use.
and enforces a maximum GLIBC requirement of 2.35. The package documents glibc 2.35 as the minimum.
macos-15host, host Python3.12.10for hash-locked DMG tooling, and a separateembedded python-build-standalone
3.12.14arm64 runtime. The final DMG is verified after post-processing.RUNNER_TEMPthroughcygpath -u; the unsigned package explicitly documents SmartScreen andchecksum verification. All runtimes suppress and purge Python bytecode caches without removing pip vendored
sources.
Compiled-only boundary
packaging scripts/workflows and package-evidence journeys; Desktop backend/Rust/package tests; documentation;
and the exact compiled
frontends/desktop/dist/**tree.src/**,public/**, Vite/TypeScript configuration, React/browser source tests, source maps,source
package-lock.json, local Trellis/Codex/agent directories, andmemory/**.frontends/desktop/static/**remains the independent Desktop v1 tree and is not deleted, overwritten, orrepurposed.
The final diff contains 158 files across the five commits below.
Commit structure and authorship
All five final commits have Git author and committer
abraxas914 <abraxas345589144233@outlook.com>:feat(desktop): integrate Desktop 2.0 runtime servicesbuild(desktop): publish compiled React Desktop 2.0 distributiontest(desktop): cover bridge, backup and package contractsci(desktop): add Desktop 2.0 quality gatesdocs(desktop): document source provenance and runtime boundariesOnly the generated-distribution commit retains
Co-authored-by: yiqi-017 <22300246009@m.fudan.edu.cn>because the compiled renderer includes his acceptedhelp and feedbacksettings work,startup recoverysupport contacts,and a delivery boundary informed by his earlier
compiled-only prototype.The same attribution is preserved in
frontends/desktop/dist/README.md.Validation
Accepted fork source
21f12f6d…passedDesktop Quality Gatesrun 32624991522,10/10 jobs including Python 3.10–3.13, Rust production/E2E, deterministic browser journeys, and Linux native
Tauri smoke.
The same exact source SHA passed the final all-platform candidate run
Build Desktop Portable Packagesrun 32625446620:Windows, Linux, and macOS builders succeeded; the final package evidence review passed; and the publisher was
intentionally skipped for
workflow_dispatch.The final source-excluded candidate
dbdc63c368d143fbefedfa1c82ffe4b01e0694d6additionally passed locally:npm ci, TypeScript/E2E types, 54 Vitest files / 399 tests, a 3,312-module production build,bundle/isolation contracts, and 10/10 browser journeys;
--no-bundlebuild from trackeddist/**;git diff --check, no conflict markers, exactly five commits, exact authorship/trailer, and zero diff for thecore runtime, Desktop v1 static tree, React source/config/tests, local-only paths, and
memory/**.The updated upstream head passed every job in
Desktop 2.0 Quality Gatesrun 32633447472:the compiled distribution contract, Python 3.10–3.13, Rust production/E2E, and Linux Tauri build smoke all
succeeded against exact PR head
dbdc63c368d143fbefedfa1c82ffe4b01e0694d6.Maintainer publication path after merge
mainSHA.Build Desktop Portable Packageswithworkflow_dispatchand targetallfor non-publishingcandidate artifacts.
desktop-portable-*tag at the chosen immutable upstream SHA; never force-move apublished tag.
into one verified prerelease.
This PR does not merge upstream, create a tag, or create a Release. It adds no private signing or notarization
credentials.
中文摘要
这份 PR 是什么
这是一个不向 upstream 提交 React 开发源码,但可由 upstream 直接构建运行的 Desktop 2.0 完整集成。
它并非纯前端改动:PR 提交从 fork 精确 SHA 构建的
dist/**,以及运行它所需的 Desktop bridge、conductor、成本账本、数据备份、settings、Tauri 外壳、测试、CI 与三平台打包流程;但不修改
GenericAgent 的 Agent/LLM/Harness 业务核心。
关键运行语义
memory/**,再按 source-wins 合并 memory;model responses 只新增不覆盖;Desktop sessions 按 session ID 去重,激活失败会回滚。managed session 或 Desktop extra 尚在运行时
服务端返回 409;独立 TUI/CLI/自动化进程不在进程内 gate 范围,导入前仍须由用户停止。
runner 卡死,后续配置后可恢复。
不会计入 running extras,也不会被停止。
已发布的版本目录;失败时回滚,配置、memory、responses、sessions 与 token ledger 保留。
E2E 配置。现有 loopback bridge 是继承的平台 P0 要求,本 PR 不把它误判成新的阻塞,也不声称已修改
操作系统 loopback 策略。
macos-15arm64、host Python3.12.10与 PBS runtime3.12.14;Windows 在 POSIX 工具读取临时路径前执行
cygpath -u,且明确披露未签名 SmartScreen 提示。复核远端 assets 后统一公开为 prerelease。
workflow_dispatch只产出候选 artifacts,publisher 会跳过。明确边界
agentmain.py、llmcore.py/llmcore/**、Agent/LLM/Harness 核心、推理、工具调用与记忆调度均保持upstream 原样;Desktop v1
static/**也保持零差异。本 PR 不包含 Reactsrc/**、public/**、Vite/TypeScript 配置、React/browser 源码测试、source map、source
package-lock.json、本地目录或memory/**。根.gitattributes只保留 source/dist notice 的 LF 规则,不带入public源文件。源码与后续协作
未来如需修改 React 界面,请到
abraxas914/GenericAgent查看源码、提交 Issue/PR 并取得反馈;改动在 fork 验收并重新构建后,再以新的
dist/**、匹配的build-provenance.json与对应 Desktop契约更新 upstream。
合并后的候选包与 Release
合并并确认 upstream
main质量门全绿后,维护者可先手动运行Build Desktop Portable Packages的all目标;它只生成三平台候选 artifacts,不发布 Release。验收后,再把新的desktop-portable-*tag 精确打在选定的 upstream SHA 上。三个只读 builder 从同一 SHA 构建,唯一publisher 在全部成功后聚合并校验六个文件,先建立不可见 draft,最后统一公开为 prerelease。
本 PR 本身不合并 upstream、不打 tag,也不创建 Release。