Skip to content
Merged
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
58 changes: 57 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
uses: actions/checkout@v5
with:
repository: SNodeC/AISuite
ref: 60c81c7f1fb7938e03725cdea4a87e617efae57e
ref: 5aeedb2c21d7da0d611219365294cc3fb052cddf
path: _deps/aisuite

- name: Install build dependencies
Expand Down Expand Up @@ -136,3 +136,59 @@ jobs:
else
git diff --check HEAD^ HEAD
fi

web:
runs-on: ubuntu-24.04
timeout-minutes: 15

steps:
- name: Check out exact CodexUI head
uses: actions/checkout@v5
with:
fetch-depth: 0
ref: >-
${{ github.event_name == 'pull_request' &&
github.event.pull_request.head.sha || github.sha }}
path: CodexUI/codexui

- name: Check out pinned AISuite frontend SDK
uses: actions/checkout@v5
with:
repository: SNodeC/AISuite
ref: 5aeedb2c21d7da0d611219365294cc3fb052cddf
path: AISuite-extraction/AISuite-final

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
cache-dependency-path: |
AISuite-extraction/AISuite-final/packages/codex-frontend/package-lock.json
CodexUI/codexui/web/package-lock.json

- name: Verify the paired SDK revision
working-directory: CodexUI/codexui
run: |
test "$(git -C ../../AISuite-extraction/AISuite-final rev-parse HEAD)" = \
"$(cat web/AISUITE_REVISION)"

- name: Test the frontend SDK
working-directory: AISuite-extraction/AISuite-final/packages/codex-frontend
run: |
npm ci
npm test
npm pack --dry-run

- name: Test and qualify CodexWebUI
working-directory: CodexUI/codexui
run: |
npm ci --prefix web
npm run release --prefix web

- name: Upload CodexWebUI production artifact
uses: actions/upload-artifact@v4
with:
name: codexui-web
path: CodexUI/codexui/web/app-dist
if-no-files-found: error
7 changes: 6 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

cmake_minimum_required(VERSION 3.20)

project(CodexUI LANGUAGES CXX)
project(CodexUI VERSION 1.0.0 LANGUAGES CXX)

include(GNUInstallDirs)
include(CTest)
Expand Down Expand Up @@ -120,6 +120,11 @@ endfunction()

configure_codexui_target(codex-ui)

set(CODEXUI_WEB_DIST_DIR "${CMAKE_CURRENT_SOURCE_DIR}/web/app-dist" CACHE PATH
"Directory containing the built CodexWebUI static artifact")
install(DIRECTORY "${CODEXUI_WEB_DIST_DIR}/"
DESTINATION "${CMAKE_INSTALL_DATADIR}/codexui/web" OPTIONAL)

if(TARGET snodec::net-in-stream-tls AND TARGET snodec::net-in6-stream-tls)
target_compile_definitions(codex-ui PRIVATE CODEXUI_CODEX_FRONTEND_TLS=1)
target_link_libraries(
Expand Down
47 changes: 43 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
# CodexUI

CodexUI is a native Qt 6 Widgets frontend for the AISuite `codex-bridge`.
It presents the Codex app-server protocol without introducing another backend,
semantic cache, snapshot store, or persistence authority.
CodexUI 1.0 is a native Qt 6 Widgets and browser frontend for the AISuite
`codex-bridge`. Both applications present the same Codex app-server behavior
without introducing another backend, semantic cache, snapshot store, or
persistence authority.

The canonical process has two threads:

Expand All @@ -19,12 +20,18 @@ event loop, selected transport, `AISuite::OpenAICodex` frontend proxy SDK,
native protocol normalization, and connection/controller telemetry. They
exchange only bounded `codexui.presentation` JSONL commands and events.

## Application
## Applications

`codex-ui` is the canonical visual application. Its production shell consumes
the normalized presentation protocol and model directly; there is no parallel
legacy UI or alternate application target.

`CodexWebUI` is the browser presentation. It uses the framework-neutral
`@snodec/codex-frontend` SDK from AISuite, connects directly to the bridge over
WebSocket, and follows the same controller, prompt, thread, turn, projection,
and reconnect rules as the native application. Browser-only limitations are
listed in the [1.0 contract](docs/web-1.0-contract.md).

## Build

Qt 6 Widgets, Threads, libgit2 development files (discoverable as `libgit2`
Expand All @@ -46,6 +53,30 @@ The executable name, application ID, `StartupWMClass`, desktop entry, and icon
name intentionally match so Linux launchers and taskbars associate the window
with the installed CodexUI application.

## Browser build

Node.js 20 or newer and the exact AISuite revision recorded in
[`web/AISUITE_REVISION`](web/AISUITE_REVISION) are required. The source
dependency expects the release/CI checkout layout shown below.

```text
workspace/
├── AISuite-extraction/AISuite-final/
└── CodexUI/codexui/
```

```sh
npm ci --prefix ../../AISuite-extraction/AISuite-final/packages/codex-frontend
npm test --prefix ../../AISuite-extraction/AISuite-final/packages/codex-frontend
npm ci --prefix web
npm run release --prefix web
```

The production artifact is `web/app-dist/`. CMake installs it below
`${CMAKE_INSTALL_DATADIR}/codexui/web`; `codex-bridge` serves those files and
its `/codex` WebSocket endpoint from the same listener. Node is not part of the
installed runtime. Deployment details are in [`web/README.md`](web/README.md).

## Architecture

The complete thread model, presentation protocol, authority rules, normalized
Expand All @@ -58,6 +89,14 @@ geometry, shell-output, Inspector, and desktop-integration decisions are
documented in
[`docs/ui-behavior.md`](docs/ui-behavior.md).

The browser architecture, native/web parity boundary, state ownership, and
version 1.0 delivery gates are documented in
[`docs/web-1.0-contract.md`](docs/web-1.0-contract.md).

Measured performance, equality evidence, packaging, and the release gate are
recorded in [`docs/web-qualification.md`](docs/web-qualification.md) and
[`docs/web-release.md`](docs/web-release.md).

## License

CodexUI is available under the LGPL-3.0-or-later OR MIT dual license.
5 changes: 4 additions & 1 deletion docs/codex-architecture.md
Original file line number Diff line number Diff line change
Expand Up @@ -449,7 +449,10 @@ The compact More menu contains the named permission profile, approval
reviewer, service tier, reasoning summary, and collaboration mode. Model,
effort, service-tier, and permission-profile choices are populated from fresh
app-server catalogs. A named permission profile and a sandbox policy are
mutually exclusive, matching the native app-server contract.
mutually exclusive, matching the native app-server contract. An explicit Access
or Network choice therefore returns the permission-profile control to Thread
default and submits the selected sandbox policy. Other individual controls keep
the active permission profile and submit their supported app-server overrides.

The settings object is a transient draft bound to the stable selected thread
identity. User changes are serialized into native `thread/start` and
Expand Down
Loading
Loading