Home / Claude Code mods / Context & memory / laya-compaction

laya-compaction

laya-compaction is a Claude Code mod by tristankenney that verbatim context compaction for Claude Code, scored by a local Laya model.

Updated 2026-09-28

What is laya-compaction?

laya-compaction is a Claude Code mod by tristankenney that verbatim context compaction for Claude Code, scored by a local Laya model. It is listed under Context & memory and has no public popularity data yet.

TypeClaude code mod
Authortristankenney
Repositorytristankenney/laya-compaction
Popularityno public popularity data yet
CategoryContext & memory
SecurityReview before installing (72/100)
Rank#4,883 of 5,272 Claude Code mods; #455 in Context & memory
Last commit2026-09-28
Hooks2 events
Seescompaction
Draws onnothing

Is laya-compaction safe to install?

laya-compaction scores 72/100 on the MCPMods security check: Review before installing. Things to review: sends data over the network; reads environment variables. It passed 5 of 8 checks.

Mod footprints come from claude plugin validate, which lists every event a mod hooks and every API call it makes without running it.

CheckResult
Sends data over the networkReview
Starts no processesPass
Writes no files or configPass
Reads environment variablesReview
Only sees the events it hooksPass
Doesn't drive ClaudePass
Passes claude plugin validatePass
No license detectedNote

API calls in its code

CallWhat it means
$.env.getreads env vars
$.http.fetchnetwork requests
$.session.compactdrives Claude
$.session.usage
$.settings.readreads settings
$.ui.logdraws interface
$.ui.toastdraws interface

How do I install laya-compaction?

  1. Check your Claude Code version. Mods need Claude Code 2.1.287 or later and are on by default.
    claude --version
  2. Read its footprint. This lists every event it hooks and every API call it makes, without running it.
    git clone https://github.com/tristankenney/laya-compaction
    claude plugin validate ./laya-compaction/.
  3. Install it. Run this in your terminal, then /reload-plugins in an open session.
    claude plugin marketplace add tristankenney/laya-compaction && claude plugin install laya-compaction@laya-compaction

Or ask Claude to set it up

Paste this into Claude Code and it installs laya-compaction for you:

Install the "laya-compaction" Claude Code mod from https://github.com/tristankenney/laya-compaction. Run claude plugin validate on it first and show me what it can access before you enable it.