143 lines
8.6 KiB
XML
143 lines
8.6 KiB
XML
<svg xmlns="http://www.w3.org/2000/svg"
|
|
width="1200" height="520" viewBox="0 0 1200 520"
|
|
role="img" aria-labelledby="arch-title arch-desc">
|
|
<title id="arch-title">PineAgents 架构</title>
|
|
<desc id="arch-desc">从用户入口经 FastAPI 服务层、运行时编排到智能体决策循环的主链路,以及治理、沙箱、记忆、用量四类横向能力。</desc>
|
|
|
|
<defs>
|
|
<linearGradient id="archbg" x1="0" y1="0" x2="0" y2="1">
|
|
<stop offset="0" stop-color="#0B1020"/>
|
|
<stop offset="1" stop-color="#0A0F1E"/>
|
|
</linearGradient>
|
|
</defs>
|
|
|
|
<rect width="1200" height="520" fill="url(#archbg)"/>
|
|
<rect x="1" y="1" width="1198" height="518" rx="26" fill="none" stroke="#1E2A44" stroke-width="1.5"/>
|
|
|
|
<text x="56" y="44" font-family="ui-monospace,SFMono-Regular,Menlo,monospace" font-size="17" letter-spacing="3" fill="#7A879B">ARCHITECTURE</text>
|
|
|
|
<!-- ===== Main pipeline row ===== -->
|
|
<g font-family="-apple-system,BlinkMacSystemFont,'Segoe UI','PingFang SC','Microsoft YaHei',sans-serif">
|
|
<g transform="translate(56 76)">
|
|
<rect width="168" height="122" rx="14" fill="#101827" stroke="#24324F" stroke-width="1"/>
|
|
<circle cx="30" cy="30" r="12" fill="#1677FF" opacity="0.16"/>
|
|
<path d="M24 24v12M18 30h12" stroke="#1677FF" stroke-width="2" stroke-linecap="round"/>
|
|
<text x="30" y="63" font-size="17" font-weight="700" fill="#E6EDF7">用户入口</text>
|
|
<text x="16" y="86" font-size="13" fill="#AAB6C9">Web / CLI / TUI</text>
|
|
<text x="16" y="106" font-size="13" fill="#AAB6C9">IM 频道(多端)</text>
|
|
</g>
|
|
|
|
<g transform="translate(240 118)">
|
|
<path d="M0 18 L14 18" stroke="#22D3EE" stroke-width="2" stroke-linecap="round"/>
|
|
<path d="M6 13 L14 18 L6 23" fill="none" stroke="#22D3EE" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
|
</g>
|
|
|
|
<g transform="translate(256 76)">
|
|
<rect width="168" height="122" rx="14" fill="#101827" stroke="#24324F" stroke-width="1"/>
|
|
<circle cx="30" cy="30" r="12" fill="#1677FF" opacity="0.16"/>
|
|
<path d="M23 27l14 6M37 27l-14 6" stroke="#1677FF" stroke-width="2" stroke-linecap="round"/>
|
|
<text x="30" y="63" font-size="17" font-weight="700" fill="#E6EDF7">app/ 服务层</text>
|
|
<text x="16" y="86" font-size="13" fill="#AAB6C9">FastAPI · REST+WS</text>
|
|
<text x="16" y="106" font-size="13" fill="#AAB6C9">认证 · 多智能体</text>
|
|
</g>
|
|
|
|
<g transform="translate(440 118)">
|
|
<path d="M0 18 L14 18" stroke="#22D3EE" stroke-width="2" stroke-linecap="round"/>
|
|
<path d="M6 13 L14 18 L6 23" fill="none" stroke="#22D3EE" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
|
</g>
|
|
|
|
<g transform="translate(456 76)">
|
|
<rect width="168" height="122" rx="14" fill="#101827" stroke="#24324F" stroke-width="1"/>
|
|
<circle cx="30" cy="30" r="12" fill="#1677FF" opacity="0.16"/>
|
|
<path d="M22 30h12M28 24l6 6-6 6" stroke="#1677FF" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
|
<text x="30" y="63" font-size="17" font-weight="700" fill="#E6EDF7">runtime/ 编排</text>
|
|
<text x="16" y="86" font-size="13" fill="#AAB6C9">prompt 组装</text>
|
|
<text x="16" y="106" font-size="13" fill="#AAB6C9">工具守卫 · 循环</text>
|
|
</g>
|
|
|
|
<g transform="translate(640 118)">
|
|
<path d="M0 18 L14 18" stroke="#22D3EE" stroke-width="2" stroke-linecap="round"/>
|
|
<path d="M6 13 L14 18 L6 23" fill="none" stroke="#22D3EE" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
|
</g>
|
|
|
|
<g transform="translate(656 76)">
|
|
<rect width="168" height="122" rx="14" fill="#101827" stroke="#24324F" stroke-width="1"/>
|
|
<circle cx="30" cy="30" r="12" fill="#1677FF" opacity="0.16"/>
|
|
<path d="M24 24l12 12M36 24l-12 12" stroke="#1677FF" stroke-width="2" stroke-linecap="round"/>
|
|
<text x="30" y="63" font-size="17" font-weight="700" fill="#E6EDF7">agents/ 决策</text>
|
|
<text x="16" y="86" font-size="13" fill="#AAB6C9">react_agent 循环</text>
|
|
<text x="16" y="106" font-size="13" fill="#AAB6C9">思考→工具→执行</text>
|
|
</g>
|
|
|
|
<g transform="translate(840 118)">
|
|
<path d="M0 18 L14 18" stroke="#22D3EE" stroke-width="2" stroke-linecap="round"/>
|
|
<path d="M6 13 L14 18 L6 23" fill="none" stroke="#22D3EE" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
|
</g>
|
|
|
|
<g transform="translate(856 76)">
|
|
<rect width="168" height="122" rx="14" fill="#101827" stroke="#24324F" stroke-width="1"/>
|
|
<circle cx="30" cy="30" r="12" fill="#22D3EE" opacity="0.16"/>
|
|
<path d="M25 24l-5 6h6l-5 6" fill="none" stroke="#22D3EE" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
|
<text x="30" y="63" font-size="17" font-weight="700" fill="#E6EDF7">输出</text>
|
|
<text x="16" y="86" font-size="13" fill="#AAB6C9">流式回复</text>
|
|
<text x="16" y="106" font-size="13" fill="#AAB6C9">控制台/频道/定时</text>
|
|
</g>
|
|
|
|
<g transform="translate(1040 118)">
|
|
<path d="M0 18 L14 18" stroke="#22D3EE" stroke-width="2" stroke-linecap="round"/>
|
|
<path d="M6 13 L14 18 L6 23" fill="none" stroke="#22D3EE" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
|
</g>
|
|
|
|
<g transform="translate(1056 76)">
|
|
<rect width="88" height="122" rx="14" fill="#0D1424" stroke="#24324F" stroke-width="1"/>
|
|
<text x="44" y="74" font-size="14" font-weight="700" fill="#AAB6C9" text-anchor="middle">记忆 ·</text>
|
|
<text x="44" y="96" font-size="14" font-weight="700" fill="#AAB6C9" text-anchor="middle">用量</text>
|
|
</g>
|
|
</g>
|
|
|
|
<!-- ===== Horizontal capabilities row ===== -->
|
|
<text x="56" y="252" font-family="ui-monospace,SFMono-Regular,Menlo,monospace" font-size="15" letter-spacing="2" fill="#7A879B">横向能力 · HORIZONTAL LAYERS</text>
|
|
|
|
<g font-family="-apple-system,BlinkMacSystemFont,'Segoe UI','PingFang SC','Microsoft YaHei',sans-serif">
|
|
<g transform="translate(56 282)">
|
|
<rect width="256" height="150" rx="14" fill="#101827" stroke="#24324F" stroke-width="1"/>
|
|
<rect width="256" height="3" rx="1.5" fill="#1677FF"/>
|
|
<circle cx="26" cy="40" r="12" fill="#1677FF" opacity="0.16"/>
|
|
<path d="M21 36l4-3 4 3 0 8H21z" fill="none" stroke="#1677FF" stroke-width="1.8" stroke-linecap="round" stroke-linejoin="round"/>
|
|
<text x="30" y="82" font-size="17" font-weight="700" fill="#E6EDF7">治理 governance/</text>
|
|
<text x="16" y="106" font-size="13.5" fill="#AAB6C9">allow / deny / ask 权限门控</text>
|
|
<text x="16" y="126" font-size="13.5" fill="#AAB6C9">决策前统一放行或拦截</text>
|
|
</g>
|
|
|
|
<g transform="translate(328 282)">
|
|
<rect width="256" height="150" rx="14" fill="#101827" stroke="#24324F" stroke-width="1"/>
|
|
<rect width="256" height="3" rx="1.5" fill="#1677FF"/>
|
|
<circle cx="26" cy="40" r="12" fill="#1677FF" opacity="0.16"/>
|
|
<path d="M22 34h12v12H22zM26 38v8M30 38v8" stroke="#1677FF" stroke-width="1.8" stroke-linecap="round"/>
|
|
<text x="30" y="82" font-size="17" font-weight="700" fill="#E6EDF7">沙箱 sandbox/</text>
|
|
<text x="16" y="106" font-size="13.5" fill="#AAB6C9">内核级执行隔离</text>
|
|
<text x="16" y="126" font-size="13.5" fill="#AAB6C9">Seatbelt / Bubblewrap</text>
|
|
</g>
|
|
|
|
<g transform="translate(600 282)">
|
|
<rect width="256" height="150" rx="14" fill="#101827" stroke="#24324F" stroke-width="1"/>
|
|
<rect width="256" height="3" rx="1.5" fill="#22D3EE"/>
|
|
<circle cx="26" cy="40" r="12" fill="#22D3EE" opacity="0.16"/>
|
|
<path d="M26 30v8M22 34l8 8 8-8" stroke="#22D3EE" stroke-width="1.8" stroke-linecap="round" stroke-linejoin="round"/>
|
|
<text x="30" y="82" font-size="17" font-weight="700" fill="#E6EDF7">记忆 memory/</text>
|
|
<text x="16" y="106" font-size="13.5" fill="#AAB6C9">工作上下文 · 逐字历史</text>
|
|
<text x="16" y="126" font-size="13.5" fill="#AAB6C9">ReMe 个人知识库(三层)</text>
|
|
</g>
|
|
|
|
<g transform="translate(872 282)">
|
|
<rect width="272" height="150" rx="14" fill="#101827" stroke="#24324F" stroke-width="1"/>
|
|
<rect width="272" height="3" rx="1.5" fill="#22D3EE"/>
|
|
<circle cx="26" cy="40" r="12" fill="#22D3EE" opacity="0.16"/>
|
|
<path d="M32 32h-8v4l8 8M32 40h-4v6" fill="none" stroke="#22D3EE" stroke-width="1.8" stroke-linecap="round" stroke-linejoin="round"/>
|
|
<text x="30" y="82" font-size="17" font-weight="700" fill="#E6EDF7">用量 token_usage/</text>
|
|
<text x="16" y="106" font-size="13.5" fill="#AAB6C9">每轮 token / 上下文统计</text>
|
|
<text x="16" y="126" font-size="13.5" fill="#AAB6C9">成本可视化与预算</text>
|
|
</g>
|
|
</g>
|
|
</svg>
|