Skip to content

[SC-19615] Draft with AI: select model documents as drafting context - #1601

Open
juanmleng wants to merge 1 commit into
mainfrom
juan/sc-19615/draft-with-ai-select-model-documents-as-drafting-context
Open

juanmleng wants to merge 1 commit into
mainfrom
juan/sc-19615/draft-with-ai-select-model-documents-as-drafting-context

Conversation

@juanmleng

Copy link
Copy Markdown
Contributor

Pull Request Description

What and why?

Draft Document and Draft Section can now take other documents of the same record as context, next to attached files. Also, a draft now reads only the files and documents you add as context. Before, it could read any file attached to the record. The guide and the FAQ said the agent reads every attached file, so they now describe the new behaviour.

The "Add files as context" section becomes "Add files and documents as context" and keeps its anchor, so existing links still work. It covers the Add Documents to Context option and its limit of 10 documents, the dialog opening with the last draft's selection, how the agent reads a document's sections and cites them under Sources, and which documents can't be added. The evidence-tracking section says that any edit to a context document marks the blocks that used it as out of date, and that Regenerate Stale Sections reuses each section's last selection.

How to test

skills/validmind-docs-coverage/scripts/render-pages.sh guide/documentation/draft-documents-with-ai.qmd faq/faq-documentation.qmd

Expected: both pages render. The only warnings are the existing ones about unresolved library API reference links. Preview links to the changed sections will be added once the PR is ready for review and validate passes.

What needs special review?

  • The new rule that a draft with nothing added reads no attached files. Please check that this wording fits the rest of the page.

Dependencies, breaking changes, and deployment notes

Documents ValidMind/backend#4010 and ValidMind/frontend#3172. Merge after both have shipped.

Release notes

You can now add other documents of the same record as context when drafting with AI. The agent reads the sections it needs and cites them as sources. A draft now reads only the files and documents you add as context. Learn more ...

Checklist

  • What and why
  • Screenshots or videos (Frontend)
  • How to test
  • What needs special review
  • Dependencies, breaking changes, and deployment notes
  • Labels applied
  • PR linked to Shortcut
  • Unit tests added (Backend)
  • Tested locally
  • Documentation updated (if required)
  • Environment variable additions/changes documented (if required)

🤖 Generated with Claude Code

A draft now reads only the files and documents added as context, and
documents of the same record can be added alongside files. Correct the
pages that said the agent reads every attached file, and describe the
documents picker, its limit, the prefilled selection, and how a context
document flags drafted blocks.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@juanmleng juanmleng added documentation Improvements or additions to documentation enhancement New feature or request labels Nov 10, 2026
@juanmleng
juanmleng marked this pull request as ready for review November 11, 2026 10:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant