From c1a81fc46359b1969965abf5f85fdfd6ef663cd6 Mon Sep 17 00:00:00 2001 From: William FH <13333726+hinthornw@users.noreply.github.com> Date: Mon, 19 Feb 2024 22:07:23 -0800 Subject: [PATCH] Rename get_current_run_tree (#454) --- python/langsmith/run_helpers.py | 5 ++++- python/pyproject.toml | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/python/langsmith/run_helpers.py b/python/langsmith/run_helpers.py index 3f4f3057d..35ce222c7 100644 --- a/python/langsmith/run_helpers.py +++ b/python/langsmith/run_helpers.py @@ -47,11 +47,14 @@ _METADATA = contextvars.ContextVar[Optional[Dict[str, Any]]]("_METADATA", default=None) -def get_run_tree_context() -> Optional[run_trees.RunTree]: +def get_current_run_tree() -> Optional[run_trees.RunTree]: """Get the current run tree context.""" return _PARENT_RUN_TREE.get() +get_run_tree_context = get_current_run_tree + + def _is_traceable_function(func: Callable) -> bool: return getattr(func, "__langsmith_traceable__", False) diff --git a/python/pyproject.toml b/python/pyproject.toml index 5467a191c..ec0414b2f 100644 --- a/python/pyproject.toml +++ b/python/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "langsmith" -version = "0.1.2" +version = "0.1.3" description = "Client library to connect to the LangSmith LLM Tracing and Evaluation Platform." authors = ["LangChain "] license = "MIT"