@glassflow-ai/rius 0.6.0 → 0.6.1
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/README.md +3 -1
- package/dist/index.cjs +5 -3
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +5 -3
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -247,7 +247,9 @@ Traces are posted to `<endpoint>/v1/traces`.
|
|
|
247
247
|
completions, tool arguments) is attached to spans. It defaults to
|
|
248
248
|
`true`. Set it to `false`, or supply a `mask` function, if your spans
|
|
249
249
|
must not carry raw content. Both apply to span attributes and to the
|
|
250
|
-
attributes of span events and links
|
|
250
|
+
attributes of span events and links, including the `metadata.*` copies the
|
|
251
|
+
Vercel AI SDK transform makes of attributes it does not translate: a
|
|
252
|
+
`metadata.<key>` is content exactly when `<key>` is. With `captureContent: false` the
|
|
251
253
|
message and stacktrace of a recorded exception are stripped as well,
|
|
252
254
|
since provider errors routinely echo the request back; the exception
|
|
253
255
|
event and its `exception.type` are kept, so failures stay visible.
|
package/dist/index.cjs
CHANGED
|
@@ -1034,7 +1034,8 @@ var init_instrumentation = __esm({
|
|
|
1034
1034
|
function isContentKey(key) {
|
|
1035
1035
|
if (CONTENT_ATTRIBUTES.has(key)) return true;
|
|
1036
1036
|
if (CONTENT_ATTRIBUTE_PREFIXES.some((p) => key.startsWith(p))) return true;
|
|
1037
|
-
|
|
1037
|
+
if (CONTENT_ATTRIBUTE_SUFFIXES.some((s) => key.endsWith(s))) return true;
|
|
1038
|
+
return key.startsWith(METADATA_PREFIX) && isContentKey(key.slice(METADATA_PREFIX.length));
|
|
1038
1039
|
}
|
|
1039
1040
|
function redactInvocationParameters(value) {
|
|
1040
1041
|
if (typeof value !== "string") return void 0;
|
|
@@ -1054,7 +1055,7 @@ function redactInvocationParameters(value) {
|
|
|
1054
1055
|
for (const member of INVOCATION_PARAMETERS_CONTENT_MEMBERS) delete bag[member];
|
|
1055
1056
|
return JSON.stringify(bag);
|
|
1056
1057
|
}
|
|
1057
|
-
var import_api4, EXCEPTION_EVENT_NAME, EXCEPTION_CONTENT_KEYS, STATUS_DESCRIPTION_KEY, MaskingSpanExporter;
|
|
1058
|
+
var import_api4, METADATA_PREFIX, EXCEPTION_EVENT_NAME, EXCEPTION_CONTENT_KEYS, STATUS_DESCRIPTION_KEY, MaskingSpanExporter;
|
|
1058
1059
|
var init_masking = __esm({
|
|
1059
1060
|
"src/masking.ts"() {
|
|
1060
1061
|
"use strict";
|
|
@@ -1062,6 +1063,7 @@ var init_masking = __esm({
|
|
|
1062
1063
|
import_api4 = require("@opentelemetry/api");
|
|
1063
1064
|
init_semconv();
|
|
1064
1065
|
init_serde();
|
|
1066
|
+
METADATA_PREFIX = "metadata.";
|
|
1065
1067
|
EXCEPTION_EVENT_NAME = "exception";
|
|
1066
1068
|
EXCEPTION_CONTENT_KEYS = ["exception.message", "exception.stacktrace"];
|
|
1067
1069
|
STATUS_DESCRIPTION_KEY = "status.description";
|
|
@@ -1833,7 +1835,7 @@ init_session();
|
|
|
1833
1835
|
init_user();
|
|
1834
1836
|
init_spans();
|
|
1835
1837
|
init_workspace();
|
|
1836
|
-
var VERSION = "0.6.
|
|
1838
|
+
var VERSION = "0.6.1";
|
|
1837
1839
|
// Annotate the CommonJS export names for ESM import in node:
|
|
1838
1840
|
0 && (module.exports = {
|
|
1839
1841
|
Generation,
|
package/dist/index.d.cts
CHANGED
|
@@ -441,6 +441,6 @@ declare function withSession<T>(sessionId: string, fn: (sessionId: string) => T)
|
|
|
441
441
|
*/
|
|
442
442
|
declare function withUser<T>(userId: string, fn: (userId: string) => T): T;
|
|
443
443
|
|
|
444
|
-
declare const VERSION = "0.6.
|
|
444
|
+
declare const VERSION = "0.6.1";
|
|
445
445
|
|
|
446
446
|
export { Generation, type GenerationBody, type GenerationOptions, type InitOptions, type Mask, Observation, type ObserveOptions, RiusClient, type RiusOptions, type SpanBody, SpanKind, type SpanOptions, VERSION, type WorkspaceExporterFactory, getTracer, init, observe, registerWorkspace, startAsCurrentGeneration, startAsCurrentSpan, startGeneration, startSpan, withSession, withUser, withWorkspace };
|
package/dist/index.d.ts
CHANGED
|
@@ -441,6 +441,6 @@ declare function withSession<T>(sessionId: string, fn: (sessionId: string) => T)
|
|
|
441
441
|
*/
|
|
442
442
|
declare function withUser<T>(userId: string, fn: (userId: string) => T): T;
|
|
443
443
|
|
|
444
|
-
declare const VERSION = "0.6.
|
|
444
|
+
declare const VERSION = "0.6.1";
|
|
445
445
|
|
|
446
446
|
export { Generation, type GenerationBody, type GenerationOptions, type InitOptions, type Mask, Observation, type ObserveOptions, RiusClient, type RiusOptions, type SpanBody, SpanKind, type SpanOptions, VERSION, type WorkspaceExporterFactory, getTracer, init, observe, registerWorkspace, startAsCurrentGeneration, startAsCurrentSpan, startGeneration, startSpan, withSession, withUser, withWorkspace };
|
package/dist/index.js
CHANGED
|
@@ -1022,7 +1022,8 @@ import { SpanStatusCode as SpanStatusCode3 } from "@opentelemetry/api";
|
|
|
1022
1022
|
function isContentKey(key) {
|
|
1023
1023
|
if (CONTENT_ATTRIBUTES.has(key)) return true;
|
|
1024
1024
|
if (CONTENT_ATTRIBUTE_PREFIXES.some((p) => key.startsWith(p))) return true;
|
|
1025
|
-
|
|
1025
|
+
if (CONTENT_ATTRIBUTE_SUFFIXES.some((s) => key.endsWith(s))) return true;
|
|
1026
|
+
return key.startsWith(METADATA_PREFIX) && isContentKey(key.slice(METADATA_PREFIX.length));
|
|
1026
1027
|
}
|
|
1027
1028
|
function redactInvocationParameters(value) {
|
|
1028
1029
|
if (typeof value !== "string") return void 0;
|
|
@@ -1042,13 +1043,14 @@ function redactInvocationParameters(value) {
|
|
|
1042
1043
|
for (const member of INVOCATION_PARAMETERS_CONTENT_MEMBERS) delete bag[member];
|
|
1043
1044
|
return JSON.stringify(bag);
|
|
1044
1045
|
}
|
|
1045
|
-
var EXCEPTION_EVENT_NAME, EXCEPTION_CONTENT_KEYS, STATUS_DESCRIPTION_KEY, MaskingSpanExporter;
|
|
1046
|
+
var METADATA_PREFIX, EXCEPTION_EVENT_NAME, EXCEPTION_CONTENT_KEYS, STATUS_DESCRIPTION_KEY, MaskingSpanExporter;
|
|
1046
1047
|
var init_masking = __esm({
|
|
1047
1048
|
"src/masking.ts"() {
|
|
1048
1049
|
"use strict";
|
|
1049
1050
|
init_esm_shims();
|
|
1050
1051
|
init_semconv();
|
|
1051
1052
|
init_serde();
|
|
1053
|
+
METADATA_PREFIX = "metadata.";
|
|
1052
1054
|
EXCEPTION_EVENT_NAME = "exception";
|
|
1053
1055
|
EXCEPTION_CONTENT_KEYS = ["exception.message", "exception.stacktrace"];
|
|
1054
1056
|
STATUS_DESCRIPTION_KEY = "status.description";
|
|
@@ -1804,7 +1806,7 @@ init_session();
|
|
|
1804
1806
|
init_user();
|
|
1805
1807
|
init_spans();
|
|
1806
1808
|
init_workspace();
|
|
1807
|
-
var VERSION = "0.6.
|
|
1809
|
+
var VERSION = "0.6.1";
|
|
1808
1810
|
export {
|
|
1809
1811
|
Generation,
|
|
1810
1812
|
Observation,
|