Skip to content

@posthog/ai@8.21.0

Choose a tag to compare

@github-actions github-actions released this 17 Nov 20:25
Immutable release. Only release title and notes can be modified.
019218e

8.21.0

Minor Changes

  • #5407 6405dfd Thanks @eli-r-ph! - With posthog-node 6.x.x, every AI event is sent through captureAi on the capture v1 AI lane, and enableFullAiCapture only controls truncation and media redaction. With posthog-node 5.x.x, nothing changes: AI events use capture unless enableFullAiCapture is set.
    (2026-11-17)

  • #5407 6405dfd Thanks @eli-r-ph! - Add per-event options for posthog-node: posthogOptions on wrapped provider calls and withTracing(), and options on the LangChain, OpenAI Agents, Claude Agent SDK, Google ADK and Genkit integrations. An event with no distinct id still has person processing turned off. On posthog-node 6.x.x, AI events carry person processing only as the process_person_profile option. On posthog-node 5.x.x, each option that version knows is sent in the form it reads, and other keys are dropped. OpenAI Agents instrument() now passes every processor option, including options and onError, to the processor it registers.
    (2026-11-17)

Patch Changes

  • #5407 6405dfd Thanks @eli-r-ph! - Genkit spans and @posthog/mcp events with no user distinct id set the process_person_profile: false event option on posthog-node 6.x.x, so a registered or context process_person_profile: true option no longer creates a person for each trace or session. Genkit also counts an empty or whitespace-only distinct id as missing.
    (2026-11-17)

  • #5407 6405dfd Thanks @eli-r-ph! - Export the table of per-event options and the event properties posthog-node 5.x.x reads instead, so posthog-node, @posthog/ai and @posthog/mcp share one copy.
    (2026-11-17)

  • #5407 6405dfd Thanks @eli-r-ph! - @posthog/ai now recognizes posthog-node 6.x.x by its registerOptions method instead of by getLibraryVersion(). A posthog-node 6.x.x client whose version a wrapper or subclass overrides, for example @posthog/mcp, no longer sends its AI events to the analytics endpoint. posthog-node 5.x.x clients still use capture() unless enableFullAiCapture is on.
    (2026-11-17)

  • #5407 6405dfd Thanks @eli-r-ph! - Supports posthog-node 6.x.x. Exception autocapture passes an options object to captureException when the client is posthog-node 6.x.x, and positional arguments for posthog-node 5.x.x.
    (2026-11-17)

  • #5407 6405dfd Thanks @eli-r-ph! - An AI event with no user distinct id now also sets the process_person_profile: false event option, so with posthog-node 6.x.x it stays personless even when a context or registered option turns person processing on. An empty or whitespace-only distinct id now counts as missing in every integration, so the event uses the trace or run id and stays personless.
    (2026-11-17)

  • Updated dependencies [6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd, 6405dfd]:

    • @posthog/core@1.69.0
    • posthog-node@6.0.0