find_files_by_chunk_content
Locate files in a project containing specific text chunks within logical code segments. Use this tool to streamline codebase searches and identify relevant files for detailed analysis.
Instructions
Step 1: Find files containing chunks with matching text.
Returns file tree only showing which files contain matches.
You must use find_matching_chunks_in_file on each relevant file
to see the actual matches.
Example workflow:
1. Find files:
files = find_files_by_chunk_content(project, ["MyClass"])
2. For each file, find actual matches:
matches = find_matching_chunks_in_file(file, ["MyClass"])
3. Get content:
content = chunk_details(file, match_id)
Input Schema
Name | Required | Description | Default |
---|---|---|---|
chunk_contents_filter | Yes | Match if any of these strings appear. Match all if None/null. Single empty string or empty list will match all. | |
project_name | Yes |
Input Schema (JSON Schema)
{
"properties": {
"chunk_contents_filter": {
"anyOf": [
{
"type": "string"
},
{
"items": {
"type": "string"
},
"type": "array"
},
{
"type": "null"
}
],
"description": "Match if any of these strings appear. Match all if None/null. Single empty string or empty list will match all.",
"title": "Chunk Contents Filter"
},
"project_name": {
"title": "Project Name",
"type": "string"
}
},
"required": [
"project_name",
"chunk_contents_filter"
],
"title": "find_files_by_chunk_contentArguments",
"type": "object"
}