Skip to content

river-run-typesafe

River Raid-style Python shooter flown by a Jev pilot that picks a lane, whether to fire and a speed in one request per decision.

ProjectprototypeMIT

Overview

River Run is a vertical-scrolling river shooter written in Python with pygame-ce, inspired by Atari's River Raid but with original code, graphics and sound. You can fly it yourself or let a TypeSafe pilot play.

The pilot splits the screen into 20 lanes. Code measures each reachable lane (time to line up, open water ahead, objects in or drifting into it), and one System One request per decision asks in parallel which lane to fly in, whether to fire, and how fast to go. Code turns the answers into controls, and the HUD shows the chosen lane and its confidence, the fire probability, speed and request time. Real-time play makes about 8 requests per second; a lockstep mode makes the game wait for each decision, and headless and recording modes are available.

What the decision model decides

TypeQuestionAnswers
ChoiceWhich of the 20 lanes should the plane fly in?—
Yes / noShould the plane fire now?—
ChoiceHow fast should the plane go?—

How it works

  1. Code measures each reachable lane's features
  2. One Jev request asks lane, fire and speed questions in parallel
  3. Code converts lane probabilities into a steering target and applies controls
  4. HUD shows choice, confidence and timing

Strengths

  • Code computes geometry; Jev only judges
  • Confidence displayed on screen
  • Lockstep and headless modes for testing

Caveats

  • About 8 requests per second in real time costs API usage
  • Needs network access to TypeSafe

Getting started

.venv/bin/pip install -r requirements.txt, export TYPESAFE_API_KEY, then .venv/bin/python -m typesafe_pilot.

At a glance

Type
Project
Status
prototype
Language
Python
Runtime
pygame-ce desktop game
Has code
yes
License
MIT

Use cases and integrations

How curated lists describe it

  • River shooter game in Python, inspired by Atari's River Raid, played by a TypeSafe AI pilot.

    hellogumbo/awesome-jev

Frequently asked questions

What does Jev decide?

Which lane to fly in, whether to fire, and how fast to go, in one request per decision.

How many requests does it make?

About 8 per second while playing in real time.

Can I play without a key?

Yes, --human lets you fly it yourself.

Related projects

  • Source for browser chess and Chess960 where code computes each legal move's facts and Jev picks one per turn as a typed Choice.

    ProjectproductionTypeScript
  • Browser 1v1 sniper arena where Jev reads match state about 9 times a second and chooses movement, aim, ADS, firing and jumping.

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

    ProjectbetaTypeScript
  • Fifteen live arcade games where Jev and LLMs play each other, led by WikiRace in which Jev picks only real links.

    ProjectbetaTypeScript
  • Real-time bot battles where you write a fighter's strategy in plain English and a System One model pilots it several times a second.

    ProjectbetaTypeScript
  • Browser extension that lets Jev, local Laya or an OpenAI-compatible model take over a running ra2web (WannaFire) RTS match.

    ProjectbetaTypeScript