Skip to main content
Initialize the Weave client, which is required for weave tracing to work.

Parameters

string
required
The W&B project name (can be project or entity/project). If you don’t specify a W&B team (e.g., ‘team/project’), your default entity is used. To find or update your default entity, refer to User Settings at https://docs.wandb.ai/platform/app/settings-page/user-settings#default-team
Partial<{…}>
(Optional) Weave tracing settingsFull type: Partial<{ attributes: Record<string, any>; genai: { batchOptions?: BufferConfig; spanProcessor?: "batch" | "simple" | SpanProcessor; }; printCallLink: boolean; useCallsComplete: boolean; useOTelV2: boolean; }>

Returns

Promise<WeaveClient> A promise that resolves to the initialized Weave client.

Throws

If the initialization fails