Skip to content

Commit e96f13b

Browse files
committed
add docs
1 parent f7b064b commit e96f13b

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

langfuse/langchain/CallbackHandler.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,12 @@ class LangchainCallbackHandler(LangchainBaseCallbackHandler):
5959
def __init__(
6060
self, *, public_key: Optional[str] = None, update_trace: bool = False
6161
) -> None:
62+
"""Initialize the LangchainCallbackHandler.
63+
64+
Args:
65+
public_key: Optional Langfuse public key. If not provided, will use the default client configuration.
66+
update_trace: Whether to update the Langfuse trace with the chains input / output / metadata / name. Defaults to False.
67+
"""
6268
self.client = get_client(public_key=public_key)
6369

6470
self.runs: Dict[UUID, Union[LangfuseSpan, LangfuseGeneration]] = {}

0 commit comments

Comments
 (0)