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.
npx agentmods add skills/peterfei/ai-agent-team/thread-managernpx skills add peterfei/ai-agent-team --skill thread-managergit clone --depth 1 https://github.com/peterfei/ai-agent-teamWrote 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.
[](https://agentmods.dev/skills/peterfei/ai-agent-team/thread-manager)<a href="https://agentmods.dev/skills/peterfei/ai-agent-team/thread-manager"><img src="https://agentmods.dev/badge/skills/peterfei/ai-agent-team/thread-manager.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00000 | $0.00458 |
| Opus 5 | $0.00000 | $0.00229 |
| Sonnet 5 | $0.00000 | $0.00092 |
| Haiku 4.5 | $0.00000 | $0.00046 |
Grade A, and why
thread-manager 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.
What it actually says
Thread Manager Skill
Thread Manager 为 Claude Code 提供多线程对话管理功能,让你可以并行处理多个任务,保持上下文隔离和专注。
功能特性
- 多线程管理: 创建、切换、更新和删除对话线程。
- 上下文隔离: 每个线程拥有独立的消息历史和上下文。
- 文件变更追踪: 自动记录每个线程中修改的文件和代码行数统计。
- 持久化存储: 使用 SQLite 本地存储所有数据,安全可靠。
- Git 集成: 自动检测文件变更详情。
安装
本 Skill 通常作为 ai-agent-team 项目的一部分安装。如果需要单独安装:
- 确保已安装 Node.js 18+。
- 运行
npm install安装依赖。 - 运行
npm run build编译代码。 - 将本 Skill 添加到 Claude Code 配置文件 (
config.json) 中。
MCP 工具
| 工具名称 | 描述 |
|---|---|
create_thread |
创建新线程 |
list_threads |
列出所有线程 |
switch_thread |
切换到指定线程 |
get_thread |
获取线程详情 |
update_thread |
更新线程信息 |
delete_thread |
删除线程 |
get_current_thread |
获取当前活跃线程 |
track_file_change |
记录文件变更 (支持自动检测) |
search_messages |
基于语义搜索历史消息 (支持自然语言) |
Slash Commands
/thread new "Title": 创建新线程/threads: 列出所有线程/thread <id>: 切换线程/thread info: 查看当前线程详情/memory search "query": 搜索历史消息 (需要调用 search_messages)
数据存储
数据存储在 ~/.claude/threads/threads.db (默认) 或环境变量 THREADS_DB_PATH 指定的位置。
What ships with it
55 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- .claude/.threads/current-context.md 648 B
- .gitignore 76 B
- .npmignore 138 B
- CHANGELOG.md 1.1 KB
- docs/clt-aliases.md 2.2 KB
- find-module.js 166 B runs code
- jest.config.js 1.1 KB runs code
- models/Xenova/all-MiniLM-L6-v2/config.json 650 B
- models/Xenova/all-MiniLM-L6-v2/onnx/model_quantized.onnx 22434 KB
- models/Xenova/all-MiniLM-L6-v2/special_tokens_map.json 125 B
- models/Xenova/all-MiniLM-L6-v2/tokenizer_config.json 366 B
- models/Xenova/all-MiniLM-L6-v2/tokenizer.json 695 KB
- package-lock.json 407 KB
- package.json 1.1 KB
- README.md 4.7 KB
- scripts/download-model.js 1.7 KB runs code
- scripts/migrate-embeddings.ts 3.4 KB runs code
- src/core/embedding-service.ts 4.3 KB runs code
- src/core/thread-manager.ts 14 KB runs code
- src/core/vector-search-engine.ts 1.2 KB runs code
- src/core/vector-utils.ts 1.0 KB runs code
- src/database/db.ts 4.5 KB runs code
- src/database/file-changes-dao.ts 2.8 KB runs code
- src/database/index.ts 121 B runs code
- src/database/messages-dao.ts 5.1 KB runs code
- src/database/threads-dao.ts 6.4 KB runs code
- src/git/git-integration.ts 5.6 KB runs code
- src/index.ts 257 B runs code
- src/server.ts 6.1 KB runs code
- src/tools/add-message.ts 1.5 KB runs code
- src/tools/create-thread.ts 1.3 KB runs code
- src/tools/delete-thread.ts 925 B runs code
- src/tools/get-current-thread.ts 2.6 KB runs code
- src/tools/get-thread.ts 1.2 KB runs code
- src/tools/list-threads.ts 1.2 KB runs code
- src/tools/search-messages.ts 4.4 KB runs code
- src/tools/switch-thread.ts 1.4 KB runs code
- src/tools/track-file-change.ts 1.7 KB runs code
- src/tools/update-thread.ts 1.2 KB runs code
- src/types/index.ts 2.6 KB runs code
- test-add-message.js 2.3 KB runs code
- test-output-format.js 546 B runs code
- tests/integration/file-tracker.test.ts 3.3 KB runs code
- tests/integration/mcp-tools.test.ts 5.4 KB runs code
- tests/integration/search-messages.test.ts 5.8 KB runs code
- tests/unit/__mocks__/embedding-service.ts 1.3 KB runs code
- tests/unit/database.test.ts 1.6 KB runs code
- tests/unit/file-changes-dao.test.ts 3.6 KB runs code
- tests/unit/git-integration.test.ts 4.9 KB runs code
- tests/unit/messages-dao.test.ts 3.9 KB runs code
- tests/unit/thread-manager.test.ts 9.2 KB runs code
- tests/unit/threads-dao.test.ts 6.0 KB runs code
- tests/unit/vector-search.test.ts 3.7 KB runs code
- tsconfig.json 464 B
- USAGE_GUIDE.md 6.7 KB
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.
- 4d ago First seen · 47 lines · 0 tokens per session scan A b0f881d1c9cc
thread-manager is a skill published in the GitHub repository peterfei/ai-agent-team (429 stars, last pushed 2mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 458 tokens. 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.
Other skills, from other repositories
ads-launch
Draft or explicitly apply a paid-ad campaign launch through Claude Ads capability-gated adapters. Use for campaign creation, launch plans, publishing ads, activating campaigns, uploading creative, or requests to push a campaign live.
api-response-optimization
Optimizes API performance through payload reduction, caching strategies, and compression techniques. Use when improving API response times, reducing bandwidth usage, or implementing efficient caching.
plan-create
Create structured implementation plans for autonomous TDD development. Use for new features, multi-file changes, or anything requiring multiple steps or tests. Triggers on aspirational openers ("let's build", "let's start building", "I want to make", "I want an app that", "help me build"), capability lists ("users…
blog-multilingual
One-command multilingual blog creation. Writes a blog post, translates it into user-specified languages, applies cultural adaptation, and emits hreflang tags, sitemap entries, and a CMS-ready language map. The complete write-to-publish pipeline for international content. Orchestrates blog-write, blog-translate…
amazing-psycoder
Route Amazing PsyCoder requests to the correct psychological experiment or behavioral-data analysis stage: Designer, Coder, or Reviewer. Use for end-to-end or multi-stage work, ambiguous requests such as “帮我做 Stroop”, cross-pipeline work, system-capability questions, or explicit invocations of Amazing PsyCoder.…
alibaba-maestro
Alibaba Cloud Maestro routing skill. Classify the user's Alibaba Cloud task, select the narrowest specialist agent or the right team of specialists from the catalog, and dispatch them — single specialist for focused tasks, parallel team (max 4) for multi-domain tasks. Never auto-dispatch live-guard agents.…