CLI Usage¶
Commands below are implemented in src/cspilot/cli.py. The installed script is
cspilot; cspiolt is also currently configured as a legacy alias.
General And Agent Commands¶
search¶
Purpose: answer a general natural-language question with the AGAPI-backed general agent.
Output files: search_result.json in the selected workdir.
Root quoted question fallback¶
Purpose: route a quoted unknown root command to search.
Output files: same as search.
agent¶
Purpose: run the direct AGAPI tool-using agent.
Options include --model, --base-url, and --agent-profile
chem|materials|general.
Output files: agent_result.json and any files generated by called tools.
plan¶
Purpose: create a strict JSON plan through AGAPI.
Output files: plan.json.
execute¶
Purpose: execute an existing JSON plan through the fixed registry.
Output files: execution_result.json and step_###_result.json.
run¶
Purpose: plan, execute, verify, and report.
Useful flags:
cspilot run "inspect tests/examples/input.xyz" --workdir runs/test --no-pretty
cspilot run "inspect tests/examples/input.xyz" --workdir runs/test --quiet
cspilot run "Find all Al2O3 materials" --workdir runs/al2o3 --profile materials --html
Output files: plan.json, execution_result.json,
verification_result.json, step_###_result.json, and final_report.md or
final_report.html.
graph-run¶
Purpose: run the LangGraph planner/executor/verifier/reporter loop.
Single mode:
cspilot graph-run "inspect tests/examples/input.xyz" \
--workdir runs/water --profile chem --agent-mode single
Multi mode with routing:
cspilot graph-run "Find all Al2O3 materials" \
--profile auto --agent-mode multi --html --workdir runs/al2o3
Useful flags: --agent-mode single|multi, --profile, --html,
--pretty/--no-pretty, --quiet, --max-retries.
Output files: plan.json, execution_result.json,
verification_result.json, final_state.json, final_report.md/html, and
route.json in multi mode.
docs-check¶
Purpose: run lightweight documentation consistency checks.
Output files: none; exits nonzero when checks fail.
Deterministic Calculation Commands¶
inspect¶
Purpose: inspect an XYZ with ASE.
Output files: timestamped run directory with copied input and result.json.
xtb-opt¶
Purpose: run xTB geometry optimization.
Output files: result.json, copied input, and xTB outputs such as
xtbopt.xyz and xtbopt.log when xTB succeeds.
orca-sp¶
Purpose: run ORCA calculations.
Output files: result.json, ORCA input/output files such as job.inp and
job.out when ORCA runs.
mace-opt¶
Purpose: run MACE geometry optimization.
Output files: result.json, and on success MACE optimized geometry,
trajectory, and log files.
stk Commands¶
Top-level shortcuts¶
cspilot stk-build-smiles "c1ccccc1" --workdir runs/stk_benzene
cspilot stk-polymer "BrCCBr" --repeating-unit A --num-repeating-units 4 --workdir runs/stk_polymer
cspilot stk-xtb "c1ccccc1" --workdir runs/stk_xtb --charge 0 --uhf 0
Output files: JSON results, molecule files such as .mol/.xyz, and for
stk-xtb a workflow_result.json plus xTB outputs when xTB runs.
stk building-block-smiles¶
Purpose: build an stk building block from SMILES.
stk building-block-file¶
Purpose: load an stk building block from a file and optionally export it.
stk linear-polymer¶
Purpose: construct a linear polymer.
stk replace-smiles¶
Purpose: edit a molecule with RDKit substructure replacement.
stk export-xyz¶
Purpose: export molecule files to XYZ using stk/RDKit fallback.
NWPESSe And GreenCatAI¶
nwpesse-search¶
Purpose: prepare and run a fragment-cluster global-minimum search.
Output files: mol.cluster, mol.inp, workflow_result.json, NWPESSe
stdout/stderr, candidate XYZ files, and lowest_energy.xyz when found.
greencatai design-mbh¶
cspilot greencatai design-mbh --output-dir runs/mbh_api \
--search-space configs/search_space.json --scoring configs/scoring.json
Purpose: call the installed GreenCatAI MBH catalyst-design API.
Output files: GreenCatAI artifacts in the selected output directory and a JSON tool result.
Fixed Workflows¶
cspilot workflow xtb-orca-sp tests/examples/input.xyz --charge 0 --mult 1
cspilot workflow xtb-orca-freq tests/examples/input.xyz --charge 0 --mult 1
cspilot workflow mace-orca tests/examples/input.xyz --model /path/to/model.model
Output files: timestamped workflow directory with workflow_result.json and
step subdirectories.