[{"data":1,"prerenderedAt":315},["ShallowReactive",2],{"content-/blog/real-time-optimization":3,"related-blog":290},{"_path":4,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":8,"description":9,"keywords":10,"author":11,"date":12,"category":13,"image":14,"body":15,"_type":284,"_id":285,"_source":286,"_file":287,"_stem":288,"_extension":289},"/blog/real-time-optimization","blog",false,"","实时优化建议","多智能体实时分析和提供优化建议","实时优化建议, Blog, HTMLPAGE","HTMLPAGE","2025-11-26","待分类","/content-images/blog/blog.jpg",{"type":16,"children":17,"toc":271},"root",[18,26,32,47,52,58,66,71,98,103,111,115,120,142,147,152,157,185,190,216,219,224,229,247,250,254],{"type":19,"tag":20,"props":21,"children":22},"element","p",{},[23],{"type":24,"value":25},"text","实时功能的优化涉及传输层、数据层与渲染层的协同优化。本文列出常见方向与工程实践。",{"type":19,"tag":27,"props":28,"children":30},"h3",{"id":29},"传输优化",[31],{"type":24,"value":29},{"type":19,"tag":33,"props":34,"children":35},"ul",{},[36,42],{"type":19,"tag":37,"props":38,"children":39},"li",{},[40],{"type":24,"value":41},"使用合适的协议（SSE/WebSocket/HTTP/2/3）并实现心跳、重连与节流策略。",{"type":19,"tag":37,"props":43,"children":44},{},[45],{"type":24,"value":46},"增量渲染与局部更新减少主线程压力，使用虚拟化处理大量实时项列表。",{"type":19,"tag":20,"props":48,"children":49},{},[50],{"type":24,"value":51},"实时优化关注减少交互延迟、降低尾时延并保证系统在高并发下的稳定性。本文列出常见瓶颈、测量方法与工程实践（以编辑器/预览场景为主）。",{"type":19,"tag":53,"props":54,"children":56},"h2",{"id":55},"关键场景与指标",[57],{"type":24,"value":55},{"type":19,"tag":33,"props":59,"children":60},{},[61],{"type":19,"tag":37,"props":62,"children":63},{},[64],{"type":24,"value":65},"编辑器交互延迟（INP/FID）、实时协作的变更传播延迟、以及实时渲染的帧率与卡顿事件。",{"type":19,"tag":53,"props":67,"children":69},{"id":68},"优化策略",[70],{"type":24,"value":68},{"type":19,"tag":33,"props":72,"children":73},{},[74,79,93],{"type":19,"tag":37,"props":75,"children":76},{},[77],{"type":24,"value":78},"本地优先渲染：尽可能在客户端做可行渲染，降低网络等待依赖。",{"type":19,"tag":37,"props":80,"children":81},{},[82,84,91],{"type":24,"value":83},"优化事件循环与长任务：拆分长函数为短任务，使用 ",{"type":19,"tag":85,"props":86,"children":88},"code",{"className":87},[],[89],{"type":24,"value":90},"requestIdleCallback",{"type":24,"value":92}," / Web Worker 处理非关键计算。",{"type":19,"tag":37,"props":94,"children":95},{},[96],{"type":24,"value":97},"减少序列化开销：在进程内传递对象、避免重复 stringify/parse。",{"type":19,"tag":53,"props":99,"children":101},{"id":100},"测试与回归",[102],{"type":24,"value":100},{"type":19,"tag":33,"props":104,"children":105},{},[106],{"type":19,"tag":37,"props":107,"children":108},{},[109],{"type":24,"value":110},"用合成负载与真实用户 RUM 对比，关注 P95/P99 变化；在 CI 中限制回归阈值。",{"type":19,"tag":112,"props":113,"children":114},"hr",{},[],{"type":19,"tag":20,"props":116,"children":117},{},[118],{"type":24,"value":119},"相关链接：",{"type":19,"tag":33,"props":121,"children":122},{},[123,133],{"type":19,"tag":37,"props":124,"children":125},{},[126],{"type":19,"tag":127,"props":128,"children":130},"a",{"href":129},"/blog",[131],{"type":24,"value":132},"返回博客分类",{"type":19,"tag":37,"props":134,"children":135},{},[136],{"type":19,"tag":127,"props":137,"children":139},{"href":138},"/blog/topic/multi-agent-system",[140],{"type":24,"value":141},"查看热门话题",{"type":19,"tag":27,"props":143,"children":145},{"id":144},"结语",[146],{"type":24,"value":144},{"type":19,"tag":20,"props":148,"children":149},{},[150],{"type":24,"value":151},"实时优化需要整体视角，评估延迟、带宽、服务器连接数与前端渲染成本的平衡点。",{"type":19,"tag":53,"props":153,"children":155},{"id":154},"初步纲要",[156],{"type":24,"value":154},{"type":19,"tag":33,"props":158,"children":159},{},[160,165,170,175,180],{"type":19,"tag":37,"props":161,"children":162},{},[163],{"type":24,"value":164},"主题简介",{"type":19,"tag":37,"props":166,"children":167},{},[168],{"type":24,"value":169},"背景与动机",{"type":19,"tag":37,"props":171,"children":172},{},[173],{"type":24,"value":174},"核心概念",{"type":19,"tag":37,"props":176,"children":177},{},[178],{"type":24,"value":179},"实践案例",{"type":19,"tag":37,"props":181,"children":182},{},[183],{"type":24,"value":184},"进一步扩展",{"type":19,"tag":53,"props":186,"children":188},{"id":187},"相关链接",[189],{"type":24,"value":187},{"type":19,"tag":33,"props":191,"children":192},{},[193,200,207],{"type":19,"tag":37,"props":194,"children":195},{},[196],{"type":19,"tag":127,"props":197,"children":198},{"href":129},[199],{"type":24,"value":132},{"type":19,"tag":37,"props":201,"children":202},{},[203],{"type":19,"tag":127,"props":204,"children":205},{"href":138},[206],{"type":24,"value":141},{"type":19,"tag":37,"props":208,"children":209},{},[210],{"type":19,"tag":127,"props":211,"children":213},{"href":212},"/blog/ai-architecture-deep-dive",[214],{"type":24,"value":215},"AI 架构深入",{"type":19,"tag":112,"props":217,"children":218},{},[],{"type":19,"tag":20,"props":220,"children":221},{},[222],{"type":24,"value":223},"本文针对编辑器与预览场景补充了更具体的工程建议与上线检查清单，帮助团队在高并发下保持低延迟体验。",{"type":19,"tag":53,"props":225,"children":227},{"id":226},"上线前检查清单",[228],{"type":24,"value":226},{"type":19,"tag":33,"props":230,"children":231},{},[232,237,242],{"type":19,"tag":37,"props":233,"children":234},{},[235],{"type":24,"value":236},"是否在关键路径上启用本地优先渲染？",{"type":19,"tag":37,"props":238,"children":239},{},[240],{"type":24,"value":241},"是否对长任务进行了拆分或移至 Worker？",{"type":19,"tag":37,"props":243,"children":244},{},[245],{"type":24,"value":246},"是否有 P95/P99 基线并在 CI 中阻断回归？",{"type":19,"tag":112,"props":248,"children":249},{},[],{"type":19,"tag":20,"props":251,"children":252},{},[253],{"type":24,"value":119},{"type":19,"tag":33,"props":255,"children":256},{},[257,264],{"type":19,"tag":37,"props":258,"children":259},{},[260],{"type":19,"tag":127,"props":261,"children":262},{"href":129},[263],{"type":24,"value":132},{"type":19,"tag":37,"props":265,"children":266},{},[267],{"type":19,"tag":127,"props":268,"children":269},{"href":138},[270],{"type":24,"value":141},{"title":7,"searchDepth":272,"depth":272,"links":273},3,[274,275,277,278,281,282,283],{"id":29,"depth":272,"text":29},{"id":55,"depth":276,"text":55},2,{"id":68,"depth":276,"text":68},{"id":100,"depth":276,"text":100,"children":279},[280],{"id":144,"depth":272,"text":144},{"id":154,"depth":276,"text":154},{"id":187,"depth":276,"text":187},{"id":226,"depth":276,"text":226},"markdown","content:blog:real-time-optimization.md","content","blog/real-time-optimization.md","blog/real-time-optimization","md",[291,299,307],{"_path":292,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":293,"description":294,"keywords":295,"author":11,"date":12,"category":13,"image":14,"_type":284,"_id":296,"_source":286,"_file":297,"_stem":298,"_extension":289},"/blog/2025-q1-updates","2025 Q1 产品更新","第一季度重大功能发布：AI 生成优化、新模板上线、编辑器增强等","2025 Q1 产品更新, Blog, HTMLPAGE","content:blog:2025-q1-updates.md","blog/2025-q1-updates.md","blog/2025-q1-updates",{"_path":300,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":301,"description":302,"keywords":303,"author":11,"date":12,"category":13,"image":14,"_type":284,"_id":304,"_source":286,"_file":305,"_stem":306,"_extension":289},"/blog/2025-roadmap","2025 产品路线图","展望 2025 年的产品规划：AI 能力增强、模板扩充、国际化等","2025 产品路线图, Blog, HTMLPAGE","content:blog:2025-roadmap.md","blog/2025-roadmap.md","blog/2025-roadmap",{"_path":308,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":309,"description":310,"keywords":311,"author":11,"date":12,"category":13,"image":14,"_type":284,"_id":312,"_source":286,"_file":313,"_stem":314,"_extension":289},"/blog/ab-testing","A/B 测试","通过 A/B 测试验证设计方案","A/B 测试, Blog, HTMLPAGE","content:blog:ab-testing.md","blog/ab-testing.md","blog/ab-testing",1774945288350]