Trunk architecture is not selectable (hardcoded ResMLP/MoE choice) #33
Notifications
Due Date
No due date set.
Blocks
Reference: lars/giant#33
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
build_trunk(giant/model/trunks.py:144-155) hardcodes exactly two shapes,both of them
Linear → N × ResBlock → Linear, chosen byrouter is None. The config exposes onlyhidden_dim,n_res_blocks,dropout. There is no way to try a transformer trunk, a gated/GLU MLP, awidth-varying stack, or a deliberately trivial
lineartrunk as an ablationbaseline, without editing
models.py.Proposal:
TRUNK_REGISTRY+register_trunk, and a[stage1_model.trunk]/[stage2_model.trunk]block keyed ontype:router.enabled = truebecomestrunk.type = "moe"with the router blocknested under it, which is the honest shape — a routed trunk is a kind of
trunk, not a boolean modifier on the default one. (
migrate_configmaps theold spelling forward; the deep-merge special-case that keeps
router.enabledfrom dropping the rest of the router defaults then goes away, since
typekeysdon't have that problem.)
Payoff: the single change that most directly delivers "the network should
be very customizable". Everything else in this batch of modularity issues is
plumbing by comparison.
Migrated from
issues.md(v0.3.0 branch review, 2026-08-13), Issue 8.