Skip to main content
Glama
Arun-kc

schemabrain

suggest_joins

Read-onlyIdempotent

Find join paths between known tables by providing qualified names. Returns shortest foreign key path per pair with columns ready for SQL JOIN, or identifies unreachable pairs.

Instructions

Use this when you already know two or more tables and need the join paths between them. Pass qualified names (schema.table) and get one shortest FK path per pair, with columns on each side ready for a SQL JOIN. Multi-hop paths via intermediates are returned; pairs with no path within max_hops (default 6) land in unreachable_pairs. Use find_relevant_tables instead when you don't yet know the table names. Common composition: chain find_relevant_tables to suggest_joins.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tablesYesList of `schema.table` qualified names (minimum 2) to find join paths between. The tool returns one shortest FK path per unordered pair, plus an `unreachable_pairs` list for pairs with no path within `max_hops`.
max_hopsNoMaximum number of FK-graph hops to traverse when searching for join paths. Default 6 — covers M:N junction-table chains common in normalised OLTP schemas. Increase only for unusually deep schemas; higher values make the search non-trivially slower.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
statusYes
dataNo
errorNo
confidenceNo
provenanceNo
follow_up_hintsNo
degradation_reasonNo
charter_versionNo1.2
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Discloses behavior beyond annotations: returns shortest FK path, multi-hop paths, unreachable pairs, and performance notes on `max_hops`. No contradiction with annotations (all safe, idempotent).

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Concise, front-loaded with usage context, then details. Every sentence adds value with no redundancy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity, annotations, and schema, the description is complete. It covers input, output, behavior, and edge cases (unreachable pairs, depth limits).

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, but the description adds context: qualified name requirement, one shortest path per unordered pair, unreachable pairs list, and semantics of `max_hops` including default and performance considerations.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States the specific action: finding join paths between known tables using qualified names. Explicitly distinguishes from the sibling tool `find_relevant_tables`.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Clearly states when to use (when tables are known) and when not to (use `find_relevant_tables` instead). Also describes common composition with `find_relevant_tables`.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other 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/Arun-kc/schemabrain'

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