# Scorer Node

> Rates input on a described rubric with Jev; writes a fractional score you can branch or loop on.

**URL:** https://caywork.com/learn/docs/node/scorer-node

## Content

The **Scorer Node** rates input text on a rubric you describe, using the Jev decision model (TypeSafe System One). It returns a probability-weighted position on your levels — a fractional number you can branch on, loop on, or rank with.

## How it works

1. The node sends the input to Jev as a single **Score** question over your ordered level descriptions.
2. Jev returns `score` (0..n_levels-1, can land between levels), `confidence`, and the probability of each level.
3. The score is written to state under your chosen output key, mirrored into `score` and `variables`.

## Parameters

* **rubric** (string): The scoring question (e.g. "How ready is this lead to buy?").
* **levels** (array, 2-10, ordered low→high): Level descriptions. Write concrete situations: "Just browsing, no signals of intent" — not "low". Numbers-only levels collapse confidence.
* **output_key** (string, default "score"): Where the score is stored. Also mirrored into `variables[output_key]` so a Condition Node can read it by name.
* **input_key** (string, default "user_message"): Which state field to score. Falls back to final_answer, then user_message.

## Pairing

* **Condition Node**: branch on the score with `>=`, `<`, or the new `between` operator (e.g. `between 1, 2` for a mid-band).
* **Loop Node (quality mode)**: set quality_field to your output key to loop until the score crosses the threshold. The loop's max_iterations backstop still applies.

## Use Cases

1. **Lead qualification**: score a lead, route to sales above threshold, nurture below.
2. **Quality loops**: score generated output each iteration until it clears a bar.
3. **Prioritization**: score tickets or messages to rank a queue.

## Tips

* Use as many levels as you can describe distinctly; three is fine.
* A fractional score is a position, not a percentage — rescale in your logic if you need one.
* If the decision service is unavailable, no score is written; downstream conditions fall back to their default path.