pub trait OutcomeTracker: Send + Sync {
// Required methods
fn build_outcome(
&self,
task_id: &str,
task_name: &str,
response_text: &str,
tool_rounds: u32,
input_tokens: u32,
output_tokens: u32,
) -> OutcomeRecord;
fn record_outcome(
&self,
docs_dir: &Path,
outcome: OutcomeRecord,
max_outcomes: usize,
) -> Result<(), Box<dyn Error>>;
}Expand description
Task execution outcome recording.
Implemented by pulse-echo. Used by pulse-null core for:
- Post-execution hooks (build and record outcomes after tasks/intents)
Required Methods§
Sourcefn build_outcome(
&self,
task_id: &str,
task_name: &str,
response_text: &str,
tool_rounds: u32,
input_tokens: u32,
output_tokens: u32,
) -> OutcomeRecord
fn build_outcome( &self, task_id: &str, task_name: &str, response_text: &str, tool_rounds: u32, input_tokens: u32, output_tokens: u32, ) -> OutcomeRecord
Build an outcome record from task execution results.
Sourcefn record_outcome(
&self,
docs_dir: &Path,
outcome: OutcomeRecord,
max_outcomes: usize,
) -> Result<(), Box<dyn Error>>
fn record_outcome( &self, docs_dir: &Path, outcome: OutcomeRecord, max_outcomes: usize, ) -> Result<(), Box<dyn Error>>
Record an outcome to persistent storage.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".