Skip to content

feat(dream): add the Dream-v0 Base 7B subject - #413

Open
hxu129 wants to merge 4 commits into
brain-score:mainfrom
hxu129:codex/dream-v0-brainscore
Open

hxu129 wants to merge 4 commits into
brain-score:mainfrom
hxu129:codex/dream-v0-brainscore

Conversation

@hxu129

@hxu129 hxu129 commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Registers Dream-org/Dream-v0-Base-7B as a Brain-Score Language ArtificialSubject for fMRI/ECoG, Futrell2018, and SyntaxGym. The neural interface pools the current text part at layer 21. The behavioral interface scores continuation subtokens with a target-hidden mask and returns summed surprisal in bits.

Behavioral readout correction

Dream's native sampler shifts raw logits one position right. To score the appended mask, the adapter now reads the raw logits at the preceding observed position. A mask-only query uses Dream's native first-position fallback. The neural readout is unchanged by this correction. next_word is outside this PR's scope.

The earlier Dream Futrell2018 and SyntaxGym scores, future-mask canvas diagnostics, and context-window diagnostics are withdrawn. Full behavioral evaluation with the corrected readout is pending.

Validation

  • Twelve checkpoint-free tests passed on the current PR head. They cover the previous indexing failure, target hiding, subtoken scoring, empty regions, context limits, neural extraction, and model registration. The memory-intensive test was deselected in that CI run.
  • A separate pinned-checkpoint acceptance run compared four short cases against full logits with Dream's native shift, including mask-only input and an intervening empty region. Surprisal agreed within 4e-15 bits, and the neural smoke test returned finite outputs.

Run the plugin tests with pytest -q brainscore_language/models/dream_v0_base/test.py -m 'not memory_intense'. The plugin README documents the checkpoint revision and DREAM_MODEL_PATH for checkpoint-based runs.

Review

The diff is limited to models/dream_v0_base. The fork checkout fix landed separately in #414, and change detection passed. Review of the adapter and its native-shift regression can proceed independently of the full behavioral rerun. For joint neural and behavioral calls, the current head can share context metadata across the two outputs even when punctuation normalization differs. A regression fix for that case has been validated locally.

AI assistance: Codex assisted with implementation, test preparation, and the PR description. The checks above were run on the submitted adapter.

@hxu129
hxu129 marked this pull request as ready for review September 28, 2026 15:07
@KartikP KartikP self-assigned this Sep 29, 2026
@KartikP KartikP changed the title Add Dream-v0 Base 7B Brain-Score Language subject feat(dream): add the Dream-v0 Base 7B subject Nov 8, 2026
KartikP added a commit that referenced this pull request Nov 8, 2026
The PR validator can report success after timeout when required statuses
never arrive, because it excludes missing results from the final check.
Require explicit success for all four contexts and reject results if the
PR head changes during validation.

Run the status validator for fork plugin submissions using trusted base
code and a read-only token. Keep label writes restricted to eligible
non-fork web submissions, and make the Actions job fail when validation
fails. Accept the polling options already used by the metadata workflow.

Validation: 31 focused tests passed, including absent statuses, pending
results, failures, changed heads, and existing Jenkins trigger behavior.
Workflow YAML structure and git diff checks passed. Read-only checks of
#412 and #413 matched their current successful status contexts.
Checkpoint tests and official benchmark execution remain separate from
this status validator.
@KartikP KartikP added ci-verification Temporary label for deployed CI verification and removed ci-verification Temporary label for deployed CI verification labels Nov 8, 2026
@KartikP KartikP removed the ci-verification Temporary label for deployed CI verification label Nov 8, 2026
KartikP added a commit that referenced this pull request Nov 8, 2026
Live verification after #441 merged found that #412 and #413 execute the
new validation job but load the old helper from their original base SHA,
97a086a. That revision predates the fail-closed validator, so green
validation jobs do not verify the deployed repair.

Check out the current base branch explicitly from the upstream
repository instead of the PR event's original base SHA. Keep the
checkout read-only and separate from the contributor's submitted head.
Log the validation-code SHA alongside the submitted SHA so future
verification can confirm both.

Validation: 31 focused tests passed; workflow YAML and trusted checkout
fields verified; git diff checks passed. Runtime changes are limited to
the workflow checkout and its documentation; a local Git regression test
covers the source-selection boundary. Model code, benchmark behavior,
Jenkins build-state policy, and account handling are unchanged.

Verification evidence:
- LLaDA:
https://github.com/brain-score/language/actions/runs/42520523395/job/128853266652
- Dream:
https://github.com/brain-score/language/actions/runs/42520525641/job/128853325777

Both logs show checkout of 97a086a while checking the correct submitted
head. After merge, rerun the label-triggered workflow and confirm that
the helper checkout includes #441 and that the validator reports current
status contexts with head_matches=true.


## Regression proof before merge

Added a test that reads the actual workflow YAML and performs checkouts
in isolated local Git repositories. The upstream repository has an old
base commit and a current validator commit. A separate fork replaces the
helper with code that raises if executed. The PR event retains the old
base SHA.

- With the #441 workflow: 3 tests fail and 1 passes. The checkout
selects obsolete code, and missing-status/new-head safeguards are
absent.
- With the #442 workflow: all 35 focused tests pass, including the four
checkout integration tests.
- The selected helper accepts complete statuses only for the submitted
fork SHA, rejects missing statuses and a changed head, and never
executes the fork helper.
- No network, GitHub, Jenkins, or AWS calls occur in this regression.
- actionlint 1.7.12 reports 16 existing findings on both workflow
versions; this change introduces none. These existing lint findings are
not claimed as resolved.

After CI executes the new regression, review the change before merge.
For the final live check, first confirm that each PR merge ref contains
the new workflow, then trigger one run and require the logs to identify
the current trusted helper SHA and the correct submitted head SHA. A
skipped validator or an old helper SHA is a failed verification,
regardless of the workflow's overall green status.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants