Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
*.sh text eol=lf
*.rs text eol=lf
*.cpp text eol=lf
*.hpp text eol=lf
*.mjs text eol=lf
*.yml text eol=lf
*.desktop text eol=lf
*.xml text eol=lf
openless-all/app/linux-egui/packaging/AppRun text eol=lf
openless-all/app/linux-egui/packaging/openless-desktop-integration text eol=lf
16 changes: 16 additions & 0 deletions .github/workflows/check-linux-egui.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: Linux egui build and backend checks
on:
pull_request:
branches: [beta]
paths:
- 'openless-all/app/**'
- 'openless-all/scripts/linux-*/**'
- '.github/workflows/*linux-egui.yml'
push:
branches: [Linux-egui]
workflow_dispatch:
permissions:
contents: write
jobs:
native:
uses: ./.github/workflows/release-linux-egui.yml
65 changes: 36 additions & 29 deletions .github/workflows/release-linux-egui.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ jobs:
appstream \
build-essential \
cmake \
clang \
desktop-file-utils \
extra-cmake-modules \
fcitx5-modules-dev \
Expand All @@ -51,6 +52,11 @@ jobs:
libfcitx5core-dev \
libfcitx5utils-dev \
libopenblas-dev \
libkf5globalaccel-dev \
qtbase5-dev \
libatspi2.0-dev \
pulseaudio-utils \
fonts-noto-cjk \
libssl-dev \
libwayland-dev \
libx11-dev \
Expand All @@ -76,8 +82,28 @@ jobs:

- uses: dtolnay/rust-toolchain@stable
with:
toolchain: '1.94.0'
components: clippy

- uses: actions/setup-node@v4
with:
node-version: '22'
cache: npm
cache-dependency-path: openless-all/app/package-lock.json

- name: Build React baseline and generate native locale catalog
working-directory: openless-all/app
run: |
npm ci
npm run build
node ../scripts/sync-egui-locales.mjs

- name: Build GNOME and KDE desktop integration
run: |
node openless-all/scripts/linux-desktop/gnome/build.mjs
cmake -S openless-all/scripts/linux-desktop/kde -B openless-all/scripts/linux-desktop/kde/build -DCMAKE_BUILD_TYPE=Release
cmake --build openless-all/scripts/linux-desktop/kde/build --parallel

- name: Cache Cargo
uses: swatinem/rust-cache@v2
with:
Expand All @@ -104,18 +130,19 @@ jobs:

- name: Verify framework-independent Linux contract
working-directory: openless-all/app
shell: pwsh
shell: bash
run: |
set -euo pipefail
cargo test --locked -p openless-core
cargo clippy --locked -p openless-core --all-targets -- -D warnings
cargo test --locked -p openless-linux-egui --all-targets
cargo test --locked -p openless-linux-egui --lib --test host_contract
cargo check --locked -p openless-linux-egui --all-targets
./scripts/check-core-deps.ps1
./scripts/check-core-deps.ps1 openless-linux-egui
./scripts/check-core-secret-surface.ps1
./scripts/check-core-test-isolation.ps1
./scripts/check-core-runtime-seam.ps1
./scripts/check-linux-public-surface.ps1
pwsh -NoProfile -File ./scripts/check-core-deps.ps1
pwsh -NoProfile -File ./scripts/check-core-deps.ps1 openless-linux-egui
pwsh -NoProfile -File ./scripts/check-core-secret-surface.ps1
pwsh -NoProfile -File ./scripts/check-core-test-isolation.ps1
pwsh -NoProfile -File ./scripts/check-core-runtime-seam.ps1
pwsh -NoProfile -File ./scripts/check-linux-public-surface.ps1

- name: Validate release target and UI gate
shell: bash
Expand Down Expand Up @@ -172,27 +199,7 @@ jobs:

- name: Verify package contents and ELF dependencies
working-directory: openless-all/app
run: |
OUTPUT=target/linux-egui-packages
test "$(find "$OUTPUT" -maxdepth 1 -name '*.deb' | wc -l)" -eq 1
test "$(find "$OUTPUT" -maxdepth 1 -name '*.rpm' | wc -l)" -eq 1
test "$(find "$OUTPUT" -maxdepth 1 -name '*.AppImage' | wc -l)" -eq 1
! ldd target/release/openless-linux-egui | grep -q 'not found'
! ldd target/release/openless-linux-egui | grep -Eqi 'webkit|wry|tauri'
! ldd src-tauri/vendor/qwen-asr/qwen_asr | grep -q 'not found'
dpkg-deb -c "$OUTPUT"/*.deb | grep -q 'usr/bin/openless'
dpkg-deb -c "$OUTPUT"/*.deb | grep -q 'fcitx5/libopenless.so'
dpkg-deb -c "$OUTPUT"/*.deb | grep -q 'usr/lib/openless/resources/qwen-asr/qwen_asr'
rpm -qlp "$OUTPUT"/*.rpm | grep -q '/usr/bin/openless'
rpm -qlp "$OUTPUT"/*.rpm | grep -q '/usr/lib64/fcitx5/libopenless.so'
rpm -qlp "$OUTPUT"/*.rpm | grep -q '/usr/lib/openless/resources/qwen-asr/qwen_asr'
"$OUTPUT"/*.AppImage --appimage-extract >/dev/null
test -x squashfs-root/usr/bin/openless
test -s squashfs-root/usr/lib/openless/resources/linux-fcitx5-plugin/libopenless.so
test -x squashfs-root/usr/lib/openless/resources/qwen-asr/qwen_asr
! ldd squashfs-root/usr/lib/openless/resources/qwen-asr/qwen_asr | grep -q 'not found'
squashfs-root/usr/lib/openless/resources/qwen-asr/qwen_asr --help >/dev/null 2>&1
rm -rf squashfs-root
run: bash scripts/verify-linux-egui-packages.sh

- name: Sign AppImage and write independent updater manifest
working-directory: openless-all/app
Expand Down
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -118,3 +118,7 @@ CapsWriter

# Mimosa 安全钩子运行状态(不属版本库)
.mimosa/

# Local Linux toolchains, build logs and packaging workspaces.
openless-all/app/.cache/
openless-all/scripts/linux-desktop/kde/build/
55 changes: 20 additions & 35 deletions docs/linux-egui-handoff/02-gap-register.md
Original file line number Diff line number Diff line change
@@ -1,35 +1,20 @@
# 02:Linux 缺口登记与实施顺序

状态:canonical(2026-09-07 以源码为准重写,L-ID 体系沿用);更新:2026-09-07。本表是源码盘点,不是通过声明。

## 1. 状态定义

- **接线缺口**:Core 已有业务,Linux Host 尚未执行必要的原生效果。
- **界面缺口**:已有 Core/Host 入口,生产 UI 未提供完整操作。
- **待实测**:存在真实实现,还需要对应桌面、设备或安装证据。

## 2. 待办登记

| ID | 状态与缺口(源码锚点) | 关闭标准 |
| --- | --- | --- |
| L01 | 接线+界面:`switch_style` / `open_app` / `style_packs` 热键修改在 `settings.rs:56-61` 被明确拒绝 | 实际全局注册、触发、重绑、失败恢复与重启还原;分别声明 X11/Wayland 支持 |
| L02 | 接线:未注入 `EditObservationAdapter`,Core 默认 `NoopEditObservationAdapter`(`ports.rs:539`)生效,Selection `source_app` 为 None | 按隐私设置捕获真实应用/允许的上下文;手改观察能产生纠错建议并拒绝迟到结果 |
| L03 | 接线:`audio.rs` `LinuxCpalRecorder` 无录音归档,未执行录音期间系统静音/恢复;缺提示音与胶囊 | 录音归档、保留策略、失败恢复、历史重转写可用;所有终态恢复音量 |
| L04 | 接线+界面:Selection Voice 未形成生产触发/捕获/意图路由;QA 缺编辑模式/应用/撤回 UI | 完整触发至 Core intent、预览、目标核验、应用/取消/撤回 |
| L05 | 界面:词典、纠错规则/建议、风格包管理没有页面(`ui_state.rs` 10 页无对应项) | 各领域增删改/启停/预设/导入导出与失败反馈,经 Core facade 持久化 |
| L06 | 界面:marketplace 服务已接入(`marketplace.rs`),市场页面缺失 | 浏览、安装、上传/下载、设备 OAuth 登录/退出,复用 Core 协议 |
| L07 | 界面+L03 依赖:历史仅只读最近条目,缺完整历史/统计/录音操作 | 浏览与既有历史操作、重润色/重转写、录音播放/导出/清理与统计 |
| L08 | 界面:本地 Qwen 有下载/激活/取消,缺完整模型管理与运行时控制 | 路径/镜像、详情/状态、删除、预载/释放与准备/测试取消;真实推理另附证据 |
| L09 | 界面部分改善:10 页导航、开始/环境引导、独立设置与手机输入页、跨页审批/取消已落地;多数 Linux 适用设置、Agent 检测/模型/路径/权限配置仍缺失 | 设置有实际消费者、revision/错误处理;保留 Less Computer 输出/审批/取消流程 |
| L10 | 接线+界面:无托盘/自启(`capabilities.rs` 仅探测 `supports_tray`,未实现);通知仅状态栏;AppImage 能力判定不等于更新器 | 窗口/后台运行、通知、自启、检查/下载/安装更新与重启有真实 Host 效果 |
| L11 | 已实现待实测:fcitx5 输入/选区(`fcitx5.rs`)、CPAL(`audio.rs`)、Secret Service(`credentials.rs`)、Qwen 运行时、CLI 进程、Remote TLS/H5(`remote_input.rs`) | 通过真实桌面/设备矩阵;逐项记录,不把整模块称为缺失 |
| L12 | 已有包构建(deb/rpm/AppImage workflow),待 Linux 产品验收与正式分发 | 完成上述应用缺口与安装/升级/回滚、签名和更新证据;不阻塞 Windows/macOS 首批交付 |

## 3. 依赖顺序

1. 保留启动、版本校验、事件与退出合同,跑通一个现有听写流程。
2. 补 L01–L03 原生能力;页面可并行,但历史音频/自动纠错不能脱离其 Host 依赖单独宣布完成。
3. 补 L04–L09 领域入口及完整成功/失败/取消流程,再补 L10 桌面集成。
4. 按 L11–L12 获取真实环境与发布证据。

任务记录格式:`ID / owner / commit / 已完成效果 / 自动证据 / 设备证据 / 剩余限制`。“待实测”不是“未实现”,也不是“已完成”。
# 02:Linux-egui L01–L12 状态

更新:2026-09-11;锁定基线:867a0d8。实现、自动检查、真实桌面验收是三个独立维度。当前没有开展前端界面验证或浏览器自动化。最终检查证据与产物见 [08 交付记录](08-linux-egui-2.0.md)。

| ID | 已实现及源码 | 自动验证 | 待人工验收 |
| --- | --- | --- | --- |
| L01 | desktop_bridge/x11_desktop、GNOME/KWin/KGlobalAccel、fcitx5;完整快捷键、严格冲突事务、恢复和重启重绑 | 设置事务、raw 键值转换、fcitx 输入合同;Linux/Qt 编译 | 八种桌面/协议组合的全局按下释放,尤其左右修饰键;桌面服务重启与实际冲突 |
| L02 | context/atspi 注入两个 Adapter;版本化目标/隐私/会话代次和文字观察 | 过期目标/迟到捕获/隐私/编辑差异测试 | GTK/Qt/浏览器应用身份及文本接口,实际手改产生建议 |
| L03 | audio、audio_mute、audio_cue、recordings;归档、保留、提示音、播放导出、静音恢复 | WAV、输出设备恢复、异常释放测试 | 真麦克风、PulseAudio/PipeWire、设备切换、退出恢复 |
| L04 | selection_voice/host_windows/popup;捕获、意图、预览、应用、取消和撤回 | Core 16 项 Selection Voice 合同、原生选区目标和撤回测试 | 焦点恢复、不同输入客户端、跨屏定位;修改后的原目标被拒绝 |
| L05 | 八页中的词典/纠错/风格;Core 持久化、预设增改删、启停、导入导出、独立提示词 | Core 词典/风格/配置持久化;原生编译 | 页面交互及视觉对照 |
| L06 | host_marketplace;真实查询/排序/详情/安装/下载/点赞/发布管理、OAuth | Core 市场协议与凭据测试;原生编译 | 授权登录、服务端发布/删除及网络错误,不在测试中发布真实风格包 |
| L07 | host_history;完整历史、统计、原文/结果、播放/导出/重转写/试用润色/取消/清理 | Core 历史/录音保留,原生 WAV/路径/取消合同 | 真实音频播放与模型重转写;界面布局 |
| L08 | host_models/host_omni;下载/取消/清理/路径/镜像/激活/测试/释放/删除、Omni 配置 | Core 下载取消、运行时缺失、Qwen 进程组结束测试;原生编译 | 实际模型下载和推理;外部服务端配置 |
| L09 | ui/settings 与 host_settings;七类设置、渠道、手机输入、云同步、隐私、Less Computer | Core revision/持久化、凭据锁定、事件和审批合同 | 七类设置全部子页及各成功/失败/取消路径,审批跨页保留 |
| L10 | tray/desktop/updater;托盘、后台、自启、通知、AppImage 校验/原子更新/回滚 | 自启、托盘命令、签名/校验、取消、回滚测试 | 桌面托盘/通知能力;签名发布包升级与包管理器安装 |
| L11 | CPAL/fcitx5/Secret Service/Qwen/CLI/Remote TLS 保留并重新接线 | Core 及 Linux 后端测试、fcitx C++ 合同、Qt 编译 | 真实 Linux 会话、钥匙环、设备、远程手机输入 |
| L12 | Linux CI、release 构建、deb/rpm/AppImage、桌面组件和交付说明 | 构建/包内容结果见 08,未签名候选产物 | 八种桌面组合验收及正式私钥签名发布;不能以 WSL 编译代替 |

完成判据:实现与自动证据齐备后可提交人工验收;只有对应矩阵和签名发布证据完成,才关闭真实桌面/分发维度。所有待人工项均保持未验收,不能标成已通过。
2 changes: 2 additions & 0 deletions docs/linux-egui-handoff/03-hotkeys-and-windows.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# 03:全局热键与窗口

> 2026-09-11 更新:下文保留 2026-09-07 原始合同及缺口背景。Linux-egui 分支当前实现和验证状态见 [02 状态表](02-gap-register.md) 与 [08 交付记录](08-linux-egui-2.0.md);本文旧缺口不作为现状结论。

状态:canonical(2026-09-07 以源码为准重写);更新:2026-09-07。对应缺口:L01、L10。系统注册和窗口效果由 Linux Host 负责,业务动作继续调用 Core。

## 1. 已有实现
Expand Down
2 changes: 2 additions & 0 deletions docs/linux-egui-handoff/04-ui-domains.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# 04:页面与领域操作

> 2026-09-11 更新:下文保留 2026-09-07 原始合同及缺口背景。Linux-egui 分支当前实现和验证状态见 [02 状态表](02-gap-register.md) 与 [08 交付记录](08-linux-egui-2.0.md);本文旧缺口不作为现状结论。

状态:canonical(2026-09-07 以源码为准重写);更新:2026-09-07。页面定义:`linux-egui/src/ui_state.rs` `Page` 枚举(10 页);主循环与交互:`main.rs`。

## 1. 十页现状
Expand Down
2 changes: 2 additions & 0 deletions docs/linux-egui-handoff/05-native-host-and-data.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# 05:原生宿主、数据与系统集成

> 2026-09-11 更新:下文保留 2026-09-07 原始合同及缺口背景。Linux-egui 分支当前实现和验证状态见 [02 状态表](02-gap-register.md) 与 [08 交付记录](08-linux-egui-2.0.md);本文旧缺口不作为现状结论。

状态:canonical(2026-09-07 以源码为准重写);更新:2026-09-07。对应 L02、L03、L10、L11。平台效果归 Linux Host;现有代码可复用。

## 1. 音频(`audio.rs`)
Expand Down
2 changes: 2 additions & 0 deletions docs/linux-egui-handoff/06-events-and-sessions.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# 06:事件、会话与取消

> 2026-09-11 更新:下文保留 2026-09-07 原始合同及缺口背景。Linux-egui 分支当前实现和验证状态见 [02 状态表](02-gap-register.md) 与 [08 交付记录](08-linux-egui-2.0.md);本文旧缺口不作为现状结论。

状态:canonical(2026-09-07 以源码为准重写);更新:2026-09-07。

入口:Core `events.rs` / `types.rs`、`linux-egui/src/lib.rs`(`LinuxHost`)、`linux-egui/src/main.rs`(主循环)。
Expand Down
2 changes: 2 additions & 0 deletions docs/linux-egui-handoff/07-acceptance.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# 07:验收与证据

> 2026-09-11 更新:下文保留 2026-09-07 原始合同及缺口背景。Linux-egui 分支当前实现和验证状态见 [02 状态表](02-gap-register.md) 与 [08 交付记录](08-linux-egui-2.0.md);本文旧缺口不作为现状结论。

状态:canonical(2026-09-07 以源码为准重写);更新:2026-09-08。

## 1. 两个不同的完成门
Expand Down
Loading
Loading