Repository navigation
Developer Guide
Welcome to the TokenPrint Developer Guide. This section is intended for engineers, researchers, and open-source contributors who want to modify the source code, add new features, or fix bugs.
TokenPrint is a complex application spanning multiple languages (Python, TypeScript) and paradigms (REST, WebSockets, React, WebGL). Without a clear map of how the codebase is structured and how to compile it, contributing can be daunting.
The repository is strictly divided into two root folders: backend/ and frontend/. They do not share dependencies, build systems, or languages.
Before you write any code, we highly recommend reading the Architecture and Visual Mapping documentation to understand the project's core philosophy: Never fabricate data.
- Repository Structure: Where files live.
- Building From Source: How to compile and run in dev mode.
- Code Style: Linters, formatters, and architectural rules.
- Adding a New Visualization: How to tie new 3D geometry to tensor data.
- Adding a New Model: How to support new architectures like DeepSeek.
- Creating UI Components: How to add buttons and panels to the AppShell.
- Debugging: How to use TokenPrint's own debug tools on itself.
- Performance Tips: How to keep WebGL running at 60fps.
flowchart LR
Dev([Developer]) --> Backend[Python Backend]
Dev --> Frontend[TypeScript Frontend]
subgraph Backend Setup
Backend --> Venv[Virtual Environment]
Venv --> PyTorch[PyTorch Engine]
end
subgraph Frontend Setup
Frontend --> NPM[Node Package Manager]
NPM --> Next[Next.js Server]
end
| Previous | Home | Next |
|---|---|---|
| Event System | Home | Repository Structure |
TokenPrint Wiki | Home | Getting Started | User Guide | Concepts | Architecture | API | GitHub
TokenPrint is an interactive 3D visualization platform for exploring transformer architectures, tensors, and real-time LLM inference.
- User Guide
- Architecture Explorer
- Live Inference
- Tensor Inspector
- Camera Controls
- HUD
- Timeline
- Scene Navigation
- Transformer Concepts
- Tokenization
- Embeddings
- Positional Encoding
- RoPE
- Multi-Head Attention
- KV Cache
- LayerNorm
- Feed Forward Network
- Residual Connections
- Logits
- Softmax
- Sampling
- Autoregressive Generation
- Visualization System
- Scene Graph
- Geometry
- Materials
- Animation System
- Color Mapping
- Camera System
- Interaction Model
- Architecture
- Overall Architecture
- Frontend
- Backend
- WebSocket Protocol
- Data Pipeline
- Renderer
- Event System