Should the Langfuse classs initialization be cached (does it do any I/O on init?) ? #4046
-
Hey, I'm calling Thanks from langfuse import Langfuse
langfuse = Langfuse(
secret_key="...",
public_key="...",
host="http://localhost:port"
) |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
Do you use the Langchain integration? If yes, I'd create a single |
Beta Was this translation helpful? Give feedback.
It just initializes the class and spawns a background process which handles the queue of events that need to be send to langfuse. Thus this will have some (minor) cpu/memory footprint which can be noticed when creating many instances in parallel.