debugging

This commit is contained in:
2026-01-29 18:05:55 +08:00
parent cbefea447b
commit 06deafc026

View File

@@ -225,4 +225,16 @@ class Pipeline:
async def aclear_memory(self):
"""Async version: Clear all memory from the graph."""
if hasattr(self.graph, "aclear_memory"):
await self.graph.aclear_memory()
await self.graph.aclear_memory()
if __name__ == "__main__":
from lang_agent.graphs import ReactGraphConfig
from dotenv import load_dotenv
load_dotenv()
# config = PipelineConfig(graph_config=ReactGraphConfig())
config = PipelineConfig()
pipeline: Pipeline = config.setup()
for out in pipeline.chat("use the calculator tool to calculate 92*55 and say the answer", as_stream=True):
# print(out)
continue