[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M70FQY20ERBA9B3G1129TJC8":3,"skill-same:01M70FQY20ERBA9B3G1129TJC8":117},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":39,"linkOnly":40,"markdownContent":41,"markdownBody":42,"frontMatter":43,"refName":47,"commitSha":48,"skillDirectory":49,"forksCount":50,"repositoryHtmlUrl":51,"repositoryHomepageUrl":6,"ownerHtmlUrl":52,"ownerBlogUrl":6,"ownerDescription":53,"updatedAt":54,"install":55,"resources":68},"01M70FQY20ERBA9B3G1129TJC8","continuous-learning-v2",null,"Instinct-based learning system that observes sessions via hooks, creates atomic instincts with confidence scoring, and evolves them into skills\u002Fcommands\u002Fagents. v2.1 adds project-scoped instincts to prevent cross-project contamination. Use when capturing lessons from a session, managing instincts, or promoting them into skills, commands, or agents.","mdnaimul22\u002Fhuman-skills","mdnaimul22","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F64520358?v=4","01M70FH95MH2H796Q01TYSFZ03","Naimul","01M70FH96798CQR4YHA13F17GA",3,"MIT","https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Faffaan-m_ECC\u002Fcontinuous-learning-v2\u002FSKILL.md",[],[19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38],"continuous learning","continuous learning v2","learning","contamination","atomic","via","with","use","lessons","sessions","scoped","session","system","learning system","commands","scoring","when","confidence scoring","hooks","project","2026-11-10 10:12:30",false,"---\nname: continuous-learning-v2\ndescription: Instinct-based learning system that observes sessions via hooks, creates atomic instincts with confidence scoring, and evolves them into skills\u002Fcommands\u002Fagents. v2.1 adds project-scoped instincts to prevent cross-project contamination. Use when capturing lessons from a session, managing instincts, or promoting them into skills, commands, or agents.\nmetadata:\n  version: 2.1.0\n  origin: ECC\n---\n\n# Continuous Learning v2.1 - Instinct\n-Based Architecture\n\nAn advanced learning system that turns your Claude Code sessions into reusable knowledge through atomic \"instincts\" - small learned behaviors with confidence scoring.\n\n**v2.1** adds **project-scoped instincts** — React patterns stay in your React project, Python conventions stay in your Python project, and universal patterns (like \"always validate input\") are shared globally.\n\n## When to Activate\n\n- Setting up automatic learning from Claude Code sessions\n- Configuring instinct-based behavior extraction via hooks\n- Tuning confidence thresholds for learned behaviors\n- Reviewing, exporting, or importing instinct libraries\n- Evolving instincts into full skills, commands, or agents\n- Managing project-scoped vs global instincts\n- Promoting instincts from project to global scope\n\n## What's New in v2.1\n\n| Feature | v2.0 | v2.1 |\n|---------|------|------|\n| Storage | Global (`~\u002F.claude\u002Fhomunculus\u002F`) | Project-scoped (`${XDG_DATA_HOME:-~\u002F.local\u002Fshare}\u002Fecc-homunculus\u002Fprojects\u002F\u003Chash>\u002F`) |\n| Scope | All instincts apply everywhere | Project-scoped + global |\n| Detection | None | git remote URL \u002F repo path |\n| Promotion | N\u002FA | Project → global when seen in 2+ projects |\n| Commands | 4 (status\u002Fevolve\u002Fexport\u002Fimport) | 6 (+promote\u002Fprojects) |\n| Cross-project | Contamination risk | Isolated by default |\n\n## What's New in v2 (vs v1)\n\n| Feature | v1 | v2 |\n|---------|----|----|\n| Observation | Stop hook (session end) | PreToolUse\u002FPostToolUse (100% reliable) |\n| Analysis | Main context | Background agent (Haiku) |\n| Granularity | Full skills | Atomic \"instincts\" |\n| Confidence | None | 0.3-0.9 weighted |\n| Evolution | Direct to skill | Instincts -> cluster -> skill\u002Fcommand\u002Fagent |\n| Sharing | None | Export\u002Fimport instincts |\n\n## The Instinct Model\n\nAn instinct is a small learned behavior:\n\n```yaml\n---\nid: prefer-functional-style\ntrigger: \"when writing new functions\"\nconfidence: 0.7\ndomain: \"code-style\"\nsource: \"session-observation\"\nscope: project\nproject_id: \"a1b2c3d4e5f6\"\nproject_name: \"my-react-app\"\n---\n\n# Prefer Functional Style\n\n## Action\nUse functional patterns over classes when appropriate.\n\n## Evidence\n- Observed 5 instances of functional pattern preference\n- User corrected class-based approach to functional on 2025-01-15\n```\n\n**Properties:**\n- **Atomic** -- one trigger, one action\n- **Confidence-weighted** -- 0.3 = tentative, 0.9 = near certain\n- **Domain-tagged** -- code-style, testing, git, debugging, workflow, etc.\n- **Evidence-backed** -- tracks what observations created it\n- **Scope-aware** -- `project` (default) or `global`\n\n## How It Works\n\n```\nSession Activity (in a git repo)\n      |\n      | Hooks capture prompts + tool use (100% reliable)\n      | + detect project context (git remote \u002F repo path)\n      v\n+---------------------------------------------+\n|  projects\u002F\u003Cproject-hash>\u002Fobservations.jsonl  |\n|   (prompts, tool calls, outcomes, project)   |\n+---------------------------------------------+\n      |\n      | Observer agent reads (background, Haiku)\n      v\n+---------------------------------------------+\n|          PATTERN DETECTION                   |\n|   * User corrections -> instinct             |\n|   * Error resolutions -> instinct            |\n|   * Repeated workflows -> instinct           |\n|   * Scope decision: project or global?       |\n+---------------------------------------------+\n      |\n      | Creates\u002Fupdates\n      v\n+---------------------------------------------+\n|  projects\u002F\u003Cproject-hash>\u002Finstincts\u002Fpersonal\u002F |\n|   * prefer-functional.yaml (0.7) [project]   |\n|   * use-react-hooks.yaml (0.9) [project]     |\n+---------------------------------------------+\n|  instincts\u002Fpersonal\u002F  (GLOBAL)               |\n|   * always-validate-input.yaml (0.85) [global]|\n|   * grep-before-edit.yaml (0.6) [global]     |\n+---------------------------------------------+\n      |\n      | \u002Fevolve clusters + \u002Fpromote\n      v\n+---------------------------------------------+\n|  projects\u002F\u003Chash>\u002Fevolved\u002F (project-scoped)   |\n|  evolved\u002F (global)                           |\n|   * commands\u002Fnew-feature.md                  |\n|   * skills\u002Ftesting-workflow.md               |\n|   * agents\u002Frefactor-specialist.md            |\n+---------------------------------------------+\n```\n\n## Project Detection\n\nThe system automatically detects your current project:\n\n1. **`CLAUDE_PROJECT_DIR` env var** (highest priority) -- honored as an explicit override even when the directory is not a git repo (hashed by its absolute path)\n2. **`git remote get-url origin`** -- hashed to create a portable project ID (same repo on different machines gets the same ID)\n3. **`git rev-parse --show-toplevel`** -- fallback using repo path (machine-specific)\n4. **Global fallback** -- if no project is detected, instincts go to global scope\n\nEach project gets a 12-character hash ID (e.g., `a1b2c3d4e5f6`). A registry file at `${XDG_DATA_HOME:-~\u002F.local\u002Fshare}\u002Fecc-homunculus\u002Fprojects.json` maps IDs to human-readable names.\n\n### Data Directory\n\nContinuous-learning-v2 stores observer data outside `~\u002F.claude` so Claude Code's sensitive-path guard does not block background instinct writes:\n\n1. `CLV2_HOMUNCULUS_DIR` when set to an absolute path\n2. `$XDG_DATA_HOME\u002Fecc-homunculus`\n3. `$HOME\u002F.local\u002Fshare\u002Fecc-homunculus`\n\nExisting users with data at `~\u002F.claude\u002Fhomunculus` can migrate once:\n\n```bash\nbash skills\u002Fcontinuous-learning-v2\u002Fscripts\u002Fmigrate-homunculus.sh\n```\n\n## Quick Start\n\n### 1. Enable Observation Hooks\n\n**If installed as a plugin** (recommended):\n\nNo extra `settings.json` hook block is required. Claude Code v2.1+ auto-loads the plugin `hooks\u002Fhooks.json`, and `observe.sh` is already registered there.\n\nIf you previously copied `observe.sh` into `~\u002F.claude\u002Fsettings.json`, remove that duplicate `PreToolUse` \u002F `PostToolUse` block. Duplicating the plugin hook causes double execution and `${CLAUDE_PLUGIN_ROOT}` resolution errors because that variable is only available inside plugin-managed `hooks\u002Fhooks.json` entries.\n\n**If installed manually** to `~\u002F.claude\u002Fskills`, add this to your `~\u002F.claude\u002Fsettings.json`:\n\n```json\n{\n  \"hooks\": {\n    \"PreToolUse\": [{\n      \"matcher\": \"*\",\n      \"hooks\": [{\n        \"type\": \"command\",\n        \"command\": \"~\u002F.claude\u002Fskills\u002Fcontinuous-learning-v2\u002Fhooks\u002Fobserve.sh\"\n      }]\n    }],\n    \"PostToolUse\": [{\n      \"matcher\": \"*\",\n      \"hooks\": [{\n        \"type\": \"command\",\n        \"command\": \"~\u002F.claude\u002Fskills\u002Fcontinuous-learning-v2\u002Fhooks\u002Fobserve.sh\"\n      }]\n    }]\n  }\n}\n```\n\n### 2. Initialize Directory Structure\n\nThe system creates directories automatically on first use, but you can also create them manually:\n\n```bash\n# Global directories\nmkdir -p \"${XDG_DATA_HOME:-$HOME\u002F.local\u002Fshare}\u002Fecc-homunculus\"\u002F{instincts\u002F{personal,inherited},evolved\u002F{agents,skills,commands},projects}\n\n# Project directories are auto-created when the hook first runs in a git repo\n```\n\n### 3. Use the Instinct Commands\n\n```bash\n\u002Finstinct-status     # Show learned instincts (project + global)\n\u002Fevolve              # Cluster related instincts into skills\u002Fcommands\n\u002Finstinct-export     # Export instincts to file\n\u002Finstinct-import     # Import instincts from others\n\u002Fpromote             # Promote project instincts to global scope\n\u002Fprojects            # List all known projects and their instinct counts\n```\n\n## Commands\n\n| Command | Description |\n|---------|-------------|\n| `\u002Finstinct-status` | Show all instincts (project-scoped + global) with confidence |\n| `\u002Fevolve` | Cluster related instincts into skills\u002Fcommands, suggest promotions |\n| `\u002Finstinct-export` | Export instincts (filterable by scope\u002Fdomain) |\n| `\u002Finstinct-import \u003Cfile>` | Import instincts with scope control |\n| `\u002Fpromote [id]` | Promote project instincts to global scope |\n| `\u002Fprojects` | List all known projects and their instinct counts |\n\n## Configuration\n\nEdit `config.json` to control the background observer:\n\n```json\n{\n  \"version\": \"2.1\",\n  \"observer\": {\n    \"enabled\": false,\n    \"run_interval_minutes\": 5,\n    \"min_observations_to_analyze\": 20\n  }\n}\n```\n\n| Key | Default | Description |\n|-----|---------|-------------|\n| `observer.enabled` | `false` | Enable the background observer agent |\n| `observer.run_interval_minutes` | `5` | How often the observer analyzes observations |\n| `observer.min_observations_to_analyze` | `20` | Minimum observations before analysis runs |\n\nOther behavior (observation capture, instinct thresholds, project scoping, promotion criteria) is configured via code defaults in `instinct-cli.py` and `observe.sh`.\n\n### Observer platform support\n\nThe background observer requires WSL2, Linux, or macOS. On native Windows\n(Git Bash \u002F MSYS2) it starts and reports success, but the process is killed\nwhen the spawning hook exits and its Job Object closes, so no analysis ever\nruns — setting `observer.enabled: true` there is effectively a no-op\n(see issue #2489).\n\n`observe.sh` detects this on the following hook invocation and writes an\nexplanatory warning to `observer-start.log` once the observer has failed to\nsurvive several times in a row.\n\n| Env var | Default | Description |\n|---------|---------|-------------|\n| `ECC_OBSERVER_NOSURVIVE_WARN_AFTER` | `3` | Consecutive non-survivals before the warning is logged |\n\n## File Structure\n\n```\n${XDG_DATA_HOME:-~\u002F.local\u002Fshare}\u002Fecc-homunculus\u002F\n+-- identity.json           # Your profile, technical level\n+-- projects.json           # Registry: project hash -> name\u002Fpath\u002Fremote\n+-- observations.jsonl      # Global observations (fallback)\n+-- instincts\u002F\n|   +-- personal\u002F           # Global auto-learned instincts\n|   +-- inherited\u002F          # Global imported instincts\n+-- evolved\u002F\n|   +-- agents\u002F             # Global generated agents\n|   +-- skills\u002F             # Global generated skills\n|   +-- commands\u002F           # Global generated commands\n+-- projects\u002F\n    +-- a1b2c3d4e5f6\u002F       # Project hash (from git remote URL)\n    |   +-- project.json    # Per-project metadata mirror (id\u002Fname\u002Froot\u002Fremote)\n    |   +-- observations.jsonl\n    |   +-- observations.archive\u002F\n    |   +-- instincts\u002F\n    |   |   +-- personal\u002F   # Project-specific auto-learned\n    |   |   +-- inherited\u002F  # Project-specific imported\n    |   +-- evolved\u002F\n    |       +-- skills\u002F\n    |       +-- commands\u002F\n    |       +-- agents\u002F\n    +-- f6e5d4c3b2a1\u002F       # Another project\n        +-- ...\n```\n\n## Scope Decision Guide\n\n| Pattern Type | Scope | Examples |\n|-------------|-------|---------|\n| Language\u002Fframework conventions | **project** | \"Use React hooks\", \"Follow Django REST patterns\" |\n| File structure preferences | **project** | \"Tests in `__tests__`\u002F\", \"Components in src\u002Fcomponents\u002F\" |\n| Code style | **project** | \"Use functional style\", \"Prefer dataclasses\" |\n| Error handling strategies | **project** | \"Use Result type for errors\" |\n| Security practices | **global** | \"Validate user input\", \"Sanitize SQL\" |\n| General best practices | **global** | \"Write tests first\", \"Always handle errors\" |\n| Tool workflow preferences | **global** | \"Grep before Edit\", \"Read before Write\" |\n| Git practices | **global** | \"Conventional commits\", \"Small focused commits\" |\n\n## Instinct Promotion (Project -> Global)\n\nWhen the same instinct appears in multiple projects with high confidence, it's a candidate for promotion to global scope.\n\n**Auto-promotion criteria:**\n- Same instinct ID in 2+ projects\n- Average confidence >= 0.8\n\n**How to promote:**\n\n```bash\n# Promote a specific instinct\npython3 instinct-cli.py promote prefer-explicit-errors\n\n# Auto-promote all qualifying instincts\npython3 instinct-cli.py promote\n\n# Preview without changes\npython3 instinct-cli.py promote --dry-run\n```\n\nThe `\u002Fevolve` command also suggests promotion candidates.\n\n## Confidence Scoring\n\nConfidence evolves over time:\n\n| Score | Meaning | Behavior |\n|-------|---------|----------|\n| 0.3 | Tentative | Suggested but not enforced |\n| 0.5 | Moderate | Applied when relevant |\n| 0.7 | Strong | Auto-approved for application |\n| 0.9 | Near-certain | Core behavior |\n\n**Confidence increases** when:\n- Pattern is repeatedly observed\n- User doesn't correct the suggested behavior\n- Similar instincts from other sources agree\n\n**Confidence decreases** when:\n- User explicitly corrects the behavior\n- Pattern isn't observed for extended periods\n- Contradicting evidence appears\n\n## Why Hooks vs Skills for Observation?\n\n> \"v1 relied on skills to observe. Skills are probabilistic -- they fire ~50-80% of the time based on Claude's judgment.\"\n\nHooks fire **100% of the time**, deterministically. This means:\n- Every tool call is observed\n- No patterns are missed\n- Learning is comprehensive\n\n## Backward Compatibility\n\nv2.1 is fully compatible with v2.0 and v1:\n- Existing global instincts can be migrated from `~\u002F.claude\u002Fhomunculus\u002Finstincts\u002F` with `scripts\u002Fmigrate-homunculus.sh`\n- Existing `~\u002F.claude\u002Fskills\u002Flearned\u002F` skills from v1 still work\n- Stop hook still runs (but now also feeds into v2)\n- Gradual migration: run both in parallel\n\n## Privacy\n\n- Observations stay **local** on your machine\n- Project-scoped instincts are isolated per project\n- Only **instincts** (patterns) can be exported — not raw observations\n- No actual code or conversation content is shared\n- You control what gets exported and promoted\n\n## Related\n\n- [ECC-Tools GitHub App](https:\u002F\u002Fgithub.com\u002Fapps\u002Fecc-tools) - Generate instincts from repo history\n- Homunculus - Community project that inspired the v2 instinct-based architecture (atomic observations, confidence scoring, instinct evolution pipeline)\n- [The Longform Guide](https:\u002F\u002Fx.com\u002Faffaanmustafa\u002Fstatus\u002F2014040193557471352) - Continuous learning section\n\n---\n\n*Instinct-based learning: teaching Claude your patterns, one project at a time.*\n","# Continuous Learning v2.1 - Instinct\n-Based Architecture\n\nAn advanced learning system that turns your Claude Code sessions into reusable knowledge through atomic \"instincts\" - small learned behaviors with confidence scoring.\n\n**v2.1** adds **project-scoped instincts** — React patterns stay in your React project, Python conventions stay in your Python project, and universal patterns (like \"always validate input\") are shared globally.\n\n## When to Activate\n\n- Setting up automatic learning from Claude Code sessions\n- Configuring instinct-based behavior extraction via hooks\n- Tuning confidence thresholds for learned behaviors\n- Reviewing, exporting, or importing instinct libraries\n- Evolving instincts into full skills, commands, or agents\n- Managing project-scoped vs global instincts\n- Promoting instincts from project to global scope\n\n## What's New in v2.1\n\n| Feature | v2.0 | v2.1 |\n|---------|------|------|\n| Storage | Global (`~\u002F.claude\u002Fhomunculus\u002F`) | Project-scoped (`${XDG_DATA_HOME:-~\u002F.local\u002Fshare}\u002Fecc-homunculus\u002Fprojects\u002F\u003Chash>\u002F`) |\n| Scope | All instincts apply everywhere | Project-scoped + global |\n| Detection | None | git remote URL \u002F repo path |\n| Promotion | N\u002FA | Project → global when seen in 2+ projects |\n| Commands | 4 (status\u002Fevolve\u002Fexport\u002Fimport) | 6 (+promote\u002Fprojects) |\n| Cross-project | Contamination risk | Isolated by default |\n\n## What's New in v2 (vs v1)\n\n| Feature | v1 | v2 |\n|---------|----|----|\n| Observation | Stop hook (session end) | PreToolUse\u002FPostToolUse (100% reliable) |\n| Analysis | Main context | Background agent (Haiku) |\n| Granularity | Full skills | Atomic \"instincts\" |\n| Confidence | None | 0.3-0.9 weighted |\n| Evolution | Direct to skill | Instincts -> cluster -> skill\u002Fcommand\u002Fagent |\n| Sharing | None | Export\u002Fimport instincts |\n\n## The Instinct Model\n\nAn instinct is a small learned behavior:\n\n```yaml\n---\nid: prefer-functional-style\ntrigger: \"when writing new functions\"\nconfidence: 0.7\ndomain: \"code-style\"\nsource: \"session-observation\"\nscope: project\nproject_id: \"a1b2c3d4e5f6\"\nproject_name: \"my-react-app\"\n---\n\n# Prefer Functional Style\n\n## Action\nUse functional patterns over classes when appropriate.\n\n## Evidence\n- Observed 5 instances of functional pattern preference\n- User corrected class-based approach to functional on 2025-01-15\n```\n\n**Properties:**\n- **Atomic** -- one trigger, one action\n- **Confidence-weighted** -- 0.3 = tentative, 0.9 = near certain\n- **Domain-tagged** -- code-style, testing, git, debugging, workflow, etc.\n- **Evidence-backed** -- tracks what observations created it\n- **Scope-aware** -- `project` (default) or `global`\n\n## How It Works\n\n```\nSession Activity (in a git repo)\n      |\n      | Hooks capture prompts + tool use (100% reliable)\n      | + detect project context (git remote \u002F repo path)\n      v\n+---------------------------------------------+\n|  projects\u002F\u003Cproject-hash>\u002Fobservations.jsonl  |\n|   (prompts, tool calls, outcomes, project)   |\n+---------------------------------------------+\n      |\n      | Observer agent reads (background, Haiku)\n      v\n+---------------------------------------------+\n|          PATTERN DETECTION                   |\n|   * User corrections -> instinct             |\n|   * Error resolutions -> instinct            |\n|   * Repeated workflows -> instinct           |\n|   * Scope decision: project or global?       |\n+---------------------------------------------+\n      |\n      | Creates\u002Fupdates\n      v\n+---------------------------------------------+\n|  projects\u002F\u003Cproject-hash>\u002Finstincts\u002Fpersonal\u002F |\n|   * prefer-functional.yaml (0.7) [project]   |\n|   * use-react-hooks.yaml (0.9) [project]     |\n+---------------------------------------------+\n|  instincts\u002Fpersonal\u002F  (GLOBAL)               |\n|   * always-validate-input.yaml (0.85) [global]|\n|   * grep-before-edit.yaml (0.6) [global]     |\n+---------------------------------------------+\n      |\n      | \u002Fevolve clusters + \u002Fpromote\n      v\n+---------------------------------------------+\n|  projects\u002F\u003Chash>\u002Fevolved\u002F (project-scoped)   |\n|  evolved\u002F (global)                           |\n|   * commands\u002Fnew-feature.md                  |\n|   * skills\u002Ftesting-workflow.md               |\n|   * agents\u002Frefactor-specialist.md            |\n+---------------------------------------------+\n```\n\n## Project Detection\n\nThe system automatically detects your current project:\n\n1. **`CLAUDE_PROJECT_DIR` env var** (highest priority) -- honored as an explicit override even when the directory is not a git repo (hashed by its absolute path)\n2. **`git remote get-url origin`** -- hashed to create a portable project ID (same repo on different machines gets the same ID)\n3. **`git rev-parse --show-toplevel`** -- fallback using repo path (machine-specific)\n4. **Global fallback** -- if no project is detected, instincts go to global scope\n\nEach project gets a 12-character hash ID (e.g., `a1b2c3d4e5f6`). A registry file at `${XDG_DATA_HOME:-~\u002F.local\u002Fshare}\u002Fecc-homunculus\u002Fprojects.json` maps IDs to human-readable names.\n\n### Data Directory\n\nContinuous-learning-v2 stores observer data outside `~\u002F.claude` so Claude Code's sensitive-path guard does not block background instinct writes:\n\n1. `CLV2_HOMUNCULUS_DIR` when set to an absolute path\n2. `$XDG_DATA_HOME\u002Fecc-homunculus`\n3. `$HOME\u002F.local\u002Fshare\u002Fecc-homunculus`\n\nExisting users with data at `~\u002F.claude\u002Fhomunculus` can migrate once:\n\n```bash\nbash skills\u002Fcontinuous-learning-v2\u002Fscripts\u002Fmigrate-homunculus.sh\n```\n\n## Quick Start\n\n### 1. Enable Observation Hooks\n\n**If installed as a plugin** (recommended):\n\nNo extra `settings.json` hook block is required. Claude Code v2.1+ auto-loads the plugin `hooks\u002Fhooks.json`, and `observe.sh` is already registered there.\n\nIf you previously copied `observe.sh` into `~\u002F.claude\u002Fsettings.json`, remove that duplicate `PreToolUse` \u002F `PostToolUse` block. Duplicating the plugin hook causes double execution and `${CLAUDE_PLUGIN_ROOT}` resolution errors because that variable is only available inside plugin-managed `hooks\u002Fhooks.json` entries.\n\n**If installed manually** to `~\u002F.claude\u002Fskills`, add this to your `~\u002F.claude\u002Fsettings.json`:\n\n```json\n{\n  \"hooks\": {\n    \"PreToolUse\": [{\n      \"matcher\": \"*\",\n      \"hooks\": [{\n        \"type\": \"command\",\n        \"command\": \"~\u002F.claude\u002Fskills\u002Fcontinuous-learning-v2\u002Fhooks\u002Fobserve.sh\"\n      }]\n    }],\n    \"PostToolUse\": [{\n      \"matcher\": \"*\",\n      \"hooks\": [{\n        \"type\": \"command\",\n        \"command\": \"~\u002F.claude\u002Fskills\u002Fcontinuous-learning-v2\u002Fhooks\u002Fobserve.sh\"\n      }]\n    }]\n  }\n}\n```\n\n### 2. Initialize Directory Structure\n\nThe system creates directories automatically on first use, but you can also create them manually:\n\n```bash\n# Global directories\nmkdir -p \"${XDG_DATA_HOME:-$HOME\u002F.local\u002Fshare}\u002Fecc-homunculus\"\u002F{instincts\u002F{personal,inherited},evolved\u002F{agents,skills,commands},projects}\n\n# Project directories are auto-created when the hook first runs in a git repo\n```\n\n### 3. Use the Instinct Commands\n\n```bash\n\u002Finstinct-status     # Show learned instincts (project + global)\n\u002Fevolve              # Cluster related instincts into skills\u002Fcommands\n\u002Finstinct-export     # Export instincts to file\n\u002Finstinct-import     # Import instincts from others\n\u002Fpromote             # Promote project instincts to global scope\n\u002Fprojects            # List all known projects and their instinct counts\n```\n\n## Commands\n\n| Command | Description |\n|---------|-------------|\n| `\u002Finstinct-status` | Show all instincts (project-scoped + global) with confidence |\n| `\u002Fevolve` | Cluster related instincts into skills\u002Fcommands, suggest promotions |\n| `\u002Finstinct-export` | Export instincts (filterable by scope\u002Fdomain) |\n| `\u002Finstinct-import \u003Cfile>` | Import instincts with scope control |\n| `\u002Fpromote [id]` | Promote project instincts to global scope |\n| `\u002Fprojects` | List all known projects and their instinct counts |\n\n## Configuration\n\nEdit `config.json` to control the background observer:\n\n```json\n{\n  \"version\": \"2.1\",\n  \"observer\": {\n    \"enabled\": false,\n    \"run_interval_minutes\": 5,\n    \"min_observations_to_analyze\": 20\n  }\n}\n```\n\n| Key | Default | Description |\n|-----|---------|-------------|\n| `observer.enabled` | `false` | Enable the background observer agent |\n| `observer.run_interval_minutes` | `5` | How often the observer analyzes observations |\n| `observer.min_observations_to_analyze` | `20` | Minimum observations before analysis runs |\n\nOther behavior (observation capture, instinct thresholds, project scoping, promotion criteria) is configured via code defaults in `instinct-cli.py` and `observe.sh`.\n\n### Observer platform support\n\nThe background observer requires WSL2, Linux, or macOS. On native Windows\n(Git Bash \u002F MSYS2) it starts and reports success, but the process is killed\nwhen the spawning hook exits and its Job Object closes, so no analysis ever\nruns — setting `observer.enabled: true` there is effectively a no-op\n(see issue #2489).\n\n`observe.sh` detects this on the following hook invocation and writes an\nexplanatory warning to `observer-start.log` once the observer has failed to\nsurvive several times in a row.\n\n| Env var | Default | Description |\n|---------|---------|-------------|\n| `ECC_OBSERVER_NOSURVIVE_WARN_AFTER` | `3` | Consecutive non-survivals before the warning is logged |\n\n## File Structure\n\n```\n${XDG_DATA_HOME:-~\u002F.local\u002Fshare}\u002Fecc-homunculus\u002F\n+-- identity.json           # Your profile, technical level\n+-- projects.json           # Registry: project hash -> name\u002Fpath\u002Fremote\n+-- observations.jsonl      # Global observations (fallback)\n+-- instincts\u002F\n|   +-- personal\u002F           # Global auto-learned instincts\n|   +-- inherited\u002F          # Global imported instincts\n+-- evolved\u002F\n|   +-- agents\u002F             # Global generated agents\n|   +-- skills\u002F             # Global generated skills\n|   +-- commands\u002F           # Global generated commands\n+-- projects\u002F\n    +-- a1b2c3d4e5f6\u002F       # Project hash (from git remote URL)\n    |   +-- project.json    # Per-project metadata mirror (id\u002Fname\u002Froot\u002Fremote)\n    |   +-- observations.jsonl\n    |   +-- observations.archive\u002F\n    |   +-- instincts\u002F\n    |   |   +-- personal\u002F   # Project-specific auto-learned\n    |   |   +-- inherited\u002F  # Project-specific imported\n    |   +-- evolved\u002F\n    |       +-- skills\u002F\n    |       +-- commands\u002F\n    |       +-- agents\u002F\n    +-- f6e5d4c3b2a1\u002F       # Another project\n        +-- ...\n```\n\n## Scope Decision Guide\n\n| Pattern Type | Scope | Examples |\n|-------------|-------|---------|\n| Language\u002Fframework conventions | **project** | \"Use React hooks\", \"Follow Django REST patterns\" |\n| File structure preferences | **project** | \"Tests in `__tests__`\u002F\", \"Components in src\u002Fcomponents\u002F\" |\n| Code style | **project** | \"Use functional style\", \"Prefer dataclasses\" |\n| Error handling strategies | **project** | \"Use Result type for errors\" |\n| Security practices | **global** | \"Validate user input\", \"Sanitize SQL\" |\n| General best practices | **global** | \"Write tests first\", \"Always handle errors\" |\n| Tool workflow preferences | **global** | \"Grep before Edit\", \"Read before Write\" |\n| Git practices | **global** | \"Conventional commits\", \"Small focused commits\" |\n\n## Instinct Promotion (Project -> Global)\n\nWhen the same instinct appears in multiple projects with high confidence, it's a candidate for promotion to global scope.\n\n**Auto-promotion criteria:**\n- Same instinct ID in 2+ projects\n- Average confidence >= 0.8\n\n**How to promote:**\n\n```bash\n# Promote a specific instinct\npython3 instinct-cli.py promote prefer-explicit-errors\n\n# Auto-promote all qualifying instincts\npython3 instinct-cli.py promote\n\n# Preview without changes\npython3 instinct-cli.py promote --dry-run\n```\n\nThe `\u002Fevolve` command also suggests promotion candidates.\n\n## Confidence Scoring\n\nConfidence evolves over time:\n\n| Score | Meaning | Behavior |\n|-------|---------|----------|\n| 0.3 | Tentative | Suggested but not enforced |\n| 0.5 | Moderate | Applied when relevant |\n| 0.7 | Strong | Auto-approved for application |\n| 0.9 | Near-certain | Core behavior |\n\n**Confidence increases** when:\n- Pattern is repeatedly observed\n- User doesn't correct the suggested behavior\n- Similar instincts from other sources agree\n\n**Confidence decreases** when:\n- User explicitly corrects the behavior\n- Pattern isn't observed for extended periods\n- Contradicting evidence appears\n\n## Why Hooks vs Skills for Observation?\n\n> \"v1 relied on skills to observe. Skills are probabilistic -- they fire ~50-80% of the time based on Claude's judgment.\"\n\nHooks fire **100% of the time**, deterministically. This means:\n- Every tool call is observed\n- No patterns are missed\n- Learning is comprehensive\n\n## Backward Compatibility\n\nv2.1 is fully compatible with v2.0 and v1:\n- Existing global instincts can be migrated from `~\u002F.claude\u002Fhomunculus\u002Finstincts\u002F` with `scripts\u002Fmigrate-homunculus.sh`\n- Existing `~\u002F.claude\u002Fskills\u002Flearned\u002F` skills from v1 still work\n- Stop hook still runs (but now also feeds into v2)\n- Gradual migration: run both in parallel\n\n## Privacy\n\n- Observations stay **local** on your machine\n- Project-scoped instincts are isolated per project\n- Only **instincts** (patterns) can be exported — not raw observations\n- No actual code or conversation content is shared\n- You control what gets exported and promoted\n\n## Related\n\n- [ECC-Tools GitHub App](https:\u002F\u002Fgithub.com\u002Fapps\u002Fecc-tools) - Generate instincts from repo history\n- Homunculus - Community project that inspired the v2 instinct-based architecture (atomic observations, confidence scoring, instinct evolution pipeline)\n- [The Longform Guide](https:\u002F\u002Fx.com\u002Faffaanmustafa\u002Fstatus\u002F2014040193557471352) - Continuous learning section\n\n---\n\n*Instinct-based learning: teaching Claude your patterns, one project at a time.*\n",{"name":5,"metadata":44,"description":7},{"origin":45,"version":46},"ECC","2.1.0","main","74715deacdc69119d739f38916f8ee4f0f979ebf","skills\u002Fstorage\u002Faffaan-m_ECC\u002Fcontinuous-learning-v2",0,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills","https:\u002F\u002Fgithub.com\u002Fmdnaimul22","AI Agents Workflows Automation | Specializing in Python, FastAPI, MCP Agents & Custom ERP.","2026-11-11 21:16:57",{"source":8,"skillName":5,"commands":56,"prompt":66,"zipAvailable":67},[57,60,63],{"tool":58,"command":59},"npx","npx skills add mdnaimul22\u002Fhuman-skills --skill continuous-learning-v2",{"tool":61,"command":62},"bunx","bunx skills add mdnaimul22\u002Fhuman-skills --skill continuous-learning-v2",{"tool":64,"command":65},"pnpm","pnpm dlx skills add mdnaimul22\u002Fhuman-skills --skill continuous-learning-v2","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Faffaan-m_ECC\u002Fcontinuous-learning-v2\u002FSKILL.md",true,[69,75,81,85,89,93,97,101,105,109,113],{"path":70,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":73,"sourceHtmlUrl":74},"agents\u002Fobserver-loop.sh","SCRIPT","脚本",19899,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Faffaan-m_ECC\u002Fcontinuous-learning-v2\u002Fagents\u002Fobserver-loop.sh",{"path":76,"resourceType":77,"resourceTypeDesc":78,"sizeBytes":79,"sourceHtmlUrl":80},"agents\u002Fobserver.md","REFERENCE","参考文档",6892,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Faffaan-m_ECC\u002Fcontinuous-learning-v2\u002Fagents\u002Fobserver.md",{"path":82,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":83,"sourceHtmlUrl":84},"agents\u002Fsession-guardian.sh",6392,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Faffaan-m_ECC\u002Fcontinuous-learning-v2\u002Fagents\u002Fsession-guardian.sh",{"path":86,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":87,"sourceHtmlUrl":88},"agents\u002Fstart-observer.sh",8643,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Faffaan-m_ECC\u002Fcontinuous-learning-v2\u002Fagents\u002Fstart-observer.sh",{"path":90,"resourceType":77,"resourceTypeDesc":78,"sizeBytes":91,"sourceHtmlUrl":92},"config.json",135,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Faffaan-m_ECC\u002Fcontinuous-learning-v2\u002Fconfig.json",{"path":94,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":95,"sourceHtmlUrl":96},"hooks\u002Fobserve.sh",28114,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Faffaan-m_ECC\u002Fcontinuous-learning-v2\u002Fhooks\u002Fobserve.sh",{"path":98,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":99,"sourceHtmlUrl":100},"scripts\u002Fdetect-project.sh",11036,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Faffaan-m_ECC\u002Fcontinuous-learning-v2\u002Fscripts\u002Fdetect-project.sh",{"path":102,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":103,"sourceHtmlUrl":104},"scripts\u002Finstinct-cli.py",91144,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Faffaan-m_ECC\u002Fcontinuous-learning-v2\u002Fscripts\u002Finstinct-cli.py",{"path":106,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":107,"sourceHtmlUrl":108},"scripts\u002Flib\u002Fhomunculus-dir.sh",1010,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Faffaan-m_ECC\u002Fcontinuous-learning-v2\u002Fscripts\u002Flib\u002Fhomunculus-dir.sh",{"path":110,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":111,"sourceHtmlUrl":112},"scripts\u002Fmigrate-homunculus.sh",2256,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Faffaan-m_ECC\u002Fcontinuous-learning-v2\u002Fscripts\u002Fmigrate-homunculus.sh",{"path":114,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":115,"sourceHtmlUrl":116},"scripts\u002Ftest_parse_instinct.py",51338,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Faffaan-m_ECC\u002Fcontinuous-learning-v2\u002Fscripts\u002Ftest_parse_instinct.py",[118,126,156,178,196,211],{"skillNo":119,"name":120,"nameZh":6,"description":121,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":122,"categories":123,"keywords":124,"publishedAt":125},"01M72JT3YP1SQHD0MANGDXQ4RT","higgsfield-websites","Build, edit, and deploy full-stack websites, apps and games via the Higgsfield CLI (`higgsfield website …`). Each is a React 19 + TanStack Start SSR app in one Cloudflare Worker (D1\u002FR2\u002FKV\u002FDO\u002FContainers). THREE product types, picked via `--type` on create: `website` (standalone, no Higgsfield integration — references\u002Fwebsite-flow.md), `app` (Sign in with Higgsfield + fnf SDK, Quanta — references\u002Fapp-flow.md), `game` (realtime multiplayer rooms — references\u002Fgame-flow.md). Routes to the right flow; each carries its own rules and deploy\u002Fpublish gates.\nUse when: \"build me a website\", \"make a landing page\", \"create a web app\", \"build a SaaS dashboard \u002F portfolio\", \"make me a game\", \"deploy this site\", \"publish\". Also owns GAME ART: \"make a spritesheet\", \"tileable texture\", \"animate a 3D character\", game music\u002FSFX — see the game-* references.\nNOT for: single image\u002Fvideo\u002Faudio generation (higgsfield-generate), product photos (higgsfield-product-photoshoot), marketplace cards (higgsfield-marketplace-cards).","https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Fhiggsfield-ai_skills\u002Fhiggsfield-websites\u002FSKILL.md",[],[],"2026-11-10 22:39:42",{"skillNo":127,"name":128,"nameZh":6,"description":129,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":130,"categories":131,"keywords":148,"publishedAt":39},"01M70JPK8HAXXA85P7Q8NKZZYG","writing-skills","Use when creating new skills, editing existing skills, or verifying skills work before deployment","https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Fobra_superpowers\u002Fwriting-skills\u002FSKILL.md",[132,137,142,145],{"categoryNo":133,"categoryName":134,"taxonomyType":135,"taxonomyTypeDesc":136},"01JBSEEDCAT000000000000018","写作与文案","SCENARIO","使用场景",{"categoryNo":138,"categoryName":139,"taxonomyType":140,"taxonomyTypeDesc":141},"01JBSEEDCAT000000000000036","内容创作者","PROFESSION","适用职业",{"categoryNo":143,"categoryName":144,"taxonomyType":135,"taxonomyTypeDesc":136},"01JBSEEDCAT000000000000023","Skill与智能体开发",{"categoryNo":146,"categoryName":147,"taxonomyType":135,"taxonomyTypeDesc":136},"01JBSEEDCAT000000000000008","测试与质量",[149,150,151,152,26,153,154,35,155],"writing","writing skills","editing","deployment","Existing","new","work",{"skillNo":157,"name":158,"nameZh":6,"description":159,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":160,"categories":161,"keywords":167,"publishedAt":39},"01M70JP4PHBH1CQVVDWZ94W159","writing-plans","Use when you have a spec or requirements for a multi-step task, before touching code","https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Fobra_superpowers\u002Fwriting-plans\u002FSKILL.md",[162,163,164],{"categoryNo":133,"categoryName":134,"taxonomyType":135,"taxonomyTypeDesc":136},{"categoryNo":138,"categoryName":139,"taxonomyType":140,"taxonomyTypeDesc":141},{"categoryNo":165,"categoryName":166,"taxonomyType":140,"taxonomyTypeDesc":141},"01JBSEEDCAT000000000000030","开发工程师",[149,168,169,170,35,171,172,26,173,174,175,176,177],"writing plans","plans","you","code","for","requirements","task","multi","spec","multi-step task",{"skillNo":179,"name":180,"nameZh":6,"description":181,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":182,"categories":183,"keywords":184,"publishedAt":39},"01M70JNTYVGXFZT8PASZ844TH8","verification-before-completion","Use when about to claim work is complete, fixed, or passing, before committing or creating PRs - requires running verification commands and confirming output before making any success claims; evidence before assertions always","https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Fobra_superpowers\u002Fverification-before-completion\u002FSKILL.md",[],[185,186,187,188,189,190,26,191,192,193,35,194,155,33,195],"verification","verification before completion","complete","about","output","assertions","prs","evidence","claim","claims","running",{"skillNo":197,"name":198,"nameZh":6,"description":199,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":200,"categories":201,"keywords":203,"publishedAt":39},"01M70JNGVSQDESWN0Q5BPJ875V","using-superpowers","Use when starting any conversation - establishes how to find and use skills, requiring skill invocation before ANY response including clarifying questions","https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Fobra_superpowers\u002Fusing-superpowers\u002FSKILL.md",[202],{"categoryNo":143,"categoryName":144,"taxonomyType":135,"taxonomyTypeDesc":136},[204,205,206,207,26,35,208,209,210],"using superpowers","superpowers","conversation","how to","how","find","questions",{"skillNo":212,"name":213,"nameZh":6,"description":214,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":215,"categories":216,"keywords":217,"publishedAt":39},"01M70JN57CE588NPYPYTWH1DWG","using-git-worktrees","Use when starting feature work that needs isolation from current workspace or before executing implementation plans - ensures an isolated workspace exists via native tools or git worktree fallback","https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Fobra_superpowers\u002Fusing-git-worktrees\u002FSKILL.md",[],[218,219,220,221,222,223,35,155,224,225,226,227,228,229,230,169,26,24,231],"using git worktrees","Using git","git","worktrees","git worktrees","implementation","git worktree","worktree","native","Tools","isolation","fallback","feature","workspace"]