WeKnora/cli/internal/cmdutil
nullkey 6f8b825f5f feat(cli): agent-first WeKnora CLI
The `weknora` command-line client for the WeKnora RAG server. Full command
surface: kb / doc / chunk / session / message / agent / model / search / chat /
auth / profile / link / api / mcp / skills / config / doctor / schema /
exit-codes.

Agent-first wire contract: JSON envelope by default, typed error codes mapped to
stable exit codes, error.retry_argv / retryable / partial-failure status,
global --dry-run preview, the exit-10 confirmation protocol for writes, and
control/ANSI/Bidi input hygiene. Stateless env-credential auth
(WEKNORA_API_KEY / WEKNORA_TOKEN + WEKNORA_HOST) for headless/CI/agent use.
A curated read-only MCP tool surface (`mcp serve`) and embedded Agent Skills
(`skills install`). Extensive unit + contract-golden tests and CI.
2026-07-06 22:53:01 +08:00
..
agentconfig.go refactor(cli): envelope sweep — Emit shape, batch ops, MCP StructuredContent, api flag cleanup 2026-05-27 10:56:34 +08:00
agentconfig_test.go chore(cli): polish + docs sync + pre-PR audit fixes 2026-05-16 16:56:33 +08:00
agenthelp.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
agenthelp_test.go feat(cli): --format json default + NDJSON event stream + context→profile cascade + help calibration + docs (BREAKING) 2026-05-27 10:56:34 +08:00
authrefresh.go refactor(cli): finish context→profile cascade + post-review hardening (BREAKING) 2026-05-27 10:56:34 +08:00
authretry.go refactor(cli): finish context→profile cascade + post-review hardening (BREAKING) 2026-05-27 10:56:34 +08:00
authretry_test.go refactor(cli): drop aiclient package; align AGENTS.md with mainstream 2026-05-15 12:03:56 +08:00
batch.go refactor(cli): finish context→profile cascade + post-review hardening (BREAKING) 2026-05-27 10:56:34 +08:00
batch_test.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
charcheck.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
charcheck_test.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
confirm.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
confirm_test.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
dryrun.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
dryrun_test.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
errors.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
errors_codes_test.go refactor(cli): drop aiclient package; align AGENTS.md with mainstream 2026-05-15 12:03:56 +08:00
errors_doc_test.go docs(cli): README / AGENTS.md / CHANGELOG + CI parity test 2026-05-18 11:10:19 +08:00
errors_retry_test.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
errors_test.go fix(cli): align stream error handling after output-mode merge 2026-07-03 00:30:34 +08:00
exit.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
exit_test.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
factory.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
factory_test.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
format.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
format_envelope_test.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
format_test.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
host.go refactor(cli): drop aiclient package; align AGENTS.md with mainstream 2026-05-15 12:03:56 +08:00
input.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
input_test.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
kb.go refactor(cli): drop aiclient package; align AGENTS.md with mainstream 2026-05-15 12:03:56 +08:00
loglevel.go refactor(cli): envelope sweep — Emit shape, batch ops, MCP StructuredContent, api flag cleanup 2026-05-27 10:56:34 +08:00
loglevel_test.go feat(cli): --log-level + kb/agent status & check + cross-cutting refactor 2026-05-18 11:10:19 +08:00
model.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
model_test.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
profilename.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
profilename_test.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
risk.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
risk_help_test.go feat(cli): --dry-run + risk metadata + validation parity on 19 mutations 2026-05-28 19:29:50 +08:00
risk_test.go feat(cli): --dry-run + risk metadata + validation parity on 19 mutations 2026-05-28 19:29:50 +08:00
suggest.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00
suggest_test.go feat(cli): agent-first WeKnora CLI 2026-07-06 22:53:01 +08:00