Files
ai-agent-book/book-ru/images/fig6-3.svg
T
liqiang b119135836
Build latest book artifacts / build (push) Canceled after 0s
dependency resolution / resolve (3.11) (push) Canceled after 0s
dependency resolution / resolve (3.13) (push) Canceled after 0s
deploy-pages / build (push) Canceled after 0s
deploy-pages / deploy (push) Canceled after 0s
i18n consistency check / check (push) Canceled after 0s
provider adoption tests / test (chapter2/context-compression) (push) Canceled after 0s
provider adoption tests / test (chapter2/prompt-injection) (push) Canceled after 0s
provider adoption tests / test (chapter2/system-hint) (push) Canceled after 0s
provider adoption tests / test (chapter3/log-sanitization) (push) Canceled after 0s
web-search-agent tests / test (push) Canceled after 0s
web-search-agent tests / agentbook (push) Canceled after 0s
ai-agent-book 精选快照(<2MB 代码与文档,来自 github.com/bojieli/ai-agent-book)
2026-08-20 13:12:50 +00:00

75 lines
13 KiB
XML

<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 40 880 440" width="880" height="440" style="background:#ffffff">
<defs><marker id="ah" markerWidth="12" markerHeight="8" refX="12" refY="4" orient="auto"><polygon points="0 0, 12 4, 0 8" fill="#333333"/></marker><marker id="ah-light" markerWidth="12" markerHeight="8" refX="12" refY="4" orient="auto"><polygon points="0 0, 12 4, 0 8" fill="#999999"/></marker></defs>
<text x="85" y="65" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="11.5" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">Внешний источник события</text>
<rect x="10" y="82" width="150" height="44" rx="6" fill="#f0f0f0" stroke="#333333" stroke-width="2"/>
<text x="85" y="98" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="16" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">Веб/приложение</text>
<text x="15" y="118" font-family="'Courier New', Courier, monospace" font-size="11" fill="#333333" text-anchor="start" dominant-baseline="central">on_user_message</text>
<rect x="10" y="140" width="150" height="44" rx="6" fill="#f0f0f0" stroke="#333333" stroke-width="2"/>
<text x="85" y="156" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="16" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">Система email</text>
<text x="15" y="176" font-family="'Courier New', Courier, monospace" font-size="11" fill="#333333" text-anchor="start" dominant-baseline="central">on_email_reply</text>
<rect x="10" y="198" width="150" height="44" rx="6" fill="#f0f0f0" stroke="#333333" stroke-width="2"/>
<text x="85" y="214" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="16" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">GitHub</text>
<text x="15" y="234" font-family="'Courier New', Courier, monospace" font-size="11" fill="#333333" text-anchor="start" dominant-baseline="central">on_github_pr_update</text>
<rect x="10" y="256" width="150" height="44" rx="6" fill="#f0f0f0" stroke="#333333" stroke-width="2"/>
<text x="85" y="272" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="16" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">Таймер</text>
<text x="15" y="292" font-family="'Courier New', Courier, monospace" font-size="11" fill="#333333" text-anchor="start" dominant-baseline="central">on_timer_expire</text>
<rect x="10" y="314" width="150" height="44" rx="6" fill="#f0f0f0" stroke="#333333" stroke-width="2"/>
<text x="85" y="330" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="16" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">Webhook</text>
<text x="15" y="350" font-family="'Courier New', Courier, monospace" font-size="11" fill="#333333" text-anchor="start" dominant-baseline="central">on_webhook_received</text>
<rect x="10" y="372" width="150" height="44" rx="6" fill="#f0f0f0" stroke="#333333" stroke-width="2"/>
<text x="85" y="388" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="11" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">Системное оповещение</text>
<text x="15" y="408" font-family="'Courier New', Courier, monospace" font-size="11" fill="#333333" text-anchor="start" dominant-baseline="central">on_resource_alert</text>
<rect x="200" y="80" width="200" height="390" rx="6" fill="#ffffff" stroke="#333333" stroke-width="2" stroke-dasharray="8,4"/>
<text x="300" y="100" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="20" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">FastAPI-сервер</text>
<rect x="215" y="120" width="170" height="50" rx="6" fill="#d0d0d0" stroke="#333333" stroke-width="2"/>
<text x="300" y="137" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="16" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">HTTP-эндпоинт</text>
<text x="300" y="157" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="14" fill="#666666" text-anchor="middle" dominant-baseline="central" font-weight="normal">POST /events/{type}</text>
<rect x="215" y="190" width="170" height="50" rx="6" fill="#f0f0f0" stroke="#333333" stroke-width="2"/>
<text x="300" y="207" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="12" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">Маршрутизатор событий</text>
<text x="300" y="227" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="11.5" fill="#666666" text-anchor="middle" dominant-baseline="central" font-weight="normal">LLM определяет срочность</text>
<rect x="215" y="260" width="170" height="50" rx="6" fill="#f0f0f0" stroke="#333333" stroke-width="2"/>
<text x="300" y="277" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="16" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">Очередь событий</text>
<text x="300" y="297" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="11.5" fill="#666666" text-anchor="middle" dominant-baseline="central" font-weight="normal">Сортировка по приоритету</text>
<rect x="215" y="330" width="170" height="50" rx="6" fill="#f0f0f0" stroke="#333333" stroke-width="2"/>
<text x="300" y="347" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="16" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">Цикл агента</text>
<text x="300" y="367" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="7.5" fill="#666666" text-anchor="middle" dominant-baseline="central" font-weight="normal">Получение → Рассуждение → Выполнение</text>
<rect x="215" y="400" width="170" height="50" rx="6" fill="#d0d0d0" stroke="#333333" stroke-width="2"/>
<text x="300" y="417" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="14.5" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">Управление сессией</text>
<text x="300" y="437" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="12" fill="#666666" text-anchor="middle" dominant-baseline="central" font-weight="normal">Многопоточный контекст</text>
<line x1="300" y1="170" x2="300" y2="190" stroke="#333333" stroke-width="2" marker-end="url(#ah)"/>
<line x1="300" y1="240" x2="300" y2="260" stroke="#333333" stroke-width="2" marker-end="url(#ah)"/>
<line x1="300" y1="310" x2="300" y2="330" stroke="#333333" stroke-width="2" marker-end="url(#ah)"/>
<line x1="300" y1="380" x2="300" y2="400" stroke="#333333" stroke-width="2" marker-end="url(#ah)"/>
<line x1="160" y1="104" x2="213" y2="145" stroke="#333333" stroke-width="2" marker-end="url(#ah)"/>
<line x1="160" y1="162" x2="213" y2="145" stroke="#333333" stroke-width="2" marker-end="url(#ah)"/>
<line x1="160" y1="220" x2="213" y2="145" stroke="#333333" stroke-width="2" marker-end="url(#ah)"/>
<line x1="160" y1="278" x2="213" y2="145" stroke="#333333" stroke-width="2" marker-end="url(#ah)"/>
<line x1="160" y1="336" x2="213" y2="145" stroke="#333333" stroke-width="2" marker-end="url(#ah)"/>
<line x1="160" y1="394" x2="213" y2="145" stroke="#333333" stroke-width="2" marker-end="url(#ah)"/>
<text x="610" y="65" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="20" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">Сервер инструментов MCP</text>
<rect x="460" y="82" width="250" height="80" rx="6" fill="#f0f0f0" stroke="#333333" stroke-width="2"/>
<text x="585" y="104" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="16" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">Инструменты восприятия</text>
<text x="470" y="130" font-family="'Courier New', Courier, monospace" font-size="12" fill="#333333" text-anchor="start" dominant-baseline="central">search_web, read_file</text>
<text x="470" y="148" font-family="'Courier New', Courier, monospace" font-size="12" fill="#333333" text-anchor="start" dominant-baseline="central">read_webpage, parse_image</text>
<rect x="460" y="182" width="250" height="80" rx="6" fill="#f0f0f0" stroke="#333333" stroke-width="2"/>
<text x="585" y="204" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="16" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">инструмент выполнения</text>
<text x="470" y="230" font-family="'Courier New', Courier, monospace" font-size="12" fill="#333333" text-anchor="start" dominant-baseline="central">code_interpreter</text>
<text x="470" y="248" font-family="'Courier New', Courier, monospace" font-size="12" fill="#333333" text-anchor="start" dominant-baseline="central">virtual_terminal, write_file</text>
<rect x="460" y="282" width="250" height="80" rx="6" fill="#f0f0f0" stroke="#333333" stroke-width="2"/>
<text x="585" y="304" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="15.5" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">инструмент сотрудничества</text>
<text x="470" y="330" font-family="'Courier New', Courier, monospace" font-size="12" fill="#333333" text-anchor="start" dominant-baseline="central">browser_use</text>
<text x="470" y="348" font-family="'Courier New', Courier, monospace" font-size="12" fill="#333333" text-anchor="start" dominant-baseline="central">request_human_approval</text>
<rect x="460" y="382" width="250" height="80" rx="6" fill="#f0f0f0" stroke="#333333" stroke-width="2"/>
<text x="585" y="404" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="16" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">инструмент уведомлений</text>
<text x="470" y="430" font-family="'Courier New', Courier, monospace" font-size="12" fill="#333333" text-anchor="start" dominant-baseline="central">send_email, send_slack</text>
<text x="470" y="448" font-family="'Courier New', Courier, monospace" font-size="12" fill="#333333" text-anchor="start" dominant-baseline="central">send_im_notification</text>
<line x1="400" y1="355" x2="458" y2="180" stroke="#333333" stroke-width="2" marker-end="url(#ah)"/>
<line x1="458" y1="260" x2="400" y2="355" stroke="#333333" stroke-width="2" marker-end="url(#ah)"/>
<rect x="740" y="82" width="130" height="380" rx="4" fill="#f5f5f5" stroke="#999999" stroke-width="2"/>
<text x="805" y="115" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="9.5" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="bold">слой персистентности</text>
<text x="805" y="160" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="13" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="normal">история диалога</text>
<text x="805" y="215" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="14.5" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="normal">журнал событий</text>
<text x="805" y="270" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="9" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="normal">запланированная задача</text>
<text x="805" y="325" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="11" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="normal">статус инструмента</text>
<text x="805" y="380" font-family="Arial, 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei', sans-serif" font-size="16" fill="#333333" text-anchor="middle" dominant-baseline="central" font-weight="normal">журнал аудита</text>
</svg>