smart-stats

smart-stats is a command for Claude Code from HYH926/smart-learn. It costs 32 tokens per session (697 once invoked), scanned A, original, MIT.

A read-only command that reports statistics from a Markdown learning library, including topics, concepts, weak points, review timing, and links between subjects.

In plain words
What is it for?
Use it to inspect learning totals, list saved topics, review weak-point coverage, view the knowledge map, and find the related notes and mind maps.
Why use it?
It shows what has been studied and which weak points may have gone too long without review, without modifying the records.

Command for Claude Code

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/hyh926/smart-learn/smart-stats
Clone the repo
git clone --depth 1 https://github.com/HYH926/smart-learn

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for smart-stats

README.md
[![agentmods](https://agentmods.dev/badge/commands/hyh926/smart-learn/smart-stats.svg)](https://agentmods.dev/commands/hyh926/smart-learn/smart-stats)
Your own site
<a href="https://agentmods.dev/commands/hyh926/smart-learn/smart-stats"><img src="https://agentmods.dev/badge/commands/hyh926/smart-learn/smart-stats.svg" alt="Measured on agentmods" height="20"></a>
Per session 32 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 697 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00032 $0.00697
Opus 5 $0.00016 $0.00349
Sonnet 5 $0.00006 $0.00139
Haiku 4.5 $0.00003 $0.00070

Measured 4d ago against content hash 937c82752f7c, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

smart-stats scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/smart-stats.md · 69 lines

What it actually says

显示 Smart Learn 学习统计数据。

统计维度

1. 学习概览

用 Glob 扫描 knowledge_store/ 目录:

# 统计 .md 笔记数量(排除思维导图和checkpoint)
ls knowledge_store/*.md 2>/dev/null | grep -v "思维导图" | grep -v "checkpoint" | wc -l

输出:

  • 📚 总学习主题数
  • 🧠 总概念数(从各笔记的概念地图中提取)
  • ⚠️ 总薄弱点数(从各笔记中提取 ⚠️ 标记)

2. 主题列表

列出每个已学主题的关键信息:

主题 学习日期 概念数 薄弱点 关键词
{主题1} {日期} {N} {N} {kw}
... ... ... ... ...

3. 薄弱点总览(含间隔复习状态)

聚合所有主题的薄弱点,解析 (首次标记:YYYY-MM-DD) 时间戳,计算距今天数:

⚠️ 薄弱点分布

🕐 距今天数  主题          薄弱点
────────────────────────────────────────
  30天     RAG基础知识     向量嵌入选型陷阱
  15天     系统架构设计     联合索引最左前缀
  7天      全栈开发         RESTful适用边界

⚠ 最近30天未复习的薄弱点:N 个
✅ 最近7天已复习的薄弱点:M 个

提示:

  • "🕐 超过 14 天未复习的薄弱点建议用 /smart-review {主题名} 回顾"
  • "📈 薄弱点复习率:{已复习数}/{总数}"

4. 知识地图总览

如果存在多个主题,输出跨主题关联:

🗺️ 知识网络
{主题A} ──关联── {主题B}
{主题A} ──关联── {主题C}
...

5. 知识库路径

  • 📝 Markdown 笔记:knowledge_store/
  • 🧠 思维导图:knowledge_store/*_思维导图.md
  • 📄 Word 文档:knowledge_store/*_学习笔记.docx(如有)

约束

  • 纯只读,不写任何文件
  • 如果 knowledge_store 为空,告知"还没有学习记录,用 /smart-learn 开始学习吧"
  • 所有数据从已有 Markdown 笔记和 checkpoint 文件中提取
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 69 lines · 32 tokens per session scan A 937c82752f7c

Subscribe to this mod's changes

smart-stats is a command published in the GitHub repository HYH926/smart-learn (21 stars, last pushed 2mo ago), licensed MIT. It adds 32 tokens to every session and 697 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.