引导式测验 · 中等 等级

约束解码测验

检查令牌级约束、增量解析、结构化输出限制以及有效格式和正确内容之间的区别。

相关引导路径受限解码
问题 1 的 8

约束解码在每个生成步骤中的作用是什么?

预览每个问题8 问题

当您参加测验时,就会出现答案和解释。

  1. 约束解码在每个生成步骤中的作用是什么?
    • 在采样之前屏蔽掉违反所需结构的标记
    • 在结构化示例上重新训练模型
    • 将温度降至零
    • 在提示中添加更多训练数据
  2. 如果请求的 JSON 模式使用结构化输出实现不支持的功能,会发生什么情况?
    • The model silently gains new training data
    • The request can be rejected with an error
    • All outputs become valid SQL
    • The schema is automatically converted to natural language
  3. 哪些技术挑战使得受限解码难以实施?
    • 如果没有它,模型根本无法输出文本
    • 需要100GB以上显存的GPU
    • 子词标记与语法符号没有完全对齐
    • 无法为 JSON 编写语法
  4. 以下哪一个是用于指定解码约束的真实格式?
    • 权重电子表格
    • GPU 温度列表
    • 随机种子值
    • JSON 模式或上下文无关语法
  5. 通常在管道中的哪个点应用约束掩码?
    • 到 logits,在 softmax/采样步骤之前
    • 在提示标记化之前
    • 文本已打印给用户后
    • 仅在模型训练期间
  6. 与简单地在提示中要求模型“输出有效的 JSON”相比,约束解码有什么优势?
    • 它用电量更少
    • 提供了硬保障而不是依赖模型的配合
    • 让模型更有创意
    • 它消除了对分词器的需要
  7. What does PICARD do with a candidate token that would make a partial SQL query unparsable?
    • Accepts it and repairs the query after generation
    • Retrains the language model immediately
    • Rejects that token during incremental parsing before it is emitted
    • Deletes the user’s database schema
  8. What does a schema-conforming output guarantee by itself?
    • Every value is true in the external world
    • The model used the right source documents
    • No refusal or incomplete response can occur
    • The output matches the supported structure, not that its values are factually correct