《曹博钧_AI+Flow_以Runtime为核心的推理系统跨层协同设计思考.pdf》由会员分享,可在线阅读,更多相关《曹博钧_AI+Flow_以Runtime为核心的推理系统跨层协同设计思考.pdf(21页珍藏版)》请在三个皮匠报告上搜索。
1、以以 Runtime Runtime 为核心的为核心的推理系统跨层协同设计思考推理系统跨层协同设计思考AI FAI Flow:low:算苗科技(北京)有限公司Create the Best Create the Best Computing PowerComputing Power汇报人:曹博钧030102BackgroundBackgroundAI AI 推理推理系统系统软件栈软件栈ThinkingThinking跨层次跨层次协同协同优化优化InspirationInspirationSystem For AISystem For AIAI For SystemAI For System目录
2、目录CONTENTS&01.行业瞬息万变行业瞬息万变 本月科技数码行业动态AI 推理系统推理系统软件栈软件栈01:KernelFrameworkRuntime:Operator.Worker 0Computation Graph BFramework SchedulerOperators-KernelsWorker 1.Computation Graph CFramework SchedulerOperators-KernelsWorker 2.Software Stream:Runtime SchedulerHardwareHardware SchedulerComputation Grap
3、h AFramework SchedulerOperators-KernelsUser IUser IIHardware ExecutorLLM EngineOrchestrationAgent Agent ClientAI AI 推理系统推理系统软件栈软件栈Agent Agent PyTorchTensorflowMindSporePaddleTensorRT-LLMvLLMClaude CodeTrae随着 AI 技术的演进,AI 推理系统软件栈正变得越来越深.:KernelFrameworkRuntime:Operator.Worker 0Computation Graph BFrame
4、work SchedulerOperators-KernelsWorker 1.Computation Graph CFramework SchedulerOperators-KernelsWorker 2.Software Stream:Runtime SchedulerHardwareHardware SchedulerComputation Graph AFramework SchedulerOperators-KernelsUser IUser IIHardware ExecutorLLM EngineOrchestrationAgent Agent ClientAI AI 推理系统推
5、理系统软件栈软件栈Agent Agent Operator FusionMemory ReuseExpert ParallelSemantic Router相应层次的优化技术也百花齐放.Operator Scheduling01.行业瞬息万变行业瞬息万变 本月科技数码行业动态跨层次协同跨层次协同优化优化02跨层次协同优化跨层次协同优化2.1 来玩俄罗斯方块吧!假设我们有两张卡:其中纵轴代表显存地址的 offset,横轴代表时间。而随着模型执行,其中存在的:则是一个个纵向占有一定显存,横向有着生命周期的方块:卡0卡12.1.2 from LLM Engine 当用户激活多个专家时:在它们的视角下
6、,感知到的还是最粗粒度的,对话返回的用时。跨层次协同优化跨层次协同优化2.1.1 from Agent Orchestration 当2个用户路由到了不同的模型时:在它们的视角下,感知到的是最粗粒度的,对话返回的用时。Semantic RouterExpert Parallel跨层次协同优化跨层次协同优化2.1.3 from Framework 当基于算子融合的层次运行kernel时:相较于更上层,在它们的视角下能更进一步的看到细化的算子粒度,如果有精炼的算子排布,是可以做到算子内紧凑复用的,但是,仍然无法避免的是算子之间产生空泡。Operator Fusion2.1.4 from Frame