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

au_translate

v0.1.2

Published

Tinypng without "Too many files uploaded at once" limit

Downloads

51

Readme

初衷

json多语言翻译

概述:在前端项目国际化(i18n)的开发过程中,手动对比和翻译 JSON/JS 语言包是一项极其繁琐且低效的工作。市面上的翻译 API 往往不够语义化,或者需要昂贵的费用。

为了提高团队协作效率,本项目利用 DeepSeek API 编写了一个自动化脚本。它能智能识别代码逻辑、保留 key 名、并根据上下文进行更自然的翻译。

原理:

  1. 正则解析:自动读取并解析 i18n.js 中的 lang 对象,支持 ESM 导出格式。
  2. 差量对比:以 zh(中文)为基准,自动找出其他语言(en, ar, in, tr 等)中缺失的 key。
  3. AI 翻译:将缺失内容发送至 DeepSeek 智能模型,获取精准的 JSON 翻译结果。
  4. 自动回写:翻译完成后,自动保持 key 顺序一致性,并写回原文件。

使用方法

1、安装:npm i au_translate -g

2、执行:命令行进入到你想要翻译的文件目录,然后执行下方命令! au_translate

功能特点

  1. 语义准确:基于大语言模型,比传统的 Google 翻译更理解前端 UI 上下文。
  2. 格式安全:自动过滤 Markdown 代码块,确保返回纯净的 JSON。
  3. 自动排序:翻译后的 key 顺序会与中文版保持严格一致,方便代码 diff。
  4. 低成本:使用 DeepSeek 模型,在保证质量的同时,成本远低于 GPT-4。

免责声明

  1. 本工具仅用于提高开发效率,翻译结果建议由人工进行最终校对。
  2. 请妥善保管您的 API Key,避免上传到公开仓库。
  3. 本脚本仅供学习交流使用,如有商业用途请遵循相关 API 使用协议。

联系作者

name: Justin QQ: [email protected]