design draft

75. Cross-host conformance

Status: unimplemented — design draft. This chapter is a plan for the owner to edit. It ships no code yet, and paths marked planned do not exist.

Premise

Every client in this book was built a chapter at a time, and each part's cases ran on the iPhone as they were written, and on each other host once chapters 10 and 11 added it. This chapter collects those cases into one conformance run and runs it on every host the book names, so a host qualifies on evidence and not on a claim.

Draft

Chapter 10 states the rule: no surface has its own agent logic. Chapter 6 made it testable: one acceptance case, written as coax drive operations, gives one trace, and every host that runs it must give the same one. Since then every chapter that teaches code has added cases. This chapter is not a new client. It is the run that keeps all the clients honest.

A conformance run plays every case against one host and compares its trace with the reference trace. A host qualifies for a case when its trace matches and its declared operations cover the case. A host that can't run an operation refuses that case and does not claim it. The result is a table: each case, each host, pass, fail or refused, with the build each ran on.

The hosts are the targets in CONTRACT.md: the web, the iPhone simulator and device, the Android emulator and device, and the desktop hosts. Android comes after the iPhone and the desktop (chapter 10). It reuses the existing Android adapters in `apps/shared/host/android` and the same cases; it does not claim a finished OpenAgents Android app until those cases pass there. The terminal is a host with declared omissions: it shows text and actions, and refuses cases that need a picture, a camera or a world.

Two kinds of checks stay outside the shared run because they can't be shared. Keyboard input methods, accessibility with VoiceOver and TalkBack, backgrounding and each platform's SDKs need the real host, and the device cases record who ran them and on what. A simulator pass is evidence for the simulator only.

Two product rules hold on every host. There is one conversation, with no switch between a chat mode and a work mode. And the screen shows only things that work: a control that does nothing is not drawn. A new member added to the registry appears on every host with no change to any of them.

What we build

A plan for what this chapter ships once the draft is approved:

  • One conformance run over every case in the book, per host, with its result table.
  • Android qualified against chapter 6's case on the existing Android adapters.
  • Device cases for keyboard, accessibility, lifecycle and SDK checks, with their evidence recorded per target.

It builds on what exists today:

The chapter's check

  • Source: the case files under openagents/examples/cases/.
  • Trace: the result table: one line per case and host.
  • Refusal: a host that lacks an operation reports the case as refused, not passed.
  • Independent check: each platform's own UI tests for the same flows, until the portable cases cover them.

On the protocol (chapter 65):

RecordSchemaCarriageToday
The stream a surface drawsopenagents.chat.v1 results and, for hosted runs, planned openagents.agent.managed.v1alpha1 events (spec 17.1, spec 18.2; compliance plan, step C5)HTTP stream; Nostr kinds 26900 and 27000Spec sketch; no .proto file. The web chat polls hand-written lines today
State that follows you between surfacesopenagents.sync.v1alpha1 (chapter 35)Binary frames on one WebSocketPlanned

Planned paths: none new. The clients are the apps in `apps/`; the portable cases live with each app's tests.

Sources

Open questions for the owner

  1. Does Android get the full OpenAgents app for 1.0, or does the Android game app come first and the agent follow?