Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Langfuse question #1868

Open
yamonkjd opened this issue May 9, 2024 · 1 comment
Open

Langfuse question #1868

yamonkjd opened this issue May 9, 2024 · 1 comment
Labels
question Further information is requested

Comments

@yamonkjd
Copy link
Contributor

yamonkjd commented May 9, 2024

Request for Explanation Regarding Changes in Internal Callback Method Management Logic in Langflow Upgrade to v1.0 for Langfuse Pull Request

I'm requesting an explanation regarding changes in the internal callback method management logic in the Langflow upgrade to v1.0. It seems that records are not being correctly logged in Langfuse as a result. This request is to gather information for the purpose of creating a pull request.

Copy link

dosubot bot commented May 9, 2024

The changes in Langflow v1.0 affecting Langfuse record logging stem from new callback handling mechanisms and their integration. Here's a concise overview to address the logging issues:

  1. Callback Handlers: Langflow v1.0 introduces StreamingLLMCallbackHandler and AsyncStreamingLLMCallbackHandler for sync and async operations, respectively. The choice between these handlers impacts how records are logged in Langfuse, especially regarding the timing and order of operations.

  2. Dynamic Callback Setup: The setup_callbacks function now dynamically sets up callbacks based on operation mode and integrates plugin callbacks, including Langfuse. This could affect logging if Langfuse callbacks have specific requirements not correctly accounted for after the upgrade.

  3. Langfuse Callback Integration: The integration process involves initializing a Langfuse callback with credentials and trace information through the get_langfuse_callback function. Any changes or issues here could lead to incorrect logging.

  4. Flush Mechanism: The flush_langfuse_callback_if_present function ensures all pending records are logged in Langfuse by calling the flush method of the Langfuse callback. Changes in the management or timing of this operation could impact logging.

To resolve logging issues, ensure the correct callback handler is used, review and update Langfuse callback integration, verify the flush mechanism is correctly triggered, and test the entire flow. Detailed insights and potential solutions can be found in the source code and migration guide available on the project's GitHub repository.

Details

Sources


About Dosu
This response is meant to be useful and save you time. It is not meant to be a precise solution, but rather a starting point for your own research.

Help me be more useful! Please leave a 👍 if this is helpful and 👎 if it is irrelevant.

To continue the conversation, mention @dosu.

@dosubot dosubot bot added the question Further information is requested label May 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant