Command line¶
neosloc PATH... assesses one or more repositories. Everything below is generated from
neosloc --help when the documentation is built.
usage: neosloc [-h] [--json] [--schema] [-v] [--only ONLY] [--salary SALARY]
[--overhead OVERHEAD] [--buy-price USD] [--horizon YEARS]
[--make-model MODEL] [--version]
[--log-level {debug,info,warning,error}] [-q]
[--log-format {text,json}] [--agentic] [--judge] [--review]
[--scope {docs,source,both}] [--tasks TASKS]
[--probe-model PROBE_MODEL] [--judge-model JUDGE_MODEL]
[--review-model REVIEW_MODEL]
[--effort {low,medium,high,xhigh,max}] [--max-turns MAX_TURNS]
[--max-cost MAX_COST] [--base-url BASE_URL] [--allow-writes]
[--auth-header AUTH_HEADER] [--no-fallbacks]
[--transcripts TRANSCRIPTS]
[paths ...]
Integrability evaluation for software repositories.
positional arguments:
paths repository directories to assess
options:
-h, --help show this help message and exit
output:
--json emit JSON (reports and errors) instead of text
--schema print the JSON Schema of --json output and exit
-v, --verbose show all evidence in the text report
--only ONLY comma-separated dimension keys to run (interface,
stability, events, identity, portability, ergonomics,
embeddability, extensibility, observability,
legibility)
--salary SALARY annual salary for cost figures (default: sloccount's
56286)
--overhead OVERHEAD overhead multiplier on salary (default: 2.4)
--buy-price USD price per year of buying/adopting the product, for
make-or-buy (default: 0)
--horizon YEARS make-or-buy horizon in years (default: 3.0)
--make-model MODEL model whose prices cost the 'make' tokens (default:
anthropic:claude-opus-5-5)
--version show program's version number and exit
diagnostics (stderr):
--log-level {debug,info,warning,error}
debug: detector timings; info (default): evaluator
progress; warning; error. Also NEOSLOC_LOG_LEVEL.
-q, --quiet only errors on stderr (same as --log-level error)
--log-format {text,json}
text (default) or one JSON object per line
LLM evaluators (call model APIs and cost money):
Models are written provider:model, e.g. anthropic:claude-opus-5-5 or
openrouter:google/gemini-3.8-flash; a comma-separated list runs a panel.
Anthropic needs ANTHROPIC_API_KEY and the [agentic] extra; OpenRouter
needs OPENROUTER_API_KEY.
--agentic probe: have a model attempt the standard integration
tasks and grade the answers
--judge judge: have a model check each grounded probe answer
against the source (implies --agentic)
--review review: have a model audit each static dimension level
against the code
--scope {docs,source,both}
what the agent may read (default: docs; 'both'
measures the documentation gap)
--tasks TASKS comma-separated task keys (default: all)
--probe-model PROBE_MODEL, --model PROBE_MODEL
probe model(s) (default: anthropic:claude-opus-5-5)
--judge-model JUDGE_MODEL
judge model (default: the first probe model)
--review-model REVIEW_MODEL
review model(s) (default: anthropic:claude-opus-5-5)
--effort {low,medium,high,xhigh,max}
effort level (default: medium)
--max-turns MAX_TURNS
per task (default: 25)
--max-cost MAX_COST shared budget for all model calls in USD; no new task
or review starts once it is spent (default: 5.0)
--base-url BASE_URL probe a running instance over HTTP
--allow-writes permit POST/PUT/PATCH/DELETE against --base-url
--auth-header AUTH_HEADER
'Name: value' header added to every live request
(repeatable)
--no-fallbacks don't let the API retry refused requests on a fallback
model
--transcripts TRANSCRIPTS
directory to save per-task transcripts
Exit status: 0 ok, 1 internal error, 2 usage error, 3 a path could not be
assessed, 4 LLM evaluator setup error (credentials, provider, model, SDK), 130
interrupted. With --json, errors are JSON on stdout too; `neosloc --schema`
describes every shape.
Output and diagnostics¶
- stdout carries the result: the text report, or with
--jsonone JSON document, including errors (JSON output). - stderr carries diagnostics through the
neosloclogger.
| Level | What you see |
|---|---|
error |
Fatal errors. -q/--quiet shows only these. |
warning |
Degraded results, such as a budget exhausted before every task ran. |
info (default) |
Progress of LLM evaluators. Static runs print nothing here. |
debug |
Per-detector levels and timings, inventory size, total time, tracebacks of internal errors. |
Set the level with --log-level or NEOSLOC_LOG_LEVEL; --quiet wins over both.
--log-format json writes one JSON object per line (ts, level, logger, message,
plus fields such as detector, seconds, code), which is useful in CI logs.
Exit status¶
| Status | Meaning | JSON error.code |
|---|---|---|
0 |
Every path was assessed. | |
1 |
Internal error, a bug in neosloc. | internal |
2 |
Invalid command line. | usage, unknown_dimension, unknown_task, bad_model_spec |
3 |
At least one path couldn't be assessed; the others are still reported. | not_a_directory |
4 |
LLM evaluator setup failed. | missing_dependency, credentials, provider_unreachable, unknown_model, model_unsupported |
130 |
Interrupted. | interrupted |
Examples¶
neosloc . # text report for the current repository
neosloc --json ~/src/a ~/src/b > report.json
neosloc --schema > neosloc.schema.json # the shape of every --json document
neosloc -q --json . | jq '.dimensions[] | {key, level}'
neosloc --log-level debug --log-format json . 2> timings.jsonl
neosloc -v --only interface,stability . # all evidence, two dimensions
neosloc --salary 90000 --overhead 1.8 . # value in your own cost terms
neosloc --agentic --scope both --transcripts runs/ .
neosloc --review --review-model openrouter:google/gemini-3.8-flash,openrouter:openai/gpt-5.6-luna .