LangChain Demo | Agent X ReAct X wikipedia 询问《三体》的主要内容

背景

LangChain学习中,尝试改了一下哈里森和吴恩达课程当中的问题,看看gpt-3.5-turbo在集成了ReAct和wikipedia后,如何回答《三体》的主要内容是什么这个问题,当然,主要是为了回答这问题时LangChain内部发生了什么。所以将langchain.debug 设置为 True。

代码出奇简洁👇

代码

import sys
import os# 添加 parent_dir 到 sys.path
current_dir = os.path.dirname(__file__)
parent_dir = os.path.dirname(current_dir)
sys.path.append(parent_dir)from constants import PROXY_URL,KEYimport warnings
warnings.filterwarnings("ignore")import langchain
langchain.debug = Truefrom langchain.agents import load_tools, initialize_agent
from langchain.agents import AgentType
from langchain.python import PythonREPL
from langchain.chat_models import ChatOpenAIllm = ChatOpenAI(temperature=0.0,model_name="gpt-3.5-turbo", openai_api_key=KEY,openai_api_base=PROXY_URL
)tools = load_tools(["wikipedia"],llm=llm
)agent= initialize_agent(tools, #第二步加载的工具llm, #第一步初始化的模型agent=AgentType.CHAT_ZERO_SHOT_REACT_DESCRIPTION,  #代理类型handle_parsing_errors=True, #处理解析错误verbose = True #输出中间步骤
)response = agent("What is the main content of the science fiction novel The Three-Body Problem?")print(response)

输出异常繁琐👇

控制台输出

[chain/start] [1:chain:AgentExecutor] Entering Chain run with input:      
{
  "input": "What is the main content of the science fiction novel The Three-Body Problem?"
}
[chain/start] [1:chain:AgentExecutor > 2:chain:LLMChain] Entering Chain run with input:
{
  "input": "What is the main content of the science fiction novel The Three-Body Problem?",
  "agent_scratchpad": "",
  "stop": [
    "Observation:"
  ]
}
[llm/start] [1:chain:AgentExecutor > 2:chain:LLMChain > 3:llm:ChatOpenAI] 
Entering LLM run with input:
{
  "prompts": [
    "System: Answer the following questions as best you can. You have access to the following tools:\n\nwikipedia: A wrapper around Wikipedia. Useful for when you need to answer general questions about people, places, companies, facts, historical events, or other subjects. Input should be a search query.\n\nThe way you use the tools is by specifying a json blob.\nSpecifically, this json should have a `action` key (with the name of the tool 
to use) and a `action_input` key (with the input to the tool going here).\n\nThe only values that should be in the \"action\" field are: wikipedia\n\nThe $JSON_BLOB should only contain a SINGLE action, do NOT return a list of multiple actions. Here is an example of a valid $JSON_BLOB:\n\n```\n{\n  \"action\": $TOOL_NAME,\n  \"action_input\": $INPUT\n}\n```\n\nALWAYS use the following format:\n\nQuestion: the input question you must answer\nThought: you should always think about what to do\nAction:\n```\n$JSON_BLOB\n```\nObservation: the result of the action\n... (this Thought/Action/Observation can repeat N times)\nThought: I now know the final answer\nFinal Answer: the final answer to the original input question\n\nBegin! Reminder to always use the exact characters `Final Answer` when responding.\nHuman: What is the main content of the science fiction novel The Three-Body Problem?"
  ]
}
[llm/end] [1:chain:AgentExecutor > 2:chain:LLMChain > 3:llm:ChatOpenAI] [3.96s] Exiting LLM run with output:
{
  "generations": [
    [
      {
        "text": "Thought: I can use Wikipedia to find information about the main content of the science fiction novel \"The Three-Body Problem\".\n\nAction:\n```\n{\n  \"action\": \"wikipedia\",\n  \"action_input\": \"The 
Three-Body Problem (novel)\"\n}\n```",
        "generation_info": {
          "finish_reason": "stop",
          "logprobs": null
        },
        "type": "ChatGeneration",
        "message": {
          "lc": 1,
          "type": "constructor",
          "id": [
            "langchain",
            "schema",
            "messages",
            "AIMessage"
          ],
          "kwargs": {
            "content": "Thought: I can use Wikipedia to find information about the main content of the science fiction novel \"The Three-Body Problem\".\n\nAction:\n```\n{\n  \"action\": \"wikipedia\",\n  \"action_input\": \"The Three-Body Problem (novel)\"\n}\n```",
            "additional_kwargs": {}
          }
        }
      }
    ]
  ],
  "llm_output": {
    "token_usage": {
      "completion_tokens": 55,
      "prompt_tokens": 306,
      "total_tokens": 361
    },
    "model_name": "gpt-3.5-turbo",
    "system_fingerprint": "fp_3bc1b5746c"
  },
  "run": null
}
[chain/end] [1:chain:AgentExecutor > 2:chain:LLMChain] [3.96s] Exiting Chain run with output:
{
  "text": "Thought: I can use Wikipedia to find information about the main content of the science fiction novel \"The Three-Body Problem\".\n\nAction:\n```\n{\n  \"action\": \"wikipedia\",\n  \"action_input\": \"The Three-Body Problem (novel)\"\n}\n```"
}
[tool/start] [1:chain:AgentExecutor > 4:tool:wikipedia] Entering Tool run 
with input:
"The Three-Body Problem (novel)"
[tool/end] [1:chain:AgentExecutor > 4:tool:wikipedia] [5.47s] Exiting Tool run with output:
"Page: The Three-Body Problem (novel)
Summary: The Three-Body Problem (Chinese: 三体; lit. 'Three-Body') is a story by Chinese science fiction author Liu Cixin, the first novel in the Remembrance of Earth's Past trilogy. The series portrays a fictional past, present and future wherein Earth encounters an alien civilization from a nearby system of three sun-like stars orbiting one another, a representative example of the three-body problem in orbital mechanics.
The story was originally serialized in Science Fiction World in 2006 before it was published as a standalone book in 2008. In 2006, it received the 
Galaxy Award for Chinese science fiction. In 2012, it was described as one of China's most successful full-length novels of the past two decades. The English translation by Ken Liu was published by Tor Books in 2014. That 
translation was the first novel by an Asian writer to win a Hugo Award for Best Novel; it was also nominated for the Nebula Award for Best Novel.The book has been adapted into other media. In 2015, a Chinese film adaptation of the same name was in production, but it was never released. A Chinese TV series, Three-Body, released in early 2023 to critical success locally. An English language Netflix series, 3 Body Problem, was released in March 2024.

Page: Three-body problem
Summary: In physics and classical mechanics, the three-body problem is the problem of taking the initial positions and velocities (or momenta) of three point masses and solving for their subsequent motion according to Newton's laws of motion and Newton's law of universal gravitation. The three-body problem is a special case of the n-body problem. Unlike two-body problems, no general closed-form solution exists, as the resulting dynamical system is chaotic for most initial conditions, and numerical methods are generally required.
Historically, the first specific three-body problem to receive extended study was the one involving the Moon, Earth, and the Sun. In an extended modern sense, a three-body problem is any problem in classical mechanics or quantum mechanics that models the motion of three particles.

Page: 3 Body Problem (TV series)
Summary: 3 Body Problem is an American science fiction television series created by David Benioff, D. B. Weiss and Alexander Woo, loosely based on the Hugo Award-winning Chinese novel The Three-Body Problem by Liu Cixin. It is the second live-action adaptation after the 2023 Chinese television series.
The series premiered on Netflix with its eight episodes on March 21, 2024."
[chain/start] [1:chain:AgentExecutor > 5:chain:LLMChain] Entering Chain run with input:
{
  "input": "What is the main content of the science fiction novel The Three-Body Problem?",
  "agent_scratchpad": "This was your previous work (but I haven't seen any of it! I only see what you return as final answer):\nThought: I can use Wikipedia to find information about the main content of the science fiction novel \"The Three-Body Problem\".\n\nAction:\n```\n{\n  \"action\": \"wikipedia\",\n  \"action_input\": \"The Three-Body Problem (novel)\"\n}\n```\nObservation: Page: The Three-Body Problem (novel)\nSummary: The Three-Body Problem (Chinese: 三体; lit. 'Three-Body') is a story by Chinese science fiction author Liu Cixin, the first novel in the Remembrance of Earth's Past trilogy. The series portrays a fictional past, present and future wherein Earth encounters an alien civilization from a nearby system of three sun-like stars orbiting one another, a representative example of the three-body problem in orbital mechanics.\nThe story was originally serialized in Science Fiction World in 2006 before it was published as a standalone book in 2008. In 2006, it received the Galaxy Award for Chinese science fiction. In 2012, it was described as one of China's most successful full-length novels of the past two decades. The English translation by Ken Liu was published by Tor Books in 2014. That translation was the first novel by an 
Asian writer to win a Hugo Award for Best Novel; it was also nominated for the Nebula Award for Best Novel.The book has been adapted into other media. In 2015, a Chinese film adaptation of the same name was in production, 
but it was never released. A Chinese TV series, Three-Body, released in early 2023 to critical success locally. An English language Netflix series, 
3 Body Problem, was released in March 2024.\n\nPage: Three-body problem\nSummary: In physics and classical mechanics, the three-body problem is the 
problem of taking the initial positions and velocities (or momenta) of three point masses and solving for their subsequent motion according to Newton's laws of motion and Newton's law of universal gravitation. The three-body problem is a special case of the n-body problem. Unlike two-body problems, no general closed-form solution exists, as the resulting dynamical system is chaotic for most initial conditions, and numerical methods are generally required.\nHistorically, the first specific three-body problem to receive extended study was the one involving the Moon, Earth, and the Sun. In an extended modern sense, a three-body problem is any problem in classical mechanics or quantum mechanics that models the motion of three particles.\n\n\n\nPage: 3 Body Problem (TV series)\nSummary: 3 Body Problem is an 
American science fiction television series created by David Benioff, D. B. Weiss and Alexander Woo, loosely based on the Hugo Award-winning Chinese 
novel The Three-Body Problem by Liu Cixin. It is the second live-action adaptation after the 2023 Chinese television series.\nThe series premiered on Netflix with its eight episodes on March 21, 2024.\n\n\nThought:",      
  "stop": [
    "Observation:"
  ]
}
[llm/start] [1:chain:AgentExecutor > 5:chain:LLMChain > 6:llm:ChatOpenAI] 
Entering LLM run with input:
{
  "prompts": [
    "System: Answer the following questions as best you can. You have access to the following tools:\n\nwikipedia: A wrapper around Wikipedia. Useful for when you need to answer general questions about people, places, companies, facts, historical events, or other subjects. Input should be a search query.\n\nThe way you use the tools is by specifying a json blob.\nSpecifically, this json should have a `action` key (with the name of the tool 
to use) and a `action_input` key (with the input to the tool going here).\n\nThe only values that should be in the \"action\" field are: wikipedia\n\nThe $JSON_BLOB should only contain a SINGLE action, do NOT return a list of multiple actions. Here is an example of a valid $JSON_BLOB:\n\n```\n{\n  \"action\": $TOOL_NAME,\n  \"action_input\": $INPUT\n}\n```\n\nALWAYS use the following format:\n\nQuestion: the input question you must answer\nThought: you should always think about what to do\nAction:\n```\n$JSON_BLOB\n```\nObservation: the result of the action\n... (this Thought/Action/Observation can repeat N times)\nThought: I now know the final answer\nFinal Answer: the final answer to the original input question\n\nBegin! Reminder to always use the exact characters `Final Answer` when responding.\nHuman: What is the main content of the science fiction novel The Three-Body Problem?\n\nThis was your previous work (but I haven't seen any of it! I only see what you return as final answer):\nThought: I can use Wikipedia to find information about the main content of the science fiction novel \"The 
Three-Body Problem\".\n\nAction:\n```\n{\n  \"action\": \"wikipedia\",\n  
\"action_input\": \"The Three-Body Problem (novel)\"\n}\n```\nObservation: Page: The Three-Body Problem (novel)\nSummary: The Three-Body Problem (Chinese: 三体; lit. 'Three-Body') is a story by Chinese science fiction author Liu Cixin, the first novel in the Remembrance of Earth's Past trilogy. 
The series portrays a fictional past, present and future wherein Earth encounters an alien civilization from a nearby system of three sun-like stars orbiting one another, a representative example of the three-body problem 
in orbital mechanics.\nThe story was originally serialized in Science Fiction World in 2006 before it was published as a standalone book in 2008. In 2006, it received the Galaxy Award for Chinese science fiction. In 2012, 
it was described as one of China's most successful full-length novels of the past two decades. The English translation by Ken Liu was published by Tor Books in 2014. That translation was the first novel by an Asian writer 
to win a Hugo Award for Best Novel; it was also nominated for the Nebula Award for Best Novel.The book has been adapted into other media. In 2015, a Chinese film adaptation of the same name was in production, but it was never released. A Chinese TV series, Three-Body, released in early 2023 to critical success locally. An English language Netflix series, 3 Body Problem, was released in March 2024.\n\nPage: Three-body problem\nSummary: In physics and classical mechanics, the three-body problem is the problem of taking the initial positions and velocities (or momenta) of three point masses and solving for their subsequent motion according to Newton's laws of motion and Newton's law of universal gravitation. The three-body problem is a special case of the n-body problem. Unlike two-body problems, no general closed-form solution exists, as the resulting dynamical system is chaotic for most initial conditions, and numerical methods are generally required.\nHistorically, the first specific three-body problem to receive extended study was the one involving the Moon, Earth, and the Sun. In an extended modern sense, a three-body problem is any problem in classical mechanics 
or quantum mechanics that models the motion of three particles.\n\n\n\nPage: 3 Body Problem (TV series)\nSummary: 3 Body Problem is an American science fiction television series created by David Benioff, D. B. Weiss and Alexander Woo, loosely based on the Hugo Award-winning Chinese novel The Three-Body Problem by Liu Cixin. It is the second live-action adaptation after the 2023 Chinese television series.\nThe series premiered on Netflix with its eight episodes on March 21, 2024.\n\n\nThought:"
  ]
}
[llm/end] [1:chain:AgentExecutor > 5:chain:LLMChain > 6:llm:ChatOpenAI] [4.10s] Exiting LLM run with output:
{
  "generations": [
    [
      {
        "text": "I have found information about the main content of the science fiction novel \"The Three-Body Problem\" by Liu Cixin. It is a story that portrays a fictional past, present, and future where Earth encounters an alien civilization from a nearby system of three sun-like stars orbiting one another. The novel is the first in the Remembrance of Earth's Past trilogy and has received critical acclaim.\n\nFinal Answer: The main content of the science fiction novel \"The Three-Body Problem\" involves Earth encountering an alien civilization from a nearby system of three sun-like stars.",
        "generation_info": {
          "finish_reason": "stop",
          "logprobs": null
        },
        "type": "ChatGeneration",
        "message": {
          "lc": 1,
          "type": "constructor",
          "id": [
            "langchain",
            "schema",
            "messages",
            "AIMessage"
          ],
          "kwargs": {
            "content": "I have found information about the main content of the science fiction novel \"The Three-Body Problem\" by Liu Cixin. It is 
a story that portrays a fictional past, present, and future where Earth encounters an alien civilization from a nearby system of three sun-like stars orbiting one another. The novel is the first in the Remembrance of Earth's Past trilogy and has received critical acclaim.\n\nFinal Answer: The main content of the science fiction novel \"The Three-Body Problem\" involves Earth encountering an alien civilization from a nearby system of three sun-like stars.",
            "additional_kwargs": {}
          }
        }
      }
    ]
  ],
  "llm_output": {
    "token_usage": {
      "completion_tokens": 113,
      "prompt_tokens": 924,
      "total_tokens": 1037
    },
    "model_name": "gpt-3.5-turbo",
    "system_fingerprint": "fp_3bc1b5746c"
  },
  "run": null
}
[chain/end] [1:chain:AgentExecutor > 5:chain:LLMChain] [4.10s] Exiting Chain run with output:
{
  "text": "I have found information about the main content of the science 
fiction novel \"The Three-Body Problem\" by Liu Cixin. It is a story that 
portrays a fictional past, present, and future where Earth encounters an alien civilization from a nearby system of three sun-like stars orbiting one another. The novel is the first in the Remembrance of Earth's Past trilogy and has received critical acclaim.\n\nFinal Answer: The main content of the science fiction novel \"The Three-Body Problem\" involves Earth encountering an alien civilization from a nearby system of three sun-like stars."
}
[chain/end] [1:chain:AgentExecutor] [13.57s] Exiting Chain run with output:
{
  "output": "The main content of the science fiction novel \"The Three-Body Problem\" involves Earth encountering an alien civilization from a nearby system of three sun-like stars."
}
{'input': 'What is the main content of the science fiction novel The Three-Body Problem?', 'output': 'The main content of the science fiction novel 
"The Three-Body Problem" involves Earth encountering an alien civilization from a nearby system of three sun-like stars.'}

最终结果

The Three-Body Problem" involves Earth encountering an alien civilization from a nearby system of three sun-like stars. 

翻译:《三体问题》涉及地球遇到来自附近三颗类太阳恒星系统的外星文明。

 

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.rhkb.cn/news/297612.html

如若内容造成侵权/违法违规/事实不符,请联系长河编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

单例模式以及线程安全问题

单例模式的概念 单例模式是指的是整个系统生命周期内,保证一个类只能产生一个实例对象 保证类的唯一性 。 通过一些编码上的技巧,使编译器可以自动发现咱们的代码中是否有多个实例,并且在尝试创建多个实例的时候,直接编译出错。 …

不讲概念,讲实操,mysql 分表模糊查询、分页查询 及 merge 表的使用

1.Mysql merge合并表的要求 1.合并的分表必须是 MyISAM 引擎,MyISAN引擎是不支持事务的。2.Merge表只保证合表后数据唯一性,合表前的数据可能会存在重复。3.表的结构必须一致,包括索引、字段类型、引擎和字符集。4.删除 tb_member1 分表正确…

阿里云可观测 2024 年 3 月产品动态

本月可观测热文回顾 文章一览: 全新架构!日志服务 SLS 自研免登录方案发布 AIOps 智能运维:有没有比专家经验更优雅的错/慢调用分析工具? 一文看懂如何做好 SQL 质量监控 使用 SPL 高效实现 Flink SLS Connector 下推 功能快…

游戏APP如何提高广告变现收益的同时,保证用户留存率?

APP广告变现对接第三方聚合广告平台主要通过SDK文档对接,一些媒体APP不具备专业运营广告变现的对接能力和资源沉淀,导致APP被封控,设置列入黑名单,借助第三方聚合广告平台进行商业化变现是最佳选择。#APP广告变现# 接入第三方平台…

IDEA配置本地Maven(解决依赖下载缓慢)

1.下载Maven Maven下载页 根据需要选择下载其中一个,我选了zip格式的 将下载好的apache-maven-3.9.5解压到你想要的目录下 2.配置系统环境 设置系统环境变量 MAVEN_HOME 为安装路径的bin目录 变量名:MAVEN_HOME 变量值:写你的 apache-m…

【C++】引用与指针

​​ 🌱博客主页:青竹雾色间. 😘博客制作不易欢迎各位👍点赞⭐收藏➕关注 ✨人生如寄,多忧何为 ✨ 目录标题 前言一.引用(Reference)二.指针(Pointer)三. 比较与总结 前…

代码随想录算法训练营第四十四天 |卡码网52. 携带研究材料 、518. 零钱兑换 II、377. 组合总和 Ⅳ

代码随想录算法训练营第四十四天 |卡码网52. 携带研究材料 、518. 零钱兑换 II、377. 组合总和 Ⅳ 卡码网52. 携带研究材料题目解法 518. 零钱兑换 II题目解法 377. 组合总和 Ⅳ题目解法 感悟 卡码网52. 携带研究材料 题目 解法 题解链接 1. #include <iostream> #inc…

Redis中的复制功能(四)

复制的实现 步骤2:建立套接字连接 在SLAVEOF命令执行之后&#xff0c;从服务器将根据命令所设置的IP地址和端口&#xff0c;创建连向主服务器的套接字连接&#xff0c;如图所示。如果从服务器创建的套接字能成功连接(connect)到主服务器&#xff0c;那么从服务器将为这个套接…

Jmeter各组件超详细介绍

1、JMeter和Loadrunner的区别&#xff1f; 2、JMeter如何开发脚本的&#xff1f;强化脚本的技术&#xff1f; 代理服务器录制脚本&#xff0c;Fiddler录制脚本&#xff0c;Badboy录制脚本&#xff0c;根据API&#xff0c;手写脚本&#xff0c;根据抓包&#xff0c;手写脚本。 …

前视声呐目标识别定位(三)-部署至机器人

前视声呐目标识别定位&#xff08;一&#xff09;-基础知识 前视声呐目标识别定位&#xff08;二&#xff09;-目标识别定位模块 前视声呐目标识别定位&#xff08;三&#xff09;-部署至机器人 前视声呐目标识别定位&#xff08;四&#xff09;-代码解析之启动识别模块 …

二、GitLab相关操作

GitLab相关操作 一、组、用户、项目管理1.创建组2.创建项目3.创建用户并分配组3.1 创建用户3.2 设置密码3.3 给用户分配组 二、拉取/推送代码1.配置ssh(第一次需要)1.1 创建一个空文件夹1.2 配置本地仓账号和邮箱1.3 生成ssh公钥密钥1.4 gitlab配置公钥 2.拉取代码3.推送代码3.…

JAVA JVM内存模型和GC分配和回收

Java 的JVM简介 JVM是&#xff08;Java Virtual Machine&#xff09;Java虚拟机的缩写。 JVM是一个虚构出来的计算机&#xff0c;是通过在实际的计算机上仿真模拟各种计算机功能来实现的。 ​ 在Java程序运行时&#xff0c;所有的.class类需要加载到JVM中才能执行代码逻辑。不…

【面试八股总结】超文本传输协议HTTP(二)

参考资料 &#xff1a;小林Coding、阿秀、代码随想录 一、HTTP缓存技术 将资源&#xff08;如网页、图像、脚本等&#xff09;的副本存储在客户端或中间代理服务器上&#xff0c;以便将来的请求可以直接从缓存中获取&#xff0c;而不必重新从服务器下载资源。这有助于减少网…

ArcGIS 10.8中文版详细安装教程(附安装包)

ArcGIS 10.8中文版详细安装教程&#xff08;附安装包&#xff09; 关键词&#xff1a;ArcGIS 10.8中文版安装 1.概述 ArcGIS Desktop 10.8中文版是由ESRI公司开发的一款专业的地理信息系统&#xff0c;一套完整的桌面GIS软件套件&#xff0c;它包含ArcMap、ArcCatalog、ArcG…

增加网站搜索引擎排名的6个准则

怎样提高网站排名首页 在竞争激烈的网络世界中&#xff0c;网站的排名对于吸引流量和提升曝光至关重要。登上搜索引擎结果页面的首页&#xff0c;意味着更多的曝光和点击率。以下是一些方法&#xff0c;可以帮助您提高网站在搜索引擎中的排名&#xff0c;让其跻身首页&#xf…

多功能知识付费源码下载-实现流量互导多渠道变现(带详细安装教程)

资源变现类产品的许多优势&#xff0c;并剔除了那些无关紧要的元素&#xff0c;使得本产品在运营和变现能力方面实现了质的飞跃。多领域素材资源知识变现营销裂变独立版本。 支持&#xff1a;视频、音频、图文、文档、会员、社群、用户发布、创作分成、任务裂变、流量主、在线…

一、Docker部署GitLab(详细步骤)

Docker部署GitLab&#xff08;详细步骤&#xff09; 一、拉取镜像二、启动容器三、修改配置四、修改密码五、浏览器访问 一、拉取镜像 docker安装教程&#xff1a;https://qingsi.blog.csdn.net/article/details/131270071 docker pull gitlab/gitlab-ce:latest二、启动容器 …

深入理解C/C++的内存管理

在C和C中&#xff0c;高效的内存管理是编写性能优化和资源高效利用程序的关键。本文将深入探讨C/C内存管理的各个方面&#xff0c;包括内存的分布、C语言和C中的动态内存管理方式&#xff0c;以及new和delete操作符的使用 C/C内存分布 C和C程序的内存可以分为以下几个区域&…

windows上配置Redis主从加哨兵模式实现缓存高可用

一、哨兵模式 哨兵&#xff08;sentinel&#xff09;是Redis的高可用性(High Availability)的解决方案&#xff1a;由一个或多个sentinel实例组成sentinel集群可以监视一个或多个主服务器和多个从服务器。当主服务器进入下线状态时&#xff0c;sentinel可以将该主服务器下的某…

深入浅出 -- 系统架构之单体架构

单体架构&#xff08;Monolithic Architecture&#xff09; 单体架构的定义 单体架构&#xff08;Monolithic Architecture&#xff09;是一种传统的软件架构模式&#xff0c;将整个应用程序作为一个单一的、统一的单元进行开发、部署和扩展。在单体架构中&#xff0c;所有的功…