async-bulkhead-llm - v3.17.0
    Preparing search index...

    Type Alias LLMRequestStats

    async-bulkhead-llm — public API surface.

    This entry point re-exports everything the package supports; the implementation lives in focused modules:

    • types.ts — request/result/options/stats/event types
    • errors.tsLLMBulkheadRejectedError
    • profiles.tsPROFILES presets
    • estimators.ts — naive + model-aware estimators, extractTextLength
    • adaptive.tscreateAdaptiveTokenEstimator (v3.8)
    • dedup.ts — deduplication internals (keying, share safety)
    • validation.ts — internal numeric/estimate/usage guards
    • bulkhead.tscreateLLMBulkhead (admission, budget, events)

    Deep-importing the internal modules is not supported; the package exports map exposes only this entry point.

    type LLMRequestStats = {
        admitted: number;
        borrowedConcurrencyAbandoned: number;
        borrowedConcurrencyAbandonedByCause: Partial<
            Record<LLMBorrowedConcurrencyAbandonCause, number>,
        >;
        inFlight: number;
        rejected: number;
        rejectedByReason: Partial<Record<LLMRejectReason, number>>;
        released: number;
    }
    Index
    admitted: number

    Successful LLM admissions (slot + budget acquired).

    borrowedConcurrencyAbandoned: number

    Borrowed concurrency slots returned before upstream work settled.

    borrowedConcurrencyAbandonedByCause: Partial<
        Record<LLMBorrowedConcurrencyAbandonCause, number>,
    >

    Borrowed concurrency abandonments split by cause.

    inFlight: number

    Capacity-holding LLM admissions that have not reached final settlement.

    rejected: number

    Total LLM-layer rejections.

    rejectedByReason: Partial<Record<LLMRejectReason, number>>

    LLM-layer rejections by reason.

    released: number

    Successful LLM releases via the wrapped LLM token.