optimization-cache

Manage cached optimization results from previous runs. This command allows you to list, view, delete, export, and import optimization results, as well as set default configurations for model/task combinations.

Basic Usage
python -m wisent optimization-cache [list|show|delete|clear|set-default|get-default|export|import] [OPTIONS]

Examples

List All Cached Results
python -m wisent optimization-cache list
List by Model
python -m wisent optimization-cache list --model meta-llama/Llama-3.1-8B-Instruct
Show Cached Result
python -m wisent optimization-cache show meta-llama/Llama-3.1-8B-Instruct refusal
Set Default Configuration
python -m wisent optimization-cache set-default meta-llama/Llama-3.1-8B-Instruct refusal --method CAA
Export Cache
python -m wisent optimization-cache export ./optimization_cache_backup.json
Import Cache
python -m wisent optimization-cache import ./optimization_cache_backup.json --merge
Clear All Cache
python -m wisent optimization-cache clear --confirm

Subcommands

SubcommandDescription
listList cached optimization results (optionally filter by --model or --task)
showShow details of a cached result (requires model and task positional args)
deleteDelete a specific cached result (requires model and task positional args)
clearClear all cached results (requires --confirm flag)
set-defaultSet a cached result as default for a model/task
get-defaultGet the default optimization result for a model/task
exportExport cache to a JSON file
importImport cache from a JSON file (use --merge to combine with existing)

Common Options

OptionDefaultDescription
--model-Filter by model name (for list) or model name (for show/delete)
--task-Filter by task name (for list)
--methodCAASteering method (for show/delete/set-default)
--confirmfalseConfirm clearing all cached results (for clear)
--mergefalseMerge with existing cache instead of replacing (for import)

Related Commands

Stay in the loop. Never miss out.

Subscribe to our newsletter and unlock Wisent insights.