persistence

This commit is contained in:
2026-04-05 05:14:20 +09:00
parent 2d7e6bd5d6
commit 00e3ae1932
15 changed files with 1450 additions and 1 deletions
+1 -1
View File
@@ -501,7 +501,7 @@ impl ToolDefinition {
// ============================================================================
/// Request configuration
#[derive(Debug, Clone, Default)]
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
pub struct RequestConfig {
/// Maximum tokens to generate
pub max_tokens: Option<u32>,
+10
View File
@@ -1308,6 +1308,16 @@ impl<C: LlmClient> Worker<C, Mutable> {
self.history.clear();
}
/// Set the turn count (for session restoration)
pub fn set_turn_count(&mut self, count: usize) {
self.turn_count = count;
}
/// Set the last_run_interrupted flag (for session restoration)
pub fn set_last_run_interrupted(&mut self, interrupted: bool) {
self.last_run_interrupted = interrupted;
}
/// Apply configuration (reserved for future extensions)
#[allow(dead_code)]
pub fn config(self, _config: WorkerConfig) -> Self {