Repository navigation
Land wave 2b R3: structured calls, model allowlist, policy bundles, rate-limit posture - #196
Merged
Merged
Conversation
An opt-in structured `generate()` calls the provider directly, validates the response against a trusted Zod schema with bounded repairs, and runs object and answer policies on canonical JSON before returning the value or saving the exchange; a denied or unevaluable output is never returned or stored. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Wave 2b, CP-S2. Stacked on #166 (CP-S1); merges in the wave 2b R3 release. Draft until then. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…el-entry settings; sum usage Denied and policy-error structured-output events no longer carry an object digest an audit reader could reverse for a small object; the digest is computed only after policy approval. The direct model call applies the model-list entry's headers, settings and provider options as Mastra does, and `usage` sums every attempt including repairs, on results and thrown errors. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Document standalone object coverage and direct structured output checks. Remove the obsolete claim that guarded agents reject structured output. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Share model-entry resolution across generate and stream. Preserve refusal audit redaction and cumulative repair usage. Reconcile stream documentation and remove shadowed bindings. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Expose token totals across attempts on the usage promise and terminal events. Cover repaired and refused calls and document stream cancellation. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Normalize model-entry provider options to the shared V2 shape. Use Mastra format-2 messages for guarded input and repairs. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Share direct-call authorization with structured generation. Keep Mastra's authorization marker and object-only policy refusals. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Require a schema for object results and preserve text result inference. Pin the overloads and correct the config and policy fixtures. Co-Authored-By: Claude Opus 5.5 <[email protected]>
stream() follows generate()'s overloads: a schema returns the guarded object stream; an omitted or undefined structuredOutput keeps the unstructured type. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Move call-option types into a shared type-only module. Preserve the public type export through the agent entry point. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Structured stream options live in the type-only call-options module; the per-call maxRepairs refusal test types its widened input explicitly. Co-Authored-By: Claude Opus 5.5 <[email protected]>
RATE_LIMIT_EXCEEDED carries retryAfterMs. rateLimitStoreFailure: deny (default) or allow for read connectors only, which audits each bypass as RATE_LIMIT_STORE_BYPASSED. Co-Authored-By: Claude Opus 5.5 <[email protected]>
createGuardedObjectWorkflow runs a Breakwater structured call in the run object with a registration-time schema; only the policy-approved object is stored. The optional Breakwater peer floor rises to 0.20.0. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Compile and validate a bundle before construction; bundle-bound decisions carry its id, version and declaration hash; policyCoverage() reports installed controls and host-declared coverage. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Refuse the allow posture without an audit logger, treat an invalid store count as a store failure, and document caller-provoked bypasses (W3-B7 risk lane). Co-Authored-By: Claude Opus 5.5 <[email protected]>
Document the drain before a downgrade and that refused input stays stored until retention removes it.
The misspelled-option tests compare against the full field list, which now includes structuredOutput.
The exhaustive policy fixture and the construction-read table name every ConnectorPolicies member, including the store-failure posture.
Carry the guarded config field list that includes structuredOutput.
Carry the guarded config field list that includes structuredOutput.
Read inline acknowledgements at both migration gates and keep the compiled value for bundles. Cover bundle source mutations and align the agent fixture.
The refusal's details carry the time-dependent retry delay.
Zod is a runtime dependency, so the isolated consumer resolves it from the package's own install as it does jose.
createGuardedAgent() takes allowedProviders and allowedModelHosts and checks every model slot (primary, fallbacks, sub-agents, scorers, memory, workflow agents) at construction; an unlisted or unreadable slot is a TypeError.
TS2859: the intersection with baseURL made the guarded config comparison too complex to check.
Check processor-held model agents, refuse opaque processor workflow steps, re-check current models, memory and gateways at each guarded entry, refuse SDK model objects under a host allowlist, and require https or wss with a listed port.
Annotating the Object.assign fixtures as MastraModelConfig made tsc relate two 8,122-member unions while narrowing the model shorthand, and the checker ran out of map entries. testModel now returns the v2 gateway language model it builds, and the fixtures infer their types from it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Compile model allowlists with bundled agent policy. Preserve structured output, actor resolution, and bundle audit attribution. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Carry the store-failure posture through compiled connector policies. Require audit when constructing inline or bundle-bound connectors that allow rate-limit bypasses. Preserve retry hints and invalid-count handling. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Deploying with
|
| Status | Name | Latest Commit | Updated (UTC) |
|---|---|---|---|
| ✅ Deployment successful! View logs |
anchorage-showcase-single-tenant | 75437d7 | Nov 29 2026, 09:57 PM |
…plies BundledGuardedAgentConfig omits the keys of GuardedAgentPolicyOptions, so the API documentation build (warnings as errors, notExported) needs that type public from the agent entry and the package root. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
gcharang
marked this pull request as ready for review
November 29, 2026 22:16
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.
Stack tip for wave 2b release R3. Merging it lands, in one step, the open pull requests it contains:
Two merges needed resolution:
packages/breakwater/src/agent/index.ts): the bundle's configuration shape, policy snapshot and scoped audit logger, with B8's allowlist checks on every model slot. The bundle compiler validates and hashes both allowlists.packages/breakwater/src/connector-sdk/index.ts): the audit requirement for anallowstore-failure posture runs after inline or bundled audit is bound, and the compiled policy carriesrateLimitStoreFailure.Merge order: after wave 2b R2 (#193) is promoted to
main;devis merged into this branch first.🤖 Generated with Claude Code