Skip to content

Document search exclusion settings for agent text search and grep#9905

Open
1chooo wants to merge 1 commit into
microsoft:mainfrom
1chooo:document-agent-search-exclusions
Open

Document search exclusion settings for agent text search and grep#9905
1chooo wants to merge 1 commit into
microsoft:mainfrom
1chooo:document-agent-search-exclusions

Conversation

@1chooo

@1chooo 1chooo commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Add guidance on how files.exclude, search.exclude, and .gitignore affect agent text search and grep
  • Explain that search match snippets consume agent context, not just opened files
  • Include example exclusion configs for Node.js, Python, and AI/data projects
  • Cross-link from optimize-usage and best-practices guides

Fixes #9898

Test plan

  • Verify links resolve correctly on the docs site
  • Review wording with docs team for accuracy of text search/grep exclusion behavior

Made with Cursor

Explain how files.exclude, search.exclude, and .gitignore improve agent
search relevance and reduce noisy context from search results.

Co-authored-by: Cursor <cursoragent@cursor.com>
@ntrogh ntrogh requested a review from mjbvz June 10, 2026 11:04
@ntrogh

ntrogh commented Jun 10, 2026

Copy link
Copy Markdown
Collaborator

@mjbvz Can you verify if these updates to workspace context are correct? Thanks!

@ntrogh ntrogh added the doc-enhancement suggested addition or improvement label Jun 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

doc-enhancement suggested addition or improvement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Recommend strict files.exclude and search.exclude to minimize noise in #textSearch results and reduce token consumption

2 participants