braintrust 3.25.0 → 3.26.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/NOTICE +6 -0
- package/dev/dist/index.d.mts +130 -2
- package/dev/dist/index.d.ts +130 -2
- package/dev/dist/index.js +2455 -1116
- package/dev/dist/index.mjs +1599 -260
- package/dist/apply-auto-instrumentation.js +439 -398
- package/dist/apply-auto-instrumentation.mjs +242 -201
- package/dist/auto-instrumentations/bundler/esbuild.cjs +853 -337
- package/dist/auto-instrumentations/bundler/esbuild.d.mts +4 -4
- package/dist/auto-instrumentations/bundler/esbuild.d.ts +4 -4
- package/dist/auto-instrumentations/bundler/esbuild.mjs +5 -8
- package/dist/auto-instrumentations/bundler/next.cjs +852 -356
- package/dist/auto-instrumentations/bundler/next.mjs +6 -29
- package/dist/auto-instrumentations/bundler/rollup.cjs +853 -337
- package/dist/auto-instrumentations/bundler/rollup.d.mts +4 -4
- package/dist/auto-instrumentations/bundler/rollup.d.ts +4 -4
- package/dist/auto-instrumentations/bundler/rollup.mjs +5 -8
- package/dist/auto-instrumentations/bundler/vite.cjs +853 -337
- package/dist/auto-instrumentations/bundler/vite.d.mts +4 -4
- package/dist/auto-instrumentations/bundler/vite.d.ts +4 -4
- package/dist/auto-instrumentations/bundler/vite.mjs +5 -8
- package/dist/auto-instrumentations/bundler/webpack-loader.cjs +1006 -266
- package/dist/auto-instrumentations/bundler/webpack-loader.d.ts +20 -12
- package/dist/auto-instrumentations/bundler/webpack.cjs +853 -337
- package/dist/auto-instrumentations/bundler/webpack.d.mts +4 -4
- package/dist/auto-instrumentations/bundler/webpack.d.ts +4 -4
- package/dist/auto-instrumentations/bundler/webpack.mjs +5 -4
- package/dist/auto-instrumentations/{chunk-JPVCUKTY.mjs → chunk-6E22MYSW.mjs} +165 -73
- package/dist/auto-instrumentations/{chunk-VT6DDNKM.mjs → chunk-AKKPLXTP.mjs} +631 -194
- package/dist/auto-instrumentations/chunk-NRE4QUQR.mjs +509 -0
- package/dist/auto-instrumentations/{chunk-7P6563SW.mjs → chunk-V5LEODRX.mjs} +2 -6
- package/dist/auto-instrumentations/{chunk-M6DLIJ2Z.mjs → chunk-XYN63IG5.mjs} +124 -194
- package/dist/auto-instrumentations/{chunk-CZ24KNHT.mjs → chunk-XZHHE4Y3.mjs} +77 -68
- package/dist/auto-instrumentations/hook.mjs +247 -182
- package/dist/auto-instrumentations/index.cjs +557 -48
- package/dist/auto-instrumentations/index.d.mts +6 -2
- package/dist/auto-instrumentations/index.d.ts +6 -2
- package/dist/auto-instrumentations/index.mjs +6 -1
- package/dist/auto-instrumentations/loader/cjs-patch.cjs +492 -195
- package/dist/auto-instrumentations/loader/cjs-patch.d.mts +2 -2
- package/dist/auto-instrumentations/loader/cjs-patch.d.ts +2 -2
- package/dist/auto-instrumentations/loader/cjs-patch.mjs +3 -2
- package/dist/auto-instrumentations/loader/esm-hook.mjs +1 -1
- package/dist/auto-instrumentations/plugin-B-aZh7EP.d.ts +30 -0
- package/dist/auto-instrumentations/plugin-Bnj4E_6B.d.mts +30 -0
- package/dist/auto-instrumentations/{types-RNPaKi9o.d.mts → types-C1fVeiCp.d.mts} +1 -1
- package/dist/auto-instrumentations/{types-RNPaKi9o.d.ts → types-C1fVeiCp.d.ts} +1 -1
- package/dist/browser.d.mts +817 -197
- package/dist/browser.d.ts +817 -197
- package/dist/browser.js +1883 -265
- package/dist/browser.mjs +1883 -265
- package/dist/{chunk-ABR2QWDP.mjs → chunk-PN7EWK66.mjs} +581 -133
- package/dist/{chunk-GSIDVFE6.js → chunk-VRZZQPAA.js} +1670 -736
- package/dist/{chunk-P25IOOU4.js → chunk-VYNNEKSA.js} +586 -138
- package/dist/{chunk-2SANLSWX.mjs → chunk-XIZOM2HO.mjs} +1052 -118
- package/dist/cli.js +1601 -263
- package/dist/edge-light.d.mts +1 -1
- package/dist/edge-light.d.ts +1 -1
- package/dist/edge-light.js +1883 -268
- package/dist/edge-light.mjs +1883 -268
- package/dist/index.d.mts +817 -197
- package/dist/index.d.ts +817 -197
- package/dist/index.js +695 -435
- package/dist/index.mjs +264 -4
- package/dist/instrumentation/index.d.mts +130 -6
- package/dist/instrumentation/index.d.ts +130 -6
- package/dist/instrumentation/index.js +1510 -80
- package/dist/instrumentation/index.mjs +1510 -80
- package/dist/vitest-evals-reporter.js +16 -16
- package/dist/vitest-evals-reporter.mjs +2 -2
- package/dist/workerd.d.mts +1 -1
- package/dist/workerd.d.ts +1 -1
- package/dist/workerd.js +1883 -268
- package/dist/workerd.mjs +1883 -268
- package/licenses/node-diagnostics-channel/LICENSE +19 -0
- package/package.json +34 -35
- package/dist/auto-instrumentations/plugin-D0KHwSJv.d.mts +0 -44
- package/dist/auto-instrumentations/plugin-G6fgxk1b.d.ts +0 -44
|
@@ -32,7 +32,7 @@ type FunctionQuery = (FunctionQueryBase & {
|
|
|
32
32
|
*/
|
|
33
33
|
interface InstrumentationConfig {
|
|
34
34
|
/**
|
|
35
|
-
* The name of the
|
|
35
|
+
* The name of the global instrumentation hook to invoke.
|
|
36
36
|
*/
|
|
37
37
|
channelName: string;
|
|
38
38
|
/**
|
|
@@ -67,23 +67,31 @@ interface ModuleMatcher {
|
|
|
67
67
|
filePath: string;
|
|
68
68
|
}
|
|
69
69
|
|
|
70
|
-
interface
|
|
71
|
-
/**
|
|
72
|
-
* Enable debug logging
|
|
73
|
-
*/
|
|
74
|
-
debug?: boolean;
|
|
70
|
+
interface BundlerPluginOptions {
|
|
75
71
|
/**
|
|
76
72
|
* Additional instrumentation configs to apply
|
|
77
73
|
*/
|
|
78
74
|
instrumentations?: InstrumentationConfig[];
|
|
79
75
|
/**
|
|
80
|
-
* Whether
|
|
76
|
+
* Whether the transformed source will run in a browser or edge-like
|
|
77
|
+
* environment.
|
|
81
78
|
*
|
|
82
|
-
*
|
|
83
|
-
*
|
|
84
|
-
*
|
|
79
|
+
* Global instrumentation hooks are runtime-independent. This option only
|
|
80
|
+
* prevents the Node-specific Mastra source patch from entering the bundle.
|
|
81
|
+
*
|
|
82
|
+
* @default false
|
|
85
83
|
*/
|
|
86
84
|
browser?: boolean;
|
|
85
|
+
/**
|
|
86
|
+
* Marks transformed source as targeting a browser or edge-like environment.
|
|
87
|
+
*
|
|
88
|
+
* This retains the previous browser-target behavior of the option. Global
|
|
89
|
+
* instrumentation hooks are runtime-independent, so no diagnostics-channel
|
|
90
|
+
* compatibility shim is injected.
|
|
91
|
+
*
|
|
92
|
+
* @deprecated Use `browser` instead.
|
|
93
|
+
*/
|
|
94
|
+
useDiagnosticChannelCompatShim?: boolean;
|
|
87
95
|
}
|
|
88
96
|
|
|
89
97
|
/**
|
|
@@ -112,11 +120,11 @@ interface LegacyBundlerPluginOptions {
|
|
|
112
120
|
/**
|
|
113
121
|
* Webpack loader that instruments JavaScript code using code-transformer.
|
|
114
122
|
*
|
|
115
|
-
* Accepts the same options as the
|
|
123
|
+
* Accepts the same options as the Braintrust bundler plugins.
|
|
116
124
|
*/
|
|
117
125
|
declare function codeTransformerLoader(this: any, code: string, inputSourceMap?: any): void;
|
|
118
126
|
declare namespace codeTransformerLoader {
|
|
119
|
-
type Options =
|
|
127
|
+
type Options = BundlerPluginOptions;
|
|
120
128
|
}
|
|
121
129
|
|
|
122
130
|
export { codeTransformerLoader as default };
|