@bunshin-cc/bunshin 0.10.0 → 0.10.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/dist/bin.js +3 -2
- package/package.json +1 -1
package/dist/bin.js
CHANGED
|
@@ -6639,7 +6639,8 @@ async function routeJob(store, sessionId, seq) {
|
|
|
6639
6639
|
const write = (a) => {
|
|
6640
6640
|
const answer = { seq, at: (/* @__PURE__ */ new Date()).toISOString(), ms: Date.now() - started, ...a };
|
|
6641
6641
|
writeJsonAtomic(answerFile(v2, sessionId, seq), answer);
|
|
6642
|
-
|
|
6642
|
+
const dense = (readJob(v2, sessionId) ?? job).dense;
|
|
6643
|
+
v2.log("v2-router", { session: sessionId, seq, serve: answer.serve ?? null, rules: answer.rules ?? [], hint: answer.hint ?? [], ms: answer.ms, modelMs: answer.modelMs, error: answer.error, dense: dense?.serve ?? null, denseHint: dense?.hint ?? [], usage: answer.usage });
|
|
6643
6644
|
return answer;
|
|
6644
6645
|
};
|
|
6645
6646
|
try {
|
|
@@ -7324,7 +7325,7 @@ async function routedText(v2, ctx, session) {
|
|
|
7324
7325
|
const rules = (await Promise.all(fresh(fallback ? [] : answer.rules ?? []).filter((id) => id !== doc?.id).map(find))).filter((s) => !!s);
|
|
7325
7326
|
const hints = fresh(fallback ? job.dense?.hint ?? [] : answer.hint ?? []).filter((id) => id !== doc?.id && !session.hinted?.includes(id));
|
|
7326
7327
|
const hintTitles = hints.map((id) => view.sections.find((s) => s.id === id)?.title).filter((t) => !!t);
|
|
7327
|
-
v2.log("v2-router-delivered", { session: session.sessionId, seq: job.seq, tool: ctx.input.tool_name, afterMs: Date.now() - Date.parse(job.at), serve: doc?.id ?? null, rules: rules.map((r) => r.id), hint: hints, fallback, ...answer.error ? { error: answer.error } : {} });
|
|
7328
|
+
v2.log("v2-router-delivered", { session: session.sessionId, seq: job.seq, tool: ctx.input.tool_name, afterMs: Date.now() - Date.parse(job.at), serve: doc?.id ?? null, rules: rules.map((r) => r.id), hint: hints, fallback, dense: job.dense?.serve ?? null, ...answer.error ? { error: answer.error } : {} });
|
|
7328
7329
|
const ids = [...doc ? [doc.id] : [], ...rules.map((r) => r.id)];
|
|
7329
7330
|
if (!ids.length && !hintTitles.length) return "";
|
|
7330
7331
|
v2.updateSession(session.sessionId, ctx.cwd, (s) => {
|