npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

deja-context

v0.1.8

Published

Stop AI coding sessions from bloating - compress, deduplicate, and stabilize LLM context

Readme

Deja — Claude Code 省钱神器

本地代理,自动压缩重复上下文,实测节省 40–90% token 消耗。公测中,免费使用。


效果

| 场景 | 节省 | |------|------| | 普通编码会话(10–15 轮工具调用) | 30–50% | | 长时间连续对话(20 轮+) | 50–90% | | 公测期间实测均值 | ~84% |

每节省 100 万 token ≈ 省 $3(Claude API 标准计费)。重度用户每月可省 $20–60。


安装

前提: Node.js 18+(下载

npm install -g deja-context

Windows(以管理员身份运行 PowerShell):

deja setup
deja service:install
deja tools:install all

macOS(Terminal):

deja setup
deja service:install
deja tools:install all

安装后打开 Claude Code,右下角出现悬浮窗即为成功。


原理

Deja 在本地运行一个代理(默认端口 9090),拦截发往 Claude API 的请求:

  1. 将超出最近 3 轮以外的 tool_result 内容替换为摘要
  2. 丢弃重复的历史文本块
  3. 上下文过长时自动切换到安全透传模式,保护对话质量

所有处理在本地完成,API key 不经过任何第三方服务器。


常用命令

deja status          # 查看运行状态和节省统计
deja dashboard       # 打开 Web 看板
deja logs --follow   # 实时日志
deja bypass on       # 手动暂停压缩(原样转发)
deja bypass off      # 恢复压缩
deja key:update --key NEW_KEY  # 更新 API key
deja stop            # 停止代理

支持的 AI 工具

| 工具 | Windows | macOS | |------|---------|-------| | Claude Code | ✅ | ✅ | | Cursor | ✅ | ✅ | | VS Code + Continue | ✅ | ✅ | | Codex CLI | ✅ | ✅ |


公测反馈

遇到问题或有功能建议,欢迎在 Issues 提交,请带上:

  • 操作系统和工具名称
  • deja status 输出
  • 问题描述

卸载

deja service:remove
deja tools:uninstall all
npm uninstall -g deja-context

License

BUSL-1.1。公测期间免费,正式收费前会提前通知。