Packages

@posthog/ai

8.22.0 · 20 Nov 2026MIT1.9M / weekRepositoryHomepagenpmAtom feed

Your version

8.9.3

1 Sep 2026Where it was published

8.22.0 is the newest release of 8.x.

In short

1 fixed1 internal

Release note

Patch Changes

  • Capture $ai_stop_reason from LangChain runs that use the OpenAI Responses API.

    The callback only understood Chat Completions vocabulary (finish_reason / stop_reason), so Responses API runs, which report status and incomplete_details.reason instead, never carried a stop reason. The Chat Completions keys keep priority, and incomplete_details.reason outranks status, so an early stop names its cause (for example max_output_tokens) instead of just incomplete. (2026-09-01)

A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.