Quick Offline code review agent with local rules & optional Ollama + Phi4 LLM AI using Docker Image
718
Offline code review CLI with deterministic local rules and optional Ollama AI.
code-review-report.html and command-creator.html.Yes. You can review any stack by selecting file extensions and folders.
--ext--ext: Java, C#, Python, PHP, Go, Rust, SQL, CSS, HTML, YAML, Terraform, and moreNote: built-in rules are generic/text and JavaScript-oriented naming/style checks in some cases, but scanning and report generation work for any text-based source files.
docker pull satmaramani/code-review-agent:latest
PowerShell:
docker run --rm --name code-review-agent -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest
Windows CMD:
docker run --rm --name code-review-agent -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest
After run, open:
./code-review-report.html./command-creator.htmlWindows PowerShell path style:
.\code-review-report.html.\command-creator.htmlUse this base in all examples:
docker run --rm --name code-review-agent -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest [OPTIONS]
Windows CMD base:
docker run --rm --name code-review-agent -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest [OPTIONS]
Common placeholders:
<mode>: git-diff | staged | full-project<format>: cli | json | markdown | html<file-list>: file1,file2,file3<dir-list>: dir1,dir2,dir3<ext-list>: js ts py java cs ...${PWD} in PowerShell and %cd% in CMDSyntax:
... --mode full-project --no-ai --format html --out <report-file>
Example:
PowerShell
docker run --rm --name code-review-agent -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode full-project --no-ai --format html --out code-review-report.html
Windows CMD
docker run --rm --name code-review-agent -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode full-project --no-ai --format html --out code-review-report.html
git-diff)Syntax:
... --format <format> --out <report-file>
Example:
PowerShell
docker run --rm --name code-review-agent -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest --format html --out code-review-report.html
Windows CMD
docker run --rm --name code-review-agent -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest --format html --out code-review-report.html
Syntax:
... --mode staged --format <format>
Example:
PowerShell
docker run --rm --name code-review-agent -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode staged --format markdown
Windows CMD
docker run --rm --name code-review-agent -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode staged --format markdown
Syntax:
... --file <file-path> --format <format> [--no-ai]
Example:
PowerShell
docker run --rm --name code-review-agent -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest --file src/badAuth.js --no-ai --format markdown
Windows CMD
docker run --rm --name code-review-agent -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest --file src/badAuth.js --no-ai --format markdown
Syntax:
... --file <file1,file2,file3> --format <format>
Example:
PowerShell
docker run --rm --name code-review-agent -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest --file src/a.js,src/b.ts,src/c.py --no-ai --format markdown
Windows CMD
docker run --rm --name code-review-agent -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest --file src/a.js,src/b.ts,src/c.py --no-ai --format markdown
Syntax:
... --dir <folder> --format <format> [--no-ai]
Example:
PowerShell
docker run --rm --name code-review-agent -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest --dir app/src/abcd --no-ai --format html --out code-review-report.html
Windows CMD
docker run --rm --name code-review-agent -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest --dir app/src/abcd --no-ai --format html --out code-review-report.html
Syntax:
... --dir <dir1,dir2,dir3> --format <format>
Example:
PowerShell
docker run --rm --name code-review-agent -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest --dir app/src,packages/core/src,services/api --no-ai --format html --out code-review-report.html
Windows CMD
docker run --rm --name code-review-agent -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest --dir app/src,packages/core/src,services/api --no-ai --format html --out code-review-report.html
Syntax:
... --include <glob1,glob2> --exclude <glob1,glob2> --format <format>
Example:
PowerShell
docker run --rm --name code-review-agent -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest --include "src/**/*.ts,services/**/*.js" --exclude "**/*.test.ts,**/dist/**" --no-ai --format markdown
Windows CMD
docker run --rm --name code-review-agent -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest --include "src/**/*.ts,services/**/*.js" --exclude "**/*.test.ts,**/dist/**" --no-ai --format markdown
Syntax:
... --mode full-project --ext <ext> --ext <ext> --ext <ext> ...
Example:
PowerShell
docker run --rm --name code-review-agent -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode full-project --ext js --ext ts --ext php --ext css --ext java --ext cs --ext py --ext go --ext rs --no-ai --format html --out code-review-report.html
Windows CMD
docker run --rm --name code-review-agent -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode full-project --ext js --ext ts --ext php --ext css --ext java --ext cs --ext py --ext go --ext rs --no-ai --format html --out code-review-report.html
Syntax:
... --mode <mode> --format json
Example:
PowerShell
docker run --rm --name code-review-agent -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode git-diff --format json
Windows CMD
docker run --rm --name code-review-agent -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode git-diff --format json
Syntax:
... --mode <mode> --format cli
Example:
PowerShell
docker run --rm --name code-review-agent -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode full-project --no-ai --format cli
Windows CMD
docker run --rm --name code-review-agent -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode full-project --no-ai --format cli
Syntax:
docker run --rm -e OLLAMA_BASE_URL=<ollama-url> -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode full-project --format html --out <report-file>
Example:
PowerShell
docker run --rm --name code-review-agent -e OLLAMA_BASE_URL=http://host.docker.internal:11434 -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode full-project --format html --out code-review-report.html
Windows CMD
docker run --rm --name code-review-agent -e OLLAMA_BASE_URL=http://host.docker.internal:11434 -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode full-project --format html --out code-review-report.html
Syntax:
... --file <file> --format <format> --maxTokens <n> --timeoutMs <ms>
Example:
PowerShell
docker run --rm --name code-review-agent -e OLLAMA_BASE_URL=http://host.docker.internal:11434 -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest --file src/badAuth.js --format markdown --maxTokens 128 --timeoutMs 60000
Windows CMD
docker run --rm --name code-review-agent -e OLLAMA_BASE_URL=http://host.docker.internal:11434 -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest --file src/badAuth.js --format markdown --maxTokens 128 --timeoutMs 60000
Syntax:
... --mode full-project --maxFiles <n> --no-ai --format <format>
Example:
PowerShell
docker run --rm --name code-review-agent -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode full-project --maxFiles 10 --no-ai --format markdown
Windows CMD
docker run --rm --name code-review-agent -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode full-project --maxFiles 10 --no-ai --format markdown
Syntax:
... --mode <mode> --format <format> --verbose
Example:
PowerShell
docker run --rm --name code-review-agent -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode full-project --format markdown --verbose
Windows CMD
docker run --rm --name code-review-agent -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest --mode full-project --format markdown --verbose
Default mode generates files and exits. Use server mode only when you specifically want localhost links.
Syntax:
docker run --rm --name code-review-agent -e SERVE=1 -p <host-port>:8787 -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest
Example:
PowerShell
docker run --rm --name code-review-agent -e SERVE=1 -p 8787:8787 -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest
Windows CMD
docker run --rm --name code-review-agent -e SERVE=1 -p 8787:8787 -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest
Open:
http://localhost:8787/code-review-report.htmlhttp://localhost:8787/command-creator.html8787 port is busyUse any free host port (container port stays 8787).
Syntax:
... -e SERVE=1 -p <another-port>:8787 ...
Example:
PowerShell
docker run --rm --name code-review-agent -e SERVE=1 -p 8791:8787 -v "${PWD}:/workspace" -w /workspace satmaramani/code-review-agent:latest
Windows CMD
docker run --rm --name code-review-agent -e SERVE=1 -p 8791:8787 -v "%cd%:/workspace" -w /workspace satmaramani/code-review-agent:latest
Then open:
http://localhost:8791/code-review-report.htmlhttp://localhost:8791/command-creator.htmlollama pull phi3:mini
ollama run phi3:mini
http://localhost:11434http://host.docker.internal:11434code-review-report.htmlcommand-creator.htmlreview.config.last-run.jsonLocation: your current project folder (same folder where you run the command).
review.config.jsonreview.config.last-run.json--mode git-diff|staged|full-project--format cli|json|markdown|html--out <file>--file <path[,path2]>--dir <folder[,folder2]> or --folder <folder[,folder2]>--include <glob[,glob2]>--exclude <glob[,glob2]>--ext <extension> (repeatable)--ext-js --ext-ts (shorthand)--maxFiles <n>--no-ai--maxTokens <n>--timeoutMs <n>--verbose--help--examplesdocker rm -f code-review-agent 2>$nullspawn git ENOENT:
docker pull satmaramani/code-review-agent:latest--mode full-project-e OLLAMA_BASE_URL=http://host.docker.internal:11434Content type
Image
Digest
sha256:b6a4c593a…
Size
55.7 MB
Last updated
7 months ago
docker pull satmaramani/code-review-agent