Skip to content

Conversation

emranbm
Copy link
Collaborator

@emranbm emranbm commented May 14, 2025

Send ingestion events (currently just Traces) in async batches. Best regards to the old implementation sample

@emranbm emranbm requested a review from Copilot May 14, 2025 09:06
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces asynchronous event ingestion for Trace events and implements an option pattern for customizing traces. Key changes include the addition of new option functions in pkg/langfuse/options.go, comprehensive tests for client behavior in pkg/langfuse/client_test.go, and a refactor that removes the legacy pkg/client files.

Reviewed Changes

Copilot reviewed 12 out of 12 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
pkg/langfuse/options.go Adds WithTags and WithSessionID options to customize trace objects.
pkg/langfuse/client.go & client_test.go Implements async event sending and prompt template conversion with accompanying tests.
internal/observer/.go and internal/models/.go Introduces and integrates the observer pattern and updated models for ingestion events.
pkg/client/* Removes legacy client files in favor of the new implementation in pkg/langfuse.
go.mod Updates module dependencies to support the new functionality.
Comments suppressed due to low confidence (1)

pkg/client/client.go:1

  • [nitpick] The removal of the legacy 'client' package files appears intentional. Please ensure that all references to these files are updated accordingly.
package client

@emranbm emranbm enabled auto-merge May 14, 2025 14:49
@emranbm emranbm requested a review from mehran-prs May 14, 2025 16:28
@emranbm emranbm force-pushed the ingestion branch 2 times, most recently from 4607987 to 6f0bc96 Compare July 19, 2025 14:29
@emranbm emranbm requested a review from mehran-prs July 19, 2025 15:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants