Clear working memory. Removes all items from working memory without affecting short-term or long-term memory.
(&self, py: Python<'_>)
| 3187 | /// |
| 3188 | /// Removes all items from working memory without affecting short-term or long-term memory. |
| 3189 | fn clear_working(&self, py: Python<'_>) -> PyResult<()> { |
| 3190 | let memory = self |
| 3191 | .inner |
| 3192 | .memory() |
| 3193 | .ok_or_else(|| PyRuntimeError::new_err("Memory not configured for this session"))? |
| 3194 | .clone(); |
| 3195 | py.allow_threads(move || get_runtime().block_on(memory.clear_working())); |
| 3196 | Ok(()) |
| 3197 | } |
| 3198 | |
| 3199 | /// Get current short-term memory items. |
| 3200 | /// |
nothing calls this directly
no test coverage detected