mirror of
https://github.com/affaan-m/everything-claude-code.git
synced 2026-04-12 12:43:32 +08:00
Revert "feat(ecc): prune plugin 43→12 items, promote 7 rules to .claude/rules/ (#245)"
This reverts commit 1bd68ff534.
This commit is contained in:
142
docs/ja-JP/commands/instinct-import.md
Normal file
142
docs/ja-JP/commands/instinct-import.md
Normal file
@@ -0,0 +1,142 @@
|
||||
---
|
||||
name: instinct-import
|
||||
description: チームメイト、Skill Creator、その他のソースからインスティンクトをインポート
|
||||
command: true
|
||||
---
|
||||
|
||||
# インスティンクトインポートコマンド
|
||||
|
||||
## 実装
|
||||
|
||||
プラグインルートパスを使用してインスティンクトCLIを実行します:
|
||||
|
||||
```bash
|
||||
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` が設定されていない場合(手動インストール):
|
||||
|
||||
```bash
|
||||
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/` に保存
|
||||
|
||||
## インポートプロセス
|
||||
|
||||
```
|
||||
📥 Importing instincts from: team-instincts.yaml
|
||||
================================================
|
||||
|
||||
Found 12 instincts to import.
|
||||
|
||||
Analyzing conflicts...
|
||||
|
||||
## New Instincts (8)
|
||||
These will be added:
|
||||
✓ use-zod-validation (confidence: 0.7)
|
||||
✓ prefer-named-exports (confidence: 0.65)
|
||||
✓ test-async-functions (confidence: 0.8)
|
||||
...
|
||||
|
||||
## Duplicate Instincts (3)
|
||||
Already have similar instincts:
|
||||
⚠️ prefer-functional-style
|
||||
Local: 0.8 confidence, 12 observations
|
||||
Import: 0.7 confidence
|
||||
→ Keep local (higher confidence)
|
||||
|
||||
⚠️ test-first-workflow
|
||||
Local: 0.75 confidence
|
||||
Import: 0.9 confidence
|
||||
→ Update to import (higher confidence)
|
||||
|
||||
## Conflicting Instincts (1)
|
||||
These contradict local instincts:
|
||||
❌ use-classes-for-services
|
||||
Conflicts with: avoid-classes
|
||||
→ Skip (requires manual resolution)
|
||||
|
||||
---
|
||||
Import 8 new, update 1, skip 3?
|
||||
```
|
||||
|
||||
## マージ戦略
|
||||
|
||||
### 重複の場合
|
||||
既存のインスティンクトと一致するインスティンクトをインポートする場合:
|
||||
- **高い信頼度が優先**: より高い信頼度を持つ方を保持
|
||||
- **証拠をマージ**: 観察回数を結合
|
||||
- **タイムスタンプを更新**: 最近検証されたものとしてマーク
|
||||
|
||||
### 競合の場合
|
||||
既存のインスティンクトと矛盾するインスティンクトをインポートする場合:
|
||||
- **デフォルトでスキップ**: 競合するインスティンクトはインポートしない
|
||||
- **レビュー用にフラグ**: 両方を注意が必要としてマーク
|
||||
- **手動解決**: ユーザーがどちらを保持するか決定
|
||||
|
||||
## ソーストラッキング
|
||||
|
||||
インポートされたインスティンクトは以下のようにマークされます:
|
||||
```yaml
|
||||
source: "inherited"
|
||||
imported_from: "team-instincts.yaml"
|
||||
imported_at: "2025-01-22T10:30:00Z"
|
||||
original_source: "session-observation" # or "repo-analysis"
|
||||
```
|
||||
|
||||
## Skill Creator統合
|
||||
|
||||
Skill Creatorからインポートする場合:
|
||||
|
||||
```
|
||||
/instinct-import --from-skill-creator acme/webapp
|
||||
```
|
||||
|
||||
これにより、リポジトリ分析から生成されたインスティンクトを取得します:
|
||||
- ソース: `repo-analysis`
|
||||
- 初期信頼度が高い(0.7以上)
|
||||
- ソースリポジトリにリンク
|
||||
|
||||
## フラグ
|
||||
|
||||
- `--dry-run`: インポートせずにプレビュー
|
||||
- `--force`: 競合があってもインポート
|
||||
- `--merge-strategy <higher|local|import>`: 重複の処理方法
|
||||
- `--from-skill-creator <owner/repo>`: Skill Creator分析からインポート
|
||||
- `--min-confidence <n>`: 閾値以上のインスティンクトのみをインポート
|
||||
|
||||
## 出力
|
||||
|
||||
インポート後:
|
||||
```
|
||||
✅ Import complete!
|
||||
|
||||
Added: 8 instincts
|
||||
Updated: 1 instinct
|
||||
Skipped: 3 instincts (2 duplicates, 1 conflict)
|
||||
|
||||
New instincts saved to: ~/.claude/homunculus/instincts/inherited/
|
||||
|
||||
Run /instinct-status to see all instincts.
|
||||
```
|
||||
Reference in New Issue
Block a user