Add content_type to DocumentationDocument for site search parity#3313
Conversation
Persist content_type alongside type so indexed _source matches website-ai-search and supports wider site search filtering (JSON can carry a distinct classification when needed). Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com> Co-authored-by: Cursor <cursoragent@cursor.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughThis PR adds a 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches✨ Simplify code
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Where would the ContentType value come from? I understand this is to leave the |
Fixes IDE0370 from dotnet format --verify-no-changes in CI lint. Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com> Co-authored-by: Cursor <cursoragent@cursor.com>
Why
Site-wide search combines documentation with other surfaces that classify documents in
_sourcedifferently than our plaintypefield alone. We need a persisted keyword that can diverge fromtypewhen JSON carries an explicit classification, while staying aligned with website-ai-search so a future sharedDocumentationDocumentcan round-trip the same shape. The intentional duplication supports wider site search filtering across those indices and clients.What
content_typeonDocumentationDocumentwith the same JSON-first normalization pattern used on the site side (stored value omitted when it matchestypefor stable round-trips).typeandcontent_typecoexist (polymorphic$type/ JSON-ignored CLR type on the other repo; persisted filter viacontent_type).Made with Cursor