跳到正文

在 Amazon Bedrock Guardrails 中编写拒绝主题的最佳实践

AWS Machine Learning Blog当事人· Jian Zhang·· 9 小时前精选Best practices for writing Denied Topics in Amazon Bedrock Guardrails
打开原文
原文
图片来自 AWS Machine Learning Blog
谁
AWS
引文
The rest of this post is a practical guide to avoiding these patterns.

发生了什么

AWS 作者介绍了在 Amazon Bedrock Guardrails 中编写拒绝主题的八项实践,并通过一个虚构的银行助手展示了宽泛的主题标签如何可能拦截合法请求。他们建议采用限定操作范围的名称和定义、提供多样的边界示例、谨慎管理重叠主题,并使用其他 Guardrails 策略来识别提示攻击或精确术语等信号。对于边界输入以及主题列表发生变化时,结果仍可能存在差异。

推荐理由

团队可以通过围绕用户操作定义拒绝主题、使用多样的边界示例以及管理重叠来减少误拦截和漏匹配;由于边界输入和主题列表变化时结果仍可能有所不同,重复测试依然十分重要。

接下来读什么

查看这件事的完整进展AWS Details Best Practices for Writing Denied Topics in Amazon Bedrock Guardrails

这件事到目前为止

AWS published a guide on the AWS Machine Learning Blog outlining eight best practices for writing Denied Topics in Amazon Bedrock Guardrails. Using a fictional bank assistant as an example, the authors showed how broad subject labels can inadvertently block legitimate user requests. To prevent over-blocking, the authors recommend using action-scoped topic names and definitions, providing varied boundary examples, and carefully managing overlapping topics. They also advise using other Guardrails policies to handle signals such as prompt attacks or exact terms, noting that results can still vary for borderline inputs and when the topic list changes.

这条收录于 11月17日 AI 日报看这一期日报的全部内容