opencode-rag-plugin 2.12.1 → 2.12.2
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.
|
@@ -92,6 +92,7 @@ export function registerQuirkCommand(program) {
|
|
|
92
92
|
const tags = q.tags.length > 0 ? ` (${q.tags.join(", ")})` : "";
|
|
93
93
|
const date = q.lastObserved ? new Date(q.lastObserved).toLocaleDateString() : "";
|
|
94
94
|
logCliInfo(ctx.logFilePath, "quirk list", ` ${c.value(badge)}${c.file(q.content)}${c.dim(tags)} ${c.dim(date)}`);
|
|
95
|
+
logCliInfo(ctx.logFilePath, "quirk list", ` ${c.dim(`id: ${q.id}`)}`);
|
|
95
96
|
}
|
|
96
97
|
await cleanupContext(ctx);
|
|
97
98
|
}
|
package/dist/opencode/tools.js
CHANGED
|
@@ -410,7 +410,8 @@ export function createRecallQuirksTool(options) {
|
|
|
410
410
|
"environment constraints discovered during previous sessions. " +
|
|
411
411
|
"Leverage when you encounter an error, need to recall how something works, " +
|
|
412
412
|
"or want to avoid known pitfalls. Results are filtered by confidence and " +
|
|
413
|
-
"relevance."
|
|
413
|
+
"relevance. Each result lists its full quirk ID — pass it unchanged to " +
|
|
414
|
+
"`update_quirk` or `delete_quirk` to maintain memory.",
|
|
414
415
|
args: {
|
|
415
416
|
query: tool.schema.string().min(1, "A search query is required."),
|
|
416
417
|
topK: tool.schema.number().int().min(1).max(25).optional(),
|
|
@@ -442,7 +443,7 @@ export function createRecallQuirksTool(options) {
|
|
|
442
443
|
? ` confidence=${(m.confidence * 100).toFixed(0)}%`
|
|
443
444
|
: "";
|
|
444
445
|
const score = r.score.toFixed(3);
|
|
445
|
-
lines.push(`- ${badge}${r.chunk.content}${tags}`, ` _score=${score}${confidence}_`);
|
|
446
|
+
lines.push(`- ${badge}${r.chunk.content}${tags}`, ` id: \`${r.chunk.id}\` | _score=${score}${confidence}_`);
|
|
446
447
|
}
|
|
447
448
|
return {
|
|
448
449
|
title: `Quirk memory recall (${results.length})`,
|
|
@@ -451,6 +452,7 @@ export function createRecallQuirksTool(options) {
|
|
|
451
452
|
tool: "recall_quirks",
|
|
452
453
|
query: args.query,
|
|
453
454
|
matches: results.length,
|
|
455
|
+
quirkIds: results.map((r) => r.chunk.id),
|
|
454
456
|
},
|
|
455
457
|
};
|
|
456
458
|
}
|