From sciris
Handles Sciris file I/O: save/load Python objects, JSON/YAML, archives with metadata, file utilities, and versioning/reproducibility checks.
How this skill is triggered — by the user, by Claude, or both
Slash command
/sciris:sciris-filesThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Reference for file I/O and version management. See full tutorial: `docs/tutorials/tut_files.ipynb`.
Reference for file I/O and version management. See full tutorial: docs/tutorials/tut_files.ipynb.
If you need more detail, use your MCP tools (Context7 or GitMCP) to look up current Sciris documentation, or consult the other Sciris skills.
sc.save('my-sim.obj', sim) # Gzipped pickle (works with any Python object)
sim = sc.load('my-sim.obj') # Load — methods and class still work
sc.zsave('fast.obj', sim) # Zstandard compression (slightly faster)
# sc.load() auto-detects compression format
sc.savejson('data.json', obj) # Saves JSONifiable parts of any object
data = sc.loadjson('data.json') # Returns dict (not original object)
data = sc.readjson(json_string) # Parse JSON from string
data = sc.readyaml(yaml_string) # Parse YAML (supports comments)
sc.saveyaml('config.yaml', data)
sc.getfilelist('*.ipynb') # List files matching pattern
sc.thispath() # Path of current file (use instead of pathlib.Path)
sc.makefilepath('data/out.csv', makedirs=True) # Ensure path exists
sc.rmpath('file_or_folder') # Remove file or folder (auto-detects)
md = sc.metadata() # Collect all environment metadata
sc.compareversions(np, '>1.0') # Version comparison (returns True/False)
sc.require('numpy>1.20') # Warn/raise if requirement not met
sc.savefig('fig.png', comments='My analysis') # Saves with metadata (use instead of plt.savefig)
md = sc.loadmetadata('fig.png') # Retrieve metadata later
sc.savearchive('sim.zip', sim, files='script.py', comments='Full run')
sim = sc.loadarchive('sim.zip') # Restore object
md = sc.loadmetadata('sim.zip') # Get metadata separately
npx claudepluginhub sciris/scirisProvides code patterns for basic Sciris features: array operations like findinds, date-formatted plotting, objdict containers, object save/load, and parallelization.
Looks up the public API of installed Python packages via introspection (inspect, pydoc, dir) and web search, caching results to avoid memory-based errors. Useful when writing code that depends on a library's exact API.
Provides a skill file (archive.md) that can be loaded into Claude Code to define archival instructions and context.