Skip to content

@uservane/langfuse-push: LangfuseScoreClient

LangfuseScoreClient = object

Defined in: index.ts:35

Minimal Langfuse surface we use (matches installed SDK; injectable for tests).

flush(callback): void

Defined in: index.ts:56

Drain the ingestion queue and report the result via the callback. We use flush(cb), NOT flushAsync(): verified against langfuse-core@3.38.20 (lib/index.mjs), flushAsync() SWALLOWS an ingestion HTTP failure (logIngestionError + resolve, never rejects), so it cannot distinguish a delivered score from a lost one. flush(cb) surfaces the final error (after the SDK’s own fetch retries) as the callback’s err argument, which is the only reliable delivery confirmation the SDK exposes.

(err?) => void

void


score(body): unknown

Defined in: index.ts:36

string | null

string

Stable id so Langfuse UPSERTS on re-push (no duplicate scores).

string

string | null

string | null

string | null

Required with observationId for observation-level scores.

number

unknown