instinct-import

A command for importing learned coding and workflow preferences from a local file or web address.

In plain words
What is it for?
Use it to bring in preferences shared by a teammate, produced from a repository analysis, collected by a community, or saved in a backup.
Why use it?
It checks the imported data, detects duplicates and conflicts, and combines it with existing preferences instead of adding everything blindly.

Command

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/codelably/harmony-claude-code/instinct-import
Clone the repo
git clone --depth 1 https://github.com/codelably/harmony-claude-code
Per session 27 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,115 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.00027 $0.01115
Opus 5 $0.00014 $0.00558
Sonnet 5 $0.00005 $0.00223
Haiku 4.5 $0.00003 $0.00112

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

Security

Grade A, and why

instinct-import 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 2d 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.

commands/instinct-import.md · 143 lines

How it starts

The opening of the file, as written. The whole thing — 143 lines — stays where its author put it; the contents beside it link to each section on GitHub.

直觉导入命令(Instinct Import Command)

实现

使用插件根路径运行直觉 CLI:

python3 "${CLAUDE_PLUGIN_ROOT}/skills/continuous-learning-v2/scripts/instinct-cli.py" import <file-or-url> [--dry-run] [--force] [--min-confidence 0.7]

如果未设置 CLAUDE_PLUGIN_ROOT(手动安装):

python3 ~/.claude/skills/continuous-learning-v2/scripts/instinct-cli.py import <file-or-url>

可以从以下来源导入直觉:

  • 团队成员的导出文件
  • 技能创建者(Skill Creator)(仓库分析)
  • 社区集合
  • 以前的机器备份

用法

/instinct-import team-instincts.yaml
/instinct-import https://github.com/org/repo/instincts.yaml
/instinct-import --from-skill-creator acme/webapp

核心流程

  1. 获取直觉文件(本地路径或 URL)
  2. 解析并验证格式
  3. 检查与现有直觉是否重复
  4. 合并或添加新直觉
  5. 保存至 ~/.claude/homunculus/instincts/inherited/

导入过程示例

📥 正在从以下路径导入直觉:team-instincts.yaml
================================================

发现 12 条待导入的直觉。

正在分析冲突...

## 新直觉 (8)
以下内容将被添加:
  ✓ use-zod-validation (置信度: 0.7)
  ✓ prefer-named-exports (置信度: 0.65)
  ✓ test-async-functions (置信度: 0.8)
  ...

## 重复直觉 (3)
已存在类似的直觉:
  ⚠️ prefer-functional-style
     本地: 0.8 置信度, 12 次观察
     导入: 0.7 置信度
     → 保留本地版本(置信度更高)

  ⚠️ test-first-workflow
     本地: 0.75 置信度
     导入: 0.9 置信度
     → 更新为导入版本(置信度更高)

## 冲突直觉 (1)
这些直觉与本地直觉冲突:
  ❌ use-classes-for-services
     冲突项:avoid-classes
     → 跳过(需要手动解决)

---
导入 8 条新直觉,更新 1 条,跳过 3 条?

合并策略(Merge Strategies)

处理重复项

当导入的直觉与现有直觉匹配时:

  • 高置信度优先:保留置信度较高的版本
  • 合并证据:合并观察计数(observation counts)
  • 更新时间戳:标记为最近已验证

处理冲突

当导入的直觉与现有直觉相矛盾时:

  • 默认跳过:不导入冲突的直觉
  • 标记待评审:将两者都标记为需要关注
  • 手动解决:由用户决定保留哪一个

来源追踪

导入的直觉会带有以下标记:

source: "inherited"
imported_from: "team-instincts.yaml"
imported_at: "2025-01-22T10:30:00Z"
original_source: "session-observation"  # 或 "repo-analysis"

技能创建者(Skill Creator)集成

从技能创建者导入时:

/instinct-import --from-skill-creator acme/webapp

这将获取通过仓库分析生成的直觉:

  • 来源:repo-analysis
  • 初始置信度较高 (0.7+)
  • 链接到源仓库

参数选项(Flags)

  • --dry-run:预览而不执行导入
  • --force:即使存在冲突也执行导入
  • --merge-strategy <higher|local|import>:如何处理重复项
  • --from-skill-creator <owner/repo>:从技能创建者分析中导入
  • --min-confidence <n>:仅导入高于阈值的直觉

Read the full file on GitHub · 143 lines

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. 2d ago First seen · 143 lines · 27 tokens per session scan A 23a70d41bfc8

Subscribe to this mod's changes

instinct-import is a command published in the GitHub repository codelably/harmony-claude-code (42 stars, last pushed 6mo ago), licensed MIT. It adds 27 tokens to every session and 1,115 once invoked, about $0.0001 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.