xab 10.0.0 → 11.0.0
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/dist/index.js +14 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1436,6 +1436,9 @@ async function runEngine(opts, cb) {
|
|
|
1436
1436
|
autoSkip = true
|
|
1437
1437
|
} = opts;
|
|
1438
1438
|
const config = loadConfig(repoPath, opts.configPath);
|
|
1439
|
+
if (opts.hints?.length) {
|
|
1440
|
+
config.promptHints = [...config.promptHints ?? [], ...opts.hints];
|
|
1441
|
+
}
|
|
1439
1442
|
const effectiveMaxAttempts = opts.maxAttempts ?? config.maxAttempts ?? Infinity;
|
|
1440
1443
|
const effectiveWorkBranch = opts.workBranch ?? config.workBranch;
|
|
1441
1444
|
const commitPrefix = config.commitPrefix ?? "backmerge:";
|
|
@@ -1451,6 +1454,12 @@ async function runEngine(opts, cb) {
|
|
|
1451
1454
|
for (const l of logs)
|
|
1452
1455
|
cb.onLog(` ${l}`, "gray");
|
|
1453
1456
|
}
|
|
1457
|
+
if (config.promptHints && config.promptHints.length > 0) {
|
|
1458
|
+
cb.onLog(`Active hints (${config.promptHints.length}):`, "cyan");
|
|
1459
|
+
for (const h of config.promptHints) {
|
|
1460
|
+
cb.onLog(` \u2192 ${h}`, "cyan");
|
|
1461
|
+
}
|
|
1462
|
+
}
|
|
1454
1463
|
cb.onStatus("Discovering repo structure & docs...");
|
|
1455
1464
|
const repoCtx = buildRepoContext(repoPath, config);
|
|
1456
1465
|
const instrCount = repoCtx.instructions.size;
|
|
@@ -3043,6 +3052,7 @@ var batch = false;
|
|
|
3043
3052
|
var jsonl = false;
|
|
3044
3053
|
var resume = true;
|
|
3045
3054
|
var showHelp = false;
|
|
3055
|
+
var hints = [];
|
|
3046
3056
|
for (let i = 0;i < args.length; i++) {
|
|
3047
3057
|
const arg = args[i];
|
|
3048
3058
|
if (arg === "--help" || arg === "-h")
|
|
@@ -3083,6 +3093,8 @@ for (let i = 0;i < args.length; i++) {
|
|
|
3083
3093
|
maxAttempts = parseInt(args[++i], 10) || 2;
|
|
3084
3094
|
else if (arg === "--config" && args[i + 1])
|
|
3085
3095
|
configPath = args[++i];
|
|
3096
|
+
else if (arg === "--hint" && args[i + 1])
|
|
3097
|
+
hints.push(args[++i]);
|
|
3086
3098
|
else if (!arg.startsWith("-"))
|
|
3087
3099
|
repoPath = arg;
|
|
3088
3100
|
}
|
|
@@ -3119,6 +3131,7 @@ Behavior:
|
|
|
3119
3131
|
--no-auto-skip Don't auto-skip commits AI identifies as present
|
|
3120
3132
|
--max-attempts <n> Max retries per commit (default: unlimited)
|
|
3121
3133
|
--no-resume Don't resume from interrupted runs (default: auto-resume)
|
|
3134
|
+
--hint <text> Operator hint injected into AI prompts (repeatable)
|
|
3122
3135
|
--config <path> Path to config file (default: auto-discover)
|
|
3123
3136
|
--help, -h Show this help
|
|
3124
3137
|
|
|
@@ -3179,6 +3192,7 @@ var engineOpts = {
|
|
|
3179
3192
|
review,
|
|
3180
3193
|
autoSkip,
|
|
3181
3194
|
resume,
|
|
3195
|
+
...hints.length > 0 && { hints },
|
|
3182
3196
|
maxAttempts,
|
|
3183
3197
|
...startAfter && { startAfter },
|
|
3184
3198
|
...limit > 0 && { limit },
|