{"id":85117,"date":"2026-07-27T00:57:23","date_gmt":"2026-07-26T16:57:23","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/85117.html"},"modified":"2026-07-27T00:57:23","modified_gmt":"2026-07-26T16:57:23","slug":"%e4%bb%8e%e5%8d%95%e4%bd%93-agent-%e5%88%b0-agent-%e5%b9%b3%e5%8f%b0%ef%bc%9a%e4%b8%80%e6%ac%a1%e6%9e%b6%e6%9e%84%e8%bf%81%e7%a7%bb%e7%9a%84%e6%8a%80%e6%9c%af%e6%96%b9%e6%a1%88%e5%92%8c%e7%bb%84","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/85117.html","title":{"rendered":"\u4ece\u5355\u4f53 Agent \u5230 Agent \u5e73\u53f0\uff1a\u4e00\u6b21\u67b6\u6784\u8fc1\u79fb\u7684\u6280\u672f\u65b9\u6848\u548c\u7ec4\u7ec7\u6311\u6218"},"content":{"rendered":"<h2>\u4ece\u5355\u4f53 Agent \u5230 Agent \u5e73\u53f0&#xff1a;\u4e00\u6b21\u67b6\u6784\u8fc1\u79fb\u7684\u6280\u672f\u65b9\u6848\u548c\u7ec4\u7ec7\u6311\u6218<\/h2>\n<h3>\u4e00\u3001\u6df1\u5ea6\u5f15\u8a00\u4e0e\u573a\u666f\u75db\u70b9<\/h3>\n<p>2024 \u5e74\u521d\u6211\u4eec\u7684 AI \u5e94\u7528\u8fd8\u53ea\u6709\u4e00\u4e2a Agent \u2014 \u4e00\u4e2a\u667a\u80fd\u5ba2\u670d\u673a\u5668\u4eba\u3002\u7528\u4e86\u5927\u534a\u5e74\u53cd\u54cd\u4e0d\u9519&#xff0c;\u4e1a\u52a1\u90e8\u95e8\u5f00\u59cb\u6765\u63d0\u9700\u6c42&#xff1a;\u6cd5\u52a1\u8981\u4e00\u4e2a\u5408\u540c\u5ba1\u67e5 Agent\u3001HR \u8981\u4e00\u4e2a\u7b80\u5386\u7b5b\u9009 Agent\u3001\u8fd0\u8425\u8981\u4e00\u4e2a\u5185\u5bb9\u5ba1\u6838 Agent\u3002\u8d77\u521d\u6211\u4eec\u5f88\u4e50\u89c2\u2014\u2014\u628a\u7b2c\u4e00\u4e2a Agent \u7684\u4ee3\u7801 copy-paste \u4e00\u4efd&#xff0c;\u6539\u6539 Prompt \u548c Tool \u4e0d\u5c31\u884c\u4e86&#xff1f;<\/p>\n<p>\u4e00\u4e2a\u6708\u540e\u6211\u4eec\u5c31\u7b11\u4e0d\u51fa\u6765\u4e86\u30024 \u4e2a Agent \u5404\u81ea\u7ef4\u62a4\u4e00\u5957\u4ee3\u7801&#xff0c;LLM \u8c03\u7528\u903b\u8f91\u3001\u9519\u8bef\u5904\u7406\u3001\u65e5\u5fd7\u91c7\u96c6\u5168\u90e8\u91cd\u590d\u3002Prompt \u6a21\u677f\u6563\u843d\u5728 4 \u4e2a\u4e0d\u540c\u7684 repo \u91cc&#xff0c;\u60f3\u7edf\u4e00\u5347\u7ea7\u6a21\u578b\u7248\u672c&#xff1f;\u6bcf\u4e2a Agent \u90fd\u8981\u5355\u72ec\u6539\u914d\u7f6e\u3001\u5355\u72ec\u90e8\u7f72\u3002\u66f4\u5934\u75bc\u7684\u662f Tool \u7684\u590d\u7528\u2014\u2014\u5408\u540c\u5ba1\u67e5\u548c\u7b80\u5386\u7b5b\u9009\u90fd\u9700\u8981&#034;\u6587\u6863\u89e3\u6790&#034;\u8fd9\u4e2a\u80fd\u529b&#xff0c;\u4f46\u5404\u81ea\u7684\u5b9e\u73b0\u65b9\u5f0f\u5b8c\u5168\u4e0d\u540c&#xff0c;\u4e00\u4efd PDF \u5728\u4e24\u4e2a Agent \u91cc\u89e3\u6790\u51fa\u6765\u7684\u6587\u672c\u7ed3\u6784\u90fd\u4e0d\u4e00\u6837\u3002<\/p>\n<p>\u7ec4\u7ec7\u5c42\u9762\u7684\u6311\u6218\u66f4\u9690\u853d\u3002Agent \u7684\u5f00\u53d1\u8005\u662f\u5404\u4e1a\u52a1\u7ebf\u7684\u5de5\u7a0b\u5e08&#xff0c;\u4ed6\u4eec\u5bf9 Prompt \u5de5\u7a0b\u548c LLM \u63a8\u7406\u7684\u7406\u89e3\u7a0b\u5ea6\u53c2\u5dee\u4e0d\u9f50\u3002\u6cd5\u52a1\u56e2\u961f\u5199\u7684 Agent \u5728\u8f93\u5165\u5f02\u5e38\u65f6\u4f1a\u76f4\u63a5\u629b unhandled exception&#xff0c;\u8fd0\u8425\u56e2\u961f\u5199\u7684 Agent \u6ca1\u6709\u505a\u4efb\u4f55 token \u7528\u91cf\u7edf\u8ba1\u2014\u2014\u6708\u672b\u5bf9\u8d26\u5355\u65f6\u624d\u53d1\u73b0\u4e00\u4e2a Agent \u4e00\u4e2a\u6708\u70e7\u6389\u4e86 2000 \u7f8e\u5143\u7684 API \u8d39\u7528\u3002<\/p>\n<p>\u5355\u4f53 Agent \u5728\u9a8c\u8bc1 PMF \u9636\u6bb5\u6ca1\u95ee\u9898&#xff0c;\u4f46\u5f53 Agent \u6570\u91cf\u4ece 1 \u53d8\u6210 N \u65f6&#xff0c;\u5171\u4eab\u80fd\u529b\u5fc5\u987b\u5e73\u53f0\u5316\u3001\u6cbb\u7406\u89c4\u5219\u5fc5\u987b\u6807\u51c6\u5316\u3001\u5f00\u53d1\u4f53\u9a8c\u5fc5\u987b\u5de5\u5177\u5316\u3002\u8fd9\u5c31\u662f\u5355\u4f53\u5230\u5e73\u53f0\u7684\u8fc1\u79fb\u3002<\/p>\n<h3>\u4e8c\u3001\u5e95\u5c42\u673a\u5236\u4e0e\u539f\u7406\u6df1\u5ea6\u5256\u6790<\/h3>\n<p>\u4ece\u5355\u4f53\u5230\u5e73\u53f0\u7684\u67b6\u6784\u6f14\u8fdb&#xff0c;\u6838\u5fc3\u662f\u628a Agent \u7684\u5171\u6027\u80fd\u529b\u62bd\u79bb\u4e3a\u5e73\u53f0\u5c42&#xff0c;\u628a\u4e1a\u52a1\u5dee\u5f02\u5c01\u88c5\u4e3a\u53ef\u63d2\u62d4\u7684\u914d\u7f6e\u548c\u63d2\u4ef6&#xff1a;<\/p>\n<p>\u5e73\u53f0\u5c42\u7684\u516d\u4e2a\u6a21\u5757\u5404\u53f8\u5176\u804c&#xff1a;<\/p>\n<ul>\n<li>Agent \u8fd0\u884c\u65f6\u5f15\u64ce&#xff1a;\u6807\u51c6\u5316\u7684 Agent \u751f\u547d\u5468\u671f\u7ba1\u7406&#xff08;\u521b\u5efa\u2192\u6267\u884c\u2192\u76d1\u63a7\u2192\u9500\u6bc1&#xff09;&#xff0c;\u6bcf\u4e2a\u4e1a\u52a1 Agent \u53ea\u662f\u4e00\u7ec4\u914d\u7f6e &#043; Prompt &#043; Tool \u5f15\u7528\u7684\u7ec4\u5408\u3002<\/li>\n<li>Tool \u6ce8\u518c\u4e2d\u5fc3&#xff1a;\u628a\u6240\u6709 Tool \u7edf\u4e00\u6ce8\u518c\u548c\u7ba1\u7406&#xff0c;\u652f\u6301\u7248\u672c\u5316\u3001\u6743\u9650\u63a7\u5236\u548c\u9650\u6d41&#xff0c;Agent \u901a\u8fc7\u58f0\u660e\u5f0f\u5f15\u7528\u63a5\u5165 Tool\u3002<\/li>\n<li>Prompt \u7ba1\u7406\u670d\u52a1&#xff1a;\u96c6\u4e2d\u7ba1\u7406 Prompt \u6a21\u677f&#xff0c;\u652f\u6301 A\/B \u6d4b\u8bd5\u3001\u7248\u672c\u56de\u6eda\u548c\u6548\u679c\u8bc4\u4f30\u3002<\/li>\n<li>LLM Gateway&#xff1a;\u7edf\u4e00\u8def\u7531 LLM \u8c03\u7528&#xff0c;\u5b9e\u73b0\u8d1f\u8f7d\u5747\u8861\u3001\u91cd\u8bd5\u3001fallback\u3001token \u8ba1\u8d39\u3002<\/li>\n<li>\u53ef\u89c2\u6d4b\u6027\u4e2d\u5fc3&#xff1a;\u7edf\u4e00\u91c7\u96c6\u65e5\u5fd7\u3001trace\u3001\u6307\u6807&#xff0c;\u6309 Agent \u7ef4\u5ea6\u805a\u5408\u3002<\/li>\n<li>\u6743\u9650 &amp; \u5b89\u5168&#xff1a;\u7edf\u4e00\u7684\u8ba4\u8bc1\u6388\u6743\u3001\u5185\u5bb9\u5b89\u5168\u8fc7\u6ee4\u3001\u8d8a\u6743\u64cd\u4f5c\u62e6\u622a\u3002<\/li>\n<\/ul>\n<h3>\u4e09\u3001\u751f\u4ea7\u7ea7\u4ee3\u7801\u5b9e\u73b0<\/h3>\n<p>import asyncio<br \/>\nimport logging<br \/>\nimport time<br \/>\nfrom abc import ABC, abstractmethod<br \/>\nfrom dataclasses import dataclass, field<br \/>\nfrom enum import Enum<br \/>\nfrom typing import Any, Optional, Protocol<\/p>\n<p>from pydantic import BaseModel, Field, ValidationError<\/p>\n<p>logging.basicConfig(level&#061;logging.INFO)<br \/>\nlogger &#061; logging.getLogger(__name__)<\/p>\n<p># \u2500\u2500 Tool \u6ce8\u518c\u4e2d\u5fc3 \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500<\/p>\n<p>class ToolProtocol(Protocol):<br \/>\n    &#034;&#034;&#034;Tool \u63a5\u53e3\u534f\u8bae&#034;&#034;&#034;<br \/>\n    name: str<br \/>\n    version: str<\/p>\n<p>    async def execute(self, **kwargs) -&gt; dict: &#8230;<\/p>\n<p>class ToolRegistry:<br \/>\n    &#034;&#034;&#034;\u5168\u5c40 Tool \u6ce8\u518c\u4e2d\u5fc3&#034;&#034;&#034;<\/p>\n<p>    _tools: dict[str, dict[str, type]] &#061; {}  # {name: {version: ToolClass}}<\/p>\n<p>    &#064;classmethod<br \/>\n    def register(cls, tool_cls: type, version: str &#061; &#034;v1&#034;):<br \/>\n        tool_name &#061; getattr(tool_cls, &#034;name&#034;, tool_cls.__name__)<br \/>\n        if tool_name not in cls._tools:<br \/>\n            cls._tools[tool_name] &#061; {}<br \/>\n        cls._tools[tool_name][version] &#061; tool_cls<br \/>\n        logger.info(f&#034;Tool \u6ce8\u518c: {tool_name}&#064;{version}&#034;)<\/p>\n<p>    &#064;classmethod<br \/>\n    def get(cls, name: str, version: str &#061; &#034;v1&#034;) -&gt; type:<br \/>\n        versions &#061; cls._tools.get(name, {})<br \/>\n        if version not in versions:<br \/>\n            available &#061; list(versions.keys())<br \/>\n            raise ValueError(f&#034;Tool {name}&#064;{version} \u4e0d\u5b58\u5728&#xff0c;\u53ef\u7528: {available}&#034;)<br \/>\n        return versions[version]<\/p>\n<p>    &#064;classmethod<br \/>\n    def list_tools(cls) -&gt; list[dict]:<br \/>\n        return [<br \/>\n            {&#034;name&#034;: name, &#034;versions&#034;: list(versions.keys())}<br \/>\n            for name, versions in cls._tools.items()<br \/>\n        ]<\/p>\n<p># \u2500\u2500 Prompt \u7ba1\u7406\u670d\u52a1 \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500<\/p>\n<p>class PromptTemplate(BaseModel):<br \/>\n    &#034;&#034;&#034;Prompt \u6a21\u677f&#034;&#034;&#034;<br \/>\n    name: str<br \/>\n    version: str<br \/>\n    system_prompt: str<br \/>\n    user_prompt_template: str<br \/>\n    variables: list[str] &#061; Field(default_factory&#061;list)<br \/>\n    metadata: dict &#061; Field(default_factory&#061;dict)<\/p>\n<p>    def render(self, **kwargs) -&gt; dict[str, str]:<br \/>\n        try:<br \/>\n            system &#061; self.system_prompt.format(**kwargs)<br \/>\n            user &#061; self.user_prompt_template.format(**kwargs)<br \/>\n        except KeyError as e:<br \/>\n            raise ValueError(f&#034;Prompt \u53d8\u91cf\u7f3a\u5931: {e}&#034;)<br \/>\n        return {&#034;system&#034;: system, &#034;user&#034;: user}<\/p>\n<p>class PromptManager:<br \/>\n    &#034;&#034;&#034;\u96c6\u4e2d\u5f0f Prompt \u7ba1\u7406&#034;&#034;&#034;<\/p>\n<p>    _prompts: dict[str, dict[str, PromptTemplate]] &#061; {}<\/p>\n<p>    &#064;classmethod<br \/>\n    def register(cls, prompt: PromptTemplate):<br \/>\n        if prompt.name not in cls._prompts:<br \/>\n            cls._prompts[prompt.name] &#061; {}<br \/>\n        cls._prompts[prompt.name][prompt.version] &#061; prompt<\/p>\n<p>    &#064;classmethod<br \/>\n    def get(cls, name: str, version: str &#061; &#034;v1&#034;) -&gt; PromptTemplate:<br \/>\n        versions &#061; cls._prompts.get(name, {})<br \/>\n        if version not in versions:<br \/>\n            raise ValueError(f&#034;Prompt {name}&#064;{version} \u4e0d\u5b58\u5728&#034;)<br \/>\n        return versions[version]<\/p>\n<p># \u2500\u2500 Agent \u914d\u7f6e&#xff08;\u58f0\u660e\u5f0f\u5b9a\u4e49&#xff09; \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500<\/p>\n<p>class AgentConfig(BaseModel):<br \/>\n    &#034;&#034;&#034;\u4e1a\u52a1 Agent \u7684\u58f0\u660e\u5f0f\u914d\u7f6e&#034;&#034;&#034;<br \/>\n    agent_id: str<br \/>\n    name: str<br \/>\n    description: str &#061; &#034;&#034;<br \/>\n    prompt_name: str<br \/>\n    prompt_version: str &#061; &#034;v1&#034;<br \/>\n    tools: list[dict] &#061; Field(default_factory&#061;list)  # [{name, version}]<br \/>\n    llm_model: str &#061; &#034;gpt-4o-mini&#034;<br \/>\n    temperature: float &#061; 0.0<br \/>\n    max_iterations: int &#061; 10<br \/>\n    max_tokens: int &#061; 4096<br \/>\n    error_budget: int &#061; 3<br \/>\n    owner: str &#061; &#034;&#034;<br \/>\n    sla_target_ms: int &#061; 5000  # P95 \u5ef6\u8fdf\u76ee\u6807<\/p>\n<p># \u2500\u2500 Agent \u8fd0\u884c\u65f6\u5f15\u64ce \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500<\/p>\n<p>class AgentRuntime:<br \/>\n    &#034;&#034;&#034;\u6807\u51c6\u5316\u7684 Agent \u8fd0\u884c\u65f6&#034;&#034;&#034;<\/p>\n<p>    def __init__(self, config: AgentConfig):<br \/>\n        self.config &#061; config<br \/>\n        self._tools: dict[str, Any] &#061; {}<br \/>\n        self._prompt: Optional[PromptTemplate] &#061; None<br \/>\n        self._init_time &#061; time.time()<br \/>\n        self._call_count &#061; 0<br \/>\n        self._total_tokens &#061; 0<\/p>\n<p>    async def _load_prompt(self):<br \/>\n        &#034;&#034;&#034;\u4ece PromptManager \u52a0\u8f7d Prompt \u6a21\u677f&#034;&#034;&#034;<br \/>\n        try:<br \/>\n            self._prompt &#061; PromptManager.get(<br \/>\n                self.config.prompt_name, self.config.prompt_version<br \/>\n            )<br \/>\n        except ValueError as e:<br \/>\n            logger.error(f&#034;Prompt \u52a0\u8f7d\u5931\u8d25 {self.config.agent_id}: {e}&#034;)<br \/>\n            raise<\/p>\n<p>    async def _load_tools(self):<br \/>\n        &#034;&#034;&#034;\u4ece ToolRegistry \u52a0\u8f7d\u58f0\u660e\u5f0f\u5f15\u7528\u7684 Tool&#034;&#034;&#034;<br \/>\n        for tool_ref in self.config.tools:<br \/>\n            name &#061; tool_ref[&#034;name&#034;]<br \/>\n            version &#061; tool_ref.get(&#034;version&#034;, &#034;v1&#034;)<br \/>\n            try:<br \/>\n                tool_cls &#061; ToolRegistry.get(name, version)<br \/>\n                self._tools[name] &#061; tool_cls()<br \/>\n            except ValueError as e:<br \/>\n                logger.error(f&#034;Tool \u52a0\u8f7d\u5931\u8d25 {self.config.agent_id}\/{name}: {e}&#034;)<br \/>\n                raise<\/p>\n<p>    async def initialize(self):<br \/>\n        &#034;&#034;&#034;\u521d\u59cb\u5316 Agent&#xff08;\u52a0\u8f7d Prompt \u548c Tool&#xff09;&#034;&#034;&#034;<br \/>\n        await asyncio.gather(self._load_prompt(), self._load_tools())<br \/>\n        logger.info(f&#034;Agent [{self.config.agent_id}] \u521d\u59cb\u5316\u5b8c\u6210, tools&#061;{list(self._tools.keys())}&#034;)<\/p>\n<p>    async def execute(self, user_input: str, context: Optional[dict] &#061; None) -&gt; dict:<br \/>\n        &#034;&#034;&#034;\u6267\u884c\u4e00\u6b21 Agent \u5bf9\u8bdd&#034;&#034;&#034;<br \/>\n        start_time &#061; time.time()<br \/>\n        self._call_count &#043;&#061; 1<\/p>\n<p>        try:<br \/>\n            if self._prompt is None:<br \/>\n                raise RuntimeError(&#034;Agent \u672a\u521d\u59cb\u5316&#034;)<\/p>\n<p>            # \u6e32\u67d3 Prompt<br \/>\n            render_vars &#061; {&#034;user_input&#034;: user_input, **(context or {})}<br \/>\n            rendered &#061; self._prompt.render(**render_vars)<\/p>\n<p>            # \u6784\u9020 Tool \u63cf\u8ff0\u7ed9 LLM<br \/>\n            tool_descriptions &#061; &#034;\\\\n&#034;.join(<br \/>\n                f&#034;- {name}: {getattr(tool, &#039;description&#039;, &#039;no description&#039;)}&#034;<br \/>\n                for name, tool in self._tools.items()<br \/>\n            )<\/p>\n<p>            # \u6a21\u62df LLM \u8c03\u7528&#xff08;\u5b9e\u9645\u5e94\u8d70 LLM Gateway&#xff09;<br \/>\n            response &#061; (<br \/>\n                f&#034;[{self.config.agent_id}] \u6536\u5230: {user_input}\\\\n&#034;<br \/>\n                f&#034;\u53ef\u7528\u5de5\u5177: {tool_descriptions}\\\\n&#034;<br \/>\n                f&#034;\u7cfb\u7edf\u6307\u4ee4: {rendered[&#039;system&#039;][:100]}&#8230;&#034;<br \/>\n            )<\/p>\n<p>            # \u6a21\u62df token \u7edf\u8ba1<br \/>\n            estimated_tokens &#061; len(user_input) &#043; len(rendered[&#034;system&#034;])<br \/>\n            self._total_tokens &#043;&#061; estimated_tokens<\/p>\n<p>            elapsed_ms &#061; (time.time() &#8211; start_time) * 1000<br \/>\n            sla_breach &#061; elapsed_ms &gt; self.config.sla_target_ms<\/p>\n<p>            return {<br \/>\n                &#034;agent_id&#034;: self.config.agent_id,<br \/>\n                &#034;response&#034;: response,<br \/>\n                &#034;elapsed_ms&#034;: elapsed_ms,<br \/>\n                &#034;tokens_used&#034;: estimated_tokens,<br \/>\n                &#034;tool_calls&#034;: len(self._tools),<br \/>\n                &#034;sla_breach&#034;: sla_breach,<br \/>\n            }<br \/>\n        except Exception as e:<br \/>\n            elapsed_ms &#061; (time.time() &#8211; start_time) * 1000<br \/>\n            logger.exception(f&#034;Agent [{self.config.agent_id}] \u6267\u884c\u5f02\u5e38: {e}&#034;)<br \/>\n            return {<br \/>\n                &#034;agent_id&#034;: self.config.agent_id,<br \/>\n                &#034;error&#034;: str(e),<br \/>\n                &#034;elapsed_ms&#034;: elapsed_ms,<br \/>\n                &#034;sla_breach&#034;: elapsed_ms &gt; self.config.sla_target_ms,<br \/>\n            }<\/p>\n<p>    def get_stats(self) -&gt; dict:<br \/>\n        return {<br \/>\n            &#034;agent_id&#034;: self.config.agent_id,<br \/>\n            &#034;uptime_seconds&#034;: time.time() &#8211; self._init_time,<br \/>\n            &#034;call_count&#034;: self._call_count,<br \/>\n            &#034;total_tokens&#034;: self._total_tokens,<br \/>\n        }<\/p>\n<p># \u2500\u2500 \u5e73\u53f0\u5165\u53e3 \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500<\/p>\n<p>class AgentPlatform:<br \/>\n    &#034;&#034;&#034;Agent \u5e73\u53f0\u4e3b\u63a7&#034;&#034;&#034;<\/p>\n<p>    def __init__(self):<br \/>\n        self._agents: dict[str, AgentRuntime] &#061; {}<\/p>\n<p>    async def deploy_agent(self, config: AgentConfig) -&gt; AgentRuntime:<br \/>\n        &#034;&#034;&#034;\u90e8\u7f72\u4e00\u4e2a Agent&#034;&#034;&#034;<br \/>\n        if config.agent_id in self._agents:<br \/>\n            raise ValueError(f&#034;Agent {config.agent_id} \u5df2\u5b58\u5728&#034;)<\/p>\n<p>        runtime &#061; AgentRuntime(config)<br \/>\n        await runtime.initialize()<br \/>\n        self._agents[config.agent_id] &#061; runtime<br \/>\n        logger.info(f&#034;Agent [{config.agent_id}] \u5df2\u90e8\u7f72&#034;)<br \/>\n        return runtime<\/p>\n<p>    async def stop_agent(self, agent_id: str):<br \/>\n        if agent_id not in self._agents:<br \/>\n            raise ValueError(f&#034;Agent {agent_id} \u4e0d\u5b58\u5728&#034;)<br \/>\n        stats &#061; self._agents[agent_id].get_stats()<br \/>\n        del self._agents[agent_id]<br \/>\n        logger.info(f&#034;Agent [{agent_id}] \u5df2\u505c\u6b62, stats&#061;{stats}&#034;)<\/p>\n<p>    async def execute(self, agent_id: str, user_input: str, context: Optional[dict] &#061; None) -&gt; dict:<br \/>\n        if agent_id not in self._agents:<br \/>\n            raise ValueError(f&#034;Agent {agent_id} \u672a\u90e8\u7f72&#034;)<br \/>\n        return await self._agents[agent_id].execute(user_input, context)<\/p>\n<p>    def list_agents(self) -&gt; list[dict]:<br \/>\n        return [<br \/>\n            {&#034;agent_id&#034;: aid, **agent.get_stats()}<br \/>\n            for aid, agent in self._agents.items()<br \/>\n        ]<\/p>\n<p># \u2500\u2500 \u4f7f\u7528\u793a\u4f8b \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500<\/p>\n<p>async def main():<br \/>\n    # \u6ce8\u518c\u5171\u4eab Tool<br \/>\n    class DocumentParser:<br \/>\n        name &#061; &#034;document_parser&#034;<br \/>\n        version &#061; &#034;v1&#034;<br \/>\n        description &#061; &#034;\u89e3\u6790 PDF\/Word \u6587\u6863\u4e3a\u7ed3\u6784\u5316\u6587\u672c&#034;<br \/>\n        async def execute(self, **kwargs) -&gt; dict:<br \/>\n            return {&#034;text&#034;: &#034;\u6a21\u62df\u6587\u6863\u89e3\u6790\u7ed3\u679c&#8230;&#034;}<\/p>\n<p>    class WebSearch:<br \/>\n        name &#061; &#034;web_search&#034;<br \/>\n        version &#061; &#034;v1&#034;<br \/>\n        description &#061; &#034;\u641c\u7d22\u4e92\u8054\u7f51\u4fe1\u606f&#034;<br \/>\n        async def execute(self, **kwargs) -&gt; dict:<br \/>\n            return {&#034;results&#034;: &#034;\u6a21\u62df\u641c\u7d22\u7ed3\u679c&#8230;&#034;}<\/p>\n<p>    ToolRegistry.register(DocumentParser, &#034;v1&#034;)<br \/>\n    ToolRegistry.register(WebSearch, &#034;v1&#034;)<\/p>\n<p>    # \u6ce8\u518c Prompt \u6a21\u677f<br \/>\n    PromptManager.register(PromptTemplate(<br \/>\n        name&#061;&#034;customer_service&#034;,<br \/>\n        version&#061;&#034;v1&#034;,<br \/>\n        system_prompt&#061;&#034;\u4f60\u662f\u5ba2\u670d\u52a9\u624b&#xff0c;\u8bf7\u53cb\u597d\u5730\u56de\u7b54\u7528\u6237\u95ee\u9898\u3002&#034;,<br \/>\n        user_prompt_template&#061;&#034;\u7528\u6237\u95ee\u9898&#xff1a;{user_input}&#034;,<br \/>\n        variables&#061;[&#034;user_input&#034;],<br \/>\n    ))<br \/>\n    PromptManager.register(PromptTemplate(<br \/>\n        name&#061;&#034;contract_review&#034;,<br \/>\n        version&#061;&#034;v1&#034;,<br \/>\n        system_prompt&#061;&#034;\u4f60\u662f\u6cd5\u52a1\u5ba1\u67e5\u52a9\u624b&#xff0c;\u8bf7\u68c0\u67e5\u5408\u540c\u6761\u6b3e\u7684\u5408\u89c4\u6027\u3002&#034;,<br \/>\n        user_prompt_template&#061;&#034;\u5408\u540c\u5185\u5bb9&#xff1a;{user_input}&#034;,<br \/>\n        variables&#061;[&#034;user_input&#034;],<br \/>\n    ))<\/p>\n<p>    # \u521b\u5efa\u5e73\u53f0<br \/>\n    platform &#061; AgentPlatform()<\/p>\n<p>    # \u90e8\u7f72\u4e24\u4e2a\u4e1a\u52a1 Agent&#xff08;\u53ea\u9700\u8981\u914d\u7f6e&#xff0c;zero \u4ee3\u7801\u590d\u5236&#xff09;<br \/>\n    service_agent &#061; AgentConfig(<br \/>\n        agent_id&#061;&#034;customer-service-v1&#034;,<br \/>\n        name&#061;&#034;\u667a\u80fd\u5ba2\u670d&#034;,<br \/>\n        prompt_name&#061;&#034;customer_service&#034;,<br \/>\n        prompt_version&#061;&#034;v1&#034;,<br \/>\n        tools&#061;[{&#034;name&#034;: &#034;web_search&#034;, &#034;version&#034;: &#034;v1&#034;}],<br \/>\n        llm_model&#061;&#034;gpt-4o-mini&#034;,<br \/>\n        owner&#061;&#034;\u5ba2\u670d\u56e2\u961f&#034;,<br \/>\n    )<\/p>\n<p>    legal_agent &#061; AgentConfig(<br \/>\n        agent_id&#061;&#034;contract-review-v1&#034;,<br \/>\n        name&#061;&#034;\u5408\u540c\u5ba1\u67e5&#034;,<br \/>\n        prompt_name&#061;&#034;contract_review&#034;,<br \/>\n        prompt_version&#061;&#034;v1&#034;,<br \/>\n        tools&#061;[{&#034;name&#034;: &#034;document_parser&#034;, &#034;version&#034;: &#034;v1&#034;}],<br \/>\n        llm_model&#061;&#034;gpt-4o&#034;,<br \/>\n        owner&#061;&#034;\u6cd5\u52a1\u56e2\u961f&#034;,<br \/>\n    )<\/p>\n<p>    try:<br \/>\n        await platform.deploy_agent(service_agent)<br \/>\n        await platform.deploy_agent(legal_agent)<\/p>\n<p>        # \u6267\u884c<br \/>\n        result &#061; await platform.execute(&#034;customer-service-v1&#034;, &#034;\u6211\u7684\u8ba2\u5355\u600e\u4e48\u8fd8\u6ca1\u53d1\u8d27&#xff1f;&#034;)<br \/>\n        logger.info(f&#034;\u5ba2\u670d\u56de\u590d: {result[&#039;response&#039;][:100]}&#034;)<\/p>\n<p>        result &#061; await platform.execute(&#034;contract-review-v1&#034;, &#034;\u8bf7\u5ba1\u67e5\u8fd9\u4efd\u91c7\u8d2d\u5408\u540c\u7684\u4ed8\u6b3e\u6761\u6b3e&#034;)<br \/>\n        logger.info(f&#034;\u6cd5\u52a1\u56de\u590d: {result[&#039;response&#039;][:100]}&#034;)<\/p>\n<p>        # \u67e5\u770b\u5e73\u53f0\u72b6\u6001<br \/>\n        agents &#061; platform.list_agents()<br \/>\n        for a in agents:<br \/>\n            logger.info(f&#034;Agent: {a[&#039;agent_id&#039;]}, \u8c03\u7528: {a[&#039;call_count&#039;]}, tokens: {a[&#039;total_tokens&#039;]}&#034;)<\/p>\n<p>    except ValueError as e:<br \/>\n        logger.error(f&#034;\u90e8\u7f72\u5931\u8d25: {e}&#034;)<br \/>\n    except Exception as e:<br \/>\n        logger.exception(f&#034;\u672a\u9884\u671f\u9519\u8bef: {e}&#034;)<\/p>\n<p>if __name__ &#061;&#061; &#034;__main__&#034;:<br \/>\n    asyncio.run(main())<\/p>\n<h3>\u56db\u3001\u8fb9\u754c\u5206\u6790\u4e0e\u67b6\u6784\u6743\u8861<\/h3>\n<p>\u5e73\u53f0\u5316 vs \u7075\u6d3b\u6027&#xff1a;\u5e73\u53f0\u5316\u4e4b\u540e&#xff0c;Agent \u5f00\u53d1\u8005\u53ea\u80fd\u901a\u8fc7\u58f0\u660e\u5f0f\u914d\u7f6e\u6765\u5b9a\u5236\u884c\u4e3a&#xff0c;\u4e0d\u80fd\u50cf\u4ee5\u524d\u90a3\u6837\u5728\u4ee3\u7801\u91cc\u968f\u610f\u63d2 Hook\u3002\u8fd9\u5bf9 80% \u7684\u7b80\u5355 Agent&#xff08;\u5ba2\u670d\u3001FAQ\u3001\u5b57\u6bb5\u63d0\u53d6&#xff09;\u6765\u8bf4\u662f\u8db3\u591f\u7684&#xff0c;\u5bf9 20% \u7684\u590d\u6742 Agent&#xff08;\u591a\u6b65\u63a8\u7406\u3001\u81ea\u5b9a\u4e49\u7f16\u6392&#xff09;\u6765\u8bf4\u4e0d\u591f\u3002\u89e3\u51b3\u65b9\u6848\u662f\u63d0\u4f9b&#034;\u5e73\u53f0\u57fa\u7c7b &#043; \u81ea\u5b9a\u4e49\u6269\u5c55\u70b9&#034;\u2014\u2014\u4fdd\u7559\u4e00\u4e2a on_pre_execute \u548c on_post_execute \u7684\u94a9\u5b50\u65b9\u6cd5&#xff0c;\u5141\u8bb8\u4e1a\u52a1\u65b9\u6ce8\u5165\u81ea\u5df1\u7684\u903b\u8f91\u3002<\/p>\n<p>Tool \u6ce8\u518c\u4e2d\u5fc3\u7684\u7248\u672c\u7ba1\u7406&#xff1a;Tool \u5347\u7ea7\u7248\u672c\u540e&#xff08;\u6bd4\u5982 DocumentParser v1\u2192v2&#xff09;&#xff0c;\u5df2\u6709\u7684 Agent \u662f\u7ee7\u7eed\u7528 v1 \u8fd8\u662f\u81ea\u52a8\u5207\u5230 v2&#xff1f;\u5efa\u8bae\u9ed8\u8ba4\u4fdd\u6301 v1&#xff0c;\u5141\u8bb8 Agent \u914d\u7f6e\u4e2d\u663e\u5f0f\u58f0\u660e\u7248\u672c&#xff0c;\u540c\u65f6\u5e73\u53f0\u4fa7\u63d0\u4f9b\u7070\u5ea6\u8fc1\u79fb\u5de5\u5177\u2014\u2014\u5148\u5207 10% \u6d41\u91cf\u5230 v2 \u89c2\u5bdf\u4e00\u5468&#xff0c;\u786e\u8ba4\u65e0\u5f02\u5e38\u518d\u5168\u91cf\u3002<\/p>\n<p>\u4e1a\u52a1\u56e2\u961f\u7684\u6280\u672f\u80fd\u529b\u5dee\u5f02&#xff1a;\u6cd5\u52a1\u5de5\u7a0b\u5e08\u5199\u7684 Prompt \u548c AI \u5de5\u7a0b\u5e08\u5199\u7684 Prompt \u8d28\u91cf\u5dee\u8ddd\u5de8\u5927\u3002\u5e73\u53f0\u4fa7\u5e94\u8be5\u63d0\u4f9b Prompt Playground \u548c\u8bc4\u4f30\u5de5\u5177&#xff0c;\u8ba9\u975e AI \u80cc\u666f\u7684\u5de5\u7a0b\u5e08\u4e5f\u80fd\u53ef\u89c6\u5316\u5730\u8c03\u8bd5 Prompt \u6548\u679c&#xff0c;\u800c\u4e0d\u662f\u5728 .yaml \u6587\u4ef6\u91cc\u76f2\u5199\u3002<\/p>\n<p>\u6210\u672c\u63a7\u5236\u7684\u6311\u6218&#xff1a;\u5e73\u53f0\u5316\u4e4b\u540e&#xff0c;Token \u6d88\u8d39\u53d8\u6210\u4e86\u5404\u4e1a\u52a1\u56e2\u961f\u72ec\u7acb\u7684\u884c\u4e3a&#xff0c;\u5e73\u53f0\u5c42\u5fc5\u987b\u63d0\u4f9b\u9884\u7b97\u63a7\u5236\u3002\u6700\u7b80\u5355\u7684\u505a\u6cd5\u662f\u6309 Agent \u8bbe\u7f6e\u6708\u5ea6 Token \u914d\u989d&#xff0c;\u8fbe\u5230 80% \u65f6\u53d1\u9884\u8b66\u3001100% \u65f6\u81ea\u52a8\u9650\u6d41\u3002\u8fd9\u79cd&#034;\u7ed9\u4f60\u81ea\u7531\u4f46\u7ed9\u4f60\u9884\u7b97&#034;\u7684\u6a21\u5f0f\u6bd4\u4e2d\u592e\u7ba1\u63a7\u66f4\u5bb9\u6613\u88ab\u4e1a\u52a1\u56e2\u961f\u63a5\u53d7\u3002<\/p>\n<h3>\u4e94\u3001\u603b\u7ed3<\/h3>\n<p>\u4ece\u5355\u4f53\u5230\u5e73\u53f0\u7684\u8fc1\u79fb&#xff0c;\u4ee3\u7801\u5c42\u9762\u7684\u5de5\u4f5c\u91cf\u5176\u5b9e\u53ea\u5360 30%&#xff0c;\u5269\u4e0b 70% \u662f\u7ec4\u7ec7\u534f\u8c03\u2014\u2014\u8bf4\u670d\u4e1a\u52a1\u56e2\u961f\u63a5\u53d7\u5171\u4eab\u80fd\u529b\u800c\u975e\u5404\u81ea\u9020\u8f6e\u5b50\u3001\u5efa\u7acb Prompt \u548c Tool \u7684\u6cbb\u7406\u89c4\u8303\u3001\u63d0\u4f9b\u591f\u597d\u7528\u7684\u5f00\u53d1\u8005\u5de5\u5177\u964d\u4f4e\u4f7f\u7528\u95e8\u69db\u3002\u6280\u672f\u4e0a\u5c31\u4e00\u53e5\u8bdd&#xff1a;\u628a Agent \u4ece\u4ee3\u7801\u53d8\u6210\u914d\u7f6e&#xff0c;\u8ba9\u65b0\u5efa\u4e00\u4e2a Agent \u7684\u65f6\u95f4\u4ece\u5929\u7ea7\u964d\u5230\u5206\u949f\u7ea7\u3002\u8dd1\u8d77\u6765\u4e4b\u540e\u6700\u5927\u7684\u611f\u53d7\u662f&#xff1a;\u7ec8\u4e8e\u4e0d\u7528\u5728 4 \u4e2a repo \u4e4b\u95f4\u6765\u56de\u5207\u6539\u540c\u4e00\u884c LLM \u8c03\u7528\u7684\u53c2\u6570\u4e86\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u4ece\u5355\u4f53 Agent \u5230 Agent \u5e73\u53f0&#xff1a;\u4e00\u6b21\u67b6\u6784\u8fc1\u79fb\u7684\u6280\u672f\u65b9\u6848\u548c\u7ec4\u7ec7\u6311\u6218<br \/>\n\u4e00\u3001\u6df1\u5ea6\u5f15\u8a00\u4e0e\u573a\u666f\u75db\u70b9<br \/>\n2024 \u5e74\u521d\u6211\u4eec\u7684 AI \u5e94\u7528\u8fd8\u53ea\u6709\u4e00\u4e2a Agent \u2014 \u4e00\u4e2a\u667a\u80fd\u5ba2\u670d\u673a\u5668\u4eba\u3002\u7528\u4e86\u5927\u534a\u5e74\u53cd\u54cd\u4e0d\u9519&#xff0c;\u4e1a\u52a1\u90e8\u95e8\u5f00\u59cb\u6765\u63d0\u9700\u6c42&#xff1a;\u6cd5\u52a1\u8981\u4e00\u4e2a\u5408\u540c\u5ba1\u67e5 Agent\u3001HR \u8981\u4e00\u4e2a\u7b80\u5386\u7b5b\u9009 Agent\u3001\u8fd0\u8425\u8981\u4e00\u4e2a\u5185\u5bb9\u5ba1\u6838 Agent\u3002\u8d77\u521d\u6211\u4eec\u5f88\u4e50\u89c2\u2014\u2014\u628a\u7b2c\u4e00\u4e2a Agent \u7684\u4ee3\u7801 copy-paste \u4e00\u4efd&#xff0c;\u6539\u6539 Prompt \u548c To<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[50],"topic":[],"class_list":["post-85117","post","type-post","status-publish","format-standard","hentry","category-server","tag-50"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>\u4ece\u5355\u4f53 Agent \u5230 Agent \u5e73\u53f0\uff1a\u4e00\u6b21\u67b6\u6784\u8fc1\u79fb\u7684\u6280\u672f\u65b9\u6848\u548c\u7ec4\u7ec7\u6311\u6218 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.wsisp.com\/helps\/85117.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u4ece\u5355\u4f53 Agent \u5230 Agent \u5e73\u53f0\uff1a\u4e00\u6b21\u67b6\u6784\u8fc1\u79fb\u7684\u6280\u672f\u65b9\u6848\u548c\u7ec4\u7ec7\u6311\u6218 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"\u4ece\u5355\u4f53 Agent \u5230 Agent \u5e73\u53f0&#xff1a;\u4e00\u6b21\u67b6\u6784\u8fc1\u79fb\u7684\u6280\u672f\u65b9\u6848\u548c\u7ec4\u7ec7\u6311\u6218 \u4e00\u3001\u6df1\u5ea6\u5f15\u8a00\u4e0e\u573a\u666f\u75db\u70b9 2024 \u5e74\u521d\u6211\u4eec\u7684 AI \u5e94\u7528\u8fd8\u53ea\u6709\u4e00\u4e2a Agent \u2014 \u4e00\u4e2a\u667a\u80fd\u5ba2\u670d\u673a\u5668\u4eba\u3002\u7528\u4e86\u5927\u534a\u5e74\u53cd\u54cd\u4e0d\u9519&#xff0c;\u4e1a\u52a1\u90e8\u95e8\u5f00\u59cb\u6765\u63d0\u9700\u6c42&#xff1a;\u6cd5\u52a1\u8981\u4e00\u4e2a\u5408\u540c\u5ba1\u67e5 Agent\u3001HR \u8981\u4e00\u4e2a\u7b80\u5386\u7b5b\u9009 Agent\u3001\u8fd0\u8425\u8981\u4e00\u4e2a\u5185\u5bb9\u5ba1\u6838 Agent\u3002\u8d77\u521d\u6211\u4eec\u5f88\u4e50\u89c2\u2014\u2014\u628a\u7b2c\u4e00\u4e2a Agent \u7684\u4ee3\u7801 copy-paste \u4e00\u4efd&#xff0c;\u6539\u6539 Prompt \u548c To\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/85117.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2026-07-26T16:57:23+00:00\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"7 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/85117.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/85117.html\",\"name\":\"\u4ece\u5355\u4f53 Agent \u5230 Agent \u5e73\u53f0\uff1a\u4e00\u6b21\u67b6\u6784\u8fc1\u79fb\u7684\u6280\u672f\u65b9\u6848\u548c\u7ec4\u7ec7\u6311\u6218 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2026-07-26T16:57:23+00:00\",\"dateModified\":\"2026-07-26T16:57:23+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/85117.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/85117.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/85117.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"\u4ece\u5355\u4f53 Agent \u5230 Agent \u5e73\u53f0\uff1a\u4e00\u6b21\u67b6\u6784\u8fc1\u79fb\u7684\u6280\u672f\u65b9\u6848\u548c\u7ec4\u7ec7\u6311\u6218\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\",\"url\":\"https:\/\/www.wsisp.com\/helps\/\",\"name\":\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"description\":\"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"contentUrl\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"caption\":\"admin\"},\"sameAs\":[\"http:\/\/wp.wsisp.com\"],\"url\":\"https:\/\/www.wsisp.com\/helps\/author\/admin\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"\u4ece\u5355\u4f53 Agent \u5230 Agent \u5e73\u53f0\uff1a\u4e00\u6b21\u67b6\u6784\u8fc1\u79fb\u7684\u6280\u672f\u65b9\u6848\u548c\u7ec4\u7ec7\u6311\u6218 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.wsisp.com\/helps\/85117.html","og_locale":"zh_CN","og_type":"article","og_title":"\u4ece\u5355\u4f53 Agent \u5230 Agent \u5e73\u53f0\uff1a\u4e00\u6b21\u67b6\u6784\u8fc1\u79fb\u7684\u6280\u672f\u65b9\u6848\u548c\u7ec4\u7ec7\u6311\u6218 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"\u4ece\u5355\u4f53 Agent \u5230 Agent \u5e73\u53f0&#xff1a;\u4e00\u6b21\u67b6\u6784\u8fc1\u79fb\u7684\u6280\u672f\u65b9\u6848\u548c\u7ec4\u7ec7\u6311\u6218 \u4e00\u3001\u6df1\u5ea6\u5f15\u8a00\u4e0e\u573a\u666f\u75db\u70b9 2024 \u5e74\u521d\u6211\u4eec\u7684 AI \u5e94\u7528\u8fd8\u53ea\u6709\u4e00\u4e2a Agent \u2014 \u4e00\u4e2a\u667a\u80fd\u5ba2\u670d\u673a\u5668\u4eba\u3002\u7528\u4e86\u5927\u534a\u5e74\u53cd\u54cd\u4e0d\u9519&#xff0c;\u4e1a\u52a1\u90e8\u95e8\u5f00\u59cb\u6765\u63d0\u9700\u6c42&#xff1a;\u6cd5\u52a1\u8981\u4e00\u4e2a\u5408\u540c\u5ba1\u67e5 Agent\u3001HR \u8981\u4e00\u4e2a\u7b80\u5386\u7b5b\u9009 Agent\u3001\u8fd0\u8425\u8981\u4e00\u4e2a\u5185\u5bb9\u5ba1\u6838 Agent\u3002\u8d77\u521d\u6211\u4eec\u5f88\u4e50\u89c2\u2014\u2014\u628a\u7b2c\u4e00\u4e2a Agent \u7684\u4ee3\u7801 copy-paste \u4e00\u4efd&#xff0c;\u6539\u6539 Prompt \u548c To","og_url":"https:\/\/www.wsisp.com\/helps\/85117.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2026-07-26T16:57:23+00:00","author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"7 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/85117.html","url":"https:\/\/www.wsisp.com\/helps\/85117.html","name":"\u4ece\u5355\u4f53 Agent \u5230 Agent \u5e73\u53f0\uff1a\u4e00\u6b21\u67b6\u6784\u8fc1\u79fb\u7684\u6280\u672f\u65b9\u6848\u548c\u7ec4\u7ec7\u6311\u6218 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2026-07-26T16:57:23+00:00","dateModified":"2026-07-26T16:57:23+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/85117.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/85117.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/85117.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"\u4ece\u5355\u4f53 Agent \u5230 Agent \u5e73\u53f0\uff1a\u4e00\u6b21\u67b6\u6784\u8fc1\u79fb\u7684\u6280\u672f\u65b9\u6848\u548c\u7ec4\u7ec7\u6311\u6218"}]},{"@type":"WebSite","@id":"https:\/\/www.wsisp.com\/helps\/#website","url":"https:\/\/www.wsisp.com\/helps\/","name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","description":"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41","name":"admin","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/","url":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","contentUrl":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","caption":"admin"},"sameAs":["http:\/\/wp.wsisp.com"],"url":"https:\/\/www.wsisp.com\/helps\/author\/admin"}]}},"_links":{"self":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/85117","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/comments?post=85117"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/85117\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=85117"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=85117"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=85117"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=85117"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}