Rebuild printable roast plans and remove machine-based adjustments
Test and deploy / test-and-deploy (push) Successful in 2m28s
Test and deploy / test-and-deploy (push) Successful in 2m28s
This commit is contained in:
1 parent
e9f2393c96
commit
824a964f9d
30 files changed
+1721
-908
No files matched your search
@@ -316,7 +316,7 @@ function makeAlog(title = "Roast") {
|
||||
return JSON.stringify({ title, mode: "C", weight: [250, 212, "g"], timex, temp1, temp2, timeindex: [1, 8, 14, 0, 0, 0, 20, 0] });
|
||||
}
|
||||
|
||||
test("roaster profile aggregates uploaded roasts; plan chat is grounded in it", async () => {
|
||||
test("roaster profile describes uploads but is excluded from plan chat", async () => {
|
||||
const chatCalls = [];
|
||||
const { agent } = await setup(
|
||||
{},
|
||||
@@ -349,7 +349,7 @@ test("roaster profile aggregates uploaded roasts; plan chat is grounded in it",
|
||||
assert.equal(Number.isFinite(profile.medians.firstCrackTempC), true);
|
||||
assert.equal(Number.isFinite(profile.rorCPerMin.maillard), true);
|
||||
|
||||
// Chat receives the plan, the coerced messages, and both learned profiles
|
||||
// Chat receives the plan and messages without automatic machine adjustments
|
||||
const chat = await agent.post("/api/plan-chat").set("x-csrf-token", csrf).send({
|
||||
plan: { fields: { "0.1": "Chat plan", "1.4": "8:30" } },
|
||||
messages: [{ role: "user", content: "Why is drop so late?" }],
|
||||
@@ -357,7 +357,8 @@ test("roaster profile aggregates uploaded roasts; plan chat is grounded in it",
|
||||
assert.equal(chat.status, 200);
|
||||
assert.equal(chat.body.reply, "Drop 20 seconds earlier.");
|
||||
assert.equal(chatCalls[0].plan.fields["0.1"], "Chat plan");
|
||||
assert.equal(chatCalls[0].roasterProfile.n, 2);
|
||||
assert.equal(chatCalls[0].roasterProfile, undefined);
|
||||
assert.equal(chatCalls[0].machineProfile, undefined);
|
||||
assert.equal(Array.isArray(chatCalls[0].messages), true);
|
||||
|
||||
// Bad chat bodies are rejected before any model call
|
||||
|
||||
Reference in new issue
Block a user