git404hub

what is prime_playground fr?

cloudd901/prime_playground — explained in plain English

Analysis updated 2026-05-18

1PythonAudience · vibe coderComplexity · 2/5LicenseSetup · easy

tl;dr

A tool that generates an interactive 3D shape from prime numbers, letting you explore different rules for how the path turns and steps between primes.

vibe map

mindmap
  root((Prime Playground))
    What it does
      Plots primes in 3D
      Interactive viewer
      Generated by Python
    Tech stack
      Python
      Three.js
      WebGL
    Use cases
      Explore prime patterns
      Compare turn rules
      Learning example
    Controls
      Turn rules
      Step length
      Z movement

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

what do people make with this?

VIBE 1

Explore visual patterns hidden in the sequence of prime numbers.

VIBE 2

Compare different turning and step length rules to see how they shape a 3D path.

VIBE 3

Use as a learning example for generating an interactive Three.js viewer from a Python script.

VIBE 4

Create an eye catching, math based visualization for a presentation or portfolio.

what's the stack?

PythonJavaScriptThree.jsWebGL

how it stacks up fr

cloudd901/prime_playground0xustaz/streamgatea-bissell/unleash-lite
Stars111
LanguagePythonPythonPython
Setup difficultyeasyhardhard
Complexity2/54/54/5
Audiencevibe coderdeveloperresearcher

Figures from each repo's GitHub metadata at analysis time.

how do i run it?

Difficulty · easy time til it works · 5min

Requires Python 3.11 or newer, a local server is used because browsers can block module imports from a file opened directly.

in plain english

Prime Playground turns prime numbers into a shape you can look at and rotate in 3D. A Python script generates a self contained browser page that draws a path connecting one point per prime number, and you view and explore that path with your mouse in a 3D viewer built on Three.js, a JavaScript library for graphics that runs on your graphics card. The path is built one prime at a time. Starting from wherever the path currently points, the program decides how far to step forward and, after placing each new point, chooses a new direction for the next step. You have several options for how that direction changes: some rules always turn around the same axis, keeping the path flat, while others rotate around different axes for different primes, letting the path curve out into three dimensions. Some rules base the turn on a fixed angle you choose, while others calculate the turn from properties of the prime itself, like the gap to the previous prime or the sum of its digits. Separately from direction, you can also control how far each step travels. Some settings make every step the same length, while others make the steps longer or shorter depending on the size of the gap between primes, the digit sum of the prime, or how large the prime number is overall. There is also an optional setting that adds extra up and down movement to each step, layered on top of whichever direction rule you picked. To run it, you need Python 3.11 or newer, and you either run the Python script directly or, on Windows, double click a provided launcher file. Either way, it regenerates the viewer, starts a small local web server on your own computer, and opens the result in your browser. All of the actual path calculation and rendering happens in the browser itself, not in Python. The project is released under the MIT license.

prompts (copy fr)

prompt 1
Explain how the Prime gap angle X/Y/Z turn rule decides which axis to rotate around.
prompt 2
Walk me through running prime_playground.py and opening the generated viewer.
prompt 3
What is the difference between Constant step length and Prime gap scaled step length?
prompt 4
Help me understand how Additional Z Movement changes the shape of the path.

Frequently asked questions

what is prime_playground fr?

A tool that generates an interactive 3D shape from prime numbers, letting you explore different rules for how the path turns and steps between primes.

What language is prime_playground written in?

Mainly Python. The stack also includes Python, JavaScript, Three.js.

How hard is prime_playground to set up?

Setup difficulty is rated easy, with roughly 5min to a first successful run.

Who is prime_playground for?

Mainly vibe coder.

peek the repo → explain another one

This repo across BitVibe Labs

double-check against the repo, no cap.