Repository navigation
STORY-01: source-native builder, SWMD-mini, HG-02 gym - #54
Draft
patrickdugan wants to merge 38 commits into
Draft
patrickdugan wants to merge 38 commits into
patrickdugan wants to merge 38 commits into
Conversation
| root = Path(td) | ||
| seed = root / "key.bin" | ||
| secret = b"private reproducibility key for synthetic smoke 01" | ||
| seed.write_bytes(secret) |
Comment on lines
+53
to
+54
| "\n".join(json.dumps({"root": x["root"], "output": json.dumps(x["expected"])}) | ||
| for x in secret) + "\n", encoding="utf-8", |
Comment on lines
+16
to
+59
| runs-on: ubuntu-latest | ||
| timeout-minutes: 15 | ||
| steps: | ||
| - name: Checkout DataGoblin | ||
| uses: actions/checkout@v4 | ||
| - name: Checkout pinned GPTStoryworld files | ||
| uses: actions/checkout@v4 | ||
| with: | ||
| repository: MoralityLabAI/GPTStoryworld | ||
| ref: 5cd0b480e9a01d07418cdf8cb3bedbc9d38ef906 | ||
| path: GPTStoryworld | ||
| filter: blob:none | ||
| sparse-checkout-cone-mode: false | ||
| sparse-checkout: | | ||
| codex-skills/storyworld-building/scripts/sweepweave_validator.py | ||
| codex-skills/storyworld-building/scripts/json_to_swmd.py | ||
| codex-skills/small-storyworld-builder/scripts/swmd_encounter_index.py | ||
| codex-skills/small-storyworld-builder/scripts/swmd_build_qlora_examples.py | ||
| verifiers_envs/storyworld-hypergames-env/src/spiral_ln/hypergames_single_player.py | ||
| verifiers_envs/storyworld-hypergames-env/src/spiral_ln/evaluation_hypergames.py | ||
| storyworlds/diplomacy/forecast_backstab.json | ||
| storyworlds/charter_of_ashen_aegis.json | ||
| storyworlds/the_fifth_testimony_p2.json | ||
| storyworlds/tsun01b_last_train_home/tsun01b.sweepweave.json | ||
| - name: Python | ||
| uses: actions/setup-python@v5 | ||
| with: | ||
| python-version: "3.11" | ||
| - name: Install DataGoblin and lint dependencies | ||
| run: python -m pip install -e '.[dev]' | ||
| - name: Native tests and source-pinned replay | ||
| env: | ||
| PYTHONPATH: src | ||
| GPTSTORYWORLD_SOURCE: GPTStoryworld | ||
| GPTSTORYWORLD_EXPECT_SHA: 5cd0b480e9a01d07418cdf8cb3bedbc9d38ef906 | ||
| run: | | ||
| ruff check src/datagoblin/training_gym/rlt_gym/storyworld_native.py src/datagoblin/training_gym/rlt_gym/storyworld_micro.py src/datagoblin/training_gym/rlt_gym/storyworld_local.py src/datagoblin/training_gym/rlt_gym/storyworld_cohort.py tests/unit/test_rlt_gym_storyworld_native.py tests/unit/test_rlt_gym_storyworld_micro.py tests/unit/test_rlt_gym_storyworld_local.py tests/unit/test_rlt_gym_storyworld_cohort.py | ||
| python -m unittest discover -s tests/unit -p 'test_rlt_gym_storyworld*.py' -v | ||
| python -m datagoblin.training_gym.rlt_gym.storyworld_native --source GPTStoryworld --expect-source-commit "$GPTSTORYWORLD_EXPECT_SHA" --per-mode 2 --seed 23 --out "$RUNNER_TEMP/dg-sw-native" | ||
| python -m datagoblin.training_gym.rlt_gym.storyworld_native --source GPTStoryworld --expect-source-commit "$GPTSTORYWORLD_EXPECT_SHA" --replay "$RUNNER_TEMP/dg-sw-native" | ||
| python -m datagoblin.training_gym.rlt_gym.storyworld_micro --source GPTStoryworld --expect-source-commit "$GPTSTORYWORLD_EXPECT_SHA" --examples-per-encounter 4 --seed 23 --out "$RUNNER_TEMP/dg-sw-micro" | ||
| python -m datagoblin.training_gym.rlt_gym.storyworld_micro --source GPTStoryworld --expect-source-commit "$GPTSTORYWORLD_EXPECT_SHA" --replay "$RUNNER_TEMP/dg-sw-micro" | ||
| python -m datagoblin.training_gym.rlt_gym.storyworld_cohort --source GPTStoryworld --per-mode 2 --micro-examples 2 --micro-max-encounters 4 --seed 23 --out "$RUNNER_TEMP/dg-sw-cohort" | ||
| python -m datagoblin.training_gym.rlt_gym.storyworld_cohort --source GPTStoryworld --replay "$RUNNER_TEMP/dg-sw-cohort" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
STORY-01 / STORY-02: source-native Storyworld gym
Implements DataGoblin's read-only GPTStoryworld research gym, with bounded native scoring, model-facing turn-by-turn play, and four-world source-held-out evaluation. Upstream source pinned at
5cd0b480e9a01d07418cdf8cb3bedbc9d38ef906; each source artifact and script is SHA-256 recorded.Native source adapters
SWMD-MICRO-0.1SFT for compile/compression/repair/targeted edit.Local interactive model runner
src/datagoblin/training_gym/rlt_gym/storyworld_local.pyuses an operator-provided, already-running localhost/v1/chat/completionsendpoint. It sends public HG-02 observations turn by turn, logs raw responses and usage, enforces 8K Mini / 16K hard context budgets, and keeps hidden state exclusively in the simulator. It rejects proxy redirects or non-loopback network destinations. Completed turns survive interrupted runs with--resumeand are independently rescored using--replay-run. GitHub tests use a public-observation-only stub policy. No actual Inky Mini inference has been claimed or run.Multi-world registry and custody
training/rlt_gym/storyworld_native/world_cohort_v1.jsonpins four source worlds and assigns each whole world to one split:Source-world isolation applies to builder/Mini and SFT. Held-out world train-label streams are empty. Larger compiler packets stay in audited
micro_oversize.jsonlrather than being silently truncated, keeping the 8K budget and source labels intact.Reproducibility receipts
Passing 14-test native workflow includes source checkout, ruff, interactive offline-stub tests, exact collection replay, four-world split audits and overbudget accounting.
Pilot cohort (seed 23, 2 native roots/world, 2 micro tasks/encounter): 4 worlds, 32 native tasks, 112 native control rollouts, 26 admitted Mini compiler tasks, 6 recorded overbudget exclusions, and 16 train-only SFT labels.
Commands and model invocation: storyworld_native README.
Scope and gates
Initial full-builder task is bounded repair, and Mini SFT uses deterministic source compiler labels. Narrative generation, independent quality criticism, new world simulation, actual local model evaluation and trained-model generalization need separate measured experiments. The public source-world holdout is an engineering split, not an undisclosed private world benchmark. Keep this PR in draft pending those results.