1// To discuss: What to send to the new endpoint? Thinking it'd make sense to put `prompt.rs` from
2// `zeta_context.rs` in cloud.
3//
4// * Run excerpt selection at several different sizes, send the largest size with offsets within for
5// the smaller sizes.
6//
7// * Longer event history.
8//
9// * Many more snippets than could fit in model context - allows ranking experimentation.
10
11pub struct Zeta2Request {
12 pub event_history: Vec<Event>,
13 pub excerpt: String,
14 pub excerpt_subsets: Vec<Zeta2ExcerptSubset>,
15 /// Within `excerpt`
16 pub cursor_position: usize,
17 pub signatures: Vec<String>,
18 pub retrieved_declarations: Vec<ReferencedDeclaration>,
19}
20
21pub struct Zeta2ExcerptSubset {
22 /// Within `excerpt` text.
23 pub excerpt_range: Range<usize>,
24 /// Within `signatures`.
25 pub parent_signatures: Vec<usize>,
26}
27
28pub struct ReferencedDeclaration {
29 pub text: Arc<str>,
30 /// Range within `text`
31 pub signature_range: Range<usize>,
32 /// Indices within `signatures`.
33 pub parent_signatures: Vec<usize>,
34 // A bunch of score metrics
35}