mirror of
https://github.com/hwchase17/langchain.git
synced 2026-07-15 15:40:34 +00:00
Merge branch 'master' into wip-v1.0
This commit is contained in:
20
.github/pr-title-labeler.yml
vendored
20
.github/pr-title-labeler.yml
vendored
@@ -3,6 +3,7 @@
|
||||
# Format: type(scope): description or type!: description (breaking)
|
||||
|
||||
add-missing-labels: true
|
||||
clear-prexisting: false
|
||||
include-commits: false
|
||||
include-title: true
|
||||
label-for-breaking-changes: breaking
|
||||
@@ -21,7 +22,24 @@ label-mapping:
|
||||
infra: ["chore", "ci", "build", "infra"]
|
||||
|
||||
# Integration partners - detected by scope
|
||||
integration: ["anthropic", "chroma", "deepseek", "exa", "fireworks", "groq", "huggingface", "mistralai", "nomic", "ollama", "openai", "perplexity", "prompty", "qdrant", "xai"]
|
||||
integration:
|
||||
[
|
||||
"anthropic",
|
||||
"chroma",
|
||||
"deepseek",
|
||||
"exa",
|
||||
"fireworks",
|
||||
"groq",
|
||||
"huggingface",
|
||||
"mistralai",
|
||||
"nomic",
|
||||
"ollama",
|
||||
"openai",
|
||||
"perplexity",
|
||||
"prompty",
|
||||
"qdrant",
|
||||
"xai",
|
||||
]
|
||||
|
||||
# Releases
|
||||
release: ["release"]
|
||||
|
||||
@@ -149,7 +149,7 @@ class HumanInTheLoopMiddleware(AgentMiddleware):
|
||||
if not messages:
|
||||
return None
|
||||
|
||||
last_ai_msg = next((msg for msg in messages if isinstance(msg, AIMessage)), None)
|
||||
last_ai_msg = next((msg for msg in reversed(messages) if isinstance(msg, AIMessage)), None)
|
||||
if not last_ai_msg or not last_ai_msg.tool_calls:
|
||||
return None
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@ dependencies = [
|
||||
]
|
||||
|
||||
name = "langchain"
|
||||
version = "1.0.0a6"
|
||||
version = "1.0.0a7"
|
||||
description = "Building applications with LLMs through composability"
|
||||
readme = "README.md"
|
||||
|
||||
|
||||
@@ -438,6 +438,15 @@ def test_human_in_the_loop_middleware_single_tool_accept() -> None:
|
||||
assert result["messages"][0] == ai_message
|
||||
assert result["messages"][0].tool_calls == ai_message.tool_calls
|
||||
|
||||
state["messages"].append(
|
||||
ToolMessage(content="Tool message", name="test_tool", tool_call_id="1")
|
||||
)
|
||||
state["messages"].append(AIMessage(content="test_tool called with result: Tool message"))
|
||||
|
||||
result = middleware.after_model(state)
|
||||
# No interrupts needed
|
||||
assert result is None
|
||||
|
||||
|
||||
def test_human_in_the_loop_middleware_single_tool_edit() -> None:
|
||||
"""Test HumanInTheLoopMiddleware with single tool edit response."""
|
||||
|
||||
10
libs/langchain_v1/uv.lock
generated
10
libs/langchain_v1/uv.lock
generated
@@ -1,5 +1,5 @@
|
||||
version = 1
|
||||
revision = 3
|
||||
revision = 2
|
||||
requires-python = ">=3.10.0, <4.0.0"
|
||||
resolution-markers = [
|
||||
"python_full_version >= '3.13' and platform_python_implementation == 'PyPy'",
|
||||
@@ -736,7 +736,7 @@ name = "exceptiongroup"
|
||||
version = "1.3.0"
|
||||
source = { registry = "https://pypi.org/simple" }
|
||||
dependencies = [
|
||||
{ name = "typing-extensions", marker = "python_full_version < '3.12'" },
|
||||
{ name = "typing-extensions", marker = "python_full_version < '3.11'" },
|
||||
]
|
||||
sdist = { url = "https://files.pythonhosted.org/packages/0b/9f/a65090624ecf468cdca03533906e7c69ed7588582240cfe7cc9e770b50eb/exceptiongroup-1.3.0.tar.gz", hash = "sha256:b241f5885f560bc56a59ee63ca4c6a8bfa46ae4ad651af316d4e81817bb9fd88", size = 29749, upload-time = "2025-05-10T17:42:51.123Z" }
|
||||
wheels = [
|
||||
@@ -1543,7 +1543,7 @@ wheels = [
|
||||
|
||||
[[package]]
|
||||
name = "langchain"
|
||||
version = "1.0.0a6"
|
||||
version = "1.0.0a7"
|
||||
source = { editable = "." }
|
||||
dependencies = [
|
||||
{ name = "langchain-core" },
|
||||
@@ -1975,7 +1975,7 @@ dependencies = [
|
||||
[package.metadata]
|
||||
requires-dist = [
|
||||
{ name = "langchain-core", editable = "../core" },
|
||||
{ name = "openai", specifier = ">=1.104.2,<2.0.0" },
|
||||
{ name = "openai", specifier = ">=1.104.2,<1.108.0" },
|
||||
{ name = "tiktoken", specifier = ">=0.7.0,<1.0.0" },
|
||||
]
|
||||
|
||||
@@ -2102,6 +2102,8 @@ test = [
|
||||
test-integration = [
|
||||
{ name = "en-core-web-sm", url = "https://github.com/explosion/spacy-models/releases/download/en_core_web_sm-3.8.0/en_core_web_sm-3.8.0-py3-none-any.whl" },
|
||||
{ name = "nltk", specifier = ">=3.9.1,<4.0.0" },
|
||||
{ name = "scipy", marker = "python_full_version == '3.12.*'", specifier = ">=1.7.0,<2.0.0" },
|
||||
{ name = "scipy", marker = "python_full_version >= '3.13'", specifier = ">=1.14.1,<2.0.0" },
|
||||
{ name = "sentence-transformers", specifier = ">=3.0.1,<4.0.0" },
|
||||
{ name = "spacy", specifier = ">=3.8.7,<4.0.0" },
|
||||
{ name = "thinc", specifier = ">=8.3.6,<9.0.0" },
|
||||
|
||||
Reference in New Issue
Block a user