Class CodeReviewPipeline

java.lang.Object
com.tnsai.quality.security.harness.CodeReviewPipeline

public final class CodeReviewPipeline extends Object
Top-level orchestrator for the agent-driven code-review pipeline (TNS-291).

Holds the pipeline configuration — matchers, agents, state store, project root — and exposes one method per stage plus a run() convenience that runs them in order. Each stage() call is idempotent and safe to invoke multiple times.

Quick start


 CodeReviewPipeline pipeline = CodeReviewPipeline.builder()
     .projectRoot(Path.of("/work/myrepo"))
     .matcher(BuiltInMatchers.SQL_INJECTION)
     .matcher(BuiltInMatchers.PATH_TRAVERSAL)
     .agent(ReviewAgent.claudeOpus(llmClient))
     .stateStore(new FileSystemPipelineStateStore(Path.of(".tnsai/security")))
     .build();

 pipeline.scan();             // matchers fire → FileRecords
 pipeline.process();          // agent runs per file
 pipeline.export(ExportFormat.SARIF, Path.of("findings.sarif"));
 
Since:
0.10.0 (TNS-291)