Tool details
| Field | Value |
|---|---|
| Name | search_files |
| Group | Search |
Playground
Input schema
Input schema
{
"type": "object",
"properties": {
"project_reference": {
"type": "string",
"description": "Project ID or slug whose indexed file chunks can be searched."
},
"query_vector": {
"type": "array",
"items": {
"type": "number",
"description": "One query vector item supplied to the tool."
},
"description": "Embedding vector for the search query, generated with a compatible embedding model."
},
"dimension": {
"type": "string",
"enum": [
"768",
"1024",
"1536",
"3072",
"4096"
],
"description": "Embedding dimension that matches the supplied query vector."
},
"branch_id": {
"anyOf": [
{
"type": "string",
"format": "uuid",
"description": "Branch identifier. Use null for the main branch when the tool supports it."
},
{
"type": "null",
"description": "Branch identifier. Use null for the main branch when the tool supports it."
}
],
"description": "Preview branch ID to search. Use null for the main branch."
},
"release_id": {
"type": "string",
"format": "uuid",
"description": "Release ID to search instead of the current branch or mainline index."
},
"release_version": {
"type": "string",
"description": "Release version to search when you do not have the release ID."
},
"limit": {
"type": "number",
"minimum": 1,
"maximum": 100,
"description": "Maximum number of ranked chunk matches to return. Defaults to 50."
},
"cursor": {
"type": "string",
"description": "Opaque pagination cursor from a previous search_files response."
},
"similarity_threshold": {
"type": "number",
"minimum": 0,
"maximum": 1,
"description": "Minimum similarity score required for a chunk to be returned. Defaults to 0.7."
}
},
"required": [
"project_reference",
"query_vector",
"dimension"
],
"additionalProperties": false,
"description": "Input schema for semantic file search over indexed project chunks.",
"$schema": "http://json-schema.org/draft-07/schema#"
}
Output schema
Output schema
{
"type": "object",
"properties": {
"data": {
"type": "array",
"items": {
"type": "object",
"properties": {
"chunk": {
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Indexed chunk identifier."
},
"file_path": {
"type": "string",
"description": "Project-relative file path that produced this chunk."
},
"file_id": {
"type": "string",
"description": "File identifier when the source file is tracked as a project file."
},
"file_version_id": {
"type": "string",
"description": "File version identifier used to generate this chunk."
},
"index": {
"type": "number",
"description": "Zero-based chunk position within the file version."
},
"content": {
"type": "string",
"description": "Chunk text content used for retrieval and inspection."
},
"start_offset": {
"type": "number",
"description": "Inclusive character offset where the chunk begins in the source file."
},
"end_offset": {
"type": "number",
"description": "Exclusive character offset where the chunk ends in the source file."
},
"token_count": {
"type": "number",
"description": "Approximate token count for the chunk content."
},
"embedding": {
"anyOf": [
{
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Embedding record identifier for this indexed chunk."
},
"model": {
"type": "string",
"description": "Embedding model name used to create the vector."
},
"status": {
"type": "string",
"enum": [
"ready",
"stale",
"missing"
],
"description": "Embedding availability status for the chunk."
}
},
"required": [
"id",
"model",
"status"
],
"additionalProperties": false,
"description": "Embedding metadata attached to an indexed file chunk."
},
{
"type": "null",
"description": "The embedding returned by the tool."
}
],
"description": "Embedding metadata for the chunk, or null when no embedding is stored."
}
},
"required": [
"id",
"file_path",
"file_version_id",
"index",
"content",
"start_offset",
"end_offset",
"token_count",
"embedding"
],
"additionalProperties": false,
"description": "Matched file chunk with the most useful retrieval fields for ranking and display."
},
"score": {
"type": "number",
"description": "Similarity score between the query vector and the returned chunk."
}
},
"required": [
"chunk",
"score"
],
"additionalProperties": false,
"description": "One ranked chunk match returned by semantic file search."
},
"description": "Ranked semantic matches for the supplied query vector."
},
"page_info": {
"type": "object",
"properties": {
"self": {
"type": [
"string",
"null"
],
"description": "Cursor representing this result page."
},
"first": {
"type": "object",
"description": "Always null because semantic search pagination is forward-only."
},
"next": {
"type": [
"string",
"null"
],
"description": "Cursor for the next page of ranked matches, or null when exhausted."
},
"prev": {
"type": [
"string",
"null"
],
"description": "Cursor for the previous page when supported by the backend, otherwise null."
}
},
"required": [
"self",
"first",
"next",
"prev"
],
"additionalProperties": false,
"description": "Pagination cursors for traversing semantic search results."
},
"total_matches": {
"type": "number",
"description": "Total number of chunk matches that met the similarity threshold."
},
"search_time_ms": {
"type": "number",
"description": "Server-side search execution time in milliseconds."
}
},
"required": [
"data",
"page_info",
"total_matches",
"search_time_ms"
],
"additionalProperties": false,
"description": "Semantic file search results ranked by vector similarity.",
"$schema": "http://json-schema.org/draft-07/schema#"
}