Langchain Agent Type-推理输出

OpenAI functions:

> Entering new AgentExecutor chain...

Invoking: `tavily_search_results_json` with `{'query': 'LangChain'}`


[{'url': 'https://www.ibm.com/topics/langchain', 'content': 'LangChain is essentially a library of abstractions for Python and Javascript, representing common steps and concepts  LangChain is an open source orchestration framework for the development of applications using large language models  other LangChain features, like the eponymous chains.  LangChain provides integrations for over 25 different embedding methods, as well as for over 50 different vector storesLangChain is a tool for building applications using large language models (LLMs) like chatbots and virtual agents. It simplifies the process of programming and integration with external data sources and software workflows. It supports Python and Javascript languages and supports various LLM providers, including OpenAI, Google, and IBM.'}]
LangChain is a tool for building applications using large language models (LLMs) like chatbots and virtual agents. It simplifies the process of programming and integration with external data sources and software workflows. LangChain provides integrations for over 25 different embedding methods and for over 50 different vector stores. It is essentially a library of abstractions for Python and JavaScript, representing common steps and concepts. LangChain supports Python and JavaScript languages and various LLM providers, including OpenAI, Google, and IBM. 
You can find more information about LangChain [here](https://www.ibm.com/topics/langchain).

> Finished chain.

{'input': 'what is LangChain?',
 'output': '
LangChain is a tool for building applications using large language models (LLMs) like chatbots and virtual agents. It simplifies the process of programming and integration with external data sources and software workflows. LangChain provides integrations for over 25 different embedding methods and for over 50 different vector stores. It is essentially a library of abstractions for Python and JavaScript, representing common steps and concepts. LangChain supports Python and JavaScript languages and various LLM providers, including OpenAI, Google, and IBM. 
You can find more information about LangChain [here](https://www.ibm.com/topics/langchain).'}

----------------------
OpenAI tools:

> Entering new AgentExecutor chain...

Invoking: `tavily_search_results_json` with `{'query': 'LangChain'}`


[{'url': 'https://www.ibm.com/topics/langchain', 'content': 'LangChain is essentially a library of abstractions for Python and Javascript, representing common steps and concepts  LangChain is an open source orchestration framework for the development of applications using large language models  other LangChain features, like the eponymous chains.  LangChain provides integrations for over 25 different embedding methods, as well as for over 50 different vector storesLangChain is a tool for building applications using large language models (LLMs) like chatbots and virtual agents. It simplifies the process of programming and integration with external data sources and software workflows. It supports Python and Javascript languages and supports various LLM providers, including OpenAI, Google, and IBM.'}]
LangChain is an open source orchestration framework for the development of applications using large language models. It is essentially a library of abstractions for Python and Javascript, representing common steps and concepts. LangChain simplifies the process of programming and integration with external data sources and software workflows. It supports various large language model providers, including OpenAI, Google, and IBM. 
You can find more information about LangChain on the IBM website: [LangChain - IBM](https://www.ibm.com/topics/langchain)

> Finished chain.

{'input': 'what is LangChain?',
 'output': '
LangChain is an open source orchestration framework for the development of applications using large language models. It is essentially a library of abstractions for Python and Javascript, representing common steps and concepts. LangChain simplifies the process of programming and integration with external data sources and software workflows. It supports various large language model providers, including OpenAI, Google, and IBM. 
You can find more information about LangChain on the IBM website: [LangChain - IBM](https://www.ibm.com/topics/langchain)'}


----------------------
XML Agent

> Entering new AgentExecutor chain...
 <tool>tavily_search_results_json</tool>
 <tool_input>what is LangChain?[{'url': 'https://aws.amazon.com/what-is/langchain/', 'content': 'What Is LangChain? What is LangChain?  How does LangChain work?  Why is LangChain important?  that LangChain provides to reduce development time.LangChain is an open source framework for building applications based on large language models (LLMs). LLMs are large deep-learning models pre-trained on large amounts of data that can generate responses to user queries—for example, answering questions or creating images from text-based prompts.'}] 
 
 <final_answer>LangChain is an open source framework for building applications based on large language models (LLMs). It allows developers to leverage the power of LLMs to create applications that can generate responses to user queries, such as answering questions or creating images from text prompts. Key benefits of LangChain are reducing development time and effort compared to building custom LLMs from scratch.</final_answer>

> Finished chain.

{'input': 'what is LangChain?',
 'output': 'LangChain is an open source framework for building applications based on large language models (LLMs). It allows developers to leverage the power of LLMs to create applications that can generate responses to user queries, such as answering questions or creating images from text prompts. Key benefits of LangChain are reducing development time and effort compared to building custom LLMs from scratch.'}
 
----------------------
JSON Chat Agent

> Entering new AgentExecutor chain...
{
    "action": "tavily_search_results_json",
    "action_input": "LangChain"
}
[{'url': 'https://www.ibm.com/topics/langchain', 'content': 'LangChain is essentially a library of abstractions for Python and Javascript, representing common steps and concepts  LangChain is an open source orchestration framework for the development of applications using large language models  other LangChain features, like the eponymous chains.  LangChain provides integrations for over 25 different embedding methods, as well as for over 50 different vector storesLangChain is a tool for building applications using large language models (LLMs) like chatbots and virtual agents. It simplifies the process of programming and integration with external data sources and software workflows. It supports Python and Javascript languages and supports various LLM providers, including OpenAI, Google, and IBM.'}]
{
    "action": "Final Answer",
    "action_input": "LangChain is an open source orchestration framework for the development of applications using large language models. It simplifies the process of programming and integration with external data sources and software workflows. It supports Python and Javascript languages and supports various LLM providers, including OpenAI, Google, and IBM."
}

> Finished chain.

----------------------
Structured Chat Agent

> Entering new AgentExecutor chain...
Action:
```
{
  "action": "tavily_search_results_json",
  "action_input": {"query": "LangChain"}
}
```
[{'url': 'https://www.ibm.com/topics/langchain', 'content': 'LangChain is essentially a library of abstractions for Python and Javascript, representing common steps and concepts  LangChain is an open source orchestration framework for the development of applications using large language models  other LangChain features, like the eponymous chains.  LangChain provides integrations for over 25 different embedding methods, as well as for over 50 different vector storesLangChain is a tool for building applications using large language models (LLMs) like chatbots and virtual agents. It simplifies the process of programming and integration with external data sources and software workflows. It supports Python and Javascript languages and supports various LLM providers, including OpenAI, Google, and IBM.'}]

Action:
```
{
  "action": "Final Answer",
  "action_input": "LangChain is an open source orchestration framework for the development of applications using large language models. It simplifies the process of programming and integration with external data sources and software workflows. LangChain provides integrations for over 25 different embedding methods and supports various large language model providers such as OpenAI, Google, and IBM. It supports Python and Javascript languages."
}
```

> Finished chain.

----------------------
Structured Chat Agent

> 进入新的 AgentExecutor 链...

我应该研究一下 LangChain 以了解更多信息。
操作:tavilly_search_results_json
操作输入:“LangChain”
[{'url': 'https://www.ibm.com/topics/langchain', 'content': 'LangChain 本质上是 Python 和 Javascript 的抽象库,代表常见步骤和概念 LangChain 是一个开源编排框架,用于使用大型语言模型和其他 LangChain 功能(例如同名链)来开发应用程序。 LangChain 提供了超过 25 种不同嵌入方法以及超过 50 种不同向量存储的集成。LangChain 是一种使用聊天机器人和虚拟代理等大型语言模型 (LLM) 构建应用程序的工具。 它简化了编程以及与外部数据源和软件工作流程集成的过程。 它支持Python和Javascript语言,并支持各种LLM提供商,包括OpenAI、Google和IBM。'}]

我应该阅读摘要并查看LangChain的不同功能和集成。
操作:tavilly_search_results_json
操作输入:“LangChain 功能和集成”
[{'url': 'https://www.ibm.com/topics/langchain', 'content': "LangChain 提供了超过 25 种不同嵌入方法的集成,以及 超过 50 个不同的向量存储 LangChain 是一个开源编排框架,用于使用其他 LangChain 功能(例如同名链)的大型语言模型来开发应用程序。LangChain 本质上是 Python 和 Javascript 的抽象库,代表常见步骤和概念由 Harrison Chase 推出 2022 年 10 月,浪链迅速崛起:截至 2023 年 6 月,它是 Github 上增长最快的开源项目1。恰逢次月 OpenAI 的 ChatGPT 重大发布,浪链在 让生成式人工智能更容易被爱好者所接受..."}]

我应该注意一下LangChain的发布日期和受欢迎程度。
操作:tavilly_search_results_json
操作输入:“LangChain 发布日期和受欢迎程度”
[{'url': 'https://www.ibm.com/topics/langchain', 'content':“LangChain 是一个开源编排框架,用于使用 大型语言模型 LangChain 的其他功能,例如同名链。LangChain 提供了超过 25 种不同嵌入方法以及超过 50 种不同向量存储的集成 LangChain 本质上是 Python 和 Javascript 的抽象库,代表常见步骤和概念由 Harrison 发起 2022 年 10 月,浪链迅速崛起:截至 2023 年 6 月,它是 Github 上增长最快的开源项目1。恰逢次月 OpenAI 的 ChatGPT 重大发布,浪链发挥了重要作用。 让生成式人工智能更容易被爱好者所接受……”}]

我现在知道了最终的答案。
最终答案:LangChain 是一个开源编排框架,用于使用聊天机器人和虚拟代理等大型语言模型 (LLM) 构建应用程序。 它由 Harrison Chase 于 2022 年 10 月推出,并于 2023 年 6 月作为 Github 上增长最快的开源项目而受到欢迎。

> 完成链条。

-----------------
Self-ask with search

What is the hometown of the reigning men's U.S. Open champion?

> Entering new AgentExecutor chain...
Yes.
Follow up: Who is the reigning men's U.S. Open champion?The reigning men's U.S. Open champion is Daniil Medvedev, who won the title in 2021.
Follow up: What is Daniil Medvedev's hometown?Daniil Medvedev has set his residence in Monte Carlo, but his hometown is Moscow, Russia.
So the final answer is: Moscow, Russia

> Finished chain.

美国公开赛男子卫冕冠军的家乡是哪里?

> 进入新的 AgentExecutor 链...
是的。
追问:美国公开赛男子卫冕冠军是谁?美国公开赛男子卫冕冠军是丹尼尔·梅德韦杰夫,他于2021年夺冠。
追问:梅德韦杰夫的家乡是哪里?梅德韦杰夫的住所定在蒙特卡洛,但他的家乡是俄罗斯莫斯科。
所以最终答案是:俄罗斯莫斯科

> 完成链条。

  • 2
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值