[Reasoning Engine] LangchainAgent.stream_query attempts to import from deprecated langchain.load path
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 55/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- python
- Lĩnh vực
- ai, machine-learning
Hướng nghiên cứu
Bắt đầu với query() và stream_query() trong bốn tệp template bị ảnh hưởng: vertexai/agent_engines/templates/langchain.py, langgraph.py và các template preview/reasoning_engines tương ứng. So sánh các import và chạy các bài kiểm thử template hoặc tái hiện các lệnh gọi LangchainAgent và LanggraphAgent; hoàn thành khi cả hai phương thức không còn thất bại do import langchain.load đã lỗi thời.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Environment details
- OS type and version: Ubuntu 24.04.4 LTS
- Python version:
3.12.10 - pip version:
25.2 google-cloud-aiplatformversion:Latest from main
Steps to reproduce
- Initialize a
LangchainAgentorLanggraphAgentfrom the agent engine or reasoning engine templates. - Call the
queryorstream_querymethod. - Observe that it fails with an
ImportErrorbecause it attempts to import fromlangchain.loadinstead oflangchain_core.load.
Code example
from vertexai.agent_engines.templates.langchain import LangchainAgent
# Initialize agent
agent = LangchainAgent(model="gemini-1.5-flash-001")
agent.set_up()
# Both query and stream_query are affected
result = agent.query(input="Hello")
for chunk in agent.stream_query(input="Hello"):
print(chunk)
Stack trace
Traceback (most recent call last):
File "example.py", line 8, in <module>
for chunk in agent.stream_query(input="Hello"):
File ".../vertexai/agent_engines/templates/langchain.py", line 665, in stream_query
from langchain.load import dump as langchain_load_dump
ImportError: cannot import name 'dump' from 'langchain.load'
Affected files
The same deprecated import (from langchain.load import dump) exists in both query() and stream_query() across all 4 template modules:
vertexai/agent_engines/templates/langchain.pyvertexai/agent_engines/templates/langgraph.pyvertexai/preview/reasoning_engines/templates/langchain.pyvertexai/preview/reasoning_engines/templates/langgraph.py
Making sure to follow these steps will guarantee the quickest resolution possible.
Thanks!
- Ngôn ngữ chính
- Python
- Star
- 908
- Fork
- 468
- Merge trung bình
- 2 ngày 4 giờ
- Pull request đã merge (30 ngày)
- 25
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của googleapis/python-aiplatform
-
Protobuf 7.35.1+ supportCó thể đã có người làm @garethknowles đã nhận 24 ngày trước. Đang mởapi: vertex-ai
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 85/100
googleapis/python-aiplatform#7132 · 1 reaction ·
Maintainer thường phản hồi trong vòng 1 ngày
-
AgentEngineConfig.agent_framework Literal rejects "a2a" — out of sync with _SUPPORTED_AGENT_FRAMEWORKS and the GA A2A templateCó thể làm lại được Pull request cho issue này đã bị đóng mà không được merge. Đang mởapi: vertex-ai
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
googleapis/python-aiplatform#7097 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
CustomContainerTrainingJob.run drops max_wait_duration=0 instead of requesting indefinite DWS waitCó thể đã có người làm @hugosmoreira đã nhận 52 ngày trước. Đang mởapi: vertex-ai
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
googleapis/python-aiplatform#7067 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
`A2aAgent` builds agent-card `url` from default region (us-central1), ignoring `GOOGLE_CLOUD_AGENT_ENGINE_LOCATION`Có thể đã có người làm @sushicw đã nhận 115 ngày trước. Đang mởapi: vertex-ai
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
googleapis/python-aiplatform#6877 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
api: vertex-ai
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
googleapis/python-aiplatform#6865 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của googleapis/python-aiplatform
Issue tương tự
-
Broken links found in docsĐang mởdocs pydanty:is-working
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
pydantic/pydantic-ai#9800 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
-
[Bug]: With --api-server-count > 1, gauges such as vllm:num_requests_running have no samples until the first requestCó thể đã có người làm @roy6n23 đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
vllm-project/vllm#59988 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
pymc-devs/pymc-examples#897 ·
-
Action calls retired claude-3-5-haiku-20241022, generating failing API requests for every userĐang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 91/100