Skip to content

Makepad's apps as native apps: Calculator, Clock, Notes, Reminders and Weather with their own agents; Task as a process app - #309

Merged
ymote merged 3 commits into
mainfrom
feat/makepad-native-apps
Oct 3, 2026
Merged

ymote merged 3 commits into
mainfrom
feat/makepad-native-apps

Conversation

@ymote

@ymote ymote commented Oct 3, 2026 •

Copy link
Copy Markdown
Contributor

The Makepad apps the desktop keeps, decided on 2 Oct: Files, Browser, Image, PDF, Calculator, Clock, Notes, Reminders, Task, Route, Weather and Finance, with AI as the assistant pane. Mixer, Score, VJ, Fab, Fabric, Video and Studio are dropped. Six of the kept apps become native apps: five with their own agents, and Task as its own sandboxed process. Browser follows separately (see below).

Commits

  1. Desktop catalog: ship only the Makepad apps OctoSense keeps.
    • desktop/config/apps.overlay.json names the upstream apps to keep (pick).
    • upstream.py writes the shipped config/apps.json and the full config/apps.makepad.json (what --apps reads).
    • The phone library's groups follow the kept apps.
  2. Calculator, Clock, Notes, Reminders and Weather become native apps.
    • Each is a linked module: on by default in the desktop shell, off on the phone for now.
    • Each has its own agent (agent.octos). Makepad model: one-shot model calls for contained apps (model.complete) #95 opens the module's peer link and answers the app's tools there.
    • Their read tools are offered to the system agent (agent.system_tools). tools/native_apps.py checks that each one is the app's own, shareable and read-only.
    • The relay sends a native app's own tools to its bus service (serves_on_bus), not only the Terminal's.
    • The assistant pane's process (aichat) is no longer listed as an app.
    • New test path: /event?data=system-call:<tool> <json> runs a declared read tool through the relay and logs the reply.
  3. Task: a native app that runs only as its own process.
    • "module": null: such an app is built into crates/process-apps, never linked into a shell, and has hosting none where there are no processes.
    • Task (the process monitor) runs under the same sandbox as other native process apps.
    • The system agent's grants now cover the native apps that run here, linked or able to start as a process (apps::process_form).

Browser is not in this PR (it follows on its own). Through crates/process-apps, makepad-browser enables makepad-widgets/cef. Cargo unifies that feature into every cargo test -p makepad-widgets in this workspace, and the phone workflow runs two. makepad-cef's build script then fetches a Chromium distribution, which this PR's first local CI run did (CEF 154). Browser needs a build in Makepad's own workspace instead. #305 and makepad #98 are already in for it.

Depends on

Validated in a hidden desktop shell (macOS, with makepad #94–#98 and #305)

  • Each app's first use shows its agent's consent sheet.
  • All five module apps answered their own tools over their links: calculator.eval 7*6 → 42, clock.now, notes.search, reminders.due, weather.current.
  • Hosted Notes and Reminders start empty.
  • Task builds through crates/process-apps and runs sandboxed.
  • Browser (validated the same way; it moves to its own PR) ran sandboxed: CEF 152 initialized, google.com rendered, the profile landed at <jail>/cef/browser, and browser.tabs and browser.page answered the system agent.

Not in this PR

  • The phone stays off; this is desktop first.
  • Files, Image and PDF are still catalog rows, not native entries.
  • Finance and Route need their data and caches moved into the jail first, and Finance seeds a sample household.
  • Browser (see above).
  • Two existing issues: Weather's animated sky costs about 180% CPU with several windows open, and the consent sheet reads "Notes's".

Checks

Runs before the rebase onto #312 (tree 0462fa14 plus the 1.1.0 lock):

  • python3 tools/native_apps.py --check: passes. python3 tools/setup.py --check --cargo: passes. cargo metadata --locked: passes. The lock gains makepad-browser, makepad-cef and makepad-task.
  • python3 -m unittest discover -s tools -p 'test_*.py': 98 OK. desktop/scripts: 59 OK (Python 3.12, which has tomllib).
  • cargo test --locked -p octosense-shell (desktop): 773 passed.
  • From phone/: cargo test --locked --features mobile-apps -p octosense-shell: 828 passed before the lock moved. With app-contract 1.1.0 locked, a_script_app_may_not_take_a_native_apps_id_or_namespace passes too.
  • Local CI on the head before Pin App Hub 0d5b47a2 and octosense-app-contract 1.1.0 #312 failed one step: App Hub's admission tests at 58c3c8ae use the now-reserved id weather. Pin App Hub 0d5b47a2 and octosense-app-contract 1.1.0 #312 fixed that on main, and this branch is rebased on it.
  • Local CI on the rebased head (with Browser) passed every step but compiled makepad-cef and fetched Chromium in the phone step. That is why Browser left this PR.
  • cargo test --locked -p octosense-ai-host --features octos-core,llm: 38 passed.
  • cargo check --locked -p octosense, from phone/ cargo check --locked -p octosense-home --features mobile-apps, and tools/check-shell-graph.sh -p octosense: pass.
  • Three existing tests changed with the manifest:
    • The tools test that pins the app list now includes Task and Browser.
    • The process-only tests use the real Task entry.
    • clients::tests::makepad_launches_build_outside_cargos_checkout uses a neutral example row, since Browser is now a native app.
    • ai-host's shipped-policy test compares every granted app with its manifest entry, Rinx still exactly the assistant services.
  • Local CI runs on the exact head before merging.

🤖 Generated with Claude Code

@ymote
ymote force-pushed the feat/makepad-native-apps branch 2 times, most recently from 74d60e9 to 7998ee5 Compare October 3, 2026 00:48
@ymote
ymote force-pushed the feat/makepad-native-apps branch 2 times, most recently from ff65636 to f0ef008 Compare October 3, 2026 01:36
@ymote ymote changed the title Makepad's apps as native apps: Calculator, Clock, Notes, Reminders and Weather with their own agents; Browser and Task as process apps Makepad's apps as native apps: Calculator, Clock, Notes, Reminders and Weather with their own agents; Task as a process app Oct 3, 2026
@ymote
ymote force-pushed the feat/makepad-native-apps branch from f0ef008 to 03db2f7 Compare October 3, 2026 01:55
@ymote
ymote marked this pull request as ready for review October 3, 2026 02:07
ymote and others added 3 commits October 2, 2026 19:07
The desktop's app catalog was generated from Makepad's whole WM registry,
so it shipped Mixer, Score, VJ, Fab, Fabric, Video and Studio beside the apps
OctoSense supports. desktop/config/apps.overlay.json now names the
upstream apps to keep (`pick`): Browser, Files, Terminal, Task, Sheets,
Clock, Weather, Finance, Notes, Reminders, Calculator and Route. Image,
PDF and AI stay appended as before.

upstream.py's merge_catalog keeps only the picked rows, pick_problems
names a pick upstream no longer curates, and the catalog command writes
the shipped config/apps.json and the full config/apps.makepad.json
(still what --apps reads). The phone library's groups follow the kept
apps.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Five of the Makepad apps the desktop keeps become native apps
(native-apps.json). Each is linked as a module: on by default in the
desktop shell, off on the phone for now. Each declares its tools
verbatim from its ai.rs.

- agent.system_tools: the app's own read tools the system agent may
  call (Calculator's eval, Clock's now, Notes' search and read,
  Reminders' due and list, Weather's current). tools/native_apps.py
  checks that each one is the app's own, shareable and read-only. The
  system chat's grants add them for the apps this build links.
- The relay sends any native app's own tools to its AI bus service in
  the open instance (serves_on_bus), not only the Terminal's.
- The assistant pane's own process (aichat) is no longer listed as an
  app: the dock and the launcher leave it out (apps::listed).
- A test path for the system agent's calls: the remote's
  /event?data=system-call:<tool> <json> runs a declared read tool
  through the relay and logs the reply.
- AGENTS.md, the READMEs and the code walkthroughs describe them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A native app may now have no module (`"module": null`). It is built
from its binary into crates/process-apps and never linked into a shell.
On a target without processes its hosting is `none`. tools/native_apps.py
checks the shape: a bin is required, the shells are off, and `none` is
for an app without a module only. The shell's hosting and the legacy-
home adoption skip such an app.

Task (the process monitor) is the first, sandboxed like every native
process app. A process-only app is never linked, so the system agent's
grants now take the native apps that run here: linked, or able to start
as their own process (apps::process_form). A closed app answers that it
is not running, as a closed module app does.

Browser follows on its own. Through process-apps, makepad-browser enables
makepad-widgets' `cef` feature, which unifies into every
`cargo test -p makepad-widgets` in this workspace (the phone workflow
runs two). makepad-cef's build script then fetches a Chromium
distribution in CI, so Browser needs a build in Makepad's own workspace.

AGENTS.md and the READMEs name Task.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@ymote
ymote force-pushed the feat/makepad-native-apps branch from 03db2f7 to b3127ae Compare October 3, 2026 02:07
@ymote

ymote commented Oct 3, 2026

Copy link
Copy Markdown
Contributor Author

Local CI passed on b3127ae (tools/ci-local.sh --only desktop,phone,apps --linux-host, 5m54s, Darwin arm64; the ubuntu jobs on the Linux build host, Linux x86_64).

GitHub would run for this PR: desktop.yml, phone.yml, apps.yml. Merged on this local pass (macOS runner queue); GitHub CI runs on the merge commit on main.

Job Step Result Time
ci-local / drift The local mapping fits the workflows PASS -
desktop.yml / desktop Prepare the pinned framework sources PASS 0s
desktop.yml / desktop Compile the desktop with the shared runtime PASS 57s
desktop.yml / desktop One copy of every shell source PASS -
desktop.yml / desktop Desktop tools and scripts PASS 10s
desktop.yml / desktop One Makepad, App Hub, octos and Rinx in the locked graph PASS 1s
desktop.yml / desktop The native apps' generated places match native-apps.json PASS 0s
phone.yml / home Prepare pinned sources and the reviewed runtime patch PASS 0s
phone.yml / home Compile Home and its bundled modules PASS 1m00s
phone.yml / home Verify the single runtime graph PASS 1s
phone.yml / home The native apps' generated places match native-apps.json PASS -
phone.yml / home The pinned octos revision PASS -
phone.yml / home Build octos (unless cached) PASS -
phone.yml / home Build Home, App Hub admission and runtime policy tests PASS 22s
phone.yml / home Test Home, App Hub admission and runtime policy PASS 2m18s
phone.yml / home Two-lane scenario (real kernel, scripted model) PASS 30s
apps.yml / services (linux) python3 tools/setup.py PASS 0s
apps.yml / services (linux) Kernel service PASS 10s
apps.yml / services (linux) App peers PASS 23s
apps.yml / services (linux) AI providers config PASS 4s
apps.yml / services (linux) L0 in-card chat (sys.chat, host side) PASS 8s
apps.yml / services (linux) System toolbox (workflow templates) PASS 1m28s
apps.yml / kernel-security (linux) python3 tools/setup.py PASS 0s
apps.yml / kernel-security (linux) The pinned octos revision PASS -
apps.yml / kernel-security (linux) Build octos (unless cached) PASS -
apps.yml / kernel-security (linux) Real-kernel tests PASS 30s
apps.yml / apps python3 tools/setup.py PASS 0s
apps.yml / apps Host services (Mail, AI providers, News) PASS 15s
apps.yml / apps Shell AI services (crates/ai-host) PASS 9s
apps.yml / apps AppCard runtime setup safeguards PASS 0s
apps.yml / apps AppCard clippy (own crates; shared runtime compiles) PASS 1s
apps.yml / apps AppCard transport and store PASS 5s
apps.yml / apps One Makepad, App Hub, octos and Rinx in the locked graph PASS 2s
linux-host / sandbox (linux) python3 tools/setup.py PASS 0s
linux-host / sandbox (linux) Process sandbox on Linux (Landlock, seccomp) PASS 1m19s

Notes:

  • GitHub runs Python 3.12; this run used Python 3.9.6
  • GitHub runs Python 3.12; the Linux host used Python 3.14.4

@ymote
ymote merged commit bf3c218 into main Oct 3, 2026
5 checks passed
@ymote

ymote commented Oct 3, 2026

Copy link
Copy Markdown
Contributor Author

Decision (3 Oct): the native-Browser follow-up mentioned above is dropped for now. The CEF Browser stays the plain Makepad catalog app it already is (desktop/config/apps.json): built from the Makepad checkout, without an OctoSense sandbox or agent tools. Pages inside apps use Splash's WebReader, the platform's own web view (WKWebView on macOS and iOS, Android's WebView). Revisit if the agent should drive a browser, or for web pages on Windows/Linux, where a WebView2/WebKitGTK backend for WebReader would be lighter than shipping CEF.

guofoo added a commit that referenced this pull request Oct 3, 2026
mobile_surface's non-floating navigation branch runs only where
mobile_navigation::ENABLED is false, which is never on Android, so its
`if android` band height and `!(android && insets.bottom > 0)` pill
condition could not hold; the band is `bottom` and the pill always draws.

apps::is_linked, the other HUB-05 point, is no longer test-only: since
#309 native_system_tools calls it, so it stays. BACKLOG.md says so.
ymote added a commit that referenced this pull request Oct 5, 2026
Five reviewers audited every file under docs/ against the code at
89e6c42. Each finding was confirmed in the code, git log or gh before
it was applied. A final review of this diff found 11 more problems,
which are fixed.

- Native agents (#309, #329, #330): ai-services, architecture and the
  walkthrough now describe:
  - the five Makepad apps' agents, through OctosPeer and serve_tools
    with no workspace, and their system_tools;
  - the Terminal's own_tools;
  - native peers living with the open window.
  They no longer say that Rinx is the only native agent or that
  nothing uses the peer link.
- terminal.run exists only while the Terminal runs as its own
  sandboxed process. Release packages ship no process-app binary, so
  there the Terminal runs in-process and Task is absent. Task is
  named as a process app.
- Admitted AGENT.md and skill text go with every turn. Mail has eight
  tools and an incoming-mail trigger. agents.provision and
  agents.status accept only os.mail.
- Smaller fixes: keys on Windows, the window-manager override path,
  phone glance cards, unsandboxed catalog apps, octos_peer frame
  names, TurnFrom (Person), the default build's octos-core, the
  packaged kernel, the octos child's runtime, and local-ci's merge
  scope, clone lock and rom.yml paths.
- ADRs get dated notes: 0002 is partly implemented; 0004 has three
  plan items open and notes on Task, the Terminal's agent, host tools
  and #238; 0005 has notes on app-contract 1.1.0; Home 0001 and 0002
  get notes. The ADR index statuses are updated, and the Photos and
  icons plans are marked done.
- Chinese parity: mail-agent-events regains its sequence diagram.
  ai-services, architecture, the walkthrough and the mail-events
  report regain their missing rows and details.
- <app> written outside code is escaped (GitHub stripped it).
  ai-services-processes.png and ai-services-cross-app-call.png show
  the shipped peer link and peer/input as solid, and mark the
  mail.send hop as planned.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
tyreseluo pushed a commit to tyreseluo/OctoSense that referenced this pull request Oct 6, 2026
The five Makepad apps that became native apps in OctoSense-org#309 were desktop
only. Their native-apps.json entries now link them into the phone shell
by default as well (shells.phone "default"), like Rinx and App Hub:
in-process modules, each with its own agent and its read tools for the
system agent.

On a Redmi Note 12 (Android 15), Calculator laid its keypad out for the
phone and then lost it: the phone shell's style reapply after a hosted
module's first frame wrote the DSL's key sizes back, and Calculator
skipped the layout it thought it had applied. makepad OctoSense-org#99 makes it lay
out again after every apply; until the next makepad move it is a
stacked runtime patch (makepad-calculator-restyle, tree 47a8b47d).

The phone and desktop READMEs name the apps on the phone.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant