Skip to content

jev-minesweeper

Browser Minesweeper demo where Jev answers 'is this cell a mine?' for every frontier cell in one request, with an exact solver as fallback.

Projectprototype

Overview

Jev x Minesweeper is a browser demo (documented in Japanese) in which TypeSafe's Jev plays Minesweeper. Each turn, the code builds one Noul question per unopened cell touching a number, asking whether that cell is a mine, and sends them all in one request, following TypeSafe's speculative fan-out pattern. Jev returns a mine probability per cell, and code decides which cells to open or flag.

The project bundles an exact solver that computes true mine probabilities from visible information. It serves as the fallback when Jev is not confident (a confidence-gated routing mode) and as the reference for checking Jev's probabilities. Views include a calibration chart in 10% bins, Brier scores and counts of confident errors. A switch compares sending pre-digested clues (numbers minus flags, as English sentences) with raw numbers. A CLI benchmark reports win rate, moves, share of Jev-decided moves, API calls, cost and latency per game.

What the decision model decides

TypeQuestionAnswers
Yes / noIs this cell a mine?yes · no

How it works

  1. Collect unopened cells adjacent to numbers
  2. Send one Noul per cell in a single Jev request
  3. Open cells at or below 5% and flag cells at or above 95% (defaults)
  4. In hybrid mode, hand turns with no confident cell to the exact solver
  5. Score calibration with a reliability chart and Brier score

Strengths

  • Exact solver gives ground-truth probabilities for calibration checks
  • Seeded, shareable boards for fair comparisons
  • No npm dependencies; tests run without the API
  • Mock mode for trying the UI without a key

Caveats

  • Requires a TypeSafe key for real Jev play
  • Documentation in Japanese
  • Exposing the relay server beyond localhost lets others spend your key

Getting started

cp .env.example .env, add TYPESAFE_API_KEY, run npm start and open http://127.0.0.1:8787

At a glance

Type
Project
Status
prototype
Language
JavaScript
Runtime
Node relay server plus browser
Has code
yes
Has tests
yes

Use cases and integrations

How curated lists describe it

Frequently asked questions

What does Jev decide?

The probability that each frontier cell is a mine; code then opens or flags cells by threshold.

How is Jev's calibration checked?

Against an exact solver's probabilities, with a 10%-bin calibration chart, Brier score and confident-error counts.

Can I play without a key?

Yes. The solver-only and manual modes, and a mock mode, work without an API key.

Related projects

  • Instrumented 2048 web lab where every move is a Jev Choice over four directions, with probabilities, latency and cost shown live.

    ProjectbetaTypeScript
  • Bilingual turtle-soup (lateral-thinking) puzzle site where Jev acts as host, judging player questions and grading solutions.

    AppbetaTypeScript
  • Pandu: tiny local policy networks (2.9K-5K parameters) with calibrated uncertainty that fall back to a teacher when unsure.

    ProjectresearchPython
  • Pokémon Red on PyBoy where code owns route and arithmetic, Jev picks only at branches, and battle faint predictions are Brier-scored.

    DemoprototypePython
  • Twenty-questions game where Jev's confidence decides when to stop: it commits, hedges or refuses to guess.

    DemoprototypeTypeScript
  • Harness where Jev or Laya pick DOOM tactics and targets from legal options while a deterministic controller presses buttons.

    ModelresearchPython