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

lcap-code

v0.3.3

Published

CLI-based code assistant powered by AI, built with React and Ink

Readme

lcap-code

一个基于 Ink 和 React 的终端编程代理。

环境配置

在使用前,需要配置以下环境变量用于AI模型鉴权:

必需环境变量

# AI网关访问令牌(必需)
export AIGW_TOKEN="your_token_here"

# AI网关API地址(必需)
export AIGW_URL="https://your-api-gateway-url.com"

可选环境变量

# 指定使用的AI模型(可选,默认使用系统配置的模型)
export AIGW_MODEL="gemini-2.5-flash"

# 指定快速AI模型(可选,用于快速响应场景)
export AIGW_FAST_MODEL="gemini-1.5-flash"

# 日志级别(可选,默认为info)
export LOG_LEVEL="debug"

# 日志文件路径(可选)
export LOG_FILE="/path/to/your/logfile.log"

# 最大日志文件大小(可选,默认10MB)
export LOG_MAX_FILE_SIZE="10485760"

# Token限制(可选,默认64000)
export TOKEN_LIMIT="64000"

# 禁用原始模式(可选,用于测试)
export DISABLE_RAW_MODE="false"

环境变量设置方式

方法1:直接在命令行设置

export AIGW_TOKEN="your_token_here"
export AIGW_URL="https://your-api-gateway-url.com"
lcap-code

方法2:使用.env文件

创建 .env 文件并添加:

AIGW_TOKEN=your_token_here
AIGW_URL=https://your-api-gateway-url.com

方法3:在shell配置文件中设置

将环境变量添加到 ~/.bashrc~/.zshrc 或相应的shell配置文件中。

⚠️ 重要提示:不设置 AIGW_TOKENAIGW_URL 环境变量,模型将无法进行鉴权,应用无法正常工作。

安装

全局安装

npm install -g lcap-code

使用方法

命令行使用

# 打开当前目录
lcap-code

lcap-code --help

文档

兼容性说明

  • 所有日志都写入到文件中,不输出到控制台