为生成模型添加实时安全防护,确保输出始终满足约束条件。
Provably Safe Generative Sampling with Constricting Barrier Functions
- 用收缩式安全管配合控制屏障函数,动态调节生成过程中的安全边界。
- 所有实验均实现100%约束满足,且保持生成内容语义一致。
- 无需重训练或修改模型,适用于图像、轨迹和机器人控制等场景。
基于流的生成模型(如扩散模型和流匹配模型)在学习复杂数据分布方面取得了显著成功,但在安全关键领域部署时仍面临重大挑战:缺乏对生成样本满足硬性约束的正式保证。本文提出一种安全过滤框架,作为任何预训练生成模型的在线防护盾。核心思想是与生成过程协同而非取代它。定义一个随生成进程从初始噪声分布逐渐收紧至目标安全集的收缩式安全管,其结构与生成过程的粗到精特征相呼应。通过控制屏障函数(CBFs)刻画该安全管,并在每一步采样中通过凸二次规划(QP)合成反馈控制输入。当噪声较高时,安全管最宽松,控制能耗最低,此时干预对模型学习结构的破坏最小。我们证明该机制在离散时间下可保证安全采样。每步合成的最小范数控制使安全分布与原始分布之间的KL散度增量最小化。所有实验均观察到100%约束满足。该框架适用于任何预训练的基于流的采样方案,无需重新训练或架构修改。我们在受限图像生成、物理一致性轨迹采样及安全机器人操作策略等多个场景中验证了该方法,均实现100%约束满足,同时保持语义保真度。
原文摘要 · Abstract (English)
Flow-based generative models, such as diffusion models and flow matching models, have achieved remarkable success in learning complex data distributions. However, a critical gap remains for their deployment in safety-critical domains: the lack of formal guarantees that generated samples will satisfy hard constraints. We propose a safety filtering framework that acts as an online shield for any pre-trained generative model. Our key insight is to cooperate with the generative process rather than override it. We define a constricting safety tube that is relaxed at the initial noise distribution and progressively tightens to the target safe set at the final data distribution, mirroring the coarse-to-fine structure of the generative process itself. By characterizing this tube via Control Barrier Functions (CBFs), we synthesize a feedback control input through a convex Quadratic Program (QP) at each sampling step. As the tube is loosest when noise is high and intervention is cheapest in terms of control energy, most constraint enforcement occurs when it least disrupts the model's learned structure. We prove that this mechanism guarantees safe sampling in discrete-time. The minimum-norm control synthesized at each step minimizes the per-step contribution to the KL divergence between the safe and original distributions. Across all experiments, we observe 100% constraint satisfaction. Our framework applies to any pre-trained flow-based sampling scheme requiring no retraining or architectural modifications. We validate the approach across constrained image generation, physically-consistent trajectory sampling, and safe robotic manipulation policies, achieving 100% constraint satisfaction while preserving semantic fidelity.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。