diff --git a/hooks/intel-index.js b/hooks/intel-index.js index 1c2390d17..6b04b4b5d 100755 --- a/hooks/intel-index.js +++ b/hooks/intel-index.js @@ -351,6 +351,11 @@ function updateIndex(filePath, exports, imports) { // Write atomically fs.writeFileSync(indexPath, JSON.stringify(index, null, 2)); + + // Detect and save conventions (regenerated on every index update) + const conventions = detectConventions(index); + const conventionsPath = path.join(process.cwd(), '.planning', 'intel', 'conventions.json'); + fs.writeFileSync(conventionsPath, JSON.stringify(conventions, null, 2)); } // Read JSON from stdin (standard hook pattern)