Releases: cisco-ai-defense/ai-defense-cli
Releases · cisco-ai-defense/ai-defense-cli
Release list
v0.1.5
Added
ai-bomanalyzer passthroughs —analyze,report,watch,diff,
benchmark,kb,cache, andpluginare forwarded verbatim to the embedded
cisco-aibomanalyzer (DisableFlagParsing), so their flags and--helpare
the analyzer's own and never drift. The analyzer runs ascisco-aid-cli ai-bom <cmd>and its exit code is propagated.cisco-aid-clirenders only the
top-levelai-bomhelp, listing the full union of analyzer + cloud commands
(AIFW-27300).ai-bom analyzeinjects[default.aibom]LLM settings asAIBOM_LLM_*
for the analyzer when not already set in the environment;ai-bom report uploadderivesAIBOM_POST_URL(…/api/ai-defense/v1/aibom/analysis) and
AI_DEFENSE_API_KEYfrom resolved config when the user hasn't supplied them.ai-bom kbbuild commands (request/request-status/list-requests)
bridge the tenant key asCISCO_AI_DEFENSE_API_KEYfrom config when the user
hasn't supplied it; the kb API base and manifest URL stay native kb flags/env.
Changed
ai-bomcommand renames —generate→analyze, andsubmit/run→
report(report show/report upload), matching analyzer terminology. The
cloud commands (list,info,delete,components,summary) are
unchanged and still call the AI Defense API directly. Because passthrough
subcommands disable flag parsing, the global--api-key/--base-url/
--profileflags do not apply to them; use environment variables or config.[default.aibom]field help aligned to the analyzer's own--helpwording;
llm_modelis no longer wizard-required (it's command-specific —ai-bom analyzeenforces it at runtime), so non-AIBOM users are never prompted for it.
Removed
- Dead Go-SDK submit path —
api/aibomno longer exposesCreateAnalysis,
SubmitReportFile, orcreateAnalysisRequestFromReport; AIBOM uploads now go
through the analyzer'sreport upload. Cloud-management methods are unchanged.
v0.1.4
Added
internal/cliexitdoc+make gen-exit-docs— machine-readable exit-code
scenario registry; generatesdocs/exit-codes-handbook.md(see ADR 0001).docs/exit-codes-handbook.md— per-command exit codes and error scenarios
(client/operator handbook); linked from service spec and getting-started guide.- Exit contract tests —
internal/cli/exit_contract_test.goasserts CLI exit
codes against the registry formodel-scan,config validate,mcp-scan, and
ai-bom. - CI —
make check-exit-docsin the test job so the handbook cannot drift
frominternal/cliexitdoc/registry.go.
Changed
- Binary renamed —
aid-cisco-cli→cisco-aid-cli(command name, release
artifactscisco-aid-cli-<version>-<os>-<arch>, install path). Update scripts and
CI invocations; see §7.1.
cisco-aid-cli install --versionstill downloads releases published as
aid-cisco-cli-*(through v0.1.3). model-scan run— removed; exits with usage error (2) directing users to
model-scan trigger(Pythonaidclimigration). Unknownmodel-scan
subcommands continue to exit 2. Baremodel-scan(no subcommand) still shows
help and exits 0.- Onboard/config wizard — esc goes back one step during setup: between core fields, between optional capabilities (AIBOM → HuggingFace → base URL), from custom URL to the region preset list, and from the first core field back to the profile picker. Rewinding clears later capability answers so they are re-prompted. Ctrl+C still cancels the wizard during esc-back prompts (exit 1,
Cancelled.).
v0.1.3
Added
aid-cisco-cli install— download and verify release binaries from GitHub
Releases (--version,--check,--prefix).aid-cisco-cli onboardandaid-cisco-cli config— interactive TUI wizard
(Charmhuh) for core credentials plus optional capability modules (private
HuggingFace repos, local AIBOM LLM settings).- Onboarding draft saves — config written after each field;
[onboard].step
tracks progress for resume. config show— TUI section browser on a terminal;--plainfor redacted TOML.config edit— section menu to change core API or capabilities (configure / remove).- Home config directory —
~/.ai-defense/config.toml(like~/.aws); wizard always writes here unlessAI_DEFENSE_CONFIG_PATHis set. Legacy XDG and project.config.tomlpaths still read for migration. - Config profiles — named profiles in
~/.ai-defense/profiles/<name>.toml;config profilecommands and global--profile/AI_DEFENSE_PROFILE; onboard opens a profile picker (active profile pre-selected) unless--profileis set. - AIBOM LLM from TOML —
[default.aibom]fields resolve after flags and env vars. - Spec-driven integrations —
internal/config/spec/config.spec.yaml(embedded schema;
user config remainsconfig.toml) declares env/TOML/wizard fields; capabilities, CLI
flags, redaction, and resolution share the same schema. - CI enforces minimum Go test coverage (
make test-cover-check, default floor 75%).
scripts/check-coverage.shandmake test-coverfor local runs. Tooling under
scripts/,main.go, and TUI/onboarding packages (install,onboard,config,
internal/tui,internal/selfupdate,internal/config/spec) are excluded from
the gate until they have unit tests. Command-layer HTTP tests use
internal/testutil/apitest(httptest +*.cisco.combase URL rewrite). - PR CI enforces diff coverage on changed production Go lines (
make test-diff-cover-check,
default floor 75% vs merge base). Overall repo coverage gate unchanged; diff gate skips when
no coverable production lines changed in scoped packages.
Changed
- CLI
--help/usage now renders as titled panels with a color scheme matching
the embedded AI BOM (cisco-aibom) CLI — faint borders/titles, bold-yellow
Usage:, bold-cyan option names, bold-green short flags, bold-yellow type
metavars — so native and aibom-backed help look consistent. Color is gated to
the destination stream being a TTY and honorsNO_COLOR/FORCE_COLOR. make bundle— skips rebuild when Python bundle inputs are unchanged; use
make bundle-forceorBUNDLE_FORCE=1to rebuild. Caches PBS tarball and pip
wheels under.build/.- Onboard/config TUI — interactive wizard and config browse/edit use the same
Typer/Rich-style colors as--help(honorsNO_COLOR/FORCE_COLOR).
v0.1.2
Changed
- Scan commands (
model-scan trigger/info,mcp-scan run/info --scan-id) now
print raw API JSON by default for Python CLI migration parity; use
--envelopefor the normalized verdict JSON/text. Migration: pipelines on
0.1.1that parsedenvelope_versionon stdout without--rawmust add
--envelope(or--raw=false) after upgrade. model-scan listandmodel-scan infoprint verbatim API JSON
(pass-through), matching Python CLI output shape; paging serializes as
count/offset/totalinstead oflimit.
v0.1.1
Fixed
- Release on merge / Create release tag — explicitly dispatch the Release workflow
after pushing a tag (GITHUB_TOKENtag pushes do not triggeron: push: tagsworkflows).
Added
- Prepare release workflow — hybrid changelog autofill, VERSION bump, pushes
release/v*
branch (open PR manually from workflow summary; base = chosenref, includingrelease/0.1.x). - Release on merge — auto-tag when a prepare PR merges to
mainorrelease/**. - Create release tag workflow (
workflow_dispatch) — dry-run or manual tag escape hatch. - Semantic versioning —
VERSIONfile,make version, versioned release binaries
(aid-cisco-cli-<version>-<os>-<arch>),checksums.txt, andmanifest.json. - GitHub Release workflow — push tag
v*to publish versioned downloads. - Public repository with Vault-inspired layout (
api/,internal/cli/). - Multi-platform CI — Linux and macOS embed builds on every PR; versioned artifacts
published onmain/release/**pushes only (7-day retention). - Install/upgrade and user/developer getting-started guides.
- Deterministic exit-code contract for scan commands so CI/CD pipelines can
branch on$?instead of parsing output. Operational failures (1-9) are
partitioned from policy verdicts (>= 10):
0pass,2usage,3auth/config,4connectivity/timeout,5scan
failed/cancelled,1unexpected,10fail,20block. - Unified verdict envelope emitted on stdout by
model-scan trigger/info
andmcp-scan run/info --scan-id:envelope_version, normalized decision,
highest severity, threat counts, and per-severity breakdown (--output json|text). - Gating flags
--fail-onand--block-on(none|low|medium|high|critical)
to configure which severities fail (10) or hard-block (20) the command;
fail-closed by default. --rawflag to print the verbatim API response instead of the envelope
(gating still applies).
Changed
- CI: version resolution folded into the
testjob;checksumsruns only on
main/release/**pushes (not on pull requests). - Upload client fallback uses redirect-safe HTTP client when
UploadHTTPClientis unset. - Dropped
linux-arm64release artifacts — publishlinux-amd64only; ARM Linux
users can use Docker (platform: linux/amd64) or build from source. - Backward-incompatible vs. the Python
aidclithis CLI replaces (the Go CLI
itself has not previously shipped):- Scan commands print the verdict envelope by default instead of the raw
API JSON. Use--rawto restore the verbatim payload. - A completed scan with findings now exits
10/20instead of0. Use
--fail-on none --block-on noneto report without gating. - Operational errors are now classified into
3/4/5instead of the
catch-all1. Usage errors remain2. - Command and flag names are unchanged, so existing invocations still run.
- See Migrating from the Python
aidcli.
- Scan commands print the verdict envelope by default instead of the raw