whatisgithub

What is prism?

badtheorylabs/prism — explained in plain English

Analysis updated 2026-05-18

43PythonAudience · developerComplexity · 3/5LicenseSetup · moderate

In one sentence

A toolkit that gives small, locally run AI models the planning, tool-use, and self-checking structure usually built into large AI models.

Mindmap

mindmap
  root((Prism))
    What it does
      Adds structure around small models
      Context and planning plates
      Runs real tests to verify
    Tech stack
      Python
      Ollama
    Use cases
      Structured coding agent loop
      Codebase context packing
      Non-coding verify and repair
    Audience
      Developers
      Local AI builders
    Status
      Core plates live
      Grounding planned

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 build with it?

USE CASE 1

Run a small local model through a structured loop that plans a coding task, edits files, and only accepts changes that pass the real tests.

USE CASE 2

Explore and summarize a codebase within a token budget before handing it to a small model.

USE CASE 3

Adapt the same verify-and-repair loop to non-coding tasks, like checking that a data reconciliation adds up.

What is it built with?

PythonOllama

How does it compare?

badtheorylabs/prismalibaba/omnidoc-tokenbencharccalc/dwmfix
Stars434343
LanguagePythonPythonPython
Setup difficultymoderatemoderateeasy
Complexity3/53/52/5
Audiencedeveloperresearchergeneral

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

How do you get it running?

Difficulty · moderate Time to first run · 30min

Needs Ollama installed with a local model pulled, the core library itself needs no pip install to try.

Use, modify, and distribute freely, including commercially, as long as you keep the copyright notice (MIT license).

So what is it?

Prism is a Python toolkit that tries to make small AI models, the kind that can run on a regular laptop, act more like the large models offered by big AI companies. The idea behind the project is that a large model is not just good because of its size, but because of everything it does behind the scenes: keeping track of a whole codebase, planning several steps ahead, checking its own answers, and using tools correctly. Small models are not as good at doing that thinking internally, so Prism tries to build all of that structure outside the model instead, as separate, visible pieces of code that any small local model can run through. The project breaks this structure into pieces it calls plates. A context plate builds a map of a codebase and packs the relevant parts into the model's limited input space. A reasoning plate breaks a task into smaller steps and feeds them to the model one at a time. A tools plate makes sure the model calls external tools correctly, with strict rules on the format it must follow. A verification plate actually runs a project's tests or compiler on the model's output and only accepts changes that pass. A critique plate has a separate check try to find mistakes and feed them back for another attempt. A trace and memory plate records what happened during each run so future runs can learn from it. Two more plates, for looking things up externally and combining multiple attempts, are listed as still being built. Prism uses Ollama, a tool for running open AI models locally, and its core code relies only on Python's standard library, so trying the demo does not require installing extra packages. The project ships command line tools for each plate, plus a full harden command that walks a task through generating code, running the real tests, and repairing failures until they pass. While the project is built around programming tasks, the README says the same structure can be reused for other kinds of work by swapping out how the answer is checked, giving an example of a data task where a model's numbers are only accepted if they add up correctly. The project is early and described by its creators as opinionated and actively changing, with contributions welcome. It is released under the MIT license.

Copy-paste prompts

Prompt 1
Help me run the Prism demo command against a local Ollama model.
Prompt 2
Use Prism's harden command to add a feature to this repo and only accept it if the tests pass.
Prompt 3
Explain what each of Prism's plates, like context, reasoning, and verification, actually does.
Prompt 4
Show me how to benchmark one of Prism's plates in isolation.

Frequently asked questions

What is prism?

A toolkit that gives small, locally run AI models the planning, tool-use, and self-checking structure usually built into large AI models.

What language is prism written in?

Mainly Python. The stack also includes Python, Ollama.

What license does prism use?

Use, modify, and distribute freely, including commercially, as long as you keep the copyright notice (MIT license).

How hard is prism to set up?

Setup difficulty is rated moderate, with roughly 30min to a first successful run.

Who is prism for?

Mainly developer.

Open on GitHub → Ask about another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.