Skip to content

feature/Large-text-corpus · L-261115-8703f2 - #111

Merged
lchoquel merged 1 commit into
devfrom
feature/Large-text-corpus
Nov 16, 2026
Merged

lchoquel merged 1 commit into
devfrom
feature/Large-text-corpus

Conversation

@lchoquel

@lchoquel lchoquel commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

TL;DR

  • The committed projection corpus is now the one pipelex dev generates after large Text, Html and JSON values became storable, and the client's compact inputs template for a JSON slot is now the bare object, as pipelex's reference projection renders it.
  • The corpus pins the shapes that may hold a url (standard 9.0.0), and the copy here was behind pipelex even before that change.
  • ⚠️ A caller reading a compact template's JSON slot now receives {} instead of the {concept, content: {json_obj}} envelope.

Behaviour changes

  • A native.JSON slot, a slot of a concept refining it, and each element of a JSON[] slot in a compact template: {"concept": "native.JSON", "content": {"json_obj": {}}} → {}. The explicit shape is unchanged.

Breaking changes

  • A consumer of project_inputs_template or render_inputs_template with explicit=False that read the envelope at a JSON slot now reads the object itself; the runtime's input shaper reads a bare object at a JSON position literally.

Changes

Corpus

  • tests/fixtures/protocol/ (input_form.json, output_form.json, pipe_io_contracts.json, inputs_template/**) copied byte for byte from pipelex-dev generate-projection-corpus at pipelex dev 5c8f298a0, the same bytes as the mthds-js twin. Text, Html and JSON contract schemas carry optional text / inner_html / json_obj beside optional url, size, mime_type and preview; scaffold_stored_natives, scaffold_verdict_natives and output_native_yes_no are new; scaffold_anything_slot is folded into scaffold_open_natives; the manifest's unshapeable record now holds only the nested-list gap.
  • tests/fixtures/protocol/README.md: provenance, the standard 9.0.0 shapes, and the unshapeable record updated.

Client projection

  • mthds/protocol/inputs_template.py: JSON leaves the envelope-keeping set; keeps_envelope returns false for a JSON node (lists included), and the compact value of a JSON node is the projection of its json_obj, mirroring projection_reference.py in pipelex.

Tests

  • tests/unit/test_inputs_template_rendering.py: the JSON compact rule held by name, for a single slot, a refining concept and a JSON[] slot.
  • tests/unit/test_protocol_pipe_io_contracts.py: every captured single Text, Markdown, Html or JSON slot states its inline value and a stored value's fields, requiring neither.
  • tests/unit/test_data.py: the cases, and the hand-written _TEXT_SCHEMA probe no longer requires text.

How it was verified

  • DO_NOT_TRACK=1 make agent-check: > done: agent-check (ruff, pyright 0 errors, mypy no issues, error registry agrees).
  • DO_NOT_TRACK=1 make agent-test: All tests passed.
  • Before the client fix, byte parity failed on the compact JSON and TOML of scaffold_open_natives and scaffold_stored_natives, and nowhere else.
  • diff -r of the generated corpus (without engine/) against tests/fixtures/protocol/: only README.md and .gitattributes differ, as intended.

Documentation

  • docs/inputs-template.md: the JSON compact rule, and why the storable natives need no rule of their own.
  • tests/fixtures/protocol/README.md: provenance and the new shapes.
  • CHANGELOG.md: one ### Changed entry under [Unreleased].

Not done

  • No release: it ships with the next mthds-python release.
  • The mthds-js twin of this step is its own pull request (L-261115-f52808).
  • conformance/tests/mthds/fixtures/protocol_corpus_census.json still lists scaffold_anything_slot and lacks the new pipes; that census belongs to conformance.

Closes L-261115-8703f2
Advances L-261113-38f717

🤖 Generated with Claude Code


Summary by cubic

Updates the compact inputs template so a JSON slot renders as the bare object it carries — for a single slot, a concept refining native.JSON, and each element of a JSON[] slot — and re-commits the projection corpus from pipelex dev at the change that made Text, Html and JSON values storable.

This is breaking: a consumer of project_inputs_template or render_inputs_template with explicit=False that read the {"concept": "native.JSON", "content": {"json_obj": {}}} envelope at a JSON slot now reads the object itself, which the runtime's input shaper accepts literally. The explicit shape is unchanged.

Corpus

  • Regenerated from pipelex dev, adding scaffold_stored_natives, scaffold_verdict_natives and output_native_yes_no, and folding scaffold_anything_slot into scaffold_open_natives.
  • Text, Html and JSON contract schemas now state their inline value beside optional url, size, mime_type and preview stored-value fields, none required.

Written for commit 3dca698. Summary will update on new commits.

View guided diff Turn on auto-fix

…ot's compact template

The projection corpus moves to the capture pipelex dev generates at
5c8f298a0: Text, Html and JSON contract schemas carry their inline value
beside an optional stored value's url, size, mime_type and preview, and the
corpus gains scaffold_stored_natives, scaffold_verdict_natives and
output_native_yes_no, folding scaffold_anything_slot into
scaffold_open_natives.

The client projection had stayed behind pipelex's reference since it unwrapped
native.JSON: a JSON slot's compact template is now the bare object its
json_obj carries, for a single slot, a refining concept and each element of a
JSON[] slot, which the input shaper reads literally.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@lchoquel
lchoquel marked this pull request as ready for review November 16, 2026 10:32
@chatgpt-codex-connector

Copy link
Copy Markdown
Codex Review Summary: 🔄 Running

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review 🔄 Running since 2026-11-16T10:32:18.262170Z 3dca698 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@lchoquel
lchoquel merged commit f5c4c86 into dev Nov 16, 2026
19 checks passed
@lchoquel
lchoquel deleted the feature/Large-text-corpus branch November 16, 2026 10:33
@github-actions github-actions Bot locked and limited conversation to collaborators Nov 16, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant