Skip to content

Command reference

For an existing WSL deployment, these scripts live in /opt/devsecops-ai/scripts. Run cd /opt/devsecops-ai before the relative commands below. Read the complete CLI walkthrough for examples, model routing, and execution behavior.

Entry pointShellPurpose / scope
scripts/ask.shWSL BashInteractive API query; reads environment file and saves thread state
scripts/devai.shWSL BashDevelopment CLI, including memory/ingestion modes
scripts/plan_exec.shWSL BashPlanning/execution workflow; choose mode deliberately
scripts/wsl-manage.ps1Windows PowerShellControl an existing WSL installation
scripts/validate-router.shWSL BashRegistry, syntax, and routing checks; requires local dependencies
scripts/validate-catalogs.pyProject PythonPrompt/playbook catalog validation
scripts/backup.shWSL BashPartial backup; see coverage limitations
scripts/deploy-to-wsl.shWSL BashState-changing deployment; known revision/rollback limitations
SettingScriptMeaning / default
DEVAI_API_URLAll threeBackend URL; http://localhost:8000
MODEL_SELECTIONask.shExplicit model request; empty means automatic
TASK_TYPEask.shOptional task hint
DEPLOY_PATHask.shLooks for .env here first; /opt/devsecops-ai
DEVAI_MODELdevai.shExplicit model request; empty means automatic
DEVAI_TASK_TYPEdevai.shOptional task hint
DEVAI_API_KEYdevai.sh, plan_exec.shOptional key override, otherwise read the script’s project-root .env
DEVAI_PYTHONdevai.shMemory helper interpreter; project .venv/bin/python
PLAN_MODELplan_exec.shPlanner model; qwen3.5:2b
EXEC_MODELplan_exec.shImplementation model; qwen2.5-coder:3b
PLAN_STYLEplan_exec.shschema by default; also draft or twopass
SCHEMA_FILEplan_exec.shProject scripts/handoff-schema.yaml
TMP_DIRdevai.sh, plan_exec.shGenerated code/plan location; /tmp/devai
LOG_FILEdevai.sh, plan_exec.shProject logs/devai_history.log or logs/plan_exec_history.log

ask.sh reads the deployment .env, then falls back to its own project-root .env; an exported API_KEY alone does not override that code path. The other two helpers use DEVAI_API_KEY first. All have an insecure default-key fallback, which should not be relied upon. Keep credentials out of command examples and shell history.

StateLocation / behavior
ask.sh thread pointer/tmp/devsecops_conversation_${USER}.txt
devai.sh thread pointer/tmp/devai_conversation_${USER}.txt; --clear removes this pointer only
Planner output/tmp/devai/current_plan.txt; overwritten by a new plan
Generated codegen_* or exec_* files under TMP_DIR
Knowledge memoryProject vector-store, shared with backend RAG when roots match

plan_exec.sh does not persist a conversation ID in the way the other helpers do. It passes plan text between phases rather than isolating the YAML handoff field. If the plan exceeds 6,000 shell-counted characters, the implementation sends its first 6,000 bytes with a truncation notice; the complete plan remains on disk. Review whether important requirements were cut off, particularly with non-ASCII text. The complete request must still fit the API’s 20,000-character limit.

Put flags before the task: bash scripts/plan_exec.sh --plan-only "task", not after it. The same applies to devai.sh --execute. Neither helper currently implements a general --model flag; use the variables above. ask.sh reads the question interactively.

Terminal window
npm run docs:check
npm run build
npm run docs:links
npm run preview

The source check validates navigation, redirects, and page metadata. The built-link check inspects generated HTML and fragment targets. Neither command runs the backend or deploys the site.

Next: Use the CLI or contribute documentation.