Skip to content

EPIC — Query insight for operators and agents #290

Done

Description

@jmmana

Objective

Tell operators and models more than allow or deny: how wasteful a legitimate query is, what the database plans to do with it, what a policy change would change, which kinds of personal data a query returns, and exactly what the guard did to a result.

Principles

Where we start (main @ 74c7b88)

Area Already on main Gap this epic closes
Query quality Opt-in complexity limits refuse (max_joins, max_subquery_depth, forbid_cartesian), required_filters No signal for allowed but wasteful queries
Plan checks Cost guard in sqlguardllm mcp for PostgreSQL and MySQL (#33) Library API, SQL Server, DuckDB, SQLite, full scans, warn mode
Policy changes sqlguardllm shadow counts (#222), test (#66), lint (#67) Per-case diff and a CI gate
Personal data Hidden and masked columns enforced through aliases, functions, casts and subqueries Classification by data class, classify
MCP results readOnlyHint and the other annotations, limit_reached, fix hints (#217) Rewrite and truncation fields, output schemas, proxy annotations

Children

No child blocks another. #295 and #293 show the #291 score when it is enabled, and #295 shows #292 warnings. Recommended order: #291 → #295 → #294 → #293 → #292.

Bugs found while planning (fix first, size S)

Activity

  1. added
    type:epic
    p1
    on Dec 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    p1type:epic

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions