[全量] 初始化项目代码、配置、文档及Agent协同harness
This commit is contained in:
9
langchain-chat/server/agent/tools/arxiv.py
Normal file
9
langchain-chat/server/agent/tools/arxiv.py
Normal file
@@ -0,0 +1,9 @@
|
||||
# LangChain 的 ArxivQueryRun 工具
|
||||
from pydantic import BaseModel, Field
|
||||
from langchain.tools.arxiv.tool import ArxivQueryRun
|
||||
def arxiv(query: str):
|
||||
tool = ArxivQueryRun()
|
||||
return tool.run(tool_input=query)
|
||||
|
||||
class ArxivInput(BaseModel):
|
||||
query: str = Field(description="The search query title")
|
||||
Reference in New Issue
Block a user