fidelity factorial arms (randk / noises0 / hidden-capacity) + pre-registration item 15

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Nils
2026-07-15 02:47:14 +02:00
co-authored by Claude Fable 5
parent d39e02f4b9
commit 0e6d6adcb9
4 changed files with 60 additions and 9 deletions
+11
View File
@@ -180,6 +180,17 @@ class ParcaeAdapter(RecurrentAdapter):
return self.A_diag().max().item()
class NoisyMergeAdapter(MergeAdapter):
"""MergeAdapter with noise s0 (factorial cell: isolates the initial
state; everything else identical to the standard merge)."""
def init_state(self, e):
n = torch.randn_like(e.float())
n = n * (e.float().norm(dim=-1, keepdim=True)
/ (n.norm(dim=-1, keepdim=True) + 1e-6))
return n.to(e.dtype)
class TiedAlphaAdapter(nn.Module):
"""Merge with LEARNED per-dim constant alpha, B tied to (1-a):
x = (1-a)*e + a*s_hat + MLP([e;s_hat]), a = sigmoid(a_hat)