# quell score

> Show the Production Readiness Score for a Python path as a panel, JSON or an SVG badge, from a cached quell-report.json or a quick rule-engine scan.

Canonical page: https://quelltest.com/docs/cli/score

`quell score` prints the Production Readiness Score (PRS) for a path: a 0 to 100 number with a tier, the counts of written, scaffolded and flagged edge cases, and the average confidence. Use it for a README badge or a script that tracks the score. For a pass or fail gate in CI use [`quell ci`](https://quelltest.com/docs/cli/ci.md).

## What is the syntax?

```bash
quell score [TARGET]
quell score [TARGET] --badge    # SVG badge on stdout
quell score [TARGET] --json     # JSON on stdout
```

| Option | Meaning |
| --- | --- |
| `--badge` | Print an SVG badge to standard output. |
| `--json` | Print the score as JSON. |
| `--sync` | Push a PRS snapshot to the cloud (Pro and Team only). |
| `--root PATH` | Project root (default `.`). |

## Where does the number come from?

`quell score` reads `quell-report.json` from the project root when it is in the bucketed format (it has `written_count` and `flagged_count`). Otherwise it prints `No cached report found — running a quick scan...` and runs the rule engine over the guard clauses: every gap the rule engine can write a test for counts as WRITTEN at confidence 80, and the rest as SCAFFOLDED, without running the verification gates. The `quell-report.json` that `quell find` writes uses a different layout (`summary` and `results`), and in the version tested a `quell score` run straight after `quell find` still printed the quick-scan message. That quick figure can therefore be higher than the score at the end of a `quell find` run. The formula is on the [PRS reference page](https://quelltest.com/docs/reference/prs.md).

## What does the JSON look like?

```json
{
  "score": 80,
  "tier": "green",
  "tier_label": "Production Ready",
  "written_count": 3,
  "scaffolded_count": 0,
  "flagged_count": 0,
  "total_edge_cases": 3,
  "edge_case_coverage_pct": 100.0,
  "avg_written_confidence": 80.0,
  "modifiers": [],
  "before_score": null
}
```

## What are the tiers?

| Score | Tier | Label |
| --- | --- | --- |
| 80 to 100 | `green` | Production Ready |
| 60 to 79 | `yellow` | Review Needed |
| 0 to 59 | `red` | Edge Cases Uncovered |

## How do I add a badge?

`quell score --badge` writes an SVG document to standard output; redirect it to a file and reference it from your README:

```bash
quell score src/ --badge > prs-badge.svg
```

Using JavaScript or TypeScript? The npm package prints a coverage-based score: see the [npm CLI reference](https://quelltest.com/docs/npm/cli.md).
