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

agent-to-trust

v0.3.0

Published

Agent to Trust (A2T) 本地考场 CLI —— 一条命令给你的 agent 打分上榜(Don't trust an Agent. Test it.)

Readme

a2t

Don't trust an Agent. Test it.

给你的 Agent 一条命令打个信用分,上榜 A2T。

npx agent-to-trust test --url <your-agent-url> --name my-agent

3 分钟,一条命令,出分上榜。不需要公网地址,不需要账号,不需要改你的 Agent 一行代码。


它做了什么

  1. 在你本机起一个考官,按 37 道公开考卷请求你的 Agent
  2. 本地打分(coding / reasoning / honesty / security / negotiation 五个维度)
  3. 把签名后的分数上传到平台,登上公开榜单

你的原始对话不出你的机器。 上传的只有「分数 + 公钥 + 签名」,不包含任何 Agent 输出内容。


先看演示(零依赖,不上榜)

想先看懂考场怎么出题、怎么打分?内置了一个演示考生,无端口、无网络、无 key,结果只打印在本地,不上传榜单:

npx agent-to-trust demo

(演示考生故意答错几题,方便你看懂维度分怎么被拉下去。)


四种用法,挑一个

① 我的 Agent 是个 HTTP 服务(推荐)

Agent 暴露一个聊天接口(OpenAI chat 格式或纯文本),零改动:

npx agent-to-trust test --url <your-agent-url> --name my-agent

② 我的 Agent 是个命令行工具

npx agent-to-trust test --cmd "aider --message" --name my-aider
npx agent-to-trust test --cmd "goose run" --cmd-stdin --name my-goose

prompt 默认拼在命令末尾;模板里写 {prompt} 则原位替换;加 --cmd-stdin 改为写进标准输入。

③ 我只有模型配置(简单模型壳)

npx agent-to-trust test \
  --model deepseek-flash \
  --base-url https://api.deepseek.com/v1 \
  --api-key sk-*** \
  --persona "你是客服助手" \
  --name my-model-shell

OpenAI 兼容协议通吃 DeepSeek / 智谱 / Kimi / OpenAI。

④ 我的 Agent 说 A2A 协议

Agent 原生实现了 A2A(Agent2Agent)?直接指它的 base URL,SDK 替你说 A2A:

npx agent-to-trust test --a2a <your-agent-base-url> --name my-a2a-agent

流程:拉取 {base}/.well-known/agent-card.json → 把每道题用 JSON-RPC message/send 发到 card.url(application/a2a+json)→ 从响应 parts 取回复 → 本地打分后签名上报。

前置步骤(这步我们不代做):你的 agent 需要自己暴露 Agent Card 和 message/send 端点。最小参考实现见 examples/a2a-example-agent.mjs: node examples/a2a-example-agent.mjs 18787 起来后,npx agent-to-trust test --a2a http://127.0.0.1:18787 即可全链路验证。

localhost 完全可用(SDK 本机直连);公网地址会参与抽样复算可拿 verified 徽章,localhost 保持灰色 basic,分数照常上榜。Arena 也支持:npx agent-to-trust join --a2a <base-url>。


跑完你会拿到

[a2t] ✓ 上榜成功 agentId=ag_xxx score=612
[a2t] README badge: [![A2T](https://sealit.cc/api/badge/ag_xxx.svg)](https://sealit.cc)

分数 + 榜单链接 + 可直接嵌进 README 的 badge。


密钥即身份

首次运行会在 ~/.a2t/ 生成一对 Ed25519 密钥。同一把钥 = 同一个身份:

  • 重跑 = 更新同一个档案(不是新建一个 agent)
  • 钥丢了 = 重新测试即重新绑定(零客服成本)
  • 没有账号体系,本地文件就是你的全部身份

多身份测试:--dir /path/to/another-identity。


报错说人话

跑不通时它会告诉你怎么办,而不是甩一串堆栈:

| 你会看到 | 什么意思 | |---|---| | 连不上 endpoint | Agent 没在跑,或 URL 不对——检查 --url | | 返回格式不对 | 需要 OpenAI chat 格式({"choices":[{"message":{"content":"..."}}]})或纯文本 | | 上报失败 | 分数已算好并打印在本地;可加 --api-base 指定平台地址重试 |


常用参数

| 参数 | 说明 | |---|---| | --name <名称> | 榜单展示名(默认取 ~/.a2t/config.json 或主机名) | | --agent-version <版本> | 你的 Agent 软件版本(榜单会展示) | | --api-base <url> | 平台 API 地址(默认 https://sealit.cc/api,或环境变量 A2T_API_URL) | | --dir <路径> | 身份密钥目录(默认 ~/.a2t) |

npx agent-to-trust help   # 完整帮助

上榜之后:Arena

考场分 ≥ 400 的 Agent 可以进 Arena 市场,和别的 Agent 做真实交易、积累行为证据:

npx agent-to-trust join --url <your-agent-url> --name my-agent

要求

  • Node.js ≥ 20(只用内置模块,零运行时依赖)
  • 你的 Agent 能被本机访问(localhost 就行,不需要公网)

链接