Skip to content

Commit 87dc768

Browse files
committed
add a quick comment
1 parent 0134e60 commit 87dc768

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

dev-packages/e2e-tests/test-applications/nextjs-15/tests/ai-error.test.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,11 @@ test('should create AI spans with correct attributes and error linking', async (
2020

2121
const spans = aiTransaction.spans || [];
2222

23+
// Each generateText call should create 2 spans: one for the pipeline and one for doGenerate
24+
// Plus a span for the tool call
25+
// TODO: For now, this is sadly not fully working - the monkey patching of the ai package is not working
26+
// because of this, only spans that are manually opted-in at call time will be captured
27+
// this may be fixed by https://github.com/vercel/ai/pull/6716 in the future
2328
const aiPipelineSpans = spans.filter(span => span.op === 'gen_ai.invoke_agent');
2429
const aiGenerateSpans = spans.filter(span => span.op === 'gen_ai.generate_text');
2530
const toolCallSpans = spans.filter(span => span.op === 'gen_ai.execute_tool');

0 commit comments

Comments
 (0)