START HERE · NO CODING EXPERIENCE REQUIRED TO FOLLOW
Your idea. A step-by-step path.
Get Pi, research an authorized reference, capture its mechanics in a spreadsheet, then author reviewed SQLite tables and give a real build to a person to test. This guide covers search, preflight, decoded assets and the in-game feedback loop, with clear stops when project-specific tools are missing.
This is a guided process, not a one-click game converter. Pi is an AI assistant in a terminal, not a game engine. Ghidra helps research programs, not automatically rebuild them. The available workbook starter ends at structured JSON. A complete game still needs a reviewed generator/runtime and human acceptance. AI never tests.
Install Node.js with npm, version 22.19 or newer. Use the official installer for your operating system.
Open Command Prompt from Windows Start, or Terminal on macOS/Linux. A terminal is a window where you type a command, then press Enter. Reopen it after installation.
Run the lines below one at a time. These install Pi and display versions, not a game.
Then make a new empty folder named my-first-project in Documents using your file manager. Open a terminal in that folder. On Windows, open the folder, type cmd in its address bar and press Enter. On macOS/Linux, type cd , drag the folder into Terminal, then press Enter. Run pi.
Connect an AI provider
Inside Pi, type /login, select a supported provider and follow its sign-in instructions. Use /model to select an available model. Provider subscriptions or API usage can cost money. Check the provider's pricing before proceeding.
Enter credentials only in the official sign-in or credential prompt, never in a project file, screenshot or public conversation.
You should see
A Pi conversation with an input area and a footer showing your project folder and selected model. Ask: Tell me which folder you are working in. Do not change any files.
If stuck: “command not found” usually means the terminal cannot locate the installation. Reopen it and follow the platform guide rather than retrying as administrator.
Use both before starting the project research loop. They solve different problems. Neither replaces the authoritative spreadsheet/SQLite database, your approval rules or human testing.
Before installing: you, the human, run the setup commands below. Save your current work, back up Pi settings and check disk space. These are third-party programs/extensions that can execute code. Review their official sources first. If either is already configured, inspect it rather than installing a second copy. Do not overwrite custom extensions, remove sessions or change provider credentials to fix setup.
A. Install RTK
RTK filters supported command output before it enters the AI conversation. It does not make decisions, grant permission or run a test by itself. Choose one installation route:
Windows: in Command Prompt, run winget install rtk-ai.rtk. If winget is unavailable, use the Windows prebuilt ZIP from official RTK releases, extract it and follow the README's PATH instructions. PATH is the list of folders where your terminal looks for programs.
macOS with Homebrew already installed: run brew install rtk. Otherwise use the matching macOS release.
Reopen your terminal, then run these lines. The last line installs RTK's own Pi extension globally for your user, so it affects your Pi projects:
rtk --version
rtk init -g --agent pi
Review any overwrite prompt instead of forcing it. The normal extension location is ~/.pi/agent/extensions/rtk.ts, where ~ means your user home folder. A project-only install is available in the official guide.
Already using pi-rtk-optimizer? Keep one RTK adapter, not both. That separate community extension has its own /rtk commands and compatibility requirements. The native route above does not promise those commands. Ask your maintainer to review an existing setup before switching.
Billion Context manages long conversations by summarizing selected history and providing tools to recover details. The name does not mean your model gets a literal billion-token context window or perfect recall.
In your terminal, with Node/npm already installed for Pi, run:
npm install -g billion-context
bili plugin install pi
This is the native Pi plugin route. It registers the package in Pi settings and starts or attaches to a local proxy when Pi loads. Continue starting Pi with pi. Do not also add the older billion-context-pi plugin or stack the alternative bili pi launcher onto this beginner setup.
The proxy handles model requests locally before forwarding them to your selected provider. This is not offline AI or a free provider. Normal provider charges and data-sharing rules still apply. Do not paste credentials into the chat or manually rewrite API URLs for this route.
Existing installation? The installer can replace legacy global plugin entries. Project-local entries may remain. Back up settings first and have a maintainer resolve duplicate-plugin warnings without deleting your history.
After saving your work, close and reopen Pi in your project folder. Do not restart someone else's active session. Read startup warnings. If a managed configuration blocks extensions, ask its maintainer to allow the specific extensions rather than disabling the safety policy.
RTK: in a separate terminal, run rtk rewrite "git status". It should suggest rtk git status. This only confirms the binary knows the rewrite, not that Pi loaded the adapter. In an existing Git project, ask Pi to show repository status without editing files or running tests, then inspect rtk gain --history yourself. Look for a new matching entry. No entry or a missing-binary warning means activation is not confirmed. Do not initialize an unrelated folder just for this check.
Billion Context: inside Pi, type /acp. After one ordinary model request, such as “Explain our project rules without running tools,” inspect its session status and /acp-cache. A fresh session can be idle and have no savings yet. Unknown commands, proxy errors or direct/uncompressed warnings mean stop and review setup. The model request has normal provider cost.
Record installed versions and what you actually observed. These are human setup checks, not permission for AI to test the game or run a software test suite. A loaded extension alone does not prove long-session compression or savings.
Everyday use: talk to Pi normally
Ask it to research evidence, organize feature rows and prepare preflight findings. RTK handles supported shell-output rewrites. Billion Context supplies compress, decompress, search_context and acp_status tools for conversation management. You do not need to manually summarize every turn.
Periodically inspect rtk gain in your terminal and /acp or /acp-cache inside Pi. RTK's token savings are estimates, not your bill. Cache/compression results depend on your provider, model and workload. No fixed savings percentage is promised.
Exact evidence wins over a summary. Before editing authoritative rows, approving a build or interpreting a human failure report, ask Pi to recover the original context and read the actual source record. Preserve full error output and human test evidence. If RTK hides needed details, request that specific read-only command without RTK filtering. A summary is never the database, a passed test or an approval. Neither tool enforces the “AI never tests” rule.
Ready when: you have observed both integrations, know how to view their status, and can recover original evidence. If either is blocked, disclose that and resolve setup before calling this workflow ready. Next: set the project boundaries.
02 / SET THE PROJECT RULES
You stay in control.
Keep a backup or version-controlled copy of your project. Start with original sample data, not your only game save or an untrusted download. Give Pi this prompt:
Create an AGENTS.md in this new project with these rules:
AI never runs tests or claims tests passed. Humans own all testing and acceptance.
Ask before installing tools, compiling, recompiling, publishing or deleting anything.
Keep one authoritative spreadsheet/database. Never patch generated game output.
After an approved SQLite cutover, edit tables and treat spreadsheets/search indexes as derived views.
Complete the detailed preflight and obtain explicit approval for each individual compile.
After the first successful compile, integrate authorized decoded assets and an in-game feedback menu in an agreed follow-up batch.
Label facts, hypotheses and unknowns. Preserve originals, saves and credentials.
Use RTK and Billion Context, but never treat filtered output or summaries as authoritative evidence.
Recover original records and full error details when needed. Never stack duplicate context plugins.
Explain each step in plain language. Stop if a required integration is unavailable.
First inspect available tools read-only and list what is present and missing.
Do not install, build, test or deploy now.
Instructions are not a security lock. Stock Pi can use tools without asking for every action. Review its activity and do not give it access to sensitive folders. A local custom safety gate, plan tool, Ghidra connector or SQLite tool is not automatically included with public Pi. No public Modport Pi extension bundle is supplied by this guide.
Choose an original example or a game/input you are authorized to analyze. Record the title, exact version, platform, permitted scope and where the untouched original is stored. A person observes the reference and writes down what happens.
Illustrative example, not a recovered game fact: “When a player with 20 health uses one small potion, health becomes 30 and potion count decreases by one. Health cannot exceed 100.” Work on this one behavior before attempting a whole game.
Ask Pi: “Turn my observation into a one-feature research checklist. Mark missing evidence. Do not invent answers or run the game.”
Ready when: the reference version and a repeatable human observation are recorded. Stop if: authorization, inputs or the version are unclear. Do not upload proprietary binaries to the site or an AI provider.
04 / GHIDRA
Research what the program does.
Get the official Ghidra release distribution, not GitHub's source-code ZIP. Read the requirements bundled with that release and install its required JDK from Temurin. Requirements vary by release.
Extract into a new folder. Launch ghidraRun.bat on Windows or ghidraRun on macOS/Linux. Follow the official guide for platform-specific native components if needed.
In Ghidra, choose File → New Project → Non-Shared Project, select a project folder and name, then finish. Choose File → Import File and select an authorized input copy.
Open the imported program in CodeBrowser and review its analysis prompt. Keep defaults only when appropriate for the detected format. If the format is not supported or the output is confusing, stop and ask an experienced researcher.
Record the relevant function/location, your interpretation, reference version and confidence. Ghidra's decompiled view is not the original source code. Do not label an AI interpretation as proven behavior.
Ask Pi: “Explain these research notes in plain language. Separate observed facts from hypotheses and propose feature rows. Do not execute the game or claim behavior is verified.”
Capture decompiler findings and human observations in a spreadsheet first. Describe how the game works: systems, inputs, states, transitions, rules, timing, units, limits and asset references. Keep facts, interpretations and unknowns separate. These example columns are a planning model, not a ready-made import schema.
Example mechanic record, not a recovered game fact
Field
Example / required information
Stable feature ID
potion.small.use
System + states
Inventory / health; available → consumed
Inputs + trigger
Health 20, maximum 100, potion count 1; player uses potion
Rule + parameters
Add 10 health, clamp to maximum, consume one potion; explicit units
Outputs + boundaries
Health 30, potion count 0; research full health, empty inventory and repeated input
Evidence + confidence
Reference version, input SHA256, function/address or source location, research note, human observation and confidence
Asset references
Stable asset IDs, format, original/decoded hashes and permission status
Revision + review
Author, date, proposed/approved/unknown, linked feedback and change reason
Ask Pi: “Organize my research into these records without inventing missing mechanics. Show evidence and unresolved questions. Do not run tests.”
Ready when: you can explain each rule yourself and every row has evidence or a visible unknown. Preserve the original binaries and researcher notes outside generated output.
06 / SPREADSHEET → SQLITE3 → EDITABLE TABLES
One database. Clear, editable tables.
Use the spreadsheet to capture the research, then map the approved records into a project-specific SQLite3 database. Review the import and choose one writable authority. After an approved SQLite cutover, edit through the database's table view and keep spreadsheet exports as dated, read-only views. Existing workbook-driven projects keep their current pipeline until that migration is explicitly approved.
A. Keep the starter honest
The public workbook starter exports Entities, Fields and Rules to JSON. Its workbook remains authoritative. It does not supply a SQLite migration, a vector index, decoded game assets or a game compiler. Do not mistake a JSON matrix for a playable game.
B. Author in database tables
Have the maintainer name the database path, schema version, import/export mapping and supported editor. Open a backed-up copy with the project's table viewer or DB Browser for SQLite. Inspect Browse Data, choose the named table and review rows before any approved change.
Use transactions, stable IDs, required fields, type/unit checks and enforced foreign keys. Show old/new values and a change reason. Save only reviewed edits. Never write directly into generated game output.
A practical table map
Proposed table responsibilities, to adapt to the project's actual schema
Records
Purpose
features / systems
What each mechanic does, scope and stable identifiers
states / transitions / rules / parameters
Inputs, outcomes, timing, limits and explicit units
evidence / assets
Research provenance, original/decoded hashes, permissions and file references
feedback / changes
Human observations, review decisions and approved corrections
build manifests
Exact database/source revisions, exporter version and asset hashes used by a build
Keep large binaries and decoded assets in controlled storage with hash-based references. Preserve originals. Do not duplicate an entire game inside cells, upload private research to a provider without permission, or share proprietary material through public listings.
Search quickly without changing the source of truth.
Exact lookup: use ordinary SQLite indexes for stable IDs, relationships and common filters.
Text lookup: use SQLite FTS5, where available, for names, notes and evidence text. This is full-text search, not semantic vector search.
Semantic / vector search: a reviewed extension such as sqlite-vec can store and query embeddings. Record the embedding model/version, dimensions and source-row hash. Review installation, provider privacy and any cost first. The author's documentation currently labels sqlite-vec pre-v1 with possible breaking changes.
Treat text/vector indexes as derived, rebuildable search data. An embedding is not proof of a mechanic and must not overwrite an authored rule. Return results with their real row IDs and evidence.
A human measures retrieval quality and latency on the actual dataset. Vector search is not automatically faster than an indexed exact lookup, and this guide makes no “ultra-fast” benchmark claim.
Ask Pi: “Identify our authority and existing editor. Propose a reviewed spreadsheet-to-SQLite mapping, table views and derived search indexes. Identify missing integration. Do not install, migrate, compile or test.”
Ready when: the authority, backups, editing path and exporter are named and the human has reviewed the cutover. Stock Pi does not automatically include a Ghidra connector, DBViewer or this database workflow.
07 / DETAILED PREFLIGHT
Resolve blockers before compiling.
Prepare this checklist once for the complete proposed feature batch, then refresh it for every recompile. Preflight is specification and release preparation, not gameplay testing, a disguised test suite or proof of parity. AI can inspect source and records and draft findings. Humans run all tests, including automated software suites.
Scope and permission: exact reference version, authorized inputs, intended feature batch and material you may use or distribute are recorded.
Recovery: original binaries, saves, authoritative database/workbook, schema, source and required asset files are backed up. Name the recovery destination, prior build and rollback procedure.
One authority: name its path and revision/hash. Confirm no competing editable workbook/database and no unreviewed migration.
Schema and records: review required values, unique stable IDs, types, units, ranges, foreign-key references and change history. Have a human run any required integrity/validator tests and attach their actual results.
Evidence: each scoped mechanic has linked research or an explicitly reviewed uncertainty. Missing or contradictory evidence is a blocker unless the owner explicitly narrows the scope.
Assets: record original/decoded hashes, supported formats, paths, IDs, budgets and permissions. For the first engine build, explicitly identify any approved placeholders and deferred asset integration.
Implementation: identify the real generator, exporter and engine/runtime that consume the tables. Review schema compatibility and missing rendering, physics, input, AI or audio code. Tables do not supply that implementation automatically.
Search: derived indexes correspond to the current row revisions and embedding configuration. Search ranking must not alter deterministic exported mechanics.
Toolchain and storage: identify installed versions, dependency locks, target platform, output directory and available disk/memory. No surprise installations, provider switches or full-app copies.
Build command: show the exact non-test command, changed files, manifest contents and expected artifact. Separate any command that launches tests so a human can run it.
Human plan: name who will boot the artifact, compare features, check boundary cases and exercise the feedback menu. Prepare disposable saves and report fields. Untested behavior stays untested.
Decision: present blocker IDs and proposed fixes, not just a green badge. A human reviews the findings, resolves blockers and explicitly approves this one compile. Failure does not authorize another compile.
Preflight record
Batch / reference version:
Authority path + revision/hash:
Source / schema / exporter / toolchain versions:
Original + decoded asset manifest:
Backup + rollback locations:
Unresolved blockers + reviewed uncertainties:
Exact non-test build command + output target:
Human-only test plan + tester:
Owner approval + date:
Build ID + artifact hash after compilation:
Do not go in circles. If compilation fails, preserve the complete error, identify the source/table/toolchain defect and propose one coherent correction. Review the updated preflight and obtain fresh approval before another compile. Never silently repeat builds or rename tests “preflight” to let AI run them.
Ready when: the human has reviewed the checklist, blockers are resolved and the exact build is approved. A completed checklist is not a human acceptance result.
08 / EXPORT → APPROVE → COMPILE
Build from the reviewed tables.
The exporter turns the approved SQLite records into deterministic engine data and an asset manifest. A project-specific generator/runtime consumes that data and its reviewed source code to produce your game. Decompiled pseudocode and tables alone are not an automatic recompilation pipeline.
Freeze the approved database revision and source revision. Record schema/exporter versions, feature IDs and asset hashes in a build manifest. Keep generated output reproducible and separate from authored records.
Identify the actual engine/runtime and the code implementing the rules. The public workbook starter does not supply a playable runtime. Stop if integration is missing rather than pretending JSON is a game.
Present the complete preflight, exact build command, feature batch, tools, output folder and storage needs. The first approved build may be a narrow engine slice with explicitly recorded placeholders.
Obtain explicit approval for this one non-test compile. AI may run that approved build, but the AI/harness must not run tests. A command that also runs tests must be separated or run by a human.
Record the build ID, database/source revisions, artifact path and hash. A successful compile is not a passed test. A person performs the first boot observation.
Ready when: there is an identified artifact, manifest and human handoff. Install Rust only if the selected runtime requires it. No universal compile command works for every game.
09 / AFTER THE FIRST SUCCESSFUL COMPILE
Add decoded assets and a feedback menu.
Once the initial engine build compiles successfully, integrate the authorized decoded assets so a person can begin meaningful gameplay comparison. Preserve the original asset files and the decoding research. Decoding an asset does not create permission to redistribute it.
For each texture, model, animation, audio clip or map, record its stable ID, original/decoded hashes, decoder version/options, format, units/scale and permission status.
Map those IDs through the database asset table and manifest into the runtime's supported import pipeline. Keep unknown formats and missing dependencies visible. Do not overwrite original assets or saves.
Add an in-game feedback menu in this post-first-build batch. The menu should let the human report the current feature, build, database revision, reproduction steps, expected/actual behavior and permitted local evidence without leaving the game.
If code or asset integration requires another compile, combine assets and menu into one reviewed follow-up batch, refresh preflight and request fresh build approval. Data-only refresh is allowed only if the runtime already supports it. Do not promise that all asset changes avoid recompilation.
Keep reports in a local feedback queue or an owner-approved destination. Reports propose changes, not automatic edits to authoritative mechanics. Never expose secrets, private saves or proprietary attachments.
Current availability: this is the required project workflow, not a claim that every catalog submission or the workbook starter already implements an asset loader or in-game menu. A developer must implement missing runtime support before calling the project ready.
Ready when: the artifact identifies the assets it uses, the feedback menu exists in the agreed runtime scope and a human is ready to exercise it. AI does not launch gameplay or test the menu.
10 / HUMAN TEST ONLY
You play. You record. You decide.
Use a backup or disposable save. Note the exact build ID and environment.
A person runs the feature scenario with the recorded inputs and compares actual behavior to the reference.
The person checks documented boundary cases and performs any required software tests. AI does not launch tests, click through gameplay or supply invented results.
Record pass, fail or not tested. Include the tester and evidence. An untested feature stays untested.
Example: you start at 20 health, use the potion and see 25 instead of 30. That is a mismatch to report, not a reason to edit the executable.
Ready when: human observations are recorded against feature IDs. Even when all checks pass, proceed to documented acceptance rather than letting AI sign off.
11 / IN-GAME FEEDBACK → REVIEW QUEUE
Report the difference while playing.
The post-first-build runtime should provide a pause/settings-accessible feedback menu. Automatically attach the build ID, database revision and selected feature where possible, but let the human describe what actually happened. The starter does not include this menu. A temporary local report form can preserve observations while a developer implements it, but is not a claim that an in-game menu exists.
Feature ID: potion.small.use
Build ID: [the build you personally tested]
Database revision / asset manifest: [revision]
Reference version: [version]
Tester / date / platform: [fill in]
Scene / save / seed: [permitted reproduction context]
Steps: Start with 20 health and one small potion. Use it once.
Expected: Health 30, potion count 0.
Actual: [what you actually saw, not a guess]
Evidence: [permitted local screenshot or notes]
Severity / result: [severity] / pass / fail / not tested
Proposed table/row: [if known, not an automatic edit]
Status: open, awaiting human review
Store each report under a stable feedback ID, linked to its build, feature and database revision.
A human reviews the observation and proposed change. AI may organize the report, locate related rows and draft an old/new-value diff, but cannot invent results or accept its own correction.
Approved corrections enter the authoritative tables through the supported editor with evidence and revision history. Rejected or unresolved reports remain traceable.
Do not let the menu silently patch rules, execute code, recompile the game or publish attachments. Never include credentials, private saves or proprietary assets without permission.
Ready when: another person can understand the observation, identify the affected row and follow the recorded steps. Human approval, not an AI confidence score, controls the correction.
12 / IMPROVE THE AUTHORITATIVE TABLES
Fix the rule at its source.
Ask Pi: “Compare this human feedback with the authoritative rows and evidence. Propose a minimal correction, explain why, and show the old and new values. Do not patch game output, compile or test.”
A human reviews whether the observation justifies a specification correction.
Update the authoritative rows through the supported editor, preserving evidence and revision history.
If the rows were already correct, do not falsify them to compensate. Record a generator/runtime defect for a developer to fix generically. Do not add a one-off patch to generated game output.
Human feedback → reviewed spreadsheet/SQLite correction → preflight → explicit approval → recompile → human test ↶
Ready when: the human retests the new build and closes the feedback record, or records the remaining mismatch for another cycle.
13 / COMPLETION
Finish with evidence, not a promise.
A human accepts the agreed feature scope on the named build.
Every scoped feature has a human result. Remaining issues and untested environments are disclosed.
The authoritative data, source revision, build instructions and feedback history are preserved.
Package only material you may distribute, with licenses, requirements and plain-language run instructions.
A human separately approves publication. Keep rollback and original saves.
Ask Pi to draft the release notes from recorded evidence. Review them yourself. For sharing, use your own source/release hosting and follow the creator hosting guide and site terms. Modport resources explain the workflow. Listings do not grant permission to redistribute someone else's game or assets; server-hosted downloads remain subject to their separately configured access and publication policy.
Your outcome: either a completed learning matrix or, when a project-specific runtime exists, a human-accepted project. State which one you actually achieved.
The application around an AI model that lets it work with files and tools. Here, Pi.
Schema
The allowed table names, columns and value types.
Source of truth
The single editable record set that controls generated results.
Preflight
A specification readiness review, not a gameplay test.
Generator / runtime
The project-specific software that converts or consumes records to make behavior run.
Compile / recompile
Produce a runnable build, then produce another after approved changes.
Acceptance
A person's documented decision that the agreed scope is ready.
Setup sources reviewed October 4, 2026; SQLite/search and game-method update reviewed October 5, 2026. Use the official instructions for the release you install. This page is an instructional diagram, not screenshots of an integrated product or proof of end-to-end acceptance.