ref!: Reduce API to a minimum that makes sense - #2429
Open
Luca Forstner (lforst) wants to merge 1 commit into
Open
ref!: Reduce API to a minimum that makes sense#2429Luca Forstner (lforst) wants to merge 1 commit into
Luca Forstner (lforst) wants to merge 1 commit into
Conversation
Abhijeet Prasad (AbhiPrasad)
left a comment
Member
There was a problem hiding this comment.
can we ai up a description that details what was removed? I figured we can just spend tokens once on it lol
Member
Author
Abhijeet Prasad (@AbhiPrasad) yeah I owed that at least 🌝 |
Abhijeet Prasad (AbhiPrasad)
approved these changes
Sep 3, 2026
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.
ref braintrustdata/braintrust-sdk-javascript#1841
braintrustexport surface with an explicit allowlist, removing roughly 140 named exports—primarily internal helpers, implementation classes, schemas, constants, and low-level types.StartSpanArgs,Span, tracing context types, eval callbacks, reporters, template plugins, and durable-eval stores.braintrust/browser,braintrust/util, andbraintrust/webpack-loader; the util bundle is no longer built or published.braintrust/nextnow resolves its built loader directly instead of exposing it as a package entrypoint._exportsForTestingOnly,_internalIso,_internalGetGlobalState,_internalSetInitialState,SpanImpl,NoopSpan,TestBackgroundLogger,ObjectFetcher, and ID-generator classes.graph,Project,CodeFunction,CodePrompt,PromptBuilder,ScorerBuilder, andToolBuilder; theprojectsfacade remains.log,summarize,traceable,newId,permalink,deepCopyEvent, template-registry internals, span fetchers, and logs-overflow helpers.BraintrustMiddlewareandwrapAISDKModelwrapMastraAgentwithExperimentandwithDatasettoAIStreamResponseesbuildPlugin,rollupPlugin,vitePlugin, andwebpackPluginuseDiagnosticChannelCompatShimExperiment.close(),Dataset.close(), andSpan.close()EvalHooks.meta,EvalResultWithSummary.toString(), andScore.errorinitExperimentinit()andinitDataset()overloadsuseOutputmode and theoutputrecord aliasinputsanddatasetRecordIdfieldswrapOpenAIv4EvalResultWithSummaryfrom an exported runtime class to a plain{ summary, results }result shape.PropagationContext; serialized span-slug strings remain internal plumbing. The public type is still namedStartSpanArgs.configureContextManager()andContextManager.getCurrentSpanStore()as the supported context integration mechanism, replacing global symbols and direct state mutation.configureInstrumentation,InstrumentationConfig, and Eve/Flue instrumentation remain underbraintrust/instrumentation.registerOtelFlushnow lives there as the narrow OTEL hook.configureContextManager()instead of internal globals.contextFromSpanExport(string)withcontextFromSpan(span).parentFromHeaders()now returns opaque W3C propagation context..env.braintrusthandling is self-contained and Edge-safe.traceparent,tracestate, andbaggage, covering client→workflow, child workflow, and same-/cross-worker activity parenting.@braintrust/browserto install a browserContextManagerthrough the public configuration API instead of mutating core isomorph internals.braintrust/utiland the exportedBraintrustStreamChunk; the adapter now derives its stream chunk type fromBraintrustStream.vercel,google,cursor,bedrock, andawsBedrock; environment spellings still map to canonical keys.