{
 "schema_version": 1,
 "generated": "2026-10-20",
 "id": "2022hpsk-speakermemr1--check-writer-training-rewards-offline",
 "repo": "2022hpsk/SpeakerMemR1",
 "repo_url": "https://github.com/2022hpsk/SpeakerMemR1",
 "repo_slug": "2022hpsk-speakermemr1",
 "title": "Verify writer-training rewards and trajectories offline",
 "page_title": "How to verify writer-training rewards and trajectories offline with Speaker Mem R1",
 "summary": "Run the offline test suite for writer training to confirm rewards and action handling before any RL run.",
 "who": "An ML engineer who wants to adapt the SpeakerLevenshtein-based writer training and first confirm the reward and trajectory code behaves as documented.",
 "problem": "Writer training involves rewards and action validation, and a silent bug there would waste a full RL run.",
 "outcome": "Passing test results for the training module, with no remote model calls needed.",
 "steps": [
  "Create the environment with `python -m pip install -r code/requirements.txt` and `python -m pip install -e code/speakermem_pkg`.",
  "Run `PYTHONPATH=code/writer_training:code/speakermem_pkg/src python -m pytest -q code/speakermem_pkg/tests/test_training.py`. (inferred, check the README)",
  "Run `python -m py_compile code/writer_training/*.py` to check the training scripts compile. (inferred, check the README)",
  "Read the reward code in code/writer_training before changing reward weights, since the README only says the tests cover reward behavior. (inferred, check the README)"
 ],
 "agent_prompt": "In the SpeakerMem-R1 repo (2022hpsk/SpeakerMemR1), run the training test file code/speakermem_pkg/tests/test_training.py with the PYTHONPATH the README gives. Expected output is a pytest summary for the training tests. Verify that the test run passes before any change to the writer reward code is accepted.",
 "agents": [
  "any"
 ],
 "difficulty": "Intermediate",
 "time": "30 minutes",
 "basis": "readme",
 "caveat": "The offline tests do not validate remote model availability or benchmark licensing, and the README reports the RL gain (57.38% to 68.20%) only for a controlled evaluation with retrieval and answering frozen.",
 "category": "Research",
 "tags": [
  "Research"
 ],
 "lang": "python",
 "requirements": [
  "Python with the ability to create a virtual environment",
  "A CPU environment is enough for the quickstart and offline checks",
  "Model service credentials (kept outside version control) for full benchmark runs",
  "Benchmark payloads placed as described in DATA_SOURCES.md for full evaluations"
 ],
 "risk": "none",
 "seen_in_the_wild": false,
 "mentioned_publicly": false,
 "risks": [],
 "best": false,
 "score": 0.7,
 "evidence": [],
 "url": "https://dedupedai.com/use-cases/2022hpsk-speakermemr1/check-writer-training-rewards-offline/",
 "md": "https://dedupedai.com/use-cases/2022hpsk-speakermemr1/check-writer-training-rewards-offline/index.md",
 "disclaimer": "Deduped lists open-source repositories that belong to other people. We do not own, maintain, audit, or vouch for any of them, and a repo appearing here is not an endorsement or a safety check. The use cases, steps, and prompts are written by AI and may be incomplete, outdated, or just wrong. Where a use case is marked \"Seen in the wild\", we link to public posts where someone described something similar, but we have not verified those posts and the use case itself is still our AI's own write-up. Use all of this at your own risk. Only run code, commands, or agents on systems and accounts you are authorized to use, and read the code and every command before you run it, especially anything that touches credentials, files, or the network. Nothing here is professional, security, legal, or financial advice. All trademarks and project names belong to their respective owners, and their use here does not imply affiliation. Content is provided as is, without warranties of any kind. Found a mistake, a safety problem, or something you want removed? Email hello@dedupedai.com and we will look at it promptly.",
 "api": "https://dedupedai.com/api/v1/usecases/2022hpsk-speakermemr1--check-writer-training-rewards-offline.json",
 "api_version": "v1"
}
