Skip to content
1 min read

fj agent

AI-assisted code operations (review, fix, explain)

fj agent [OPTIONS] <COMMAND>

Every command also accepts the global flags: --host, --debug, --no-pager, --json-fields.

fj agent review

Run an automated review of the current change

fj agent review [OPTIONS]

Options

  • -R, --repo <REPO> — Target repository as <owner>/<name>. Inferred from the git remote when omitted
  • --pr <PR> — Review a specific PR’s diff instead of the working-tree diff
  • --stack — Review each item of the local stack separately
  • --security — Focus the analysis on security (adds a security advisory and frames the provider prompt accordingly)
  • --json — Emit JSON instead of a table (honors the global --json-fields)

fj agent fix

Apply automated fixes to the current change

fj agent fix [OPTIONS]

Options

  • -R, --repo <REPO> — Target repository as <owner>/<name>. Inferred from the git remote when omitted
  • --write — Apply the proposed patch to the working tree (instead of printing it)
  • --pr — Apply the patch on a new branch, commit, push, and open a PR
  • --branch <BRANCH> — Branch name for --pr (default: agent-fix)
  • --title <TITLE> — PR title and commit subject for --pr (default: “Apply agent fix”)
  • --dry-run — Print the planned actions and exit without mutating anything

fj agent explain

Explain a piece of code or a change

fj agent explain [OPTIONS] [TARGET]

Arguments

  • [TARGET] — What to explain: a file path, a git revision, or omitted for the current working-tree diff

Options

  • --json — Emit JSON instead of a table (honors the global --json-fields)
Contributors
  • Stephen Way