Built-in Prompts

Built-in prompts

In addition to the 16 tools, the Single Origin MCP server ships with four pre-written prompts. They're invoked from your client's prompt palette (Claude Code: /<prompt-name>) and orchestrate the right sequence of tool calls for the most common workflows — so your agent doesn't have to figure them out from scratch.

list_recommendations

Surveys the workspace's current optimization opportunities, ranks them by projected impact, and produces a short summary your team can scan.

When to use: weekly optimization review, a kickoff "what should we work on this sprint?" conversation, or anyone asking "where are we wasting compute?"

Sample invocation

/list_recommendations

What the agent does

  1. Calls list_recommendations with status ACTIVE.
  2. Sorts by projected $/month savings.
  3. Returns the top 5–10 recommendations with one-line summaries and links to each recommendation_id for deeper review.

review_recommendation

Walks through a single recommendation end-to-end: target queries, projected savings, the SQL change it implies, and a recommendation about whether to accept, dismiss, or modify.

When to use: before clicking "implement" on a recommendation — get a structured second opinion that pulls together the underlying queries and DDL.

Sample invocation

/review_recommendation rec_01HXY

What the agent does

  1. Calls get_recommendation for the full payload.
  2. Calls get_recommendation_items to see per-query impact.
  3. For the top target queries, calls query_detail and query_profile_detail to confirm the recommendation's rationale matches the queries' actual hot spots.
  4. Summarizes the decision with caveats (e.g. "low impact for top query, high impact across the tail — consider implementing if maintenance cost is low").

similar_query_search

Starts from a single query and finds the cluster of structurally similar queries it belongs to, then summarizes the whole cluster.

When to use: an engineer flags one slow query — you want to know if it's a one-off or part of a pattern worth fixing once.

Sample invocation

/similar_query_search qry_8f3a

What the agent does

  1. Calls query_detail and query_fragments_for_query for the anchor query.
  2. Calls search_similar_queries to find the cluster.
  3. Calls similar_query_group_summary and list_similar_query_group_items to summarize.
  4. Returns the cluster's shape, size, total runtime, and whether an active recommendation already targets it.

parse_dag_task_from_signature

Maps a query signature back to the upstream artifact that produced it — the dbt model, Airflow task, or scheduled job. Use this when the query's user is a service account and you need to find a human owner.

When to use: a slow query is owned by airflow_service — you need to know which DAG/task to fix.

Sample invocation

/parse_dag_task_from_signature qry_8f3a

What the agent does

  1. Calls query_detail for the SQL and metadata.
  2. Inspects the query comment header / tags that Single Origin's ingestion preserves (e.g. -- airflow_dag: analytics_daily, task: orders_rollup).
  3. Returns the parsed dbt model / Airflow task / scheduled job that emitted the query.

Back to Overview.