β Buy me Claude Code credits or support a project! β
Every donation keeps the code flowing β these tools are built with your support.
AI-powered game trainer for Linux/Steam. Describe what you want in plain English β the AI finds it.
Classic Amiga trainer philosophy meets modern AI. Phantasm uses Claude to automate memory discovery, cheat generation, and post-update adaptation for Steam games running under Proton/Wine on Linux.
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β PHANTASM β
β β
β "I want infinite health" β
β β
β AI: Scanning for float values... β
β AI: Take some damage, then tell me. β
β AI: Found 3 candidates. Writing test value... β
β AI: Health locked at 100.0 β bound to F1. β
β β
β [F1] Infinite Health β [F2] Max Gold β [F3] No Fall β β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
- AI-Driven Cheat Discovery β Tell Claude what you want. It figures out the memory addresses, value types, and scan strategy automatically.
- Memory Scanner β Exact value, unknown initial, fuzzy float, and changed/unchanged scans across 2-4GB game processes in seconds.
- AOB Pattern Scanner β Array of bytes scanning with wildcard (
??) support for finding code signatures that survive game updates. - Code Patching β NOP sleds, forced branches, conditional jump removal. The AI understands x86/x64 assembly.
- Pointer Chain Resolution β Multi-level pointer chains with ASLR-aware module-relative base addresses.
- Freeze Loop β Background 60Hz write loop to lock values (health, ammo, gold) at their cheat values.
- Cheat Engine Import β Import
.CTfiles from Cheat Engine and forum posts directly into Phantasm's format. - Auto-Adaptation β When a game updates and addresses shift, the AI re-discovers them using AOB signatures.
- TUI (Terminal) β ratatui-based keyboard-driven interface with dashboard, scanner, AI chat, and cheat table views.
- Web Dashboard β Dark-themed browser UI at
localhost:13337with process manager, AI workspace, memory viewer, and cheat editor. - Hotkey System β Global hotkeys via
/dev/inputthat work even when the game has focus (Wayland compatible). - Proton/Wine Aware β Auto-detects Steam games running under Proton, resolves Windows-style module names.
- Rust 1.93+ (Arch:
pacman -S rust, or rustup.rs) - Linux with
/procfilesystem (any modern distro) - Root or CAP_SYS_PTRACE for memory access
- Anthropic API key for AI features (optional β scanner works without it)
git clone https://github.com/dpaschal/phantasm.git
cd phantasm
cargo build --releaseThe binary is at target/release/phantasm.
# List running Steam/Proton game processes
sudo phantasm ps
# Attach to a game by name or PID
sudo phantasm attach "Grim Dawn"
sudo phantasm attach 12345
# Launch the TUI (terminal interface)
sudo phantasm tui
# Launch the web dashboard
sudo phantasm web # default port 13337
sudo phantasm web -p 8080 # custom port
# Load a saved cheat table
sudo phantasm load ~/.config/phantasm/tables/grimdawn.toml
# Import a Cheat Engine table
sudo phantasm import trainer.ct
sudo phantasm import trainer.ct -o grimdawn.tomlNote:
sudois required for/proc/pid/memaccess. Alternatively, grantCAP_SYS_PTRACE:sudo setcap cap_sys_ptrace=eip target/release/phantasm
Set your Anthropic API key to enable AI features:
export ANTHROPIC_API_KEY="sk-ant-..."Then use the AI chat in the TUI (Tab 3) or web dashboard to describe what cheats you want.
phantasm (single binary)
βββ mem/ Memory engine
β βββ process Process attach, /proc/pid/mem, region enumeration
β βββ scanner Value scanning (exact, changed, fuzzy)
β βββ writer Write operations (single, freeze, toggle, patch)
β βββ pattern AOB signature scanning with wildcards
β βββ pointer Multi-level pointer chain resolution
β βββ freeze Background 60Hz write loop
βββ ai/ AI orchestrator
β βββ client Claude Messages API with tool use
β βββ strategy Tool dispatch (scan, read, write, disassemble)
β βββ adapter Post-update cheat table recovery
βββ cheat/ Cheat management
β βββ table CheatTable TOML serialization
β βββ entry Cheat definitions (value, patch, pointer chain)
β βββ hotkey Global hotkeys via evdev /dev/input
β βββ import Cheat Engine .CT file parser
βββ tui/ Terminal interface (ratatui)
β βββ views Dashboard, Scanner, AI Chat, Cheats
βββ web/ Web dashboard
βββ server axum REST API (localhost:13337)
βββ api 8 REST endpoints + WebSocket
βββ frontend Embedded dark-theme single-page app
Phantasm stores cheat tables as human-readable TOML files in ~/.config/phantasm/tables/:
[meta]
game = "Grim Dawn"
steam_app_id = 219990
executable = "Grim Dawn.exe"
version = "1.2.1.0"
created = "2026-02-18"
last_verified = "2026-02-18"
ai_adaptable = true
[[cheats]]
name = "Infinite Health"
description = "Locks player health at max"
hotkey = "F1"
enabled = false
[cheats.target]
type = "f32"
value = 100.0
mode = "freeze"
[cheats.target.pointer_chain]
base_module = "Game.dll"
base_offset = 0x01A3F4C0
offsets = [0x28, 0x10, 0xB8, 0x60]
[cheats.target.aob_signature]
pattern = "F3 0F 11 86 ?? ?? ?? ?? 48 8B 5C 24"
offset = 0
[[cheats]]
name = "No Fall Damage"
hotkey = "F3"
[cheats.target]
type = "bytes"
mode = "patch"
original = "0F 85 A3 00 00 00"
patched = "90 90 90 90 90 90"
[cheats.target.aob_signature]
pattern = "0F 85 ?? ?? ?? ?? F3 0F 10 45"
offset = 0Import .CT files from Cheat Engine or cheat forums:
# Import a .CT file β outputs a .toml cheat table
phantasm import my_trainer.ct
# Specify output path
phantasm import my_trainer.ct -o ~/.config/phantasm/tables/game.tomlPhantasm parses the CT XML format and converts:
- Variable types (Float, 4 Bytes, Double, etc.)
- Pointer chains (with CE's reversed offset order)
- AOB signatures
- Hotkeys (Windows virtual key codes to Linux key names)
The web dashboard runs at http://localhost:13337 and provides:
| Tab | Function |
|---|---|
| Processes | Detect and attach to running Steam/Proton games |
| AI Chat | Natural language cheat discovery with Claude |
| Scanner | Manual memory scanning with type selection |
| Cheats | View and toggle active cheat table entries |
| Tables | Browse and load saved cheat tables |
Dark theme with green/cyan accents β classic trainer aesthetic.
| Key | Action |
|---|---|
1-4 |
Jump to view (Dashboard/Scanner/Chat/Cheats) |
Tab |
Next view |
Shift+Tab |
Previous view |
q |
Quit |
F1-F12 |
Toggle cheats (configurable) |
Home |
Master toggle (all cheats on/off) |
Insert |
Show/hide TUI |
~/.config/phantasm/config.toml:
[general]
web_port = 13337
tui_toggle_key = "Insert"
master_toggle_key = "Home"
tables_dir = "~/.config/phantasm/tables"
[ai]
api_key_env = "ANTHROPIC_API_KEY"
model = "claude-sonnet-4-5-20250929"
max_tokens = 4096
[steam]
library_path = "~/.local/share/Steam/steamapps"
proton_aware = trueWhen you tell Phantasm "I want infinite health", the AI:
- Classifies the request β health is likely a float (f32), range 1-10000, decreases when taking damage
- Generates a scan plan β "take damage" β decreased scan β "heal" β increased scan β narrow candidates
- Executes using memory engine tools β scan, read, write, disassemble
- Creates a cheat entry β address, type, freeze value, hotkey, AOB signature for persistence
- Adapts after game updates β re-scans using saved AOB signatures to find new addresses
The AI has 8 tools at its disposal:
| Tool | Purpose |
|---|---|
scan_exact |
Find all addresses holding a specific value |
scan_changed |
Narrow by increased/decreased/unchanged |
read_address |
Read memory at an address |
write_address |
Write a value to memory |
list_regions |
Enumerate process memory regions |
aob_scan |
Signature scan with ?? wildcards |
resolve_pointer |
Follow a pointer chain |
disassemble |
Disassemble x86/x64 instructions |
# Run all 96 tests
cargo test
# Run specific test suites
cargo test --test mem_process # 19 tests β process attachment, maps parsing
cargo test --test mem_scanner # 22 tests β exact/changed value scanning
cargo test --test mem_pattern # 5 tests β AOB pattern scanning
cargo test --test mem_writer # 4 tests β write operations
cargo test --test mem_pointer # 2 tests β pointer chains
cargo test --test cheat_table # 3 tests β TOML serialization
cargo test --test cheat_hotkey # 11 tests β hotkey key name parsing
cargo test --test cheat_import # 7 tests β CT file import
cargo test --test ai_client # 13 tests β Claude API client
cargo test --test ai_strategy # 5 tests β tool dispatch routing- Requires elevated privileges (
rootorCAP_SYS_PTRACE) to read/write game memory - API key is read from environment variable, never stored in config files
- Web dashboard binds to
127.0.0.1only β no remote access - No telemetry, no phoning home, no data collection
- Cheat tables are local files β nothing is shared without explicit user action
Phantasm is designed for single-player and offline games. Using memory modification tools in online/multiplayer games may violate terms of service and result in bans. Use responsibly.
MIT License β see LICENSE for details.
Contributions welcome! Please open an issue or PR on GitHub.
Built with Rust, powered by Claude AI.