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

@chouchiu/localite

v1.0.2

Published

Minecraft Mod 简体中文汉化补全工具 — 自动检测未汉化条目,调用 DeepSeek 生成高质量翻译并输出补全资源包

Readme

localite

Minecraft Mod 简体中文汉化补全工具——自动检测实例中未汉化的 Mod,结合 CFPA 术语表MC 百科 上下文,调用 DeepSeek 大模型生成高质量翻译,输出补全资源包。

[!CAUTION] 翻译由 AI 模型自动生成,不对翻译质量做任何保证。请自行审核翻译结果。

特性

  • 自动扫描 Minecraft 实例(MultiMC / PrismLauncher 或标准目录结构),定位缺失的汉化条目,支持 Fabric / Quilt 和 Forge / NeoForge
  • 匹配版本下载 CFPA 社区汉化包作为基线,拉取 CFPAOrg/Glossary 术语表保证翻译风格统一
  • 查询 MC 百科页面辅助模型理解 Mod 背景
  • DeepSeek 批量翻译,支持思考模式(off / high / max),可配置并发
  • 智能保护 Minecraft 格式化代码(%s{0}§a 等)
  • API Key 通过操作系统凭据库加密存储,永不明文落盘
  • 基于 OpenTUI 的终端交互界面,键盘全操作

前置要求

安装

一键安装(推荐):

# Linux / macOS
curl -fsSL https://raw.githubusercontent.com/ChouChiu/localite/main/install.sh | bash

# Windows(PowerShell)
irm https://raw.githubusercontent.com/ChouChiu/localite/main/install.ps1 | iex

手动安装:

# 1. 安装 Bun:https://bun.sh
# 2. 全局安装 @chouchiu/localite
bun install -g @chouchiu/localite

临时使用(无需安装):

bunx @chouchiu/localite

快速开始

localite

在 TUI 界面中,F2 自动检测实例 → F5 开始翻译。翻译完成后,补全资源包输出到当前目录。

按键参考

| 按键 | 功能 | |------|------| | F2 | 自动检测 Minecraft 实例 | | F3 | 手动浏览文件系统选择实例目录 | | F5 | 开始扫描与翻译 | | Tab / Shift+Tab | 切换表单字段 | | / | 切换选项(加载器 / 思考模式) | | Esc / Ctrl+C | 退出 |

目录选择器: 浏览,Enter 进入子目录,S 选择当前目录, / Backspace 返回上级,Esc 回到设置页。

翻译完成后: 全部成功按 Enter / Q / Esc 退出;部分失败按 R 重试或 S 跳过生成补全包;出错按 B 返回配置页。

配置

首次运行自动生成。路径:

| 平台 | 路径 | |------|------| | Linux | ~/.config/localite/config.toml | | macOS | ~/Library/Application Support/localite/config.toml | | Windows | %APPDATA%/localite/config.toml |

api_key = ""                    # 必填,保存后自动迁移到系统凭据库
model = "deepseek-chat"
thinking_level = "off"          # off / high / max
concurrency = 4                 # 1–32
conversation_cache_ttl_minutes = 30
glossary_cache_ttl_days = 7
prompt_template = """..."""     # 自定义提示词(须含 {{entries_json}})

以上选项也可在 TUI 界面中直接编辑。api_key 保存后 TOML 中的明文值会被自动清空。

工作流程

flowchart TD
    A[下载 CFPA 汉化包<br>匹配版本/加载器,获取社区已有翻译作为基线]
    B[扫描 Mod 语言文件<br>遍历实例所有 .jar,解析 en_us 找出缺失条目]
    C[加载 CFPA 术语表<br>从 CFPAOrg/Glossary 拉取标准译名映射]
    D[查询 MC 百科<br>为每个缺失的 namespace 获取 Mod 介绍页]
    E[调用 DeepSeek 翻译<br>分批发送缺失条目 + 术语表 + MC 百科上下文]
    F[生成补全资源包<br>输出 .zip 到当前目录]

    A --> B --> C --> D --> E --> F

开发

bun install          # 安装依赖
bun run start        # 启动 TUI
bun run check        # lint + typecheck
bun run check:fix    # 自动修复
bun test             # 运行测试
bun run build        # 编译为独立二进制 (dist/localite)

技术栈:Bun + TypeScript + OpenTUI + Biome

许可

MIT