feat(resource)!: adopt Blossom server hints - #206
Merged
Conversation
Expose the proposed NAP-RESOURCE server-hint envelope across public APIs, transport, conformance, and documentation. BREAKING CHANGE: resource.bytesMany now accepts ResourceBytesRequest[] and emits requests rather than a string urls array. Co-Authored-By: Codex <noreply@openai.com>
Keep the dedicated protocol branch release scope and debug provenance separate from PR #205's optimizer work. Co-Authored-By: Codex <noreply@openai.com>
Co-Authored-By: Codex <noreply@openai.com>
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.
What
Implements the NAP-RESOURCE server-hint amendment from live proposal revision
9511232.resource.bytescarries optional advisoryservers.resource.bytesManyaccepts ordered per-resourcerequests.ResourceBytesRequest { url, servers? }.ResourceInfoexposes optionalmaxServers.@napplet/core,@napplet/nap,@napplet/sdk,@napplet/shim, and@napplet/conformance.Protocol boundary
Server hints are advisory and apply only to
blossom:resource resolution. Runtime implementations retain accepted-server filtering, ordered fallback, SSRF defenses, caching, and Blossom hash verification. This PR does not invent host network policy or alter resource cache identity.Split boundary
This protocol amendment was extracted from #205 so it can be reviewed and released independently against
main. Nopackages/vite-plugin/src/optimizer/file and no@napplet/vite-pluginrelease entry is included here. PR #205 has been restored to commitbc77a610and its original fixture evidence.Verification
pnpm build,pnpm type-check, andpnpm -r test:unitpassedpnpm check:jsr,pnpm test:release-tooling, andpnpm test:tutorialpassedgit diff --checkand the optimizer-path boundary audit passedorigin/main(js-yaml,nanoid, andpostcss); this branch changes no dependency or lockfileOut of scope
The PR #205 optimizer loader adaptation to the amended request-object API remains with that optimizer PR and should be applied after this protocol PR lands.