chore: drop non-code junk (pi-mono-reference, runtime state, root duplicates)
Remove files that should never have been tracked: - pi-mono-reference/: 688-file copy of an upstream monorepo, zero imports, used only as offline human reference - build/electron-builder.runtime.json: environment-specific build artifact with hardcoded local paths - state/cancel-signal-state.json: runtime state written by the app - prompt.txt, logo.svg (root): exact duplicates of the canonical copies under .planning/archive/ and assets/ Add state/ to .gitignore so future runtime state stays out.
This commit is contained in:
1 parent
34ca5b77f1
commit
1f7230fe87
691 files changed
+3
-190434
No files matched your search
@@ -1,38 +0,0 @@
|
||||
import { describe, expect, it } from "vitest";
|
||||
import { isThinkingPart, retainThoughtSignature } from "../src/providers/google-shared.js";
|
||||
|
||||
describe("Google thinking detection (thoughtSignature)", () => {
|
||||
it("treats part.thought === true as thinking", () => {
|
||||
expect(isThinkingPart({ thought: true, thoughtSignature: undefined })).toBe(true);
|
||||
expect(isThinkingPart({ thought: true, thoughtSignature: "opaque-signature" })).toBe(true);
|
||||
});
|
||||
|
||||
it("does not treat thoughtSignature alone as thinking", () => {
|
||||
// Per Google docs, thoughtSignature is for context replay and can appear on any part type.
|
||||
// Only thought === true indicates thinking content.
|
||||
// See: https://ai.google.dev/gemini-api/docs/thought-signatures
|
||||
expect(isThinkingPart({ thought: undefined, thoughtSignature: "opaque-signature" })).toBe(false);
|
||||
expect(isThinkingPart({ thought: false, thoughtSignature: "opaque-signature" })).toBe(false);
|
||||
});
|
||||
|
||||
it("does not treat empty/missing signatures as thinking if thought is not set", () => {
|
||||
expect(isThinkingPart({ thought: undefined, thoughtSignature: undefined })).toBe(false);
|
||||
expect(isThinkingPart({ thought: false, thoughtSignature: "" })).toBe(false);
|
||||
});
|
||||
|
||||
it("preserves the existing signature when subsequent deltas omit thoughtSignature", () => {
|
||||
const first = retainThoughtSignature(undefined, "sig-1");
|
||||
expect(first).toBe("sig-1");
|
||||
|
||||
const second = retainThoughtSignature(first, undefined);
|
||||
expect(second).toBe("sig-1");
|
||||
|
||||
const third = retainThoughtSignature(second, "");
|
||||
expect(third).toBe("sig-1");
|
||||
});
|
||||
|
||||
it("updates the signature when a new non-empty signature arrives", () => {
|
||||
const updated = retainThoughtSignature("sig-1", "sig-2");
|
||||
expect(updated).toBe("sig-2");
|
||||
});
|
||||
});
|
||||
Reference in new issue
Block a user