-
Notifications
You must be signed in to change notification settings - Fork 16.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Deprecate LLMSymbolicMath from langchain core (#11615)
Deprecate LLMSymbolicMath from langchain core package.
- Loading branch information
Showing
4 changed files
with
10 additions
and
301 deletions.
There are no files selected for viewing
22 changes: 10 additions & 12 deletions
22
libs/langchain/langchain/chains/llm_symbolic_math/__init__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,12 @@ | ||
"""Chain that interprets a prompt and executes python code to do math. | ||
def raise_on_import() -> None: | ||
"""Raise an error on import since is deprecated.""" | ||
raise ImportError( | ||
"This module has been moved to langchain-experimental. " | ||
"For more details: https://github.com/langchain-ai/langchain/discussions/11352." | ||
"To access this code, install it with `pip install langchain-experimental`." | ||
"`from langchain_experimental.llm_symbolic_math.base " | ||
"import LLMSymbolicMathChain`" | ||
) | ||
|
||
Heavily borrowed from llm_math, wrapper for SymPy | ||
""" | ||
from langchain._api import warn_deprecated | ||
|
||
warn_deprecated( | ||
since="0.0.304", | ||
message=( | ||
"On 2023-10-06 this module will be moved to langchain-experimental as " | ||
"it relies on sympy https://github.com/sympy/sympy/issues/10805" | ||
), | ||
pending=True, | ||
) | ||
raise_on_import() |
156 changes: 0 additions & 156 deletions
156
libs/langchain/langchain/chains/llm_symbolic_math/base.py
This file was deleted.
Oops, something went wrong.
51 changes: 0 additions & 51 deletions
51
libs/langchain/langchain/chains/llm_symbolic_math/prompt.py
This file was deleted.
Oops, something went wrong.
82 changes: 0 additions & 82 deletions
82
libs/langchain/tests/unit_tests/chains/test_llm_symbolic_math.py
This file was deleted.
Oops, something went wrong.