@skillrecordings/cli 0.18.0 → 0.18.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.
@@ -3,7 +3,7 @@ import {
3
3
  SUPPORT_AGENT_PROMPT,
4
4
  agentTools,
5
5
  runSupportAgent
6
- } from "./chunk-IR6KG25Y.js";
6
+ } from "./chunk-LV53JZHC.js";
7
7
  import "./chunk-KEV3QKXP.js";
8
8
  import "./chunk-MLNDSBZ4.js";
9
9
  import "./chunk-ZNF7XD2S.js";
@@ -18,4 +18,4 @@ export {
18
18
  agentTools,
19
19
  runSupportAgent
20
20
  };
21
- //# sourceMappingURL=config-C7CDVTO7.js.map
21
+ //# sourceMappingURL=config-6PEJQQJY.js.map
package/dist/index.js CHANGED
@@ -20,7 +20,7 @@ import {
20
20
  runPipeline,
21
21
  validate,
22
22
  validateSync
23
- } from "./chunk-J4IC3GC3.js";
23
+ } from "./chunk-ZCWCT4ES.js";
24
24
  import "./chunk-HK3PEWFD.js";
25
25
  import "./chunk-WYKL32C3.js";
26
26
  import {
@@ -40,7 +40,7 @@ import {
40
40
  getApp,
41
41
  getOutcomeHistory,
42
42
  getRedis
43
- } from "./chunk-IR6KG25Y.js";
43
+ } from "./chunk-LV53JZHC.js";
44
44
  import "./chunk-KEV3QKXP.js";
45
45
  import {
46
46
  MemoryService,
@@ -74555,7 +74555,7 @@ import { resolve as resolve8 } from "path";
74555
74555
 
74556
74556
  // src/core/config-loader.ts
74557
74557
  init_esm_shims();
74558
- import { readFileSync } from "fs";
74558
+ import { existsSync as existsSync2, readFileSync } from "fs";
74559
74559
  import { resolve } from "path";
74560
74560
 
74561
74561
  // src/core/user-config.ts
@@ -74603,6 +74603,13 @@ function getUserConfigDir(configDir) {
74603
74603
  function getUserConfigPath(fileName, configDir) {
74604
74604
  return join(getUserConfigDir(configDir), fileName);
74605
74605
  }
74606
+ function getAgeKeyPath(configDir) {
74607
+ const envKey = process.env.AGE_USER_KEY;
74608
+ if (envKey && envKey.trim() !== "") {
74609
+ return envKey;
74610
+ }
74611
+ return getUserConfigPath(USER_CONFIG_PATHS.ageKey, configDir);
74612
+ }
74606
74613
 
74607
74614
  // src/core/config-loader.ts
74608
74615
  function parseEnvContent(content) {
@@ -74620,12 +74627,11 @@ function parseEnvContent(content) {
74620
74627
  return env;
74621
74628
  }
74622
74629
  async function decryptEnvFile(encryptedPath) {
74623
- const { existsSync: existsSync17 } = await import("fs");
74624
74630
  const { readFile: readFile10 } = await import("fs/promises");
74625
- if (!existsSync17(encryptedPath)) {
74631
+ if (!existsSync2(encryptedPath)) {
74626
74632
  return {};
74627
74633
  }
74628
- const ageKey = await getAgeKeyFrom1Password();
74634
+ const ageKey = await getAgeKey();
74629
74635
  if (!ageKey) {
74630
74636
  return {};
74631
74637
  }
@@ -74638,10 +74644,18 @@ async function decryptEnvFile(encryptedPath) {
74638
74644
  return {};
74639
74645
  }
74640
74646
  }
74641
- async function getAgeKeyFrom1Password() {
74647
+ async function getAgeKey() {
74642
74648
  if (process.env.SKILL_AGE_KEY) {
74643
74649
  return process.env.SKILL_AGE_KEY;
74644
74650
  }
74651
+ try {
74652
+ const ageKeyPath = getAgeKeyPath();
74653
+ if (existsSync2(ageKeyPath)) {
74654
+ const key = readFileSync(ageKeyPath, "utf8").trim();
74655
+ if (key) return key;
74656
+ }
74657
+ } catch {
74658
+ }
74645
74659
  try {
74646
74660
  const { getFromKeychain: getFromKeychain2, storeInKeychain: storeInKeychain2, autoBootstrapKeychain: autoBootstrapKeychain2 } = await import("./keychain-IEZHT5WN.js");
74647
74661
  const fromKeychain = getFromKeychain2("age-private-key");
@@ -75087,7 +75101,7 @@ async function loginAction(ctx, options) {
75087
75101
 
75088
75102
  // src/commands/auth/setup.ts
75089
75103
  init_esm_shims();
75090
- import { existsSync as existsSync2, writeFileSync } from "fs";
75104
+ import { existsSync as existsSync3, writeFileSync } from "fs";
75091
75105
  import { resolve as resolve2 } from "path";
75092
75106
  import { confirm, select } from "@inquirer/prompts";
75093
75107
 
@@ -75436,7 +75450,7 @@ async function authSetupAction(ctx, options = {}) {
75436
75450
  });
75437
75451
  if (persistence === "env") {
75438
75452
  const envPath = resolve2(process.cwd(), ".env.local");
75439
- if (existsSync2(envPath)) {
75453
+ if (existsSync3(envPath)) {
75440
75454
  const overwrite = await confirm({
75441
75455
  message: `.env.local already exists at ${envPath}. Overwrite?`,
75442
75456
  default: false
@@ -77143,12 +77157,12 @@ init_esm_shims();
77143
77157
 
77144
77158
  // src/commands/config/get.ts
77145
77159
  init_esm_shims();
77146
- import { existsSync as existsSync4, readFileSync as readFileSync3 } from "fs";
77160
+ import { existsSync as existsSync5, readFileSync as readFileSync3 } from "fs";
77147
77161
  import { Decrypter as Decrypter2 } from "age-encryption";
77148
77162
 
77149
77163
  // src/commands/config/set.ts
77150
77164
  init_esm_shims();
77151
- import { existsSync as existsSync3, readFileSync as readFileSync2, writeFileSync as writeFileSync3 } from "fs";
77165
+ import { existsSync as existsSync4, readFileSync as readFileSync2, writeFileSync as writeFileSync3 } from "fs";
77152
77166
  import { password, select as select2 } from "@inquirer/prompts";
77153
77167
  import { Decrypter, Encrypter, identityToRecipient } from "age-encryption";
77154
77168
 
@@ -77159,7 +77173,7 @@ import { join as join2 } from "path";
77159
77173
  function getUserConfigDir2() {
77160
77174
  return join2(homedir2(), ".config", "skill");
77161
77175
  }
77162
- function getAgeKeyPath() {
77176
+ function getAgeKeyPath2() {
77163
77177
  return join2(getUserConfigDir2(), "age.key");
77164
77178
  }
77165
77179
  async function configInitAction(ctx, options = {}) {
@@ -77197,7 +77211,7 @@ function parseKeyValue(input2) {
77197
77211
  return { key, value };
77198
77212
  }
77199
77213
  async function readExistingConfig(identity, configPath) {
77200
- if (!existsSync3(configPath)) {
77214
+ if (!existsSync4(configPath)) {
77201
77215
  return {};
77202
77216
  }
77203
77217
  try {
@@ -77223,8 +77237,8 @@ async function readExistingConfig(identity, configPath) {
77223
77237
  }
77224
77238
  async function configSetAction(ctx, keyValue, options = {}) {
77225
77239
  const outputJson = options.json === true || ctx.format === "json";
77226
- const keyPath = getAgeKeyPath();
77227
- if (!existsSync3(keyPath)) {
77240
+ const keyPath = getAgeKeyPath2();
77241
+ if (!existsSync4(keyPath)) {
77228
77242
  const result = {
77229
77243
  success: false,
77230
77244
  error: "Age key not found. Run: skill config init"
@@ -77311,24 +77325,9 @@ async function configSetAction(ctx, keyValue, options = {}) {
77311
77325
  }
77312
77326
 
77313
77327
  // src/commands/config/get.ts
77314
- async function getAgeKeyFrom1Password2() {
77315
- if (!process.env.OP_SERVICE_ACCOUNT_TOKEN) {
77316
- return null;
77317
- }
77318
- try {
77319
- const { OnePasswordProvider: OnePasswordProvider2 } = await import("./secrets-MGVPGMFJ.js");
77320
- const op = new OnePasswordProvider2();
77321
- if (!await op.isAvailable()) {
77322
- return null;
77323
- }
77324
- return await op.resolve("op://Support/skill-cli-age-key/private_key");
77325
- } catch {
77326
- return null;
77327
- }
77328
- }
77329
77328
  async function decryptConfig(identity) {
77330
77329
  const configPath = getEncryptedConfigPath();
77331
- if (!existsSync4(configPath)) {
77330
+ if (!existsSync5(configPath)) {
77332
77331
  return {};
77333
77332
  }
77334
77333
  const encrypted = readFileSync3(configPath);
@@ -77356,11 +77355,11 @@ async function decryptConfig(identity) {
77356
77355
  }
77357
77356
  async function configGetAction(ctx, key, options = {}) {
77358
77357
  const outputJson = options.json === true || ctx.format === "json";
77359
- const identity = await getAgeKeyFrom1Password2();
77358
+ const identity = await getAgeKey();
77360
77359
  if (!identity) {
77361
77360
  const result = {
77362
77361
  success: false,
77363
- error: "OP_SERVICE_ACCOUNT_TOKEN not set. Required for encrypted config."
77362
+ error: "No age key found. Set SKILL_AGE_KEY, place key at ~/.config/skill/age.key, or configure 1Password."
77364
77363
  };
77365
77364
  if (outputJson) {
77366
77365
  ctx.output.data(result);
@@ -77413,26 +77412,11 @@ async function configGetAction(ctx, key, options = {}) {
77413
77412
 
77414
77413
  // src/commands/config/list.ts
77415
77414
  init_esm_shims();
77416
- import { existsSync as existsSync5, readFileSync as readFileSync4 } from "fs";
77415
+ import { existsSync as existsSync6, readFileSync as readFileSync4 } from "fs";
77417
77416
  import { Decrypter as Decrypter3 } from "age-encryption";
77418
- async function getAgeKeyFrom1Password3() {
77419
- if (!process.env.OP_SERVICE_ACCOUNT_TOKEN) {
77420
- return null;
77421
- }
77422
- try {
77423
- const { OnePasswordProvider: OnePasswordProvider2 } = await import("./secrets-MGVPGMFJ.js");
77424
- const op = new OnePasswordProvider2();
77425
- if (!await op.isAvailable()) {
77426
- return null;
77427
- }
77428
- return await op.resolve("op://Support/skill-cli-age-key/private_key");
77429
- } catch {
77430
- return null;
77431
- }
77432
- }
77433
77417
  async function decryptConfig2(identity) {
77434
77418
  const configPath = getEncryptedConfigPath();
77435
- if (!existsSync5(configPath)) {
77419
+ if (!existsSync6(configPath)) {
77436
77420
  return {};
77437
77421
  }
77438
77422
  const encrypted = readFileSync4(configPath);
@@ -77460,11 +77444,11 @@ async function decryptConfig2(identity) {
77460
77444
  }
77461
77445
  async function configListAction(ctx, options = {}) {
77462
77446
  const outputJson = options.json === true || ctx.format === "json";
77463
- const identity = await getAgeKeyFrom1Password3();
77447
+ const identity = await getAgeKey();
77464
77448
  if (!identity) {
77465
77449
  const result = {
77466
77450
  success: false,
77467
- error: "OP_SERVICE_ACCOUNT_TOKEN not set. Required for encrypted config."
77451
+ error: "No age key found. Set SKILL_AGE_KEY, place key at ~/.config/skill/age.key, or configure 1Password."
77468
77452
  };
77469
77453
  if (outputJson) {
77470
77454
  ctx.output.data(result);
@@ -77889,7 +77873,7 @@ function registerDeployCommands(program3) {
77889
77873
  // src/commands/doctor.ts
77890
77874
  init_esm_shims();
77891
77875
  import { execSync as execSync3 } from "child_process";
77892
- import { existsSync as existsSync6 } from "fs";
77876
+ import { existsSync as existsSync7 } from "fs";
77893
77877
  import { join as join3 } from "path";
77894
77878
  var REQUIRED_ENV_VARS = [
77895
77879
  "DATABASE_URL",
@@ -77954,7 +77938,7 @@ function checkTools() {
77954
77938
  function checkWorkspace() {
77955
77939
  const checks = [];
77956
77940
  const hivePath = join3(process.cwd(), ".hive");
77957
- const hiveExists = existsSync6(hivePath);
77941
+ const hiveExists = existsSync7(hivePath);
77958
77942
  checks.push({
77959
77943
  name: ".hive directory",
77960
77944
  status: hiveExists ? "ok" : "warn",
@@ -80393,7 +80377,7 @@ init_esm_shims();
80393
80377
  // src/commands/eval-pipeline/run.ts
80394
80378
  init_esm_shims();
80395
80379
  import { createHash as createHash2 } from "crypto";
80396
- import { existsSync as existsSync7, mkdirSync, readFileSync as readFileSync5, rmSync, writeFileSync as writeFileSync4 } from "fs";
80380
+ import { existsSync as existsSync8, mkdirSync, readFileSync as readFileSync5, rmSync, writeFileSync as writeFileSync4 } from "fs";
80397
80381
  import { join as join6 } from "path";
80398
80382
  import { readFile as readFile6 } from "fs/promises";
80399
80383
  import { glob as glob4 } from "glob";
@@ -80811,7 +80795,7 @@ function getClassifySourceHash() {
80811
80795
  join6(process.cwd(), "../core/src/pipeline/classify.ts")
80812
80796
  ];
80813
80797
  for (const path of possiblePaths) {
80814
- if (existsSync7(path)) {
80798
+ if (existsSync8(path)) {
80815
80799
  const content = readFileSync5(path, "utf-8");
80816
80800
  return createHash2("md5").update(content).digest("hex");
80817
80801
  }
@@ -80823,7 +80807,7 @@ function getClassifySourceHash() {
80823
80807
  function loadCachedClassify(cacheKey) {
80824
80808
  const cachePath = join6(CACHE_DIR, `${cacheKey}.json`);
80825
80809
  try {
80826
- if (existsSync7(cachePath)) {
80810
+ if (existsSync8(cachePath)) {
80827
80811
  return JSON.parse(readFileSync5(cachePath, "utf-8"));
80828
80812
  }
80829
80813
  } catch {
@@ -80832,7 +80816,7 @@ function loadCachedClassify(cacheKey) {
80832
80816
  }
80833
80817
  function saveCachedClassify(cacheKey, result) {
80834
80818
  try {
80835
- if (!existsSync7(CACHE_DIR)) {
80819
+ if (!existsSync8(CACHE_DIR)) {
80836
80820
  mkdirSync(CACHE_DIR, { recursive: true });
80837
80821
  }
80838
80822
  const cachePath = join6(CACHE_DIR, `${cacheKey}.json`);
@@ -80842,7 +80826,7 @@ function saveCachedClassify(cacheKey, result) {
80842
80826
  }
80843
80827
  function clearClassifyCache() {
80844
80828
  try {
80845
- if (existsSync7(CACHE_DIR)) {
80829
+ if (existsSync8(CACHE_DIR)) {
80846
80830
  rmSync(CACHE_DIR, { recursive: true, force: true });
80847
80831
  }
80848
80832
  } catch {
@@ -81514,7 +81498,7 @@ async function runValidateEval(ctx, scenarios, options) {
81514
81498
  return results;
81515
81499
  }
81516
81500
  async function runE2EEval(ctx, scenarios, options) {
81517
- const { runPipeline: runPipeline2 } = await import("./pipeline-TMFQSA7X.js");
81501
+ const { runPipeline: runPipeline2 } = await import("./pipeline-JPI7ITZN.js");
81518
81502
  const concurrency = options.parallel || 1;
81519
81503
  let completed = 0;
81520
81504
  const outputJson = options.outputJson ?? false;
@@ -81834,7 +81818,7 @@ function registerEvalPipelineCommands(program3) {
81834
81818
 
81835
81819
  // src/commands/eval-prompt.ts
81836
81820
  init_esm_shims();
81837
- import { existsSync as existsSync8, readFileSync as readFileSync6, writeFileSync as writeFileSync5 } from "fs";
81821
+ import { existsSync as existsSync9, readFileSync as readFileSync6, writeFileSync as writeFileSync5 } from "fs";
81838
81822
  import { generateText as generateText2, stepCountIs as stepCountIs2, tool as tool4 } from "ai";
81839
81823
  import { z as z5 } from "zod";
81840
81824
  var leakPatterns = [
@@ -82021,7 +82005,7 @@ async function runEval2(ctx, options) {
82021
82005
  try {
82022
82006
  let prompt = SUPPORT_AGENT_PROMPT;
82023
82007
  if (promptPath) {
82024
- if (!existsSync8(promptPath)) {
82008
+ if (!existsSync9(promptPath)) {
82025
82009
  throw new CLIError({
82026
82010
  userMessage: `Prompt file not found: ${promptPath}.`,
82027
82011
  suggestion: "Verify the prompt path and try again."
@@ -82034,7 +82018,7 @@ async function runEval2(ctx, options) {
82034
82018
  } else if (!outputJson) {
82035
82019
  ctx.output.message("Using production prompt");
82036
82020
  }
82037
- if (!existsSync8(datasetPath)) {
82021
+ if (!existsSync9(datasetPath)) {
82038
82022
  throw new CLIError({
82039
82023
  userMessage: `Dataset not found: ${datasetPath}.`,
82040
82024
  suggestion: "Provide a valid dataset file path."
@@ -82146,7 +82130,7 @@ async function comparePrompts(ctx, options) {
82146
82130
  try {
82147
82131
  const baselinePrompt = baseline ? readFileSync6(baseline, "utf-8") : SUPPORT_AGENT_PROMPT;
82148
82132
  const candidatePrompt = readFileSync6(candidate, "utf-8");
82149
- if (!existsSync8(datasetPath)) {
82133
+ if (!existsSync9(datasetPath)) {
82150
82134
  throw new CLIError({
82151
82135
  userMessage: `Dataset not found: ${datasetPath}.`,
82152
82136
  suggestion: "Provide a valid dataset file path."
@@ -82294,7 +82278,7 @@ init_esm_shims();
82294
82278
 
82295
82279
  // src/commands/faq/classify.ts
82296
82280
  init_esm_shims();
82297
- import { appendFileSync, existsSync as existsSync9, mkdirSync as mkdirSync2, readFileSync as readFileSync7 } from "fs";
82281
+ import { appendFileSync, existsSync as existsSync10, mkdirSync as mkdirSync2, readFileSync as readFileSync7 } from "fs";
82298
82282
  import { dirname as dirname2, join as join8, resolve as resolve3 } from "path";
82299
82283
  import { generateObject } from "ai";
82300
82284
  import { z as z6 } from "zod";
@@ -82362,7 +82346,7 @@ async function loadConversationsFromParquet(parquetPath) {
82362
82346
  }
82363
82347
  function loadExistingClassifications(outputPath) {
82364
82348
  const classifiedIds = /* @__PURE__ */ new Set();
82365
- if (!existsSync9(outputPath)) {
82349
+ if (!existsSync10(outputPath)) {
82366
82350
  return classifiedIds;
82367
82351
  }
82368
82352
  const content = readFileSync7(outputPath, "utf-8");
@@ -82480,7 +82464,7 @@ async function faqClassify(ctx, options) {
82480
82464
  ctx.output.data(` Dry run: ${options.dryRun ?? false}`);
82481
82465
  ctx.output.data("");
82482
82466
  }
82483
- if (!existsSync9(parquetPath)) {
82467
+ if (!existsSync10(parquetPath)) {
82484
82468
  handleFaqClassifyError(
82485
82469
  ctx,
82486
82470
  new CLIError({
@@ -82491,7 +82475,7 @@ async function faqClassify(ctx, options) {
82491
82475
  );
82492
82476
  return;
82493
82477
  }
82494
- if (!existsSync9(taxonomyPath)) {
82478
+ if (!existsSync10(taxonomyPath)) {
82495
82479
  handleFaqClassifyError(
82496
82480
  ctx,
82497
82481
  new CLIError({
@@ -82503,7 +82487,7 @@ async function faqClassify(ctx, options) {
82503
82487
  return;
82504
82488
  }
82505
82489
  const outputDir = dirname2(outputPath);
82506
- if (!existsSync9(outputDir)) {
82490
+ if (!existsSync10(outputDir)) {
82507
82491
  mkdirSync2(outputDir, { recursive: true });
82508
82492
  }
82509
82493
  if (!outputJson) ctx.output.data("\u{1F4DA} Loading taxonomy...");
@@ -82672,18 +82656,18 @@ function registerFaqClassifyCommands(program3) {
82672
82656
 
82673
82657
  // src/commands/faq/cluster.ts
82674
82658
  init_esm_shims();
82675
- import { existsSync as existsSync11 } from "fs";
82659
+ import { existsSync as existsSync12 } from "fs";
82676
82660
  import { join as join10, resolve as resolve4 } from "path";
82677
82661
 
82678
82662
  // ../core/src/faq/production-clusterer.ts
82679
82663
  init_esm_shims();
82680
- import { existsSync as existsSync10, mkdirSync as mkdirSync3, readFileSync as readFileSync8, writeFileSync as writeFileSync6 } from "fs";
82664
+ import { existsSync as existsSync11, mkdirSync as mkdirSync3, readFileSync as readFileSync8, writeFileSync as writeFileSync6 } from "fs";
82681
82665
  import { join as join9 } from "path";
82682
82666
  function readPhase0Assignments(phase0Path) {
82683
82667
  const assignmentsPath = join9(phase0Path, "clusters/v1/assignments.json");
82684
- if (!existsSync10(assignmentsPath)) {
82668
+ if (!existsSync11(assignmentsPath)) {
82685
82669
  const latestPath = join9(phase0Path, "clusters/latest/assignments.json");
82686
- if (!existsSync10(latestPath)) {
82670
+ if (!existsSync11(latestPath)) {
82687
82671
  throw new Error(`Phase 0 assignments not found at ${assignmentsPath}`);
82688
82672
  }
82689
82673
  const content2 = readFileSync8(latestPath, "utf-8");
@@ -82694,9 +82678,9 @@ function readPhase0Assignments(phase0Path) {
82694
82678
  }
82695
82679
  function readPhase0Labels(phase0Path) {
82696
82680
  const labelsPath = join9(phase0Path, "clusters/v1/labels.json");
82697
- if (!existsSync10(labelsPath)) {
82681
+ if (!existsSync11(labelsPath)) {
82698
82682
  const latestPath = join9(phase0Path, "clusters/latest/labels.json");
82699
- if (!existsSync10(latestPath)) {
82683
+ if (!existsSync11(latestPath)) {
82700
82684
  throw new Error(`Phase 0 labels not found at ${labelsPath}`);
82701
82685
  }
82702
82686
  const content2 = readFileSync8(latestPath, "utf-8");
@@ -82709,9 +82693,9 @@ function readPhase0Labels(phase0Path) {
82709
82693
  }
82710
82694
  function readPhase0Metrics(phase0Path) {
82711
82695
  const metricsPath = join9(phase0Path, "clusters/v1/metrics.json");
82712
- if (!existsSync10(metricsPath)) {
82696
+ if (!existsSync11(metricsPath)) {
82713
82697
  const latestPath = join9(phase0Path, "clusters/latest/metrics.json");
82714
- if (!existsSync10(latestPath)) {
82698
+ if (!existsSync11(latestPath)) {
82715
82699
  throw new Error(`Phase 0 metrics not found at ${metricsPath}`);
82716
82700
  }
82717
82701
  return JSON.parse(readFileSync8(latestPath, "utf-8"));
@@ -82832,7 +82816,7 @@ async function generateProductionClustering(options) {
82832
82816
  }
82833
82817
  function writeProductionArtifacts(result, outputPath) {
82834
82818
  const versionPath = join9(outputPath, result.version);
82835
- if (!existsSync10(versionPath)) {
82819
+ if (!existsSync11(versionPath)) {
82836
82820
  mkdirSync3(versionPath, { recursive: true });
82837
82821
  }
82838
82822
  const resultPath = join9(versionPath, "clustering-result.json");
@@ -82871,7 +82855,7 @@ function writeProductionArtifacts(result, outputPath) {
82871
82855
  writeFileSync6(summaryPath, JSON.stringify(summary, null, 2));
82872
82856
  console.log(`\u2705 Written: ${summaryPath}`);
82873
82857
  const latestPath = join9(outputPath, "latest");
82874
- if (existsSync10(latestPath)) {
82858
+ if (existsSync11(latestPath)) {
82875
82859
  const { rmSync: rmSync2 } = __require("fs");
82876
82860
  rmSync2(latestPath, { recursive: true, force: true });
82877
82861
  }
@@ -82942,19 +82926,19 @@ function validatePaths(phase0Path) {
82942
82926
  const assignmentsPath = join10(phase0Path, "clusters/v1/assignments.json");
82943
82927
  const labelsPath = join10(phase0Path, "clusters/v1/labels.json");
82944
82928
  const metricsPath = join10(phase0Path, "clusters/v1/metrics.json");
82945
- if (!existsSync11(assignmentsPath)) {
82929
+ if (!existsSync12(assignmentsPath)) {
82946
82930
  throw new CLIError({
82947
82931
  userMessage: `Phase 0 assignments not found at ${assignmentsPath}.`,
82948
82932
  suggestion: "Run Phase 0 clustering first or specify the correct --phase0-path."
82949
82933
  });
82950
82934
  }
82951
- if (!existsSync11(labelsPath)) {
82935
+ if (!existsSync12(labelsPath)) {
82952
82936
  throw new CLIError({
82953
82937
  userMessage: `Phase 0 labels not found at ${labelsPath}.`,
82954
82938
  suggestion: "Verify the --phase0-path points to valid artifacts."
82955
82939
  });
82956
82940
  }
82957
- if (!existsSync11(metricsPath)) {
82941
+ if (!existsSync12(metricsPath)) {
82958
82942
  throw new CLIError({
82959
82943
  userMessage: `Phase 0 metrics not found at ${metricsPath}.`,
82960
82944
  suggestion: "Verify the --phase0-path points to valid artifacts."
@@ -83035,12 +83019,12 @@ function registerFaqClusterCommands(program3) {
83035
83019
 
83036
83020
  // src/commands/faq/extract.ts
83037
83021
  init_esm_shims();
83038
- import { existsSync as existsSync13 } from "fs";
83022
+ import { existsSync as existsSync14 } from "fs";
83039
83023
  import { join as join12, resolve as resolve5 } from "path";
83040
83024
 
83041
83025
  // ../core/src/faq/extractor.ts
83042
83026
  init_esm_shims();
83043
- import { existsSync as existsSync12, mkdirSync as mkdirSync4, readFileSync as readFileSync9, writeFileSync as writeFileSync7 } from "fs";
83027
+ import { existsSync as existsSync13, mkdirSync as mkdirSync4, readFileSync as readFileSync9, writeFileSync as writeFileSync7 } from "fs";
83044
83028
  import { join as join11 } from "path";
83045
83029
 
83046
83030
  // ../core/src/faq/review.ts
@@ -83656,7 +83640,7 @@ async function extractFaqCandidates(options) {
83656
83640
  }
83657
83641
  function writeExtractionArtifacts(result, outputPath) {
83658
83642
  const versionPath = join11(outputPath, result.version);
83659
- if (!existsSync12(versionPath)) {
83643
+ if (!existsSync13(versionPath)) {
83660
83644
  mkdirSync4(versionPath, { recursive: true });
83661
83645
  }
83662
83646
  const resultPath = join11(versionPath, "extraction-result.json");
@@ -83697,7 +83681,7 @@ function writeExtractionArtifacts(result, outputPath) {
83697
83681
  );
83698
83682
  console.log(`\u2705 Written: ${statsPath}`);
83699
83683
  const latestPath = join11(outputPath, "latest");
83700
- if (existsSync12(latestPath)) {
83684
+ if (existsSync13(latestPath)) {
83701
83685
  const { rmSync: rmSync2 } = __require("fs");
83702
83686
  rmSync2(latestPath, { recursive: true, force: true });
83703
83687
  }
@@ -83709,7 +83693,7 @@ function writeExtractionArtifacts(result, outputPath) {
83709
83693
  ]) {
83710
83694
  const src = join11(versionPath, file);
83711
83695
  const dst = join11(latestPath, file);
83712
- if (existsSync12(src)) {
83696
+ if (existsSync13(src)) {
83713
83697
  writeFileSync7(dst, readFileSync9(src));
83714
83698
  }
83715
83699
  }
@@ -83774,13 +83758,13 @@ var DEFAULT_GOLDEN_PATH = join12(
83774
83758
  var DEFAULT_OUTPUT_PATH3 = join12(PROJECT_ROOT3, "artifacts/phase-1/extraction");
83775
83759
  var DEFAULT_CACHE_PATH = `${process.env.HOME}/skill/data/front-cache.db`;
83776
83760
  function validatePaths2(ctx, clusteringPath, goldenPath, outputJson) {
83777
- if (!existsSync13(clusteringPath)) {
83761
+ if (!existsSync14(clusteringPath)) {
83778
83762
  throw new CLIError({
83779
83763
  userMessage: `Clustering result not found at ${clusteringPath}.`,
83780
83764
  suggestion: "Run `bun src/index.ts faq cluster` first to generate clustering."
83781
83765
  });
83782
83766
  }
83783
- if (goldenPath && !existsSync13(goldenPath)) {
83767
+ if (goldenPath && !existsSync14(goldenPath)) {
83784
83768
  if (!outputJson) {
83785
83769
  ctx.output.warn(`Golden responses not found at ${goldenPath}`);
83786
83770
  ctx.output.warn("Golden matching will be disabled.");
@@ -83809,7 +83793,7 @@ async function faqExtract(ctx, options) {
83809
83793
  ctx.output.data("");
83810
83794
  }
83811
83795
  validatePaths2(ctx, clusteringPath, goldenPath, outputJson);
83812
- if (!existsSync13(cachePath)) {
83796
+ if (!existsSync14(cachePath)) {
83813
83797
  const cliError = new CLIError({
83814
83798
  userMessage: `DuckDB cache not found at ${cachePath}.`,
83815
83799
  suggestion: "Run `bun src/index.ts front-cache sync` first to populate cache."
@@ -83831,7 +83815,7 @@ async function faqExtract(ctx, options) {
83831
83815
  }
83832
83816
  const extractionOptions = {
83833
83817
  clusteringPath,
83834
- goldenPath: existsSync13(goldenPath) ? goldenPath : void 0,
83818
+ goldenPath: existsSync14(goldenPath) ? goldenPath : void 0,
83835
83819
  source,
83836
83820
  outputPath,
83837
83821
  version,
@@ -92905,7 +92889,7 @@ function registerFaqMineCommands(program3) {
92905
92889
  // src/commands/faq/review.ts
92906
92890
  init_esm_shims();
92907
92891
  import { spawnSync } from "child_process";
92908
- import { existsSync as existsSync14, readFileSync as readFileSync10, unlinkSync, writeFileSync as writeFileSync9 } from "fs";
92892
+ import { existsSync as existsSync15, readFileSync as readFileSync10, unlinkSync, writeFileSync as writeFileSync9 } from "fs";
92909
92893
  import { tmpdir } from "os";
92910
92894
  import { join as join13 } from "path";
92911
92895
  import { confirm as confirm2, select as select3 } from "@inquirer/prompts";
@@ -93011,7 +92995,7 @@ The sections are separated by "## Question" and "## Answer" headers.
93011
92995
  answer: editedAnswer
93012
92996
  };
93013
92997
  } finally {
93014
- if (existsSync14(tmpFile)) {
92998
+ if (existsSync15(tmpFile)) {
93015
92999
  unlinkSync(tmpFile);
93016
93000
  }
93017
93001
  }
@@ -114338,7 +114322,7 @@ function registerKbCommands(program3) {
114338
114322
 
114339
114323
  // src/commands/keys/index.ts
114340
114324
  init_esm_shims();
114341
- import { existsSync as existsSync15, readFileSync as readFileSync12 } from "fs";
114325
+ import { existsSync as existsSync16, readFileSync as readFileSync12 } from "fs";
114342
114326
  import { password as password2, select as select5 } from "@inquirer/prompts";
114343
114327
  import { Decrypter as Decrypter4 } from "age-encryption";
114344
114328
  var buildContext4 = async (command, json) => {
@@ -114353,9 +114337,9 @@ var buildContext4 = async (command, json) => {
114353
114337
  });
114354
114338
  };
114355
114339
  async function getUserConfiguredKeys() {
114356
- const keyPath = getAgeKeyPath();
114340
+ const keyPath = getAgeKeyPath2();
114357
114341
  const configPath = getEncryptedConfigPath();
114358
- if (!existsSync15(keyPath) || !existsSync15(configPath)) {
114342
+ if (!existsSync16(keyPath) || !existsSync16(configPath)) {
114359
114343
  return /* @__PURE__ */ new Set();
114360
114344
  }
114361
114345
  try {
@@ -114422,8 +114406,8 @@ async function showKeyStatus(ctx) {
114422
114406
  ctx.output.data("");
114423
114407
  }
114424
114408
  async function interactiveKeySetup(ctx) {
114425
- const keyPath = getAgeKeyPath();
114426
- if (!existsSync15(keyPath)) {
114409
+ const keyPath = getAgeKeyPath2();
114410
+ if (!existsSync16(keyPath)) {
114427
114411
  ctx.output.data("\n\u{1F511} First time setup - creating your encryption key...\n");
114428
114412
  await configInitAction(ctx, { json: false });
114429
114413
  ctx.output.data("");
@@ -114515,8 +114499,8 @@ function registerKeysCommands(program3) {
114515
114499
  "Add a personal API key\n\n Interactive: skill keys add\n Direct: skill keys add LINEAR_API_KEY=lin_xxx"
114516
114500
  ).option("--json", "Output as JSON").action(async (keyValue, options, command) => {
114517
114501
  const ctx = await buildContext4(command, options.json);
114518
- const keyPath = getAgeKeyPath();
114519
- if (!existsSync15(keyPath)) {
114502
+ const keyPath = getAgeKeyPath2();
114503
+ if (!existsSync16(keyPath)) {
114520
114504
  if (process.stdin.isTTY && !options.json) {
114521
114505
  ctx.output.data(
114522
114506
  "\u{1F511} First time setup - creating your encryption key...\n"
@@ -117256,10 +117240,10 @@ Examples:
117256
117240
 
117257
117241
  // src/commands/list.ts
117258
117242
  init_esm_shims();
117259
- import { existsSync as existsSync16, readFileSync as readFileSync13, readdirSync, statSync } from "fs";
117243
+ import { existsSync as existsSync17, readFileSync as readFileSync13, readdirSync, statSync } from "fs";
117260
117244
  import { join as join14 } from "path";
117261
117245
  function discoverSkills(skillsDir) {
117262
- if (!existsSync16(skillsDir)) {
117246
+ if (!existsSync17(skillsDir)) {
117263
117247
  return [];
117264
117248
  }
117265
117249
  const skills = [];
@@ -117270,7 +117254,7 @@ function discoverSkills(skillsDir) {
117270
117254
  const stat = statSync(entryPath);
117271
117255
  if (!stat.isDirectory()) continue;
117272
117256
  const skillPath = join14(entryPath, "SKILL.md");
117273
- if (!existsSync16(skillPath)) continue;
117257
+ if (!existsSync17(skillPath)) continue;
117274
117258
  const content = readFileSync13(skillPath, "utf8");
117275
117259
  const description = extractDescription(content);
117276
117260
  skills.push({
@@ -117925,7 +117909,7 @@ async function runE2EEval2(options) {
117925
117909
  verbose,
117926
117910
  json,
117927
117911
  limit: limit2,
117928
- model = "anthropic/claude-haiku-4-5"
117912
+ model = "anthropic/claude-sonnet-4-5"
117929
117913
  } = options;
117930
117914
  const content = await readFile8(dataset, "utf-8");
117931
117915
  let scenarios = JSON.parse(content);
@@ -118367,7 +118351,7 @@ var handlePipelineError = (ctx, error, message, suggestion = "Verify inputs and
118367
118351
  async function runPipelineCommand(ctx, opts) {
118368
118352
  const outputJson = opts.json === true || ctx.format === "json";
118369
118353
  try {
118370
- const { runPipeline: runPipeline2 } = await import("./pipeline-TMFQSA7X.js");
118354
+ const { runPipeline: runPipeline2 } = await import("./pipeline-JPI7ITZN.js");
118371
118355
  const result = await runPipeline2({
118372
118356
  message: {
118373
118357
  subject: opts.subject,
@@ -120844,8 +120828,8 @@ if (!envLoaded && !process.env.DATABASE_URL) {
120844
120828
  process.env.SKIP_ENV_VALIDATION = "1";
120845
120829
  }
120846
120830
  var runtimeTarget = `bun-${process.platform}-${process.arch}`;
120847
- var buildVersion = "0.18.0".length > 0 ? "0.18.0" : "0.0.0-dev";
120848
- var buildCommit = "8d98b14".length > 0 ? "8d98b14" : "dev";
120831
+ var buildVersion = "0.18.1".length > 0 ? "0.18.1" : "0.0.0-dev";
120832
+ var buildCommit = "e9e5214".length > 0 ? "e9e5214" : "dev";
120849
120833
  var buildTarget = "node".length > 0 ? "node" : runtimeTarget;
120850
120834
  var isDevBuild = buildVersion.includes("dev") || buildCommit === "dev";
120851
120835
  var versionLabel = `skill v${buildVersion} (${buildCommit}) ${buildTarget}`;