Ship bounded native Braid Capsule DSL v0 - #90
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Based on
mainat41c1a9cf. Closes #77.The gap
The only human CLI authoring path was JSON shaped exactly like the IR. The JavaScript elaborator proved the frontend seam, but it could not express the Day-0 CMS graph as native Braid source. D6 therefore remained unfired and Braid still had no bounded language of its own.
The fix
Ratify D33 and add one closed
cms::v1Capsule grammar. The frontend bounds source work before allocation, lowers exclusively throughbraid_sdk::Builder, compares declared capabilities and effects to the derived graph, encodes the existing Capsule wire, and re-enters the independent verifier before returning success.A general-purpose grammar was the rejected alternative. It is worse because schemas, state, Flow, imports, macros, recurrence, literals, and arbitrary registries do not have canonical substrate contracts. Accepting syntax for them would create a second authority by implication.
The real user path
Regressions
Twenty crate-level cases drive source through parse, lowering, canonical encoding, independent admission, and rendering. They include ten pinned CID programs, typed refusals for authority and effect mismatches, hostile UTF-8 generation, and bounded pipeline work. Four black-box CLI cases compare the DSL and JSON-of-IR bytes, verify widening behavior, and prove rejected source leaves no artifact. Two execution cases prepare the verifier and planner proofs and reach
execute_runnable; a transplanted authority set is refused before any host call.Source-only names do not alter identity
Three golden variants rename only the source capsule or step label and retain the same CID. The labels are diagnostics, not hidden fields in the canonical wire.
Touched-surface account
checkwrites nothing;compilewrites only after admissionFull CI, run locally at
3f287331f8c5.wwfd/local-ci.sh-D warningslgwks_stdfeature and MSRV matrixReceipt:
/Users/srinji/wwfd/state/local-ci-receipt.json, subject3f287331f8c5.What is still not done
Schemas, state and statecharts, Flow authoring, imports, macros, recurrence, runtime literal payloads, arbitrary registries, and replacement-language claims remain refused. This does not publish crates, update the installed binary, or fix the dependency register that is currently operating with enforcement disabled; those are separate release and dependency-authority changes.