Skip to content

feat(cli): run review/scan without an API key (select_judge; deterministic-only mode with notice) #646

Closed

Description

@ajianaz

From the architecture audit. Part 5 of 6. Depends on 2/6.

Problem

LLM configuration is a precondition of every command: build_llm_config returns NoApiKey (config/loader.rs:~368) and is called from main.rs (commit, review before the diff is read, scan) and mcp/tools.rs. With no key, cora review/cora scan fail with "no API key found" even though the deterministic half needs no LLM (the LLM-failure fallback in engine/review.rs is never reached).

Proposal

One select_judge(config, flags) at the entry point: HttpLlm when a key/provider resolves, otherwise None. Add explicit --no-llm. With no key, run deterministic only and print a clear one-line notice ("no LLM configured: deterministic checks only; run cora auth login to enable AI review"). Output (pretty/json/SARIF) and summary must say deterministic only, so an empty result is never read as "reviewed and clean". Exit-code semantics unchanged.

Done when

  • cora review/cora scan with no key and no config exit normally with deterministic results and the notice.
  • --no-llm forces it even when a key exists.
  • Tests cover key / no key / flag.

Activity

  1. added
    enhancement
    scope:cli
    on Oct 15, 2026
  2. ajianaz commented on Oct 15, 2026

    @ajianaz
    CollaboratorAuthor

    Series map (sequential, one PR each): 1/6 finalize #648 → 2/6 prepare/judge/finalize #649 → 3/6 untrusted judge output + cache #644 → 4/6 scan deterministic family #645 (can parallel 3/6) → 5/6 select_judge #646 → 6/6 MCP agent tools + skill #647.

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

    enhancementscope:cli

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions