@@ -69,7 +69,23 @@ pub async fn review_diff_content_raw(
6969 config : config:: Config ,
7070 repo_path : & Path ,
7171) -> Result < ReviewResult > {
72- review_diff_content_raw_with_progress ( diff_content, config, repo_path, None ) . await
72+ review_diff_content_raw_internal ( diff_content, config, repo_path, None , None ) . await
73+ }
74+
75+ pub async fn review_diff_content_raw_with_verification_reuse (
76+ diff_content : & str ,
77+ config : config:: Config ,
78+ repo_path : & Path ,
79+ verification_reuse_cache : crate :: review:: verification:: VerificationReuseCache ,
80+ ) -> Result < ReviewResult > {
81+ review_diff_content_raw_internal (
82+ diff_content,
83+ config,
84+ repo_path,
85+ None ,
86+ Some ( verification_reuse_cache) ,
87+ )
88+ . await
7389}
7490
7591#[ tracing:: instrument( name = "review_pipeline" , skip( diff_content, config, repo_path, on_progress) , fields( diff_bytes = diff_content. len( ) , model = %config. model) ) ]
@@ -79,16 +95,53 @@ pub async fn review_diff_content_raw_with_progress(
7995 repo_path : & Path ,
8096 on_progress : Option < ProgressCallback > ,
8197) -> Result < ReviewResult > {
98+ review_diff_content_raw_internal ( diff_content, config, repo_path, on_progress, None ) . await
99+ }
100+
101+ pub async fn review_diff_content_raw_with_progress_and_verification_reuse (
102+ diff_content : & str ,
103+ config : config:: Config ,
104+ repo_path : & Path ,
105+ on_progress : Option < ProgressCallback > ,
106+ verification_reuse_cache : crate :: review:: verification:: VerificationReuseCache ,
107+ ) -> Result < ReviewResult > {
108+ review_diff_content_raw_internal (
109+ diff_content,
110+ config,
111+ repo_path,
112+ on_progress,
113+ Some ( verification_reuse_cache) ,
114+ )
115+ . await
116+ }
117+
118+ async fn review_diff_content_raw_internal (
119+ diff_content : & str ,
120+ config : config:: Config ,
121+ repo_path : & Path ,
122+ on_progress : Option < ProgressCallback > ,
123+ verification_reuse_cache : Option < crate :: review:: verification:: VerificationReuseCache > ,
124+ ) -> Result < ReviewResult > {
125+ let verification_reuse_cache = verification_reuse_cache. unwrap_or_default ( ) ;
126+
82127 if let Some ( result) = maybe_review_chunked_diff_content (
83128 diff_content,
84129 config. clone ( ) ,
85130 repo_path,
86131 on_progress. clone ( ) ,
132+ verification_reuse_cache. clone ( ) ,
87133 )
88134 . await ?
89135 {
90136 return Ok ( result) ;
91137 }
92138
93- orchestrate:: review_diff_content_raw_inner ( diff_content, config, repo_path, on_progress) . await
139+ orchestrate:: review_diff_content_raw_inner (
140+ diff_content,
141+ config,
142+ repo_path,
143+ on_progress,
144+ verification_reuse_cache,
145+ )
146+ . await
94147}
0 commit comments