Format condensed entries as human-readable text. Output format: ```text [User] Fix the auth bug in login.rs [Assistant] I'll fix the token validation... [Tool] Edit: src/auth/login.rs [Tool] Bash: cargo test [Assistant] The fix is applied and tests pass. [Files Modified] - src/auth/login.rs ``` This is the format passed to the reasoning generator and stored in `UnhashedTurnData.condensed_text`.
(entries: &[CondensedEntry], files: &[String])
| 104 | /// This is the format passed to the reasoning generator and stored in |
| 105 | /// `UnhashedTurnData.condensed_text`. |
| 106 | pub fn format_condensed(entries: &[CondensedEntry], files: &[String]) -> String { |
| 107 | let mut out = String::new(); |
| 108 | |
| 109 | for (i, entry) in entries.iter().enumerate() { |
| 110 | if i > 0 { |
| 111 | out.push('\n'); |
| 112 | } |
| 113 | out.push_str(&entry.to_string()); |
| 114 | out.push('\n'); |
| 115 | } |
| 116 | |
| 117 | if !files.is_empty() { |
| 118 | out.push_str("\n[Files Modified]\n"); |
| 119 | for file in files { |
| 120 | out.push_str("- "); |
| 121 | out.push_str(file); |
| 122 | out.push('\n'); |
| 123 | } |
| 124 | } |
| 125 | |
| 126 | out |
| 127 | } |
| 128 | |
| 129 | /// Extract user prompts from condensed entries. |
| 130 | pub fn extract_prompts(entries: &[CondensedEntry]) -> Vec<String> { |