{
  "baseline": {
    "version": "peaksat-app-workflow-2026-10-22.v1",
    "scope": "Authenticated production application HTTP integration with a dedicated synthetic QA identity and independently checked original fixtures. Not a browser session, generated-question approval audit, student study, or score-gain test.",
    "applicationOrigin": "https://www.peaksat.com",
    "workflow": [
      "anonymous hint rejected",
      "signed-in account without entitlement rejected",
      "create isolated DB-only QA entitlement",
      "full explanation before attempt rejected",
      "hint before attempt",
      "next-step follow-up",
      "submit the prewritten deliberately wrong answer through the actual drill answer endpoint",
      "full explanation after attempt",
      "submit a known correct answer to the original fresh transfer fixture"
    ],
    "providerPolicy": "Use the unchanged production app model and generation settings. No cheaper-model fallback or result-driven rerun. Keep application errors and unexpected outputs. The endpoint reports its configured model identifier; it does not expose the provider's returned model version.",
    "grading": {
      "access": "Anonymous 401; authenticated unentitled 403; pre-attempt full explanation 409; subsequent valid requests 200.",
      "referenceAnswers": "Independent rational arithmetic and substitution fixed before any tutor response.",
      "hintReview": "AI-assisted editorial review checks whether one useful next step is given and the final answer is withheld. Record reasoning and failures; do not equate this with teacher review.",
      "explanationReview": "AI-assisted editorial review checks the reference answer, correction of the scripted wrong answer, and stated mathematical reasoning. Record all returned text and limitations.",
      "transfer": "A scripted client sends a known correct answer to a new fixture. This checks answer handling and persistence, not that a learner understood or transferred learning.",
      "execution": "One application request per registered stage. The unchanged Google client may internally retry transient provider failures according to its existing production policy; this harness does not retry a failed observation."
    },
    "cases": [
      {
        "id": "distribution-linear",
        "topicName": "Linear equations in one variable",
        "question": "Solve 4(x - 3) = 2x + 10. What is the value of x?",
        "answer": "11",
        "wrongAnswer": "5",
        "reference": "4x - 12 = 2x + 10, so 2x = 22 and x = 11. Substitution gives 32 = 32. At x = 5, the two sides are 8 and 20.",
        "hintRequest": "I am stuck before starting. Give me one small hint and a question to try. Do not reveal the value of x.",
        "stepRequest": "I distributed to get 4x - 12 = 2x + 10. What is the next small step? Please do not finish it for me.",
        "explainRequest": "I submitted 5. Explain exactly where that value fails, show a valid solution, and ask me to check it.",
        "transfer": {
          "question": "Solve 5(x + 2) = 3x + 24. What is the value of x?",
          "answer": "7",
          "reference": "5x + 10 = 3x + 24, so 2x = 14 and x = 7. Substitution gives 45 = 45."
        }
      },
      {
        "id": "reverse-percentage",
        "topicName": "Percentages",
        "question": "After a 20% discount, a jacket costs $64. What was its original price in dollars?",
        "answer": "80",
        "wrongAnswer": "76.8",
        "reference": "The final price is 80% of the original: 0.8p = 64, so p = 80. Multiplying 80 by 0.8 returns 64. Increasing 64 by 20% instead gives 76.8 and uses the wrong base.",
        "hintRequest": "I am unsure which number is the percentage base. Give one small hint and ask me to set up the relationship, without giving the original price.",
        "stepRequest": "I wrote 0.8p = 64. What should I do next? Please give only the operation, not the final price.",
        "explainRequest": "I submitted 76.8 by adding 20% to 64. Explain the mistaken base, solve correctly, and show a multiplication check.",
        "transfer": {
          "question": "After a 20% increase, an annual membership costs $150. What was the original price in dollars?",
          "answer": "125",
          "reference": "The final price is 120% of the original: 1.2p = 150, so p = 125. Multiplying 125 by 1.2 returns 150."
        }
      }
    ],
    "privacy": "Only a new @example.invalid QA identity and its own fixtures, tutor history and attempts are read or written. No production student identities, conversations, scores or outcomes are used. No Stripe calls, mail, opt-ins or customer testimonials. Session credentials remain in a mode-0600 private file and are excluded from public evidence."
  },
  "independentReferences": {
    "registeredAt": "2026-10-23T03:08:40.433506+00:00",
    "protocolSha256": "f3f3ac9a1c62f196f65c37807db3710c85d6ccb6b0e3c1bebd6473987a8396d0",
    "method": "Python exact rational arithmetic and original-condition substitution, before provider requests",
    "checks": [
      {
        "case": "distribution-linear",
        "answer": "11",
        "left": "32",
        "right": "32",
        "passed": true
      },
      {
        "case": "distribution-linear-transfer",
        "answer": "7",
        "left": "45",
        "right": "45",
        "passed": true
      },
      {
        "case": "reverse-percentage",
        "answer": "80",
        "left": "64",
        "right": "64",
        "passed": true
      },
      {
        "case": "reverse-percentage-transfer",
        "answer": "125",
        "left": "150",
        "right": "150",
        "passed": true
      }
    ],
    "passed": true
  },
  "candidateFollowup": {
    "version": "peaksat-app-workflow-prompt-followup-2026-10-22.v1",
    "registeredAt": "2026-10-23T03:20:38.396004+00:00",
    "baselineProtocolSha256": "f3f3ac9a1c62f196f65c37807db3710c85d6ccb6b0e3c1bebd6473987a8396d0",
    "sourceSha256": {
      "lib/study-platform/tutor.ts": "f49521979a1d1b79b43e046e81a7283d529bc446af61d9363a06e3ff617c2435",
      "lib/gemini/client.ts": "6371f5b12d683fa28d8f32580a2bd7a931f45cb2d60edbe724093588b5085699",
      "lib/study-platform/content-generation.ts": "9a5f6b06a750af3fbdfb566bd54cc2ef88b83c1073ec0e024b3e4c778e07f815",
      "lib/study-platform/tutor-prompt.test.cjs": "e16fce9b35c70e793ed943283502ca494e4147b91a25c09a8390e358d1ff35ab"
    },
    "environment": "Local candidate production tutor and answer-submission server functions, real configured Google API, production Cloud SQL with only the same newly created synthetic QA owner. This run does not pass through HTTP authentication middleware or a browser.",
    "reason": "Baseline explanations were mathematically correct but unnecessarily mentioned missing choices and made unsupported common-error frequency claims. The candidate prompt now treats numeric responses separately and requires evidence or explicitly conditional error-cause wording.",
    "stages": [
      "pre-attempt explain must reject with409",
      "hint without final answer",
      "next step without final answer",
      "submit the fixed wrong answer through the unchanged application answer function",
      "explanation after attempt"
    ],
    "cases": [
      {
        "id": "distribution-linear",
        "topicName": "Linear equations in one variable",
        "question": "Solve 4(x - 3) = 2x + 10. What is the value of x?",
        "answer": "11",
        "wrongAnswer": "5",
        "reference": "4x - 12 = 2x + 10, so 2x = 22 and x = 11. Substitution gives 32 = 32. At x = 5, the two sides are 8 and 20.",
        "hintRequest": "I am stuck before starting. Give me one small hint and a question to try. Do not reveal the value of x.",
        "stepRequest": "I distributed to get 4x - 12 = 2x + 10. What is the next small step? Please do not finish it for me.",
        "explainRequest": "I submitted 5. Explain exactly where that value fails, show a valid solution, and ask me to check it.",
        "transfer": {
          "question": "Solve 5(x + 2) = 3x + 24. What is the value of x?",
          "answer": "7",
          "reference": "5x + 10 = 3x + 24, so 2x = 14 and x = 7. Substitution gives 45 = 45."
        }
      },
      {
        "id": "reverse-percentage",
        "topicName": "Percentages",
        "question": "After a 20% discount, a jacket costs $64. What was its original price in dollars?",
        "answer": "80",
        "wrongAnswer": "76.8",
        "reference": "The final price is 80% of the original: 0.8p = 64, so p = 80. Multiplying 80 by 0.8 returns 64. Increasing 64 by 20% instead gives 76.8 and uses the wrong base.",
        "hintRequest": "I am unsure which number is the percentage base. Give one small hint and ask me to set up the relationship, without giving the original price.",
        "stepRequest": "I wrote 0.8p = 64. What should I do next? Please give only the operation, not the final price.",
        "explainRequest": "I submitted 76.8 by adding 20% to 64. Explain the mistaken base, solve correctly, and show a multiplication check.",
        "transfer": {
          "question": "After a 20% increase, an annual membership costs $150. What was the original price in dollars?",
          "answer": "125",
          "reference": "The final price is 120% of the original: 1.2p = 150, so p = 125. Multiplying 125 by 1.2 returns 150."
        }
      }
    ],
    "checks": {
      "mathematics": "Same independently fixed rational references as the baseline; no new reference chosen from model output.",
      "withholding": "Hint and step do not reveal the final unknown.",
      "format": "Numeric explanation does not discuss distractors, empty lists or missing choices.",
      "causes": "Do not assert a specific cause for the linear wrong answer without shown work; conditional possibilities are allowed. The percentage request explicitly states its calculation and may be corrected from that evidence.",
      "frequency": "Do not claim common/most-common/typical error frequency without a source.",
      "sampling": "One call per registered stage, retaining all failures. Normal production transient-error retries remain active. This is a small before/follow-up observation, not a controlled causal study."
    },
    "excludedClaims": [
      "No student learning or score improvement measured.",
      "No Google OAuth, checkout or browser interaction tested in this follow-up.",
      "No generated-question approval pipeline or broad tutor accuracy estimate tested.",
      "Two reused original tasks are not an unseen or representative sample."
    ]
  }
}
