agent-skills-standard 1.3.0 โ†’ 1.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -39,7 +39,7 @@ You can run the tool instantly without installing, or install it globally for co
39
39
 
40
40
  ```bash
41
41
  # Use instantly (Recommended)
42
- npx agent-skills-standard sync
42
+ npx agent-skills-standard@latest sync
43
43
 
44
44
  # Or install globally
45
45
  npm install -g agent-skills-standard
@@ -57,7 +57,7 @@ ags sync
57
57
  Run this once to detect your project type and choose which "skills" you want your AI to have.
58
58
 
59
59
  ```bash
60
- npx agent-skills-standard init
60
+ npx agent-skills-standard@latest init
61
61
  ```
62
62
 
63
63
  ### 2. Boost Your AI
@@ -65,7 +65,7 @@ npx agent-skills-standard init
65
65
  Run this to fetch the latest high-density instructions and install them into your hidden agent folders (like `.cursor/skills/` or `.github/skills/`).
66
66
 
67
67
  ```bash
68
- npx agent-skills-standard sync
68
+ npx agent-skills-standard@latest sync
69
69
 
70
70
  ```
71
71
 
@@ -101,6 +101,7 @@ skills:
101
101
  - **๐Ÿš€ High-Density Instructions**: Optimized syntax that is **40% more compact** than standard English.
102
102
  - **๐Ÿ›ก๏ธ Universal Support**: Works out-of-the-box with Cursor, Claude, GitHub Copilot, and more.
103
103
  - **๐Ÿ”’ Secure Protection**: Mark specific files as "Locked" (overrides) so the CLI never changes your custom tweaks.
104
+ - **๐Ÿงช Production-Grade Reliability**: Guarded by a 100% statement coverage test suite and strict CI enforcement.
104
105
 
105
106
  ---
106
107
 
@@ -25,8 +25,7 @@ class InitCommand {
25
25
  const agentDetection = await this.detectionService.detectAgents();
26
26
  const anyAgentDetected = Object.values(agentDetection).some((d) => d);
27
27
  const shouldCheck = (id) => anyAgentDetected ? agentDetection[id] : true;
28
- const defaultRegistry = 'https://github.com/HoangNguyen0403/agent-skills-standard';
29
- const { categories: supportedCategories, metadata } = await this.registryService.discoverRegistry(defaultRegistry);
28
+ const { categories: supportedCategories, metadata } = await this.registryService.discoverRegistry(constants_1.DEFAULT_REGISTER);
30
29
  const choices = constants_1.SUPPORTED_FRAMEWORKS.map((f) => ({
31
30
  name: supportedCategories.includes(f.id)
32
31
  ? f.name
@@ -70,17 +69,14 @@ class InitCommand {
70
69
  type: 'input',
71
70
  name: 'registry',
72
71
  message: 'Skills Registry URL:',
73
- default: defaultRegistry,
72
+ default: constants_1.DEFAULT_REGISTER,
74
73
  },
75
74
  ]);
76
- const framework = answers.framework;
77
- if (!supportedCategories.includes(framework)) {
78
- console.log(picocolors_1.default.yellow(`\nNotice: Skills for ${framework} are not yet strictly defined and will be added soon.`));
79
- console.log(picocolors_1.default.gray('The CLI will still generate rule files with global standards.\n'));
80
- }
81
- const config = this.configService.buildInitialConfig(framework, answers.agents, answers.registry, metadata);
75
+ const frameworkId = answers.framework;
76
+ const frameworkDef = constants_1.SUPPORTED_FRAMEWORKS.find((f) => f.id === frameworkId);
77
+ const config = this.configService.buildInitialConfig(frameworkId, answers.agents, answers.registry, metadata, frameworkDef?.languages || []);
82
78
  const projectDeps = await this.detectionService.getProjectDeps();
83
- this.configService.applyDependencyExclusions(config, framework, projectDeps);
79
+ this.configService.applyDependencyExclusions(config, frameworkId, projectDeps);
84
80
  const commentHeader = `# Auto-detected configuration generated by agent-skills-standard init
85
81
  #
86
82
  # Presence in 'skills' list = Active. To disable a skill, remove it from the list.
@@ -92,7 +88,7 @@ class InitCommand {
92
88
  `;
93
89
  await fs_extra_1.default.writeFile(configPath, commentHeader + js_yaml_1.default.dump(config));
94
90
  console.log(picocolors_1.default.green('\nโœ… Initialized .skillsrc with your preferences!'));
95
- console.log(picocolors_1.default.gray(` Selected framework: ${framework}`));
91
+ console.log(picocolors_1.default.gray(` Selected framework: ${frameworkId}`));
96
92
  console.log(picocolors_1.default.cyan('\nNext step: Run `agent-skills-standard sync` to generate rule files.'));
97
93
  }
98
94
  }
@@ -0,0 +1,21 @@
1
+ export declare enum Agent {
2
+ Cursor = "cursor",
3
+ Trae = "trae",
4
+ Claude = "claude",
5
+ Copilot = "copilot",
6
+ Antigravity = "antigravity",
7
+ OpenAI = "openai",
8
+ OpenCode = "opencode",
9
+ Gemini = "gemini",
10
+ Roo = "roo",
11
+ Windsurf = "windsurf"
12
+ }
13
+ export declare enum Framework {
14
+ Flutter = "flutter",
15
+ NestJS = "nestjs",
16
+ Golang = "golang",
17
+ NextJS = "nextjs",
18
+ React = "react",
19
+ ReactNative = "react-native",
20
+ Angular = "angular"
21
+ }
@@ -0,0 +1,26 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Framework = exports.Agent = void 0;
4
+ var Agent;
5
+ (function (Agent) {
6
+ Agent["Cursor"] = "cursor";
7
+ Agent["Trae"] = "trae";
8
+ Agent["Claude"] = "claude";
9
+ Agent["Copilot"] = "copilot";
10
+ Agent["Antigravity"] = "antigravity";
11
+ Agent["OpenAI"] = "openai";
12
+ Agent["OpenCode"] = "opencode";
13
+ Agent["Gemini"] = "gemini";
14
+ Agent["Roo"] = "roo";
15
+ Agent["Windsurf"] = "windsurf";
16
+ })(Agent || (exports.Agent = Agent = {}));
17
+ var Framework;
18
+ (function (Framework) {
19
+ Framework["Flutter"] = "flutter";
20
+ Framework["NestJS"] = "nestjs";
21
+ Framework["Golang"] = "golang";
22
+ Framework["NextJS"] = "nextjs";
23
+ Framework["React"] = "react";
24
+ Framework["ReactNative"] = "react-native";
25
+ Framework["Angular"] = "angular";
26
+ })(Framework || (exports.Framework = Framework = {}));
@@ -1,25 +1,7 @@
1
- export declare enum Agent {
2
- Cursor = "cursor",
3
- Trae = "trae",
4
- Claude = "claude",
5
- Copilot = "copilot",
6
- Antigravity = "antigravity",
7
- OpenAI = "openai",
8
- OpenCode = "opencode",
9
- Gemini = "gemini",
10
- Roo = "roo",
11
- Windsurf = "windsurf"
12
- }
13
- export declare enum Framework {
14
- Flutter = "flutter",
15
- NestJS = "nestjs",
16
- Golang = "golang",
17
- NextJS = "nextjs",
18
- React = "react",
19
- ReactNative = "react-native",
20
- Angular = "angular"
21
- }
1
+ import { Agent, Framework } from './enums';
2
+ export { Agent, Framework };
22
3
  export declare const UNIVERSAL_SKILLS: string[];
4
+ export declare const DEFAULT_REGISTER = "https://github.com/HoangNguyen0403/agent-skills-standard";
23
5
  export interface AgentDefinition {
24
6
  id: Agent;
25
7
  name: string;
@@ -1,96 +1,77 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.SKILL_DETECTION_REGISTRY = exports.SUPPORTED_FRAMEWORKS = exports.SUPPORTED_AGENTS = exports.getFrameworkDefinition = exports.getAgentDefinition = exports.UNIVERSAL_SKILLS = exports.Framework = exports.Agent = void 0;
4
- var Agent;
5
- (function (Agent) {
6
- Agent["Cursor"] = "cursor";
7
- Agent["Trae"] = "trae";
8
- Agent["Claude"] = "claude";
9
- Agent["Copilot"] = "copilot";
10
- Agent["Antigravity"] = "antigravity";
11
- Agent["OpenAI"] = "openai";
12
- Agent["OpenCode"] = "opencode";
13
- Agent["Gemini"] = "gemini";
14
- Agent["Roo"] = "roo";
15
- Agent["Windsurf"] = "windsurf";
16
- })(Agent || (exports.Agent = Agent = {}));
17
- var Framework;
18
- (function (Framework) {
19
- Framework["Flutter"] = "flutter";
20
- Framework["NestJS"] = "nestjs";
21
- Framework["Golang"] = "golang";
22
- Framework["NextJS"] = "nextjs";
23
- Framework["React"] = "react";
24
- Framework["ReactNative"] = "react-native";
25
- Framework["Angular"] = "angular";
26
- })(Framework || (exports.Framework = Framework = {}));
3
+ exports.SKILL_DETECTION_REGISTRY = exports.SUPPORTED_FRAMEWORKS = exports.SUPPORTED_AGENTS = exports.getFrameworkDefinition = exports.getAgentDefinition = exports.DEFAULT_REGISTER = exports.UNIVERSAL_SKILLS = exports.Framework = exports.Agent = void 0;
4
+ const enums_1 = require("./enums");
5
+ Object.defineProperty(exports, "Agent", { enumerable: true, get: function () { return enums_1.Agent; } });
6
+ Object.defineProperty(exports, "Framework", { enumerable: true, get: function () { return enums_1.Framework; } });
27
7
  exports.UNIVERSAL_SKILLS = ['common'];
8
+ exports.DEFAULT_REGISTER = 'https://github.com/HoangNguyen0403/agent-skills-standard';
28
9
  const getAgentDefinition = (id) => {
29
10
  switch (id) {
30
- case Agent.Cursor:
11
+ case enums_1.Agent.Cursor:
31
12
  return {
32
13
  id,
33
14
  name: 'Cursor',
34
15
  path: '.cursor/skills',
35
16
  detectionFiles: ['.cursor', '.cursorrules'],
36
17
  };
37
- case Agent.Trae:
18
+ case enums_1.Agent.Trae:
38
19
  return {
39
20
  id,
40
21
  name: 'Trae',
41
22
  path: '.trae/skills',
42
23
  detectionFiles: ['.trae'],
43
24
  };
44
- case Agent.Claude:
25
+ case enums_1.Agent.Claude:
45
26
  return {
46
27
  id,
47
28
  name: 'Claude Code',
48
29
  path: '.claude/skills',
49
30
  detectionFiles: ['.claude', 'CLAUDE.md'],
50
31
  };
51
- case Agent.Copilot:
32
+ case enums_1.Agent.Copilot:
52
33
  return {
53
34
  id,
54
35
  name: 'GitHub Copilot',
55
36
  path: '.github/skills',
56
37
  detectionFiles: ['.github'],
57
38
  };
58
- case Agent.Antigravity:
39
+ case enums_1.Agent.Antigravity:
59
40
  return {
60
41
  id,
61
42
  name: 'Antigravity',
62
43
  path: '.agent/skills',
63
44
  detectionFiles: ['.agent'],
64
45
  };
65
- case Agent.OpenAI:
46
+ case enums_1.Agent.OpenAI:
66
47
  return {
67
48
  id,
68
49
  name: 'OpenAI',
69
50
  path: '.codex/skills',
70
51
  detectionFiles: ['.codex'],
71
52
  };
72
- case Agent.OpenCode:
53
+ case enums_1.Agent.OpenCode:
73
54
  return {
74
55
  id,
75
56
  name: 'OpenCode',
76
57
  path: '.opencode/skills',
77
58
  detectionFiles: ['.opencode'],
78
59
  };
79
- case Agent.Gemini:
60
+ case enums_1.Agent.Gemini:
80
61
  return {
81
62
  id,
82
63
  name: 'Gemini',
83
64
  path: '.gemini/skills',
84
65
  detectionFiles: ['.gemini'],
85
66
  };
86
- case Agent.Roo:
67
+ case enums_1.Agent.Roo:
87
68
  return {
88
69
  id,
89
70
  name: 'Roo Code',
90
71
  path: '.roo/skills',
91
72
  detectionFiles: ['.roo'],
92
73
  };
93
- case Agent.Windsurf:
74
+ case enums_1.Agent.Windsurf:
94
75
  return {
95
76
  id,
96
77
  name: 'Windsurf',
@@ -102,14 +83,14 @@ const getAgentDefinition = (id) => {
102
83
  exports.getAgentDefinition = getAgentDefinition;
103
84
  const getFrameworkDefinition = (id) => {
104
85
  switch (id) {
105
- case Framework.Flutter:
86
+ case enums_1.Framework.Flutter:
106
87
  return {
107
88
  id,
108
89
  name: 'Flutter',
109
90
  languages: ['dart'],
110
91
  detectionFiles: ['pubspec.yaml'],
111
92
  };
112
- case Framework.NestJS:
93
+ case enums_1.Framework.NestJS:
113
94
  return {
114
95
  id,
115
96
  name: 'NestJS',
@@ -117,14 +98,14 @@ const getFrameworkDefinition = (id) => {
117
98
  detectionFiles: ['nest-cli.json'],
118
99
  detectionDependencies: ['@nestjs/core'],
119
100
  };
120
- case Framework.Golang:
101
+ case enums_1.Framework.Golang:
121
102
  return {
122
103
  id,
123
104
  name: 'Go (Golang)',
124
105
  languages: ['go'],
125
106
  detectionFiles: ['go.mod'],
126
107
  };
127
- case Framework.NextJS:
108
+ case enums_1.Framework.NextJS:
128
109
  return {
129
110
  id,
130
111
  name: 'Next.js',
@@ -132,7 +113,7 @@ const getFrameworkDefinition = (id) => {
132
113
  detectionFiles: ['next.config.js', 'next.config.mjs'],
133
114
  detectionDependencies: ['next'],
134
115
  };
135
- case Framework.React:
116
+ case enums_1.Framework.React:
136
117
  return {
137
118
  id,
138
119
  name: 'React',
@@ -140,7 +121,7 @@ const getFrameworkDefinition = (id) => {
140
121
  detectionFiles: [],
141
122
  detectionDependencies: ['react', 'react-dom'],
142
123
  };
143
- case Framework.ReactNative:
124
+ case enums_1.Framework.ReactNative:
144
125
  return {
145
126
  id,
146
127
  name: 'React Native',
@@ -148,7 +129,7 @@ const getFrameworkDefinition = (id) => {
148
129
  detectionFiles: ['metro.config.js'],
149
130
  detectionDependencies: ['react-native'],
150
131
  };
151
- case Framework.Angular:
132
+ case enums_1.Framework.Angular:
152
133
  return {
153
134
  id,
154
135
  name: 'Angular',
@@ -158,7 +139,7 @@ const getFrameworkDefinition = (id) => {
158
139
  }
159
140
  };
160
141
  exports.getFrameworkDefinition = getFrameworkDefinition;
161
- exports.SUPPORTED_AGENTS = Object.values(Agent).map(exports.getAgentDefinition);
162
- exports.SUPPORTED_FRAMEWORKS = Object.values(Framework).map(exports.getFrameworkDefinition);
142
+ exports.SUPPORTED_AGENTS = Object.values(enums_1.Agent).map(exports.getAgentDefinition);
143
+ exports.SUPPORTED_FRAMEWORKS = Object.values(enums_1.Framework).map(exports.getFrameworkDefinition);
163
144
  var skills_1 = require("./skills");
164
145
  Object.defineProperty(exports, "SKILL_DETECTION_REGISTRY", { enumerable: true, get: function () { return skills_1.SKILL_DETECTION_REGISTRY; } });
@@ -1,12 +1,12 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.SKILL_DETECTION_REGISTRY = void 0;
4
- const index_1 = require("./index");
4
+ const enums_1 = require("./enums");
5
5
  /**
6
6
  * Registry of automatic skill detection rules grouped by framework.
7
7
  */
8
8
  exports.SKILL_DETECTION_REGISTRY = {
9
- [index_1.Framework.Flutter]: [
9
+ [enums_1.Framework.Flutter]: [
10
10
  {
11
11
  id: 'riverpod-state-management',
12
12
  packages: ['flutter_riverpod', 'riverpod'],
@@ -40,7 +40,7 @@ exports.SKILL_DETECTION_REGISTRY = {
40
40
  packages: ['retrofit'],
41
41
  },
42
42
  ],
43
- [index_1.Framework.NestJS]: [
43
+ [enums_1.Framework.NestJS]: [
44
44
  {
45
45
  id: 'caching',
46
46
  packages: ['@nestjs/cache-manager', 'cache-manager'],
package/dist/index.js CHANGED
@@ -10,7 +10,7 @@ const program = new commander_1.Command();
10
10
  program
11
11
  .name('agent-skills-standard')
12
12
  .description('A CLI to manage and sync AI agent skills for Cursor, Claude, Copilot, Windsurf, and more.')
13
- .version('1.3.0');
13
+ .version('1.3.1');
14
14
  program
15
15
  .command('init')
16
16
  .description('Initialize a .skillsrc configuration file interactively')
@@ -0,0 +1,7 @@
1
+ #!/usr/bin/env node
2
+ /**
3
+ * Token Metrics Calculator
4
+ * Calculates token costs for each skill category based on SKILL.md files.
5
+ * Uses character-based approximation: ~4 characters = 1 token (cl100k_base average)
6
+ */
7
+ export {};
@@ -0,0 +1,159 @@
1
+ #!/usr/bin/env node
2
+ "use strict";
3
+ /**
4
+ * Token Metrics Calculator
5
+ * Calculates token costs for each skill category based on SKILL.md files.
6
+ * Uses character-based approximation: ~4 characters = 1 token (cl100k_base average)
7
+ */
8
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
9
+ if (k2 === undefined) k2 = k;
10
+ var desc = Object.getOwnPropertyDescriptor(m, k);
11
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
12
+ desc = { enumerable: true, get: function() { return m[k]; } };
13
+ }
14
+ Object.defineProperty(o, k2, desc);
15
+ }) : (function(o, m, k, k2) {
16
+ if (k2 === undefined) k2 = k;
17
+ o[k2] = m[k];
18
+ }));
19
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
20
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
21
+ }) : function(o, v) {
22
+ o["default"] = v;
23
+ });
24
+ var __importStar = (this && this.__importStar) || (function () {
25
+ var ownKeys = function(o) {
26
+ ownKeys = Object.getOwnPropertyNames || function (o) {
27
+ var ar = [];
28
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
29
+ return ar;
30
+ };
31
+ return ownKeys(o);
32
+ };
33
+ return function (mod) {
34
+ if (mod && mod.__esModule) return mod;
35
+ var result = {};
36
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
37
+ __setModuleDefault(result, mod);
38
+ return result;
39
+ };
40
+ })();
41
+ var __importDefault = (this && this.__importDefault) || function (mod) {
42
+ return (mod && mod.__esModule) ? mod : { "default": mod };
43
+ };
44
+ Object.defineProperty(exports, "__esModule", { value: true });
45
+ const fs_extra_1 = __importDefault(require("fs-extra"));
46
+ const path = __importStar(require("path"));
47
+ const SKILLS_DIR = path.join(__dirname, '../../../skills');
48
+ const METADATA_PATH = path.join(SKILLS_DIR, 'metadata.json');
49
+ const CHARS_PER_TOKEN = 4; // Approximate ratio for cl100k_base tokenizer
50
+ function calculateFileTokens(filePath) {
51
+ const content = fs_extra_1.default.readFileSync(filePath, 'utf-8');
52
+ const lines = content.split('\n').length;
53
+ const characters = content.length;
54
+ const tokens = Math.ceil(characters / CHARS_PER_TOKEN);
55
+ return { lines, characters, tokens };
56
+ }
57
+ function getSkillsInCategory(categoryPath) {
58
+ const skills = [];
59
+ if (!fs_extra_1.default.existsSync(categoryPath)) {
60
+ return skills;
61
+ }
62
+ const entries = fs_extra_1.default.readdirSync(categoryPath, { withFileTypes: true });
63
+ for (const entry of entries) {
64
+ if (entry.isDirectory()) {
65
+ const skillMdPath = path.join(categoryPath, entry.name, 'SKILL.md');
66
+ if (fs_extra_1.default.existsSync(skillMdPath)) {
67
+ const metrics = calculateFileTokens(skillMdPath);
68
+ skills.push({
69
+ skillName: entry.name,
70
+ ...metrics,
71
+ });
72
+ }
73
+ }
74
+ }
75
+ return skills;
76
+ }
77
+ function calculateCategoryMetrics(skills) {
78
+ if (skills.length === 0) {
79
+ return {
80
+ totalSkills: 0,
81
+ totalLines: 0,
82
+ totalCharacters: 0,
83
+ totalTokens: 0,
84
+ avgTokensPerSkill: 0,
85
+ largestSkill: 'N/A',
86
+ largestSkillTokens: 0,
87
+ };
88
+ }
89
+ const totalSkills = skills.length;
90
+ const totalLines = skills.reduce((sum, s) => sum + s.lines, 0);
91
+ const totalCharacters = skills.reduce((sum, s) => sum + s.characters, 0);
92
+ const totalTokens = skills.reduce((sum, s) => sum + s.tokens, 0);
93
+ const avgTokensPerSkill = Math.round(totalTokens / totalSkills);
94
+ const largest = skills.reduce((max, s) => (s.tokens > max.tokens ? s : max), skills[0]);
95
+ return {
96
+ totalSkills,
97
+ totalLines,
98
+ totalCharacters,
99
+ totalTokens,
100
+ avgTokensPerSkill,
101
+ largestSkill: largest.skillName,
102
+ largestSkillTokens: largest.tokens,
103
+ };
104
+ }
105
+ async function main() {
106
+ console.log('๐Ÿ“Š Calculating token metrics for skills...\n');
107
+ // Read existing metadata
108
+ const metadata = JSON.parse(fs_extra_1.default.readFileSync(METADATA_PATH, 'utf-8'));
109
+ // Get all categories
110
+ const categories = Object.keys(metadata.categories);
111
+ const results = {};
112
+ for (const category of categories) {
113
+ const categoryPath = path.join(SKILLS_DIR, category);
114
+ const skills = getSkillsInCategory(categoryPath);
115
+ const metrics = calculateCategoryMetrics(skills);
116
+ results[category] = metrics;
117
+ // Update metadata with token_metrics
118
+ metadata.categories[category].token_metrics = {
119
+ total_skills: metrics.totalSkills,
120
+ total_tokens: metrics.totalTokens,
121
+ avg_tokens_per_skill: metrics.avgTokensPerSkill,
122
+ largest_skill: `${metrics.largestSkill} (${metrics.largestSkillTokens} tokens)`,
123
+ };
124
+ console.log(`๐Ÿ“ฆ ${category}:`);
125
+ console.log(` Skills: ${metrics.totalSkills}`);
126
+ console.log(` Total Tokens: ${metrics.totalTokens}`);
127
+ console.log(` Avg/Skill: ${metrics.avgTokensPerSkill}`);
128
+ console.log(` Largest: ${metrics.largestSkill} (${metrics.largestSkillTokens} tokens)`);
129
+ console.log('');
130
+ }
131
+ // Calculate grand total
132
+ const grandTotal = Object.values(results).reduce((sum, m) => sum + m.totalTokens, 0);
133
+ const totalSkills = Object.values(results).reduce((sum, m) => sum + m.totalSkills, 0);
134
+ console.log('โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•');
135
+ console.log(`๐Ÿ“ˆ GRAND TOTAL: ${grandTotal} tokens across ${totalSkills} skills`);
136
+ console.log('โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•\n');
137
+ // Write updated metadata
138
+ fs_extra_1.default.writeFileSync(METADATA_PATH, JSON.stringify(metadata, null, 2) + '\n');
139
+ console.log('โœ… Updated metadata.json with token_metrics');
140
+ // Update README.md table
141
+ const readmePath = path.join(__dirname, '../../../README.md');
142
+ if (fs_extra_1.default.existsSync(readmePath)) {
143
+ let readmeContent = fs_extra_1.default.readFileSync(readmePath, 'utf-8');
144
+ for (const category of categories) {
145
+ const metrics = results[category];
146
+ const version = metadata.categories[category].version;
147
+ // Find the row for this category (case-insensitive for emojis)
148
+ // Standardizes on the format: | **ICON Category** | Key Modules | Version | Skills | Avg. Footprint |
149
+ const regex = new RegExp(`(\\|\\s*\\*\\*.*${category}.*\\*\\*\\s*\\|.*\\|\\s*\`v?${version}\`\\s*\\|)\\s*\\d+\\s*\\|\\s*~?\\d+\\s*tokens\\s*\\|`, 'i');
150
+ const replacement = `$1 ${metrics.totalSkills} | ~${metrics.avgTokensPerSkill} tokens |`;
151
+ if (readmeContent.match(regex)) {
152
+ readmeContent = readmeContent.replace(regex, replacement);
153
+ }
154
+ }
155
+ fs_extra_1.default.writeFileSync(readmePath, readmeContent);
156
+ console.log('โœ… Updated README.md support table');
157
+ }
158
+ }
159
+ main().catch(console.error);
@@ -3,6 +3,6 @@ import { RegistryMetadata } from '../models/types';
3
3
  export declare class ConfigService {
4
4
  loadConfig(cwd?: string): Promise<SkillConfig | null>;
5
5
  saveConfig(config: SkillConfig, cwd?: string): Promise<void>;
6
- buildInitialConfig(framework: string, agents: string[], registry: string, metadata: Partial<RegistryMetadata>): SkillConfig;
6
+ buildInitialConfig(framework: string, agents: string[], registry: string, metadata: Partial<RegistryMetadata>, languages?: string[]): SkillConfig;
7
7
  applyDependencyExclusions(config: SkillConfig, framework: string, projectDeps: Set<string>): void;
8
8
  }
@@ -44,7 +44,7 @@ class ConfigService {
44
44
  const configPath = path_1.default.join(cwd, '.skillsrc');
45
45
  await fs_extra_1.default.writeFile(configPath, js_yaml_1.default.dump(config));
46
46
  }
47
- buildInitialConfig(framework, agents, registry, metadata) {
47
+ buildInitialConfig(framework, agents, registry, metadata, languages = []) {
48
48
  const skills = {};
49
49
  // Add main framework
50
50
  skills[framework] = {
@@ -52,6 +52,14 @@ class ConfigService {
52
52
  ? `${metadata.categories[framework].tag_prefix || ''}${metadata.categories[framework].version}`
53
53
  : 'main',
54
54
  };
55
+ // Add associated languages (e.g., typescript, javascript)
56
+ for (const lang of languages) {
57
+ if (metadata.categories?.[lang]) {
58
+ skills[lang] = {
59
+ ref: `${metadata.categories[lang].tag_prefix || ''}${metadata.categories[lang].version}`,
60
+ };
61
+ }
62
+ }
55
63
  // Add common category if available
56
64
  if (metadata.categories?.['common']) {
57
65
  skills['common'] = {