feat: Enhanced Development Experience with Mock Mode (#35)

* feat: support mock for re-planning

* chore: update mock example: vibe coding

* chore: update final-answer.txt
This commit is contained in:
Henry Li
2025-05-12 20:24:49 +08:00
committed by GitHub
parent 229b59ab88
commit 77a7f8f8ab
6 changed files with 15832 additions and 446 deletions

View File

@@ -77,10 +77,13 @@ async function* chatReplayStream(
if (urlParams.get("mock")) {
replayFilePath = `/mock/${urlParams.get("mock")!}.txt`;
} else {
replayFilePath =
params.interrupt_feedback === "accepted"
? "/mock/before-interrupt.txt"
: "/mock/after-interrupt.txt";
if (params.interrupt_feedback === "accepted") {
replayFilePath = "/mock/final-answer.txt";
} else if (params.interrupt_feedback === "edit_plan") {
replayFilePath = "/mock/re-plan.txt";
} else {
replayFilePath = "/mock/first-plan.txt";
}
}
fastForwardReplaying = true;
} else {