Skip to content

theAstiv/token-saver-stack

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

token-saver-stack

One-command setup for a Claude Code token-savings stack. Installs and wires up four tools that reduce token usage at different layers.

Source code  ──→  context-link   (91% reduction — serve only exact symbols)
CLI output   ──→  RTK            (60-90% reduction — compress shell output)
Session memory ─→ MemStack       (persistent memory, skills, diary, vector recall)
API transport ──→ Headroom       (~34% reduction — compress in transit)
                      │
               MemStack auto-starts Headroom
Layer Tool Mechanism
Code intelligence context-link MCP server (stdio)
CLI compression RTK Bash tool hook (PreToolUse)
Session memory MemStack SessionStart/Stop/Pre/PostToolUse hooks
API compression Headroom HTTP proxy (auto-managed by MemStack)

Prerequisites

  • Claude Code installed
  • context-link already installed and indexed for your project
  • Python 3.10+
  • Git
  • macOS: Homebrew — Linux/Windows (Git Bash): curl

Install

Clone this repo, then run the installer from your project directory:

git clone <this-repo-url> token-saver-stack
cd /path/to/your/project
bash /path/to/token-saver-stack/install.sh

Or if you're already in the token-saver-stack directory:

bash install.sh

Flags

Flag Description
--project <path> Target project directory (default: current dir)
--dry-run Print every command without executing
--skip-rtk Skip RTK install and hook registration
--skip-memstack Skip MemStack, Headroom, and .claude symlink

Verify

bash verify.sh
bash verify.sh --project /path/to/project

Uninstall

bash uninstall.sh
bash uninstall.sh --project /path/to/project --dry-run

Removes: .claude symlink, RTK global hook, headroom-ai pip package. Prompts before deleting ~/memstack (contains diary and memory data).

What gets installed where

  • RTK hook~/.claude/settings.json (global, all projects)
  • Headroom → pip package; proxy auto-started by MemStack on session open
  • MemStack → cloned to ~/memstack; linked into each project via .claude symlink
  • context-link → not installed by this script (prerequisite); .mcp.json is created/verified

Daily workflow

cd /path/to/your/project
claude

Everything activates automatically. Before closing, say "save diary" so MemStack stores your session for next time.

To link MemStack to additional projects:

cd /path/to/another/project
bash /path/to/token-saver-stack/install.sh

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages