Skip to content

ref!: Don't make generated types part of public api - #2517

Merged
Luca Forstner (lforst) merged 6 commits into
v4from
lforst/dum-e/istanbul-f974789198
Sep 24, 2026
Merged

Luca Forstner (lforst) merged 6 commits into
v4from
lforst/dum-e/istanbul-f974789198

Conversation

@lforst

Copy link
Copy Markdown
Member

Ref SDK-226

  • Replace broad, backend-generated SDK types with smaller, explicit contracts, reducing the type complexity users’ editors and TypeScript compilers must process.
  • Bundle only the runtime validators the SDK needs. Previously, importing generated schemas also pulled unrelated backend validators into client bundles.
  • Simplify prompt and function types and remove internal cache-serialization methods from the public API, while preserving supported inputs and autocomplete.
  • Keep generated definitions as compatibility references, with tests checking type compatibility, validation behavior, autocomplete, and their exclusion from production bundles. All 1,536 replay tests pass.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lforst Luca Forstner (lforst) mentioned this pull request Sep 24, 2026
14 tasks
@lforst
Luca Forstner (lforst) merged commit 9dc5212 into v4 Sep 24, 2026
48 checks passed
@lforst
Luca Forstner (lforst) deleted the lforst/dum-e/istanbul-f974789198 branch September 24, 2026 16:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants