zeta2: Update prompts to match training more closely (#40383)

Release Notes:

- N/A
This commit is contained in:
Agus Zubiaga
2025-10-16 14:13:19 +00:00
committed by GitHub
parent ae25baad02
commit fba7f4d8cc
6 changed files with 116 additions and 52 deletions
+4 -1
View File
@@ -94,6 +94,8 @@ struct Zeta2Args {
file_indexing_parallelism: usize,
#[arg(long, default_value_t = false)]
disable_imports_gathering: bool,
#[arg(long, default_value_t = false)]
disable_reference_retrieval: bool,
}
#[derive(clap::ValueEnum, Default, Debug, Clone)]
@@ -111,7 +113,7 @@ impl Into<predict_edits_v3::PromptFormat> for PromptFormat {
Self::MarkedExcerpt => predict_edits_v3::PromptFormat::MarkedExcerpt,
Self::LabeledSections => predict_edits_v3::PromptFormat::LabeledSections,
Self::OnlySnippets => predict_edits_v3::PromptFormat::OnlySnippets,
Self::NumberedLines => predict_edits_v3::PromptFormat::NumberedLines,
Self::NumberedLines => predict_edits_v3::PromptFormat::NumLinesUniDiff,
}
}
}
@@ -300,6 +302,7 @@ impl Zeta2Args {
fn to_options(&self, omit_excerpt_overlaps: bool) -> zeta2::ZetaOptions {
zeta2::ZetaOptions {
context: EditPredictionContextOptions {
use_references: !self.disable_reference_retrieval,
use_imports: !self.disable_imports_gathering,
excerpt: EditPredictionExcerptOptions {
max_bytes: self.max_excerpt_bytes,