Skip to content

Repository files navigation

⚔ S P I R E S C O P E ⚔

Card lookup · Deck analysis · Live run tracking · Analytics for Slay the Spire 2

CI Python 3.11+ License: MIT Tests Coverage

A local-first intelligence dashboard for Slay the Spire 2 — card/relic/enemy lookup, deck analysis, live run tracking, run history, analytics, community meta, and strategy guides. No cloud, no accounts, no telemetry. Runs entirely on your machine.

Game data: current through STS2 v0.110.0 (refreshed 2026-08-08). Refresh anytime with python -m sts2 update.

SpireScope Dashboard — your runs, your stats, your data

SpireScope Live Run Tracker — real-time deck, HP, and floor tracking

SpireScope Card Browser — all 639 cards with filters and search

Features

Current With Every Patch (v3.0)

  • Self-updating game data — a multi-source pipeline (slaythespire2.gg primary, slaythespire.wiki.gg secondary, save-file discovery third) keeps cards, relics, and potions current; a source run offers new data bundles on startup for one-click, checksum-verified install — no app update needed. Packaged builds keep that check off unless you set SPIRESCOPE_CHECK_UPDATES=1, so a downloaded copy makes no unsolicited network call; python -m sts2 update refreshes on demand either way.
  • Patch-era analytics — every run resolves to a named patch era. Default views scope to the current patch with an all-time toggle; reworked cards and relics carry "Changed in ..." markers with before/after win-rate and pick-rate comparisons (sample-size guarded).
  • Enchantment display — enchanted cards show their enchantment in the live tracker and run history.
  • Main vs beta awareness — runs badge their game branch; beta-only content is chipped; filter analytics by branch.
  • Merged save history — vanilla and modded save trees merge into one deduplicated history (the game copies saves between them since v0.108.0); runs carry a vanilla/modded origin filter.
  • Badges — earned badges with bronze/silver/gold tiers on the Records page.
  • Languages — switch under Settings. Navigation and settings are translated into fifteen languages (most page bodies are still English); card, relic and enemy text can be translated too with one command. See Languages.

Browse & Research

  • Card Browser — All cards across 5 characters with filters by character, type, rarity, cost, and keyword. Paginated (30 per page).
  • Relic & Potion Browser — Browse and filter all relics and potions
  • Enemy Guides — Boss patterns, elite strategies, and encounter tips
  • Event Guide — Optimal choices for every event
  • Strategy Guides — Per-character archetypes, key cards, key relics, and general tips

Play & Track

  • Live Run Tracker — Real-time dashboard via Server-Sent Events (SSE) — no page reloads. Shows deck, relics, potions, HP, floor history, counter-cards, synergy hints, danger alerts, encounters won, and events encountered.
  • Deck Analyzer — Select cards to get archetype detection, synergy analysis, weakness identification, and suggestions. Save/load decks to localStorage.
  • Run History — Floor-by-floor breakdown with HP tracking, card picks, cards offered (what you rejected), potions gained, monsters fought, gold per floor, and damage taken. Visual HP timeline chart. Import/export runs as JSON or standalone HTML.
  • Run Comparison — Side-by-side comparison of two runs with deck diff, relic diff, and stat comparison
  • Collections — Track card/relic discovery progress with ascension filtering
  • Epochs — Track all 57 epoch unlock requirements, see what's locked/unlocked, filter by category and character; deprecated epochs are marked and never suggested
  • Co-op Support — Track any player in a multiplayer run via ?player=N

Analyze & Compete

  • Analytics — Aggregate stats: per-character win rates, floor survival, card pick rates, HP curves, death floor heatmaps, and causes of death. Filter by ascension level, game version, or time range. Boss matchup intelligence, per-character relic tiers, and card pick heatmaps.
  • Personal Records — Hall of fame with fastest win, highest ascension, biggest/smallest deck, flawless bosses, per-character breakdowns, and notable achievements
  • Per-Act Breakdown — Damage, card picks, deaths, and gold tracked separately for Act 1/2/3
  • Combat Efficiency — Average turns per fight type with scaling trend analysis and turns-vs-damage correlation
  • Archetype Detection — Auto-classify decks into archetypes (Strength Scaling, Poison, etc.) with per-archetype win rates
  • Card Pick Timing — When you pick cards: early (floors 1-10), mid (11-25), or late (26+)
  • Encounter Danger Ratings — Danger grades (Low/Medium/High/Extreme) for every encounter based on your damage history
  • Gold Economy — Track gold earned, gold at death, peak gold, and win-vs-loss gold comparison
  • Co-op Analytics — Compare multiplayer vs solo win rates (shown only when co-op runs exist)
  • Healing Sources — Breakdown of HP recovery by source: rest sites, combat, and passive/relic healing
  • Boss Matchups — Win rate, average damage, and fight count per boss, broken down by character
  • Relic Tiers by Character — Top relics by win rate for each character
  • Card Pick Heatmap — Pick rate vs win rate grid — green means pick and win, red means pick and lose
  • Card Regret Analysis — Cards you pick in losses but skip in wins, helping identify bad picks
  • Win Streak Tracker — Prominent current win streak display on the home page
  • Next Epoch Suggestions — Upcoming epochs you haven't unlocked yet with requirements and rewards
  • Community Meta — Tier lists and strategy guides from the Steam community, community-voted card tiers, aggregate player stats with import/export
  • Global Search — Fuzzy search with "Did you mean?" suggestions across all entities

Advanced Analytics (v2.9.3)

  • The Graveyard — Every dead run gets a procedural epitaph: "Had 4 potions. Used none of them." Visit /graveyard to see your memorial wall.
  • Ghost Run Comparison — Speedrun-style splits against your best run. See HP and gold deltas floor by floor during live runs. Green arrows = ahead, red = behind.
  • Tilt Detection — Tracks session momentum and warns when you're on a losing streak: "Your last 4 runs averaged floor 11. Your session average is 23. Consider a break."
  • Anti-Pattern Detection — Named recurring mistakes: "The Hoarder" (unused potions), "The Greedy Builder" (oversized decks), "The Coward" (skipping elites).
  • Deck Health Score — Synergy graph analysis scoring deck coherence from 0-100. Identifies orphan cards with zero synergy connections.
  • Archetype Drift — Alerts when your card picks drift away from your deck's archetype mid-run.
  • Cascade Map — Open a completed run to see, for each card you picked, how damage taken, fight length, and HP changed afterwards. Observational before/after comparison — later floors are harder, so it shows what happened after a pick, not what the pick caused.
  • Prophecy Engine — Pre-run predictions based on your history: win probability, danger zone floors, and strategic recommendations. Shown on the home page and graded against the outcome on the run detail page.
  • Hypothesis Lab — Register strategic beliefs ("Skipping elites helps") and test them with a Beta-Binomial model across your runs: posterior win rates per arm and the probability your history leans that way. An association in your own runs, not a controlled result.
  • Rivalry Seeds — Export your run, share the seed with a friend, import their run, and compare decisions against your own attempt on that seed.
  • Run Integrity — SHA-256 checksum over a run's complete record, shown on the run detail page and embedded in every export; imports are re-checked against it. Tamper evidence, not proof of authorship.

Customize & Extend

  • Keyboard Shortcuts — Press ? for shortcut help, navigate pages with single keys, / to search
  • Dark/Light Theme — Dark gothic fantasy aesthetic (Cinzel serif font, warm gold/crimson palette) with a warm parchment light mode toggle
  • Mod Support — Load custom cards, relics, and enemies from JSON files in a mods directory
  • Content Creator API — Paginated JSON endpoints with CSV export and optional API key bypass
  • User Guide — In-app guide covering setup, features, and troubleshooting

Quick Start

Download (No Python Required)

Download Spirescope for Windows — extract the zip, open the Spirescope folder and double-click Spirescope.exe. Your browser opens automatically; leave the console window open while you use it, since closing it stops the app. (If the browser doesn't open, go to http://127.0.0.1:8000 yourself.) A macOS build (Spirescope-macos.zip) is also attached to each release. All archives ship with .sha256 checksum files.

Windows may warn you, or block the file outright ("contains a virus or potentially unwanted software"). This is a false positive on unsigned PyInstaller apps — the packaging format, not the contents. Read docs/ANTIVIRUS.md for why it happens, how to verify the download yourself with the published SHA-256, and how to run from source instead if you'd rather not touch the executable at all.

SpireScope is open source, local-only by default, and the packaged release avoids the UPX-compressed hidden-window profile that triggers extra false positives. Builds are produced only by GitHub Actions from tagged commits in this repository, and GitHub Releases is the only official download source.

macOS will refuse to run the download until you clear the quarantine flag. The build is not signed or notarized, so Gatekeeper blocks it — depending on how you open it you'll see "cannot be opened because the developer cannot be verified", "is damaged and can't be opened", or simply nothing at all. After extracting, run this once:

xattr -dr com.apple.quarantine /path/to/Spirescope

Then launch ./Spirescope from that folder. Only do this for downloads you have verified — check the published .sha256 first. If you'd rather not, running from source works on macOS with no quarantine issue.

If you're cautious about unsigned Windows apps, that's fair — and running from source (below) sidesteps the issue entirely.

From Source

macOS / Linux:

git clone https://github.com/thequantumfalcon/Spirescope.git && cd Spirescope
python3 -m venv .venv && source .venv/bin/activate
pip install -e .
spirescope

Windows (PowerShell or cmd):

git clone https://github.com/thequantumfalcon/Spirescope.git
cd Spirescope
python -m venv .venv
.venv\Scripts\activate
pip install -e .
spirescope

(The venv matters: modern Python installs — macOS Homebrew, Debian 12+, Ubuntu 23.04+ — refuse system-wide pip install per PEP 668.)

Or run directly:

python -m sts2

Opens your browser at http://127.0.0.1:8000.

Build Executable

pip install -e ".[dev]"
python build_exe.py

Output: dist/Spirescope/Spirescope.exe — zip the entire dist/Spirescope/ folder and share it. Local builds also write dist/SHA256SUMS.txt for checksum verification.

Docker

export STS2_AUTH_TOKEN=$(openssl rand -hex 24)
echo "Your token: $STS2_AUTH_TOKEN"
docker compose up --build

The bundled compose file publishes on 127.0.0.1 only, keeps state in a named volume, and requires STS2_AUTH_TOKEN — inside a container the app binds a non-loopback interface, and network binds always require the token (open http://127.0.0.1:8000/?token=<your token> once per browser). With plain docker run:

docker build -t spirescope .
docker run -p 127.0.0.1:8000:8000 -e STS2_AUTH_TOKEN=<long random string> spirescope

Never publish the port as a bare -p 8000:8000 on a machine others can reach: Docker binds that on every interface, and the dashboard serves your complete run history to anyone holding the token — or, with STS2_ALLOW_UNAUTHENTICATED=1, to anyone at all. Use TLS or a reverse proxy for anything beyond a trusted LAN. To see your runs in the container, mount your save directory read-only (see the commented examples in docker-compose.yml).

Languages

Pick a language under Settings. That translates the shared chrome — navigation, buttons and the settings page. Most page bodies are still English; contributions there are welcome. It ships in fifteen: English, Simplified Chinese, Traditional Chinese, German, Spanish, Latin American Spanish, French, Italian, Japanese, Korean, Polish, Brazilian Portuguese, Russian, Thai and Turkish. English and Traditional Chinese are reviewed; the others are drafts, and corrections from native speakers are welcome.

Card, relic, potion, enemy and event text is separate, because that text belongs to the game. To see it in your language, run this once:

spirescope localize          # or: python -m sts2 localize

It reads the language files from the copy of Slay the Spire 2 already installed on your machine and writes them to sts2/locales/content/. Nothing is downloaded and nothing is sent anywhere; the game directory is only read from, never written to. Restart Spirescope and card text follows your language setting, with search matching the translated names.

spirescope localize --list          # which languages your install offers
spirescope localize --lang de,ja    # only these

A standard installation offers thirteen languages besides English. Because the text comes from your own install, it stays in step with whatever game version you have rather than going stale. Anything the game does not translate — and any card added since your installed version — stays in English.

Why SpireScope?

Unlike cloud trackers, SpireScope runs entirely on your machine -- your run data never leaves your PC. Unlike browser extensions, it works on any OS and doesn't require game mods. Unlike the wiki, it knows your specific run history and tracks how your win rate changes across patches, characters, and ascension levels. And unlike anything else in the STS2 ecosystem, it's fully open source.

Works Without STS2 Installed

The card browser, relic browser, enemy guides, event guides, deck analyzer, and strategy guides all work without any save files. If you're curious about the game before buying, SpireScope is a full reference tool.

Using with Mods

SpireScope watches both vanilla and modded save trees: run history is merged and deduplicated across them, and live tracking follows whichever tree is freshest. If you use multiple mods, install UnifiedSavePath to merge both paths into one location.

  • Vanilla: %APPDATA%\SlayTheSpire2\steam\<id>\profile1\saves\
  • Modded: %APPDATA%\SlayTheSpire2\steam\<id>\modded\profile1\saves\

Streamer Mode / OBS Browser Source

SpireScope's live run tracker works as an OBS browser source. Two options:

  • Full view: Add http://127.0.0.1:8000/live as a Browser Source — full dashboard with all coaching features
  • Overlay mode: Add http://127.0.0.1:8000/overlay — minimal transparent HUD showing character, floor, HP bar, top cards, and danger alerts. Designed for always-on-top windows or small OBS overlays.

Both update in real time via SSE — no page reloads, no stream interruption. Use ?player=N for co-op runs to track a specific teammate.

Steam Deck

SpireScope runs on Steam Deck via the Linux source install. From Desktop Mode (the venv matters — SteamOS refuses system-wide pip install per PEP 668):

python3 -m venv ~/.spirescope-venv && source ~/.spirescope-venv/bin/activate
pip install -e .
spirescope

Saves live under (Proton): ~/.local/share/Steam/steamapps/compatdata/2868840/pfx/drive_c/users/steamuser/AppData/Local/SlayTheSpire2/

If auto-detection doesn't find them, set STS2_SAVE_DIR to the profile's saves directory itself — steam/<steam-id>/profile1/saves/ under that path — not the tree root; the variable is used verbatim as the saves directory.

CLI Commands

spirescope              # Start the web dashboard (default)
spirescope serve        # Same as above
spirescope serve --browser     # Force opening browser automatically
spirescope serve --no-browser  # Start without opening browser
spirescope update       # Fetch latest data from the wiki + saves
spirescope update --save-only  # Discover from saves only (no network)
spirescope community    # Fetch community data from Steam
spirescope export       # Export aggregate stats to JSON file
spirescope reset-stats  # Delete aggregate stats file
spirescope localize --list        # List languages your game install offers
spirescope localize               # Translate card/relic text from your install
spirescope localize --lang de,ja  # ...only these languages
spirescope sync-up      # Upload local aggregate stats to sync service
spirescope sync-down    # Download and merge community stats from sync service
spirescope --help       # Show usage
spirescope --version    # Show version

Configuration

Variable Description Default
STS2_SAVE_DIR Path to your STS2 save directory Auto-detected
STS2_GAME_DIR Path to STS2 game install Auto-detected
STS2_MODS_DIR Path to mods directory (JSON files) mods/ under STS2_STATE_DIR; beside the executable in packaged builds
STS2_HOST Server bind address 127.0.0.1
STS2_PORT Server port 8000
STS2_AUTH_TOKEN Required credential for every request on a non-loopback bind (header X-Auth-Token, or ?token= once per browser) None — non-loopback serve refuses to start without it
STS2_ALLOW_UNAUTHENTICATED 1 explicitly serves a non-loopback bind with no credential — trusted reverse proxy/network only Off
STS2_ALLOWED_HOSTS Comma-separated Host header values this server answers to. Requests carrying any other host are refused, which is what stops a page that has repointed its own hostname at your machine from talking to a loopback install Loopback names on a loopback bind; unrestricted on a network bind, where only you know the address it is reached by
STS2_LOG_FILE Path to the game's godot.log for live tracking Auto-detected
STS2_COMMUNITY_SOURCES Community sources: all, steam all
STS2_SYNC_URL Sync service URL (opt-in) Disabled
STS2_SYNC_KEY API key for sync service None
SPIRESCOPE_API_KEY Optional API key for rate limit bypass None
SPIRESCOPE_ADMIN_TOKEN Token for /api/reload and /api/reset/stats Unset — admin endpoints disabled
SPIRESCOPE_OPEN_BROWSER 1/0 override for browser auto-open on serve Enabled
SPIRESCOPE_CHECK_UPDATES 1/0 override for automatic GitHub update checks, both directions: 1 enables them for packaged builds, 0 disables them for source installs Source: enabled, packaged build: disabled
STS2_CORS_ORIGINS Comma-separated CORS allowed origins Localhost only
STS2_LANG Interface language code, e.g. de (see Languages) Settings choice, else en
STS2_STATE_DIR Your settings, stats and saved hypotheses %APPDATA%\SpireScope, ~/Library/Application Support/SpireScope, or $XDG_DATA_HOME/SpireScope
STS2_DATA_DIR Game data directory (cards, relics, enemies) Bundled data; beside the executable in packaged builds

Save File Location

  • Windows: %APPDATA%\SlayTheSpire2\steam\<steam_id>\profile1\saves\
  • Windows (modded): %APPDATA%\SlayTheSpire2\steam\<steam_id>\modded\profile1\saves\
  • macOS: ~/Library/Application Support/SlayTheSpire2/steam/<steam_id>/profile1/saves/
  • Linux: ~/.local/share/SlayTheSpire2/steam/<steam_id>/profile1/saves/

SpireScope auto-detects both vanilla and modded paths; history merges across them and live tracking follows the freshest.

API Endpoints

Endpoint Method Description
/api/search?q= GET Search all entities
/api/cards/{card_id} GET Card details + stats (JSON)
/api/runs GET Run history (JSON, filterable by character/result)
/api/analytics GET Aggregate analytics (JSON)
/api/live?player=0 GET Current run state (JSON)
/api/live/stream?player=0 GET SSE stream of live run updates
/api/export/stats GET Export aggregate player stats (JSON)
/api/export/runs GET Export run history (CSV)
/api/import/stats POST Import/merge aggregate stats
/api/reload POST Hot-reload knowledge base (requires X-Admin-Token header)
/api/reset/stats POST Reset aggregate stats (requires X-Admin-Token header)
/overlay?player=0 GET Minimal overlay for OBS browser source or second monitor
/shutdown POST Gracefully stop SpireScope (localhost only)
/health GET Health check for monitors
/docs GET Interactive API documentation (Swagger UI)

Security

  • Non-loopback binds require authentication: every request must present STS2_AUTH_TOKEN (loopback stays zero-config; serve refuses a network bind with no token unless STS2_ALLOW_UNAUTHENTICATED=1 is set explicitly)
  • CSRF protection on every state-changing POST a browser can reach through a form, including /shutdown (loopback alone is not treated as proof of intent); the two admin-only JSON endpoints instead require an X-Admin-Token header, which a cross-origin page cannot set
  • Content-Security-Policy, X-Frame-Options, Referrer-Policy, X-Content-Type-Options
  • Per-IP rate limiting (60 req/min) when bound to a non-loopback address via STS2_HOST; skipped on loopback, where the server is single-user
  • Admin-token-gated reload endpoint (constant-time comparison); admin endpoints stay disabled until a token is configured
  • SSE connection caps (10 total, 3 per client) with 5-minute idle timeout
  • Jinja2 auto-escaping on all user-reflected input
  • Request body size limit enforced before parsing (2 MB), with tighter per-route caps on run and stats imports
  • Input validation on all query parameters
  • Anti-manipulation caps and counter invariants on aggregate stats merging

Code signing

Windows release builds are currently unsigned, which is why Windows Defender and SmartScreen may flag the download — a false positive on the packaging format rather than the contents. See docs/ANTIVIRUS.md to verify a download yourself or run from source instead.

Every release publishes a .sha256 checksum file alongside each archive, so a download can be checked against the checksum the build produced. (Local builds via build_exe.py additionally write a combined dist/SHA256SUMS.txt.)

Project Structure

sts2/
  __main__.py        # CLI entry point
  app.py             # FastAPI app, middleware, security headers
  routes.py          # All route handlers
  analytics.py       # Run analytics computation
  i18n.py            # Interface translation, content overlays
  localize.py        # Builds translated game text from your install
  sources.py         # Data source adapters for the update pipeline
  patches.py         # Patch manifest: what each game version changed
  community/         # Community data (Steam)
    __init__.py      # Orchestrator + re-exports
    _types.py        # Shared types, extraction functions
    _merge.py        # Weighted merge logic
    steam.py         # Steam data fetcher (reviews, guides, discussions)
  aggregate.py       # Aggregate stats computation and merging
  config.py          # Auto-detected paths and settings
  fetcher.py         # Data fetcher (wiki + save file discovery)
  knowledge.py       # Search, filter, synergy, and deck analysis engine
  logparser.py       # Game log tailer for live run tracking
  models.py          # Pydantic models for all game entities
  saves.py           # Save file parser (progress + run history + co-op)
  sync.py            # Aggregate sync client (upload/download)
  persist.py         # Atomic writes for the small state files
  updater.py         # Auto-update checker + data-bundle installer
  watcher.py         # File watcher with debounce + polling fallback
  graveyard.py, prophecy.py, hypothesis.py, rivalry.py, cascade.py,
  ghost.py, drift.py, spectral.py, integrity.py,
  behavior.py           # The advanced analytics modules
  data/              # JSON game data + mods
  templates/         # Jinja2 HTML templates (32 templates)
  static/            # CSS, fonts (Cinzel), images, JS
tests/               # pytest + pytest-asyncio, plus 15 Playwright browser tests

Requirements

  • Python 3.11+
  • Slay the Spire 2 (for save file features)

Disclaimer

SpireScope is a fan-made project and is not affiliated with, endorsed by, or associated with Mega Crit Games. Slay the Spire and Slay the Spire 2 are trademarks of Mega Crit Games. All game content and materials referenced within this tool are the property of their respective owners.

Acknowledgments

Card, relic, potion, and event data is derived from the community wiki at slaythespire.wiki.gg, available under CC BY-SA 4.0, and from the slaythespire2.gg reference site (scraped with their robots.txt permission, identified by a project-named User-Agent). Strategy guides for the Epochs system reference notes by NeonLightsMedia. UI typography uses Cinzel by Natanael Gama under the SIL Open Font License 1.1. Full third-party attributions are in THIRD_PARTY_NOTICES.md.

License

MIT

About

Local-first STS2 companion — card/relic/enemy browser, live run tracker, deck analyzer, run analytics, overlay mode. No cloud, no accounts. Open source.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

26 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages