Some checks failed
Build & Deploy / 🔍 Prepare (push) Successful in 20s
Build & Deploy / 🧪 QA (push) Failing after 34s
Build & Deploy / 🏗️ Build (push) Has started running
Build & Deploy / 🚀 Deploy (push) Has been cancelled
Build & Deploy / 🧪 Smoke Test (push) Has been cancelled
Build & Deploy / ⚡ Lighthouse (push) Has been cancelled
Build & Deploy / 🔔 Notify (push) Has been cancelled
21 lines
908 B
Plaintext
21 lines
908 B
Plaintext
import type { Span } from '../../types-hoist/span';
|
|
import type { AnthropicAiInstrumentedMethod, AnthropicAiResponse } from './types';
|
|
/**
|
|
* Check if a method path should be instrumented
|
|
*/
|
|
export declare function shouldInstrument(methodPath: string): methodPath is AnthropicAiInstrumentedMethod;
|
|
/**
|
|
* Set the messages and messages original length attributes.
|
|
* Extracts system instructions before truncation.
|
|
*/
|
|
export declare function setMessagesAttribute(span: Span, messages: unknown): void;
|
|
/**
|
|
* Capture error information from the response
|
|
* @see https://docs.anthropic.com/en/api/errors#error-shapes
|
|
*/
|
|
export declare function handleResponseError(span: Span, response: AnthropicAiResponse): void;
|
|
/**
|
|
* Include the system prompt in the messages list, if available
|
|
*/
|
|
export declare function messagesFromParams(params: Record<string, unknown>): unknown[];
|
|
//# sourceMappingURL=utils.d.ts.map |