Skip to content

Structured capacity/limit errors before the first model request #2125

Backlog

Description

@cc7gs

Problem Statement

When a change set exceeds a unit/byte capacity limit, or the change graph grows past its hard limits, OCR fails late with a timeout or an empty result. Callers cannot tell "too big" from "broken", cannot reject the run before it starts, and cannot give the author an actionable message. An empty or timed-out result also looks like success at a glance in automation.

Affected area: review input validation / preflight.

Proposed Solution

  • Return a structured error (for example OCR_CAPACITY_EXCEEDED) before the first model request, carrying requestedFiles, limitFiles, requestedBytes, limitBytes, and the stage that rejected the input.
  • Document the per-task change-graph unit/byte hard limits, and give each limit a stable error code so callers can pre-reject with specific diagnostics instead of parsing timeouts.

Alternatives Considered

Parsing timeouts and empty reports after the fact - ambiguous, and costly: an oversized run still burns its whole task window before failing, which is exactly the time a caller does not have.

Additional Context

Split from #2113 (its items on structured capacity errors and change-graph limits) so the grouping ask there can close with #2117. Related but orthogonal: #313 (degradation strategy for oversized single files) - that handles one huge file, this handles preflight rejection of an oversized change set.

Aggregated private-repo measurements only; no private code, repository names, or patches included.

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions