Skip to content

feat(protocol): define worker-local inference contracts - #158902

Merged
RomneyDa merged 2 commits into
mainfrom
openclaw/pr-154390-native-worker-ui
Oct 5, 2026
Merged

RomneyDa merged 2 commits into
mainfrom
openclaw/pr-154390-native-worker-ui

Conversation

@roboclaw-bot

@roboclaw-bot roboclaw-bot commented Sep 26, 2026 •

Copy link
Copy Markdown
Collaborator

What Problem This Solves

Defines the protocol and config foundation for worker-local model inference.

  • Uses the node's canonical top-level models.providers configuration for worker-local inference; there is no separate node-side inference file or model allowlist.
  • Publishes inference: "worker" in worker profile and active placement projections.
  • Advertises the versioned worker-local-inference-v1 protocol capability.
  • Uses worker as the only public value. The earlier runtime-local spelling never shipped, so this stack does not add a Doctor migration or runtime compatibility reader for it.

Stack

  1. This PR — protocol/config foundation
  2. feat(worker): add native inference runtime #163645 — worker native-inference runtime
  3. feat(gateway): dispatch worker-local native inference safely #163646 — Gateway dispatch and node-host model projection
  4. feat(clients): adopt worker-local inference placement #163647 — TUI and Control UI adoption
  5. feat(workers): require configured worker placement for sessions #158903 — configured required-worker policy

Evidence

  • pnpm config:docs:check
  • pnpm check:base-config-schema
  • pnpm check:bundled-channel-config-metadata
  • pnpm tsgo
  • pnpm check:test-types
  • AutoReview P1 findings resolved

@clawsweeper

clawsweeper Bot commented Sep 26, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation app: web-ui App: web-ui gateway Gateway runtime size: L labels Sep 26, 2026
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. merge-risk: 🚨 auth-provider 🚨 May break OAuth, tokens, provider routing, model choice, or credentials. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Sep 26, 2026
@clawsweeper

clawsweeper Bot commented Sep 26, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs changes before merge. Reviewed October 5, 2026, 5:03 PM ET / 21:03 UTC (Revision 45).

ClawSweeper review

What this changes

Adds optional worker-local inference metadata to worker profiles and active session placements, plus versioned worker and node capability identifiers.

Merge readiness

⛔ Needs changes before merge - 1 item remains

This protocol foundation remains necessary: current main lacks the new metadata and capability identifiers. The narrowed patch has no actionable correctness findings, and earlier runtime/UI concerns belong to the separate stack slices.

Priority: P2
Reviewed head: 2985d82f7c01e8ba8cf3200e38f177d933250023

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A focused additive protocol patch with meaningful schema coverage and no actionable correctness findings; required test-cost reporting remains incomplete.
Proof confidence 🌊 off-meta tidepool Not applicable: The bot-authored protocol slice is exempt from ordinary contributor runtime proof. Its schema cases are supplemental validation; historical UI captures do not prove this slice. No material authority change or stored-data writer triggers an additional proof gate.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: The bot-authored protocol slice is exempt from ordinary contributor runtime proof. Its schema cases are supplemental validation; historical UI captures do not prove this slice. No material authority change or stored-data writer triggers an additional proof gate.
Evidence reviewed 10 items Pinned introduced scope: The verified merge-base-to-head delta adds only protocol metadata, capability identifiers, and two schema-validation cases. Base-only test changes are excluded from ownership.
Current main still needs the foundation: Pinned current-main profile and active-placement schemas lack inference metadata; its worker feature list and server capability table lack the new identifiers. No merged fixing PR establishes redundancy.
Latest release check: The latest supplied release's worker protocol feature list does not include worker-local-inference-v1.
Findings None None.
Security None None.

How this fits together

Gateway protocol schemas define the messages exchanged among OpenClaw clients, the Gateway, and execution workers. These additions let later runtime and client changes distinguish worker-local inference from inference through the Gateway.

flowchart TD
  A[Configured worker profiles] --> B[Environment summaries]
  C[Active session placement] --> D[Placement summaries]
  B --> E[Gateway protocol validation]
  D --> E
  F[Worker build capabilities] --> E
  E --> G[Clients and worker connections]
Loading

Before merge

  • Complete next step (P2) - Add measured pnpm test <file> --maxWorkers=1 whole-file wall times and available CI seconds for packages/gateway-protocol/src/schema/environments.test.ts and packages/gateway-protocol/src/schema/session-placement.test.ts to the PR Evidence section.
Agent review details

Security

None.

PR surface

Source +5, Tests +28. Total +33 across 6 files.

View PR surface stats
Area Files Added Removed Net
Source 4 5 0 +5
Tests 2 28 0 +28
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 6 33 0 +33

Review metrics

Metric Value Why it matters
Protocol contract additions 2 optional metadata fields; 2 capability identifiers; 0 config options The narrowed foundation describes inference placement without introducing another configuration owner.

Root-cause cluster

Relationship: canonical
Canonical: #158902
Summary: This PR owns the protocol foundation; the linked open PRs own distinct runtime, dispatch, client, and policy slices.

Members:

Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything.

Technical review

Best possible solution:

Keep one additive protocol vocabulary, with optional worker metadata and capability-gated runtime adoption in the separately reviewed stack.

Do we have a high-confidence way to reproduce the issue?

Not applicable: this PR defines a new protocol capability rather than repairing a reported existing-behavior failure.

Is this the best way to solve the issue?

Yes: the narrowed additions extend the existing schemas and capability vocabulary without duplicating configuration or runtime owners.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 0e54386a4634.

Labels

Label changes:

No label changes.

Label justifications:

  • P2: This is a bounded protocol foundation for an actively developed optional worker-inference capability.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: The bot-authored protocol slice is exempt from ordinary contributor runtime proof. Its schema cases are supplemental validation; historical UI captures do not prove this slice. No material authority change or stored-data writer triggers an additional proof gate.

Evidence

What I checked:

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)
  • roboclaw-bot: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)
  • RomneyDa: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Record measured whole-file wall times and available CI seconds for the two changed schema suites.

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

History

Review history (44 earlier review cycles; latest 8 shown)
  • reviewed 2026-10-01T16:27:16.640Z sha 73f873b :: blocked before merge. :: [P2] Render inference only from an exact placement fact | [P3] Report whole-file costs for the added tests
  • reviewed 2026-10-02T16:59:15.485Z sha 2ee6991 :: blocked before merge. :: [P3] Remove or supply the missing native-inference documentation target | [P3] Record the whole-file costs for this split’s changed tests
  • reviewed 2026-10-03T00:28:55.975Z sha cf4c0e5 :: blocked before merge. :: none
  • reviewed 2026-10-04T07:23:42.924Z sha 89c26a213a9071544b9e820c1bd1abf94d8e3f48 :: blocked before merge. :: none
  • reviewed 2026-10-04T07:34:08.797Z sha 7afde7f :: blocked before merge. :: none
  • reviewed 2026-10-04T07:51:40.474Z sha 7afde7f :: blocked before merge. :: none
  • reviewed 2026-10-04T15:28:06.356Z sha 8db748eb0bc0eca17f6306952f1cf8ab4cf4cae7 :: blocked before merge. :: none
  • reviewed 2026-10-04T15:40:31.746Z sha 86e1097 :: blocked before merge. :: none

@clawsweeper clawsweeper Bot added proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. proof: sufficient ClawSweeper judged the real behavior proof convincing. merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. and removed proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. labels Sep 26, 2026
@roboclaw-bot

Copy link
Copy Markdown
Collaborator Author

Worker workspace finalization wording

Real Control UI with synthetic paired-worker facts, held in the same pending-finalization state. Only the wording changes; the synchronization fence and usable composer are unchanged. These captures do not depict a live deployment.

Before

Before: cloud-specific worker finalization wording

After

After: worker-neutral workspace finalization wording

@clawsweeper clawsweeper Bot removed the merge-risk: 🚨 auth-provider 🚨 May break OAuth, tokens, provider routing, model choice, or credentials. label Sep 27, 2026
@roboclaw-bot
roboclaw-bot force-pushed the openclaw/pr-154390-native-worker-ui branch from 0cecc88 to 2858309 Compare September 27, 2026 18:03
@roboclaw-bot
roboclaw-bot force-pushed the openclaw/pr-154390-native-worker-runtime branch 2 times, most recently from 82744ad to 4741a64 Compare September 28, 2026 00:30
@roboclaw-bot
roboclaw-bot force-pushed the openclaw/pr-154390-native-worker-ui branch from 93ecb59 to 3d3904d Compare September 28, 2026 00:30
@roboclaw-bot
roboclaw-bot force-pushed the openclaw/pr-154390-native-worker-runtime branch from 93b6c9f to fe65c67 Compare September 29, 2026 07:01
@roboclaw-bot
roboclaw-bot force-pushed the openclaw/pr-154390-native-worker-ui branch from d0809af to d47703b Compare September 29, 2026 07:01
@openclaw-barnacle openclaw-barnacle Bot added channel: msteams Channel integration: msteams channel: nextcloud-talk Channel integration: nextcloud-talk channel: nostr Channel integration: nostr channel: signal Channel integration: signal channel: slack Channel integration: slack channel: telegram Channel integration: telegram channel: tlon Channel integration: tlon channel: voice-call Channel integration: voice-call labels Oct 2, 2026
@RomneyDa

RomneyDa commented Oct 2, 2026

Copy link
Copy Markdown
Member

@clawsweeper re-review exact head 98ae53c9f09: CI repair only renames the unchanged native-inference SQLite fixture to the existing .test-support ownership convention; database-worker ratchet and the 21-test worker RPC file pass.

@clawsweeper

clawsweeper Bot commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@RomneyDa

RomneyDa commented Oct 2, 2026

Copy link
Copy Markdown
Member

@clawsweeper re-review exact head e4b248a8cc3: final CI repair replaces wall-clock test races with the repository-owned Vitest cancellation signal. Timeout-race ratchet, all core-test type shards, and the 14-test real worker process file pass.

@clawsweeper

clawsweeper Bot commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@github-actions

github-actions Bot commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

Security-sensitive guard cleared

Current revision: 2985d82f7c01e8ba8cf3200e38f177d933250023

This PR no longer changes files in the maintainer security-review tier.

Separate CODEOWNERS requirements still apply to security policy and enforcement files.

@RomneyDa

RomneyDa commented Oct 2, 2026

Copy link
Copy Markdown
Member

@clawsweeper re-review\n\nExact head: d85e754bda0c. The branch was reconstructed as one commit on current main to remove stale stack ancestry; GitHub now reports 125 changed files. Please review this exact head.

@clawsweeper

clawsweeper Bot commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper assist is taking a look at your question.

I queued a lightweight read-only assist pass. It will post a separate answer comment and will not edit the durable ClawSweeper review comment or trigger close, merge, repair, label, or branch changes.

Request: re-review\n\nExact head: d85e754bda0c. The branch was reconstructed as one commit on current main to remove stale stack ancestry; GitHub now reports 125 changed files. Please review this exact head.

@clawsweeper

clawsweeper Bot commented Oct 2, 2026

Copy link
Copy Markdown
Contributor

ClawSweeper assist: This needs a full correctness re-review. The requested d85e754bda0c does not match the supplied PR head, d85e754bda05dfeaacf6c6ce260c8a9b2c8fb24f.

Evidence:

  • Supplied GitHub metadata shows one commit and 125 changed files for this PR.
  • The previous review covered 73f873bb1bd2…, so it does not establish correctness of the reconstructed head.
  • The supplied ui/src/pages/chat/components/chat-pane-placement.ts patch still derives “Through Gateway” from session.agentRuntime?.id === "openclaw" when placement.inference is absent—the behavior identified by the prior P2 finding.

Suggested next action: Request @clawsweeper review on the PR, specifying exact head d85e754bda05dfeaacf6c6ce260c8a9b2c8fb24f.


Source: #158902 (comment)
Assist reasoning: medium.

@RomneyDa

RomneyDa commented Oct 2, 2026

Copy link
Copy Markdown
Member

@clawsweeper review

Exact head: d85e754bda05dfeaacf6c6ce260c8a9b2c8fb24f.

@clawsweeper

clawsweeper Bot commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@RomneyDa

RomneyDa commented Oct 2, 2026

Copy link
Copy Markdown
Member

@clawsweeper review

Exact head: 1d68b272edcf58de110bceceab82ec853fd015fb.

@clawsweeper

clawsweeper Bot commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@RomneyDa

RomneyDa commented Oct 2, 2026

Copy link
Copy Markdown
Member

@clawsweeper review

Exact head: 1d68b272edcc1c48cc552c2272bbd22b66bd1d55.

@clawsweeper

clawsweeper Bot commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@RomneyDa

RomneyDa commented Oct 3, 2026

Copy link
Copy Markdown
Member

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Oct 3, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: web-ui App: web-ui gateway Gateway runtime P2 Normal backlog priority with limited blast radius. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: XS status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants