Skip to main content
Glama

search_tiles

Search for research content within hierarchical tile structures to find specific questions, hypotheses, methods, or results across interconnected nodes.

Instructions

Search for tiles by content

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesSearch query
treeIdNoOptional tree ID to filter by

Implementation Reference

  • Core implementation of the search_tiles tool logic: filters tiles matching the query in title, description, or splitAttribute, optionally within a specific tree.
    search(query: string, treeId?: string): Tile[] { let tilesToSearch = Array.from(this.tiles.values()); if (treeId) { const tree = this.trees.get(treeId); if (!tree) { throw new Error(`Tree ${treeId} not found`); } tilesToSearch = this.getTilesInTree(tree.rootTileId); } const lowerQuery = query.toLowerCase(); return tilesToSearch.filter( (tile) => tile.title.toLowerCase().includes(lowerQuery) || tile.description.toLowerCase().includes(lowerQuery) || tile.splitAttribute?.toLowerCase().includes(lowerQuery) ); }
  • MCP server handler for search_tiles tool: calls ResearchTreeManager.search and returns JSON result.
    case "search_tiles": { const result = treeManager.search( args.query as string, args.treeId as string | undefined ); return { content: [ { type: "text", text: JSON.stringify(result, null, 2), }, ], }; }
  • Input schema definition for search_tiles tool, registered in TOOLS array for ListTools requests.
    { name: "search_tiles", description: "Search for tiles by content", inputSchema: { type: "object", properties: { query: { type: "string", description: "Search query", }, treeId: { type: "string", description: "Optional tree ID to filter by", }, }, required: ["query"], }, },
  • src/index.ts:393-395 (registration)
    Registers all tools including search_tiles for listing via ListToolsRequestSchema.
    server.setRequestHandler(ListToolsRequestSchema, async () => ({ tools: TOOLS, }));

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/k-chrispens/tiling-trees-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server