{"id":48848911,"url":"https://github.com/masonwyatt23/ashlr-plugin","last_synced_at":"2026-04-15T07:02:26.186Z","repository":{"id":351461077,"uuid":"1211085901","full_name":"masonwyatt23/ashlr-plugin","owner":"masonwyatt23","description":"Open-source Claude Code plugin — token-efficient Read/Grep/Edit via @ashlr/core-efficiency. MIT.","archived":false,"fork":false,"pushed_at":"2026-04-15T06:07:17.000Z","size":700,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-15T06:13:22.642Z","etag":null,"topics":["anthropic","ashlrcode","bun","claude","claude-code","claude-code-plugin","mcp","mcp-server","token-efficiency","typescript"],"latest_commit_sha":null,"homepage":"https://masonwyatt23.github.io/ashlr-plugin/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/masonwyatt23.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-04-15T03:49:59.000Z","updated_at":"2026-04-15T06:07:20.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/masonwyatt23/ashlr-plugin","commit_stats":null,"previous_names":["masonwyatt23/ashlr-plugin"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/masonwyatt23/ashlr-plugin","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/masonwyatt23%2Fashlr-plugin","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/masonwyatt23%2Fashlr-plugin/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/masonwyatt23%2Fashlr-plugin/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/masonwyatt23%2Fashlr-plugin/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/masonwyatt23","download_url":"https://codeload.github.com/masonwyatt23/ashlr-plugin/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/masonwyatt23%2Fashlr-plugin/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31830158,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-14T18:05:02.291Z","status":"online","status_checked_at":"2026-04-15T02:00:06.175Z","response_time":63,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["anthropic","ashlrcode","bun","claude","claude-code","claude-code-plugin","mcp","mcp-server","token-efficiency","typescript"],"created_at":"2026-04-15T07:02:25.309Z","updated_at":"2026-04-15T07:02:26.178Z","avatar_url":"https://github.com/masonwyatt23.png","language":"TypeScript","readme":"# ashlr-plugin\n\n[![landing page](./docs/assets/og.png)](https://plugin.ashlr.ai/)\n\n**Landing page:** [plugin.ashlr.ai](https://plugin.ashlr.ai/) · **Core library:** [`@ashlr/core-efficiency`](https://github.com/masonwyatt23/ashlr-core-efficiency) · **License:** MIT\n\nOpen-source Claude Code plugin that **cuts token usage** via genome-aware file retrieval, 3-tier context compression, and provider-aware prompt budgeting. Alternative to [WOZCODE](https://wozcode.com). Mean **−79.5%** savings on files ≥ 2 KB ([benchmarks](./docs/benchmarks.json)).\n\n## What it does\n\nReplaces Claude Code's built-in file/shell/SQL workflows with optimized MCP tools that return **fewer tokens per call** while preserving the information the agent actually needs:\n\n| Tool | Mechanism | Typical saving |\n|------|-----------|----------------|\n| `ashlr__read` | Snips tool-result blobs \u003e 2000 chars using `snipCompact` | **−79.5%** on files ≥ 2 KB ([benchmarks](./docs/benchmarks.json)) |\n| `ashlr__grep` | Genome-aware relevance filtering when `.ashlrcode/genome/` exists; ripgrep fallback | 40–80% on projects with a genome |\n| `ashlr__edit` | In-place search/replace with diff summary only; strict-by-default for safety | 20–50% on structured edits |\n| `ashlr__sql` | SQLite + Postgres in one call. `explain`, `schema` modes. CSV-baseline savings math | ~2,300 tok / query on 100+ row result sets |\n| `ashlr__bash` | Shell with stderr-safe auto-compression + structured summaries for `git status`, `ls`, `ps`, `npm ls` | 60–85% on verbose-output commands |\n\nPlus three agents that mirror the WOZCODE tri-agent pattern:\n\n| Agent | Model | Role |\n|-------|-------|------|\n| `ashlr:code` | sonnet | Main coding agent. Delegates when appropriate. |\n| `ashlr:explore` | haiku | Read-only codebase exploration (cheap, fast). |\n| `ashlr:plan` | haiku | Architecture + implementation planning (cheap, fast). |\n\nAnd **four hooks** that make savings automatic instead of opt-in:\n\n| Hook | Event | What it does |\n|------|-------|--------------|\n| `tool-redirect` | PreToolUse on Read/Grep/Edit | Nudges the agent to use the `ashlr__*` equivalent — savings become automatic, not reliant on the agent remembering. |\n| `commit-attribution` | PreToolUse on Bash | Rewrites `git commit -m \"...\"` to append `Assisted-By: ashlr-plugin`. Skips if `Co-Authored-By:` / `Assisted-By:` is already present. Toggle off via `ashlr.attribution: false`. |\n| `edit-batching-nudge` | PostToolUse on Edit | After 3 edits in the same 60-second window, nudges the agent to batch — real ~40% token saving on repeat-edits. |\n| `session-start` | SessionStart | Once-per-day activation notice. |\n\nPlus a **status-line integration** (`scripts/savings-status-line.ts`) that shows session + lifetime token savings live in the Claude Code status bar. Install with `bun run ~/.claude/plugins/ashlr-plugin/scripts/install-status-line.ts`.\n\n## Install\n\n**Prerequisites:** [bun](https://bun.sh) ≥ 1.3 and Claude Code. No account, no API key.\n\n### 🪄 Fastest — one-liner\n\n```bash\ncurl -fsSL plugin.ashlr.ai/install.sh | bash\n```\n\nThen inside Claude Code:\n\n```\n/plugin marketplace add masonwyatt23/ashlr-plugin\n/plugin install ashlr@ashlr-marketplace\n```\n\nRestart Claude Code. Done.\n\n### 🧠 Ask Claude Code to do it\n\nCopy and paste this into any Claude Code session:\n\n```\nInstall the ashlr-plugin for me:\n\n1. Run in a terminal:\n   curl -fsSL plugin.ashlr.ai/install.sh | bash\n\n2. Then inside this session, run these two slash commands:\n   /plugin marketplace add masonwyatt23/ashlr-plugin\n   /plugin install ashlr@ashlr-marketplace\n\n3. Restart this Claude Code session, then verify:\n   /ashlr-status\n```\n\nClaude Code runs the shell command, then the slash commands, then asks you to restart.\n\n### 🔨 Fully manual (if you want to see every step)\n\n```bash\n# 1. Clone to Claude Code's plugin cache\ngit clone https://github.com/masonwyatt23/ashlr-plugin \\\n  ~/.claude/plugins/cache/ashlr-marketplace/ashlr\n\n# 2. Install MCP deps (or skip — the SessionStart hook auto-installs on first run)\ncd ~/.claude/plugins/cache/ashlr-marketplace/ashlr \u0026\u0026 bun install\n\n# 3. Inside Claude Code\n#   /plugin marketplace add masonwyatt23/ashlr-plugin\n#   /plugin install ashlr@ashlr-marketplace\n\n# 4. Restart Claude Code, then verify\n#   /ashlr-status\n```\n\n### Verify it's working\n\nLook for **`ashlr:code`** on the right side of the input field — that's the badge confirming the MCP server connected. Or run:\n\n```\n/ashlr-status     # plugin health + core library version + genome detection\n/ashlr-savings    # running token-savings total\n/ashlr-benchmark  # benchmark against your current project\n```\n\n### About the auto-install\n\nSince v0.3.0, the `SessionStart` hook detects a missing `node_modules/` and runs `bun install` transparently on first session load. You shouldn't need to `bun install` yourself.\n\n## Commands\n\n| Command | Description |\n|---------|-------------|\n| `/ashlr-savings` | Show estimated tokens saved this session and lifetime |\n| `/ashlr-settings` | View or change plugin settings (attribution, toolRedirect, statusLine toggles, etc.) |\n| `/ashlr-status` | Plugin status + MCP server health + genome detection |\n| `/ashlr-recall` | Recall saved user context and preferences from `~/.ashlr/recall.json` |\n| `/ashlr-update` | `git pull` the plugin, `bun install`, and report what changed |\n| `/ashlr-benchmark` | Run the benchmark harness against your current project |\n\n## How the efficiency tech works\n\nAll three optimizations live in the shared `@ashlr/core-efficiency` library, which is also used by Mason's standalone CLI [`ashlrcode`](../ashlrcode). One implementation, two consumers.\n\n- **Genome RAG** — `.ashlrcode/genome/` stores a sectioned, evolving project spec. Instead of dumping full files into context, the plugin retrieves only task-relevant sections via TF-IDF or Ollama-powered semantic search.\n- **3-tier compression** — `autoCompact` (LLM summarize old turns) → `snipCompact` (truncate tool results \u003e 2KB) → `contextCollapse` (drop short/duplicate messages).\n- **Provider-aware budget** — system prompt = 5% of the provider's context limit, capped at 50K. Anthropic 200K → 10K budget; xAI 2M → 50K budget.\n\nSee [`../ashlr-core-efficiency`](../ashlr-core-efficiency) for the library internals.\n\n## Status\n\n**v0.1.0 scaffold.** Directory structure, manifests, agent definitions, MCP server scaffold, and slash commands are in place. The MCP server's `ashlr__read` / `ashlr__grep` / `ashlr__edit` tools are functional stubs; they wire through `@ashlr/core-efficiency` primitives but are not yet benchmarked against WOZCODE.\n\nRoadmap before v1.0:\n- [ ] Benchmark suite comparing tokens-per-task vs Claude Code defaults and WOZCODE\n- [ ] Savings tracker persistence (`~/.ashlr/stats.json`)\n- [ ] Hook: on session-start, announce plugin activation + savings\n- [ ] Auto-delegation hints in `ashlr:code` prompt so it correctly offloads to `ashlr:explore` / `ashlr:plan`\n- [ ] Publish to npm and register with Claude Code marketplace\n\n## License\n\nMIT — [LICENSE](./LICENSE).\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmasonwyatt23%2Fashlr-plugin","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmasonwyatt23%2Fashlr-plugin","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmasonwyatt23%2Fashlr-plugin/lists"}