实时机器学习推理中流滞后下的特征新鲜度预算
Feature Freshness Budgets for Real-Time ML Inference Under Stream Lag
浏览论文内容
中文总结 AI 辅助
针对在线特征存储中训练-服务偏差的新鲜度差距,提出特征新鲜度预算模型,证明陈旧度界限与闭式崩溃阈值,并通过模拟与真实管道验证,发现采样相位伪影是模拟-基础设施差距主因,随机化相位可显著调和。
中文摘要 AI 辅助
在线特征存储将特征计算与模型服务解耦,将来自上游事件流的特征物化到低延迟存储中,推理在请求时读取该存储。这种解耦引入了新鲜度差距——即事件在源头发生与其效果在所提供的特征向量中可见之间的间隔——这一差距被广泛记录为训练-服务偏差的原因,但尚未作为有界、成本量化的量进行正式处理。我们将在线特征存储建模为事件流上的物化视图,并定义每个特征的新鲜度预算:特征被消费的决策窗口与服务管道施加给它的陈旧度之间的差异。我们证明了两个命题——每个特征的陈旧度界限,以及一个闭式阈值,低于该阈值特征永远无法在预算内被服务——并在一个有种子、可复现的离散事件模拟以及真实的Apache Kafka、Redis和PostgreSQL管道上验证了它们。预测的崩溃阈值在真实基础设施上复现,决策错误转变落在闭式预测的位置。调和模拟和真实的丢弃率揭示了一个具有独立意义的方法论结果:主导的模拟到基础设施差距不是延迟,而是采样阶段伪影——请求时钟和重新计算节奏相位锁定的模拟系统性地低估了陈旧度。随机化该相位将模拟与基础设施调和到每个特征丢弃率的平均绝对误差在0.018以内。结果仅限于所研究的工作负载和配置,并非对任何特定生产特征存储实现的声明。
英文摘要
Online feature stores decouple feature computation from model serving, materializing features from upstream event streams into a low-latency store that inference reads at request time. This decoupling introduces a freshness gap - the interval between an event occurring at the source and its effect becoming visible in the served feature vector - that is widely documented as a cause of training-serving skew but has no formal treatment as a bounded, cost-quantified quantity. We model the online feature store as a materialized view over an event stream and define a per-feature freshness budget: the difference between the decision window a feature is consumed within and the staleness the serving pipeline imposes on it. We prove two propositions - a per-feature staleness bound, and a closed-form threshold below which a feature can never be served within budget - and validate them in a seeded, reproducible discrete-event simulation and on a real Apache Kafka, Redis, and PostgreSQL pipeline. The predicted collapse threshold reproduces on real infrastructure, with the decision-error transition landing where the closed form predicts. Reconciling simulated and real drop rates surfaces a methodological result of independent interest: the dominant simulation-to-infrastructure gap is not latency but a sampling-phase artifact - a simulation whose request clock and recomputation cadence are phase-locked systematically under-observes staleness. Randomizing that phase reconciles simulation and infrastructure to within 0.018 mean absolute error in per-feature drop rate. Results are scoped to the studied workloads and configurations and are not claims about any specific production feature-store implementation.