Skip to content

LM-1: local-model contracts and native feasibility (#377) - #397

Merged
BunsDev merged 2 commits into
mainfrom
lm1-contract
Oct 24, 2026
Merged

BunsDev merged 2 commits into
mainfrom
lm1-contract

Conversation

@BunsDev

@BunsDev BunsDev commented Oct 24, 2026 •

Copy link
Copy Markdown
Contributor

Closes nothing by itself. This is the reviewable artifact for #377 under #376.

What this adds

  • apps/desktop/src/shared/local-models.ts: the contracts for harness, connection, exact opaque model ID, credential reference and run provenance. Qualification evidence is per capability, and capabilityStatus fails closed: an unknown or changed CLI, runtime, model, template, parser, context or effective setting reads as unknown.
  • Seven contract tests, including legacy-fixture migration and effective-settings invalidation.
  • docs/local-models.md: the source, interface and safety map.

No product route changes. No local feature is enabled. There is no new SDK, executor, proxy or tool dispatcher.

Native evidence

Real codex app-server with Strata 0.1.47 (qwen3.8-flash-next-iq3_s, context 32768, loopback). Native shell read, then an interrupted Stop, then a same-thread continuation.

  • Codex 0.163.0: original receipt.
  • Codex 0.164.0, 2026-10-23: the CLI change invalidated the receipt. All ten runtime hashes still match, and the same probes passed again on the first attempt. ThreadStartParams is byte-identical; TurnStartParams adds only Responses client-metadata fields. See the refresh section of the feasibility doc and the filtered receipt in docs/reviews/2026-10-23-lm1-0164/native-summary.json.
  • After turn/interrupt, the command stays a background terminal until thread/backgroundTerminals/terminate removes it. That confirms Modex should keep its endTerminals path.

Not qualified: Plan mode, fresh-process resume, account/profile isolation, edit/test, Ollama, LM Studio, images, offline operation and UI.

Checks (on c30633d, base 70123b9)

  • pnpm build: exit 0.
  • pnpm test: exit 0. Worktree 117/117, core 16/16, desktop 1847 passed with 16 skipped, native 21/21, site 10/10, Store 16/16.
  • pnpm typecheck: exit 0.
  • No UI change, so no e2e.

An independent review in the lm-foundation session recommended accepting the original commit 048d1e8 for narrow contract and feasibility use. The commit is rebased here with authorship preserved, and every commit is SSH-signed.

🤖 Generated with Claude Code

BunsDev and others added 2 commits October 23, 2026 19:03
The installed CLI moved from 0.163.0 to 0.164.0, which invalidates the
earlier receipt. Same Strata build (all ten runtime hashes match), same
probes: schema selection and real read -> Stop -> continuation passed again.
Records the schema delta and keeps every earlier boundary.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@vercel

vercel Bot commented Oct 24, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
modex Ready Ready Preview Oct 24, 2026 12:09am UTC

Request Review

@@ -0,0 +1,135 @@
import { spawn, execFileSync } from 'node:child_process';
import { mkdtempSync, mkdirSync, writeFileSync, appendFileSync, readFileSync } from 'node:fs';
@github-code-quality

Copy link
Copy Markdown

Code coverage overview

Languages: TypeScript

TypeScript / code-coverage-agent

main 70123b9 lm1-contract c30633d +/-
65% 65% 0%
View coverage of the 1 most impacted file.
File main 70123b9 lm1-contract c30633d +/-
apps/desktop/sr...local-models.ts 0% 100% +100%

ℹ️ Calculations represent line coverage. Results may change as calculations are updated.

BunsDev commented Oct 24, 2026

Copy link
Copy Markdown
Contributor Author

The signed LM-1 finish changes are published in PR #400, head 8b3b35ed16c76c39b70c56fb2128417576ae8445, stacked on this queued PR. GitHub rejected updating the queued branch; its head and queue entry were left unchanged. The follow-up adds the canonical runtime/identity mapping, a failing-first fixture-verified LM-2 adoption patch, sanitized Strata launch configuration and the explicitly unapproved metadata-policy proposal.

Val, please review #400 for narrow Gate A acceptance and the AGENTS proposal. Local build/test/typecheck passed (2,029 passed, 16 skipped); CI is running for the follow-up. Ollama/LM Studio native probing still awaits explicit authorization, and this session has not merged or dequeued anything.

Merged via the queue into main with commit ffb9e1d Oct 24, 2026
13 checks passed
@BunsDev
BunsDev deleted the lm1-contract branch October 24, 2026 06:26
BunsDev added a commit that referenced this pull request Oct 24, 2026
…378)

Val accepted Gate A narrowly on 2026-10-24 for main at bb0e1a4: the
LM-1 contract (#397, #400) and the recorded Strata combination only (see
the acceptance comment on #377). local-models.md, both status bullets
and the LM-2 receipt now say so instead of "not accepted", and list
what remains open: native Ollama/LM Studio metadata reads, the AGENTS.md
network wording, the #386/#398 choice and the landing order.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

This branch was successfully deployed

1 active deployment
Preview — c30633d7 Deployed Oct 24, 2026 by vercel[bot]
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