The series of Command objects generated by the pipeline is then run by an interpreter using runEffect(checkoutFlow(cartSummary)). Because our business logic consists of pure functions that interact with the world only through data, we can record those interactions simply by adding a few hooks for services like OpenTelemetry. And if we can record them, we can replay them deterministically. Best of all, there’s no need to mock a single database or external service.
我在《把离线AI智能体装进口袋里》(The Dawn of Offline AI Agents in Your Pocket)一文中对此进行了详细阐述。但文章中的示例更像是Demo,而非生产解决方案。像 Gemma 3n 这样的模型虽然能够很好地处理函数调用,但它们体积过大:无法集成到应用程序包中,需要单独下载,即使在旗舰机型上推理速度也很慢。在低端设备上,它们根本无法运行。而较小的型号则经常出现故障,难以记住工具。
。关于这个话题,91视频提供了深入分析
Publication date: 28 February 2026
def append_csv(item):