Files
google__adk-docs/docs/assets/workflow-plugin-hooks.svg
2025-08-01 15:08:51 +01:00

585 lines
20 KiB
XML

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
viewBox="0 0 900 350"
font-family="sans-serif"
version="1.1"
id="svg24"
sodipodi:docname="workflow-plugin-hooks-2.1.svg"
width="900"
height="350"
inkscape:version="1.4.2 (ebf0e940, 2025-05-08)"
inkscape:export-filename="workflow-plugin-hooks-2.1.png"
inkscape:export-xdpi="245.11"
inkscape:export-ydpi="245.11"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg">
<sodipodi:namedview
id="namedview24"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:showpageshadow="2"
inkscape:pageopacity="0.0"
inkscape:pagecheckerboard="0"
inkscape:deskcolor="#d1d1d1"
inkscape:zoom="1.2561538"
inkscape:cx="733.58849"
inkscape:cy="107.47091"
inkscape:window-width="2520"
inkscape:window-height="1365"
inkscape:window-x="1398"
inkscape:window-y="272"
inkscape:window-maximized="0"
inkscape:current-layer="agent-user" />
<!-- Definitions for reusable elements like arrowheads -->
<rect
x="458.65686"
y="262.87573"
width="120"
height="40"
rx="5"
class="main-box"
id="rect10"
style="font-variation-settings:normal;opacity:1;vector-effect:none;fill:#c8dcfb;fill-opacity:1;stroke:#5a9efc;stroke-width:2.66667;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;-inkscape-stroke:none;stop-color:#000000;stop-opacity:1" />
<defs
id="defs1">
<marker
id="arrowhead"
markerWidth="7.1428571"
markerHeight="5"
refX="0"
refY="3.5"
orient="auto"
viewBox="0 0 10 7"
preserveAspectRatio="xMidYMid">
<polygon
points="10,3.5 0,7 0,0 "
fill="#333333"
id="polygon1" />
</marker>
<marker
id="arrowhead-1"
markerWidth="10"
markerHeight="7"
refX="0"
refY="3.5"
orient="auto"
viewBox="0 0 10 7"
preserveAspectRatio="xMidYMid">
<polygon
points="0,7 0,0 10,3.5 "
fill="#333333"
id="polygon1-8" />
</marker>
<marker
id="arrowhead-8"
markerWidth="10"
markerHeight="7"
refX="0"
refY="3.5"
orient="auto"
viewBox="0 0 10 7"
preserveAspectRatio="xMidYMid">
<polygon
points="0,7 0,0 10,3.5 "
fill="#333333"
id="polygon1-5" />
</marker>
<marker
id="arrowhead-14"
markerWidth="10"
markerHeight="7"
refX="0"
refY="3.5"
orient="auto"
markerUnits="userSpaceOnUse"
viewBox="0 0 10 7"
preserveAspectRatio="xMidYMid">
<polygon
points="0,7 0,0 10,3.5 "
fill="#333333"
id="polygon1-9" />
</marker>
<marker
id="arrowhead-4"
markerWidth="10"
markerHeight="7"
refX="0"
refY="3.5"
orient="auto"
viewBox="0 0 10 7"
preserveAspectRatio="xMidYMid">
<polygon
points="0,7 0,0 10,3.5 "
fill="#333333"
id="polygon1-7" />
</marker>
<marker
id="arrowhead-5"
markerWidth="7.1428571"
markerHeight="5"
refX="0"
refY="3.5"
orient="auto"
viewBox="0 0 10 7"
preserveAspectRatio="xMidYMid">
<polygon
points="0,7 0,0 10,3.5 "
fill="#333333"
id="polygon1-89" />
</marker>
<marker
id="arrowhead-5-9"
markerWidth="7.1428571"
markerHeight="5"
refX="0"
refY="3.5"
orient="auto"
viewBox="0 0 10 7"
preserveAspectRatio="xMidYMid">
<polygon
points="0,0 10,3.5 0,7 "
fill="#333333"
id="polygon1-89-7" />
</marker>
<marker
id="arrowhead-5-2"
markerWidth="7.1428571"
markerHeight="5"
refX="0"
refY="3.5"
orient="auto"
viewBox="0 0 10 7"
preserveAspectRatio="xMidYMid">
<polygon
points="0,0 10,3.5 0,7 "
fill="#333333"
id="polygon1-89-4" />
</marker>
</defs>
<rect
x="458.65686"
y="164.0392"
width="120"
height="40"
rx="5"
class="main-box"
id="rect14"
style="font-variation-settings:normal;opacity:1;vector-effect:none;fill:#c8dcfb;fill-opacity:1;stroke:#5a9efc;stroke-width:2.66667;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;-inkscape-stroke:none;stop-color:#000000;stop-opacity:1" />
<!-- Styles -->
<style
id="style1">
.main-box {
fill: #e0e8f0;
stroke: #a0b0c0;
stroke-width: 1;
}
.main-box-text {
font-size: 18px;
text-anchor: middle;
dominant-baseline: middle;
fill: #000;
}
.event-label {
fill: #fefee8;
stroke: #f2d400;
stroke-width: 1;
}
.event-label-text {
font-size: 14px;
text-anchor: middle;
dominant-baseline: middle;
fill: #333;
}
.flow-line {
stroke: #333;
stroke-width: 1.5;
marker-end: url(#arrowhead);
fill: none;
}
</style>
<!-- AgentUsers -->
<g
id="agent-user"
transform="translate(52.900593,-30.44334)">
<circle
cx="3.9804041"
cy="220.76546"
r="20"
fill="#4dd0e1"
id="circle1"
style="font-variation-settings:normal;opacity:1;vector-effect:none;fill:#c8dcfb;fill-opacity:1;stroke:#5a9efc;stroke-width:2.66667;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;-inkscape-stroke:none;stop-color:#000000;stop-opacity:1" />
<path
d="m -21.019596,250.76546 q 25.0000002,-10 50,0 v 10 q -24.9999998,10 -50,0 z"
fill="#4dd0e1"
id="path1"
style="font-variation-settings:normal;opacity:1;vector-effect:none;fill:#c8dcfb;fill-opacity:1;stroke:#5a9efc;stroke-width:2.66667;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;-inkscape-stroke:none;stop-color:#000000;stop-opacity:1" />
<text
y="290.76547"
class="main-box-text"
font-size="16px"
id="text1"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'"
x="3.9804041">AgentUsers</text>
</g>
<!-- User Message -->
<!-- Runner (Left) -->
<rect
x="244.33966"
y="52.25108"
width="120"
height="40"
rx="5"
class="main-box"
id="rect4"
style="font-variation-settings:normal;opacity:1;vector-effect:none;fill:#c8dcfb;fill-opacity:1;stroke:#5a9efc;stroke-width:2.66667;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;-inkscape-stroke:none;stop-color:#000000;stop-opacity:1" />
<rect
x="88.545105"
y="42.017467"
width="120"
height="55.921585"
rx="5"
class="main-box"
id="rect4-7"
style="font-variation-settings:normal;opacity:1;vector-effect:none;fill:#c8dcfb;fill-opacity:1;stroke:#5a9efc;stroke-width:2.66667;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;-inkscape-stroke:none;stop-color:#000000;stop-opacity:1" />
<rect
x="737.47089"
y="160.47115"
width="120"
height="55.921585"
rx="5"
class="main-box"
id="rect4-7-6"
style="font-variation-settings:normal;vector-effect:none;fill:#c8dcfb;fill-opacity:1;stroke:#5a9efc;stroke-width:2.66667;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;-inkscape-stroke:none;stop-color:#000000" />
<text
class="main-box-text"
id="text5"
x="304.33966"
y="72.251083"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:18.6667px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'"><tspan
style="font-weight:bold"
id="tspan25">Runner</tspan></text>
<g
id="g24"
transform="translate(399.86936,42)">
<rect
x="-180"
y="-13"
width="100"
height="25"
rx="5"
class="event-label"
id="rect5"
style="fill:#fcfebf;fill-opacity:1;stroke:#fbc513;stroke-width:2;stroke-dasharray:none;stroke-opacity:1" />
<text
x="-130"
y="0"
class="event-label-text"
id="text6"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:13.3333px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'">before_run</text>
</g>
<!-- Agent -->
<rect
x="399.33966"
y="52.25108"
width="120"
height="40"
rx="5"
class="main-box"
id="rect6"
style="font-variation-settings:normal;opacity:1;vector-effect:none;fill:#c8dcfb;fill-opacity:1;stroke:#5a9efc;stroke-width:2.66667;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;-inkscape-stroke:none;stop-color:#000000;stop-opacity:1" />
<text
class="main-box-text"
id="text7"
x="459.33966"
y="72.251083"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:18.6667px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'"><tspan
style="font-weight:bold"
id="tspan26">Agent</tspan></text>
<rect
x="367.2576"
y="29.000011"
width="110"
height="25"
rx="5"
class="event-label"
id="rect7"
style="fill:#fcfebf;fill-opacity:1;stroke:#fbc513;stroke-width:2;stroke-dasharray:none;stroke-opacity:1" />
<text
x="422.2576"
y="42.000011"
class="event-label-text"
id="text8"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:13.3333px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'">before_agent</text>
<rect
x="464.50806"
y="89.502151"
width="100"
height="25"
rx="5"
class="event-label"
id="rect8"
style="fill:#fcfebf;fill-opacity:1;stroke:#fbc513;stroke-width:2;stroke-dasharray:none;stroke-opacity:1" />
<text
x="514.50806"
y="102.50215"
class="event-label-text"
id="text9"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:13.3333px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'">after_agent</text>
<!-- Split Flow Lines -->
<path
class="flow-line"
d="m 420.91899,92.3737 0.33419,92.9096 h 22.64999"
id="path9"
sodipodi:nodetypes="ccc"
style="stroke-width:2.66667;stroke-dasharray:none;marker-end:url(#arrowhead-5)" />
<path
class="flow-line"
d="m 408.8834,92.62258 0.33419,190.82754 h 33.79512"
id="path9-6"
sodipodi:nodetypes="ccc"
style="fill:none;stroke:#333333;stroke-width:2.66667;stroke-dasharray:none;marker-end:url(#arrowhead-5)" />
<path
class="flow-line"
d="m 55.377833,150.07706 0.33419,-79.04386 h 15.79512"
id="path9-6-8"
sodipodi:nodetypes="ccc"
style="fill:none;stroke:#333333;stroke-width:2.66667;stroke-dasharray:none;marker-end:url(#arrowhead-5-2)" />
<path
class="flow-line"
d="m 577.45356,284.00858 h 124 v -82 h 20"
id="path10"
style="stroke-width:2.66667;stroke-dasharray:none;marker-end:url(#arrowhead-5)"
sodipodi:nodetypes="cccc" />
<!-- Tool Branch -->
<text
class="main-box-text"
id="text10"
x="518.65686"
y="282.87573"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:18.6667px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'"><tspan
style="font-weight:bold"
id="tspan28">Tool</tspan></text>
<rect
x="402.91592"
y="240.42076"
width="110"
height="25"
rx="5"
class="event-label"
id="rect11"
style="fill:#fcfebf;fill-opacity:1;stroke:#fbc513;stroke-width:2;stroke-dasharray:none;stroke-opacity:1" />
<text
x="457.91589"
y="253.42078"
class="event-label-text"
id="text11"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:13.3333px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'">before_tool</text>
<rect
x="523.02917"
y="296.94247"
width="90"
height="25"
rx="5"
class="event-label"
id="rect13"
style="fill:#fcfebf;fill-opacity:1;stroke:#fbc513;stroke-width:2;stroke-dasharray:none;stroke-opacity:1" />
<text
x="568.02917"
y="309.94247"
class="event-label-text"
id="text13"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:13.3333px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'">after_tool</text>
<!-- Model Branch -->
<text
class="main-box-text"
id="text14"
x="518.65686"
y="184.0392"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:18.6667px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'"><tspan
style="font-weight:bold"
id="tspan27">Model</tspan></text>
<rect
x="401.32373"
y="142.38028"
width="115"
height="25"
rx="5"
class="event-label"
id="rect15"
style="fill:#fcfebf;fill-opacity:1;stroke:#fbc513;stroke-width:2;stroke-dasharray:none;stroke-opacity:1" />
<text
x="458.82373"
y="155.38025"
class="event-label-text"
id="text15"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:13.3333px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'">before_model</text>
<rect
x="523.02917"
y="202.08635"
width="100"
height="25"
rx="5"
class="event-label"
id="rect17"
style="fill:#fcfebf;fill-opacity:1;stroke:#fbc513;stroke-width:2;stroke-dasharray:none;stroke-opacity:1" />
<text
x="573.02917"
y="215.08635"
class="event-label-text"
id="text17"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:13.3333px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'">after_model</text>
<!-- Join Flow Lines -->
<path
class="flow-line"
d="m 519.78669,75.10396 h 181.83956 v 98 h 18.83527"
id="path17-4"
style="fill:none;stroke:#333333;stroke-width:2.66667;stroke-dasharray:none;marker-end:url(#arrowhead-5)"
sodipodi:nodetypes="cccc" />
<!-- Event -->
<text
class="main-box-text"
id="text21"
x="796.66852"
y="189.29454"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:18.6667px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'"><tspan
style="font-weight:bold"
id="tspan29">Event</tspan></text>
<rect
x="750.07635"
y="138.31784"
width="90"
height="25"
rx="5"
class="event-label"
id="rect21"
style="fill:#fcfebf;fill-opacity:1;stroke:#fbc513;stroke-width:2;stroke-dasharray:none;stroke-opacity:1" />
<text
x="795.07635"
y="150.81784"
class="event-label-text"
id="text22"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:13.3333px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'">on_event</text>
<!-- Runner (Right) -->
<rect
x="735.86023"
y="43.066753"
width="120"
height="40"
rx="5"
class="main-box"
id="rect22"
style="font-variation-settings:normal;opacity:1;vector-effect:none;fill:#c8dcfb;fill-opacity:1;stroke:#5a9efc;stroke-width:2.66667;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;-inkscape-stroke:none;stop-color:#000000;stop-opacity:1" />
<text
class="main-box-text"
id="text23"
x="795.86023"
y="63.066757"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:18.6667px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'"><tspan
style="font-weight:bold"
id="tspan30">Runner</tspan></text>
<rect
x="779.53442"
y="77.929581"
width="90"
height="25"
rx="5"
class="event-label"
id="rect23"
style="fill:#fcfebf;fill-opacity:1;stroke:#fbc513;stroke-width:2;stroke-dasharray:none;stroke-opacity:1" />
<text
x="824.53442"
y="90.929581"
class="event-label-text"
id="text24"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:13.3333px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'">after_run</text>
<rect
x="105.33171"
y="93.694443"
width="130"
height="25"
rx="5"
class="event-label"
id="rect3"
style="fill:#fcfebf;fill-opacity:1;stroke:#fbc513;stroke-width:2;stroke-dasharray:none;stroke-opacity:1" />
<text
x="170.33171"
y="106.19444"
class="event-label-text"
id="text4"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:13.3333px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'">on_user_message</text>
<path
class="flow-line"
d="m 364.33966,72.25108 h 19.65095"
id="path6"
style="stroke-width:2.66667;stroke-dasharray:none;marker-end:url(#arrowhead-5)"
sodipodi:nodetypes="cc" />
<path
class="flow-line"
d="m 208.69606,73.09324 h 20.44703"
id="path6-9"
style="fill:none;stroke:#333333;stroke-width:2.66667;stroke-dasharray:none;marker-end:url(#arrowhead-5)"
sodipodi:nodetypes="cc" />
<path
style="font-variation-settings:normal;opacity:1;vector-effect:none;fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#333333;stroke-width:2.66667;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;-inkscape-stroke:none;marker-end:url(#arrowhead-5);stop-color:#000000;stop-opacity:1"
d="m 578.02,186.5193 142.84752,0.79608"
id="path30"
inkscape:connector-type="polyline"
inkscape:connector-curvature="0"
sodipodi:nodetypes="cc" />
<path
class="flow-line"
d="m 856.26127,188.54992 h 30 v -122 h -14.58052"
id="path17"
style="stroke-width:2.66667;stroke-dasharray:none;marker-end:url(#arrowhead-5)"
sodipodi:nodetypes="cccc" />
<rect
x="570.10815"
y="246.80101"
width="120"
height="25"
rx="5"
class="event-label"
id="rect12"
style="fill:#f4d7d7;fill-opacity:1;stroke:#fb7a13;stroke-width:2;stroke-dasharray:none;stroke-opacity:1" />
<text
y="259.30103"
class="event-label-text"
id="text12"
x="630.10815"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:13.3333px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'">on_tool_error</text>
<rect
x="569.31207"
y="144.78017"
width="120"
height="25"
rx="5"
class="event-label"
id="rect16"
style="fill:#f4d7d7;fill-opacity:1;stroke:#fb7a13;stroke-width:2;stroke-dasharray:none;stroke-opacity:1" />
<text
y="157.28017"
class="event-label-text"
id="text16"
x="629.31207"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:13.3333px;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'">on_model_error</text>
<text
xml:space="preserve"
style="font-size:18.6667px;line-height:1;font-family:Arial;-inkscape-font-specification:Arial;text-align:center;text-anchor:middle"
x="149.72852"
y="64.738541"
id="text31"><tspan
sodipodi:role="line"
id="tspan31"
x="149.72852"
y="64.738541"
style="font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;font-size:18.6667px;line-height:1;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'">User</tspan><tspan
sodipodi:role="line"
x="149.72852"
y="83.490257"
id="tspan32"
style="font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;font-size:18.6667px;line-height:1;font-family:'Google Sans';-inkscape-font-specification:'Google Sans'">Message</tspan></text>
</svg>