---
title: "Playground · Mentat"
description: "Give Mentat two engineering rules and watch the three-stage conflict pipeline run: scope intersection, axis and direction, then adjudication. Including the stages that decide there is nothing here."
url: https://trymentat.pages.dev/playground
---

Playground

# Hand it two contradictory rules.

This runs the real pipeline. The same functions execute in the deployed Worker, in the CLI, and in CI, and the trace below shows every stage including the ones that stop a pair before it costs a model call.

TRY

DECISION A

Constraint

Why

Scope

DECISION B

Constraint

Why

Scope

01

Scope intersectiondeterministic

Waiting.

…

02

Axis and directiondeterministic

Waiting.

…

03

Adjudicationmodel

Waiting.

…

Nothing here is canned. The same functions run in the deployed Worker, in the CLI, and in CI. Stage three falls back to a deterministic adjudicator when no model key is configured, which is also what the precision test is measured against.

## Why three stages

Naive pairwise semantic comparison is quadratic with a terrible base rate. Worse, a false conflict is an accusation about two colleagues' judgment, which costs more than a missed one.

01

Scope intersection

Deterministic set arithmetic over glob, module, and symbol scopes. No model. This is where most apparent contradictions dissolve: "use Postgres" and "use DynamoDB" do not conflict when they govern different services. It also collapses the quadratic pair space to a handful.

02

Axis and direction

Cheap classification of which axis each rule constrains and which way it pushes. Overlapping scope but different axes is not a conflict. Same axis, opposed direction, and a shared subject makes a candidate.

03

Adjudication

Only survivors are worth a model call, and only to answer one question: must an engineer editing this scope violate one of them? Below 0.75 confidence the pair is surfaced as a question rather than a conflict. Without a key this stage is deterministic, which is what the precision test measures.

A test in this repository asserts that twenty unrelated decision pairs produce exactly zero conflicts. That gate matters more than any positive result: two real conflicts a month beats twenty maybes, and one confident-wrong accusation between colleagues ends the trial.

---

Mentat: https://trymentat.pages.dev/ · Docs: https://trymentat.pages.dev/docs · Developers: https://trymentat.pages.dev/developers · API: https://trymentat.pages.dev/openapi.json · Index for agents: https://trymentat.pages.dev/llms.txt
