Requires Go 1.25+ to build from source:
go install github.com/noeljackson/deepsec/cmd/deepsec@latestOr build locally:
git clone https://github.com/noeljackson/deepsec
cd deepsec
go build -o bin/deepsec ./cmd/deepsecPre-built binaries for linux/darwin/windows × amd64/arm64 ship per
release. There's also a Dockerfile (distroless, ~20 MB).
From inside the repo you want to scan:
deepsec init --project-id myproj --root .That writes deepsec.config.toml in the current directory.
deepsec scan --project-id myprojThe scanner walks the project root, runs the bundled regex matchers
gated on detected tech, and writes a FileRecord JSON per file under
data/myproj/files/....
Set the appropriate env var and run process:
export ANTHROPIC_API_KEY=sk-ant-...
deepsec process --project-id myproj --agent anthropic --concurrency 4Or use any of the other built-in providers:
export OPENAI_API_KEY=sk-... && deepsec process --project-id myproj --agent openai
export ZAI_API_KEY=... && deepsec process --project-id myproj --agent glm
export MOONSHOT_API_KEY=... && deepsec process --project-id myproj --agent kimi
export DEEPSEEK_API_KEY=... && deepsec process --project-id myproj --agent deepseekRun deepsec list-providers to see what's wired up.
Pass --max-cost-usd 5.00 to abort the run mid-flight when cumulative
spend exceeds the cap. Real cost is computed from a per-model pricing
table built into the provider profile, so the number is accurate (not a
token estimate).
deepsec report --project-id myproj # markdown + JSON + CSV
deepsec metrics --project-id myproj # cost / TP-FP rates
deepsec export --project-id myproj --format sarif --output deepsec.sarifdeepsec scan --project-id myproj --diff origin/main
deepsec process --project-id myproj --diff origin/main
deepsec pr-comment --project-id myproj --output pr-comment.md --skip-empty