MCPcopy Create free account
hub / github.com/AI45Lab/Code / remember_success

Method remember_success

sdk/python/src/lib.rs:3004–3020  ·  view source on GitHub ↗
(
        &self,
        py: Python<'_>,
        task: String,
        tools: Vec<String>,
        result: String,
    )

Source from the content-addressed store, hash-verified

3002 /// result: Summary of the result
3003 #[pyo3(signature = (task, tools, result))]
3004 fn remember_success(
3005 &self,
3006 py: Python<'_>,
3007 task: String,
3008 tools: Vec<String>,
3009 result: String,
3010 ) -> PyResult<()> {
3011 let memory = self
3012 .inner
3013 .memory()
3014 .ok_or_else(|| PyRuntimeError::new_err("Memory not configured for this session"))?
3015 .clone();
3016 py.allow_threads(move || {
3017 get_runtime().block_on(memory.remember_success(&task, &tools, &result))
3018 })
3019 .map_err(|e| PyRuntimeError::new_err(format!("Remember failed: {e}")))
3020 }
3021
3022 /// Remember a failed task execution.
3023 ///

Callers

nothing calls this directly

Calls 4

block_onMethod · 0.80
get_runtimeFunction · 0.70
cloneMethod · 0.45
memoryMethod · 0.45

Tested by

no test coverage detected