MCPcopy Create free account
hub / github.com/CopilotKit/OpenGenerativeUI / clear_pending_template

Function clear_pending_template

apps/agent/src/templates.py:251–264  ·  view source on GitHub ↗

Clear the pending_template from state after applying it. Call this after you have finished applying a template.

(runtime: ToolRuntime)

Source from the content-addressed store, hash-verified

249
250@tool
251def clear_pending_template(runtime: ToolRuntime) -> Command:
252 """
253 Clear the pending_template from state after applying it.
254 Call this after you have finished applying a template.
255 """
256 return Command(update={
257 "pending_template": None,
258 "messages": [
259 ToolMessage(
260 content="Pending template cleared",
261 tool_call_id=runtime.tool_call_id,
262 )
263 ],
264 })
265
266
267template_tools = [

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected