perf(agents): compact JSON in commitments and heartbeat prompts (#113657)

This commit is contained in:
Peter Steinberger
2026-07-25 06:19:01 -07:00
committed by GitHub
parent 9a7a5791c7
commit 504e5bbf89
4 changed files with 9 additions and 8 deletions

View File

@@ -161,9 +161,9 @@ describe("commitment extraction", () => {
],
});
expect(prompt).toContain('"now": "2026-05-30T12:00:00.000Z"');
expect(prompt).toContain('"dedupeKey": "valid"');
expect(prompt).not.toContain('"dedupeKey": "invalid"');
expect(prompt).toContain('"now":"2026-05-30T12:00:00.000Z"');
expect(prompt).toContain('"dedupeKey":"valid"');
expect(prompt).not.toContain('"dedupeKey":"invalid"');
});
it("rejects disabled, low-confidence, and non-future candidates", () => {

View File

@@ -245,7 +245,7 @@ Rules:
- Dedupe keys should be stable within a session, like "interview:2026-04-29" or "sleep:2026-04-29".
Items:
${JSON.stringify(items, null, 2)}`;
${JSON.stringify(items)}`;
}
function parseDueMs(raw: string | undefined): number | undefined {