EngramModule has double residual — one in Engram, one in TransformerBlock #16
Loading…
Reference in a new issue
No description provided.
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?
Problem
EngramModule.forward()(engram.py:156) returnsh + y(a residual connection). Then inmodel.py:130-133, the TransformerBlock also adds a residual:So the Engram output gets two residual additions — one from Engram itself and one from TransformerBlock. The input
hbypasses both the Engram processing and the block's attention/FFN.Impact
hreaches the next layer through two independent paths (Engram residual + block residual)Action needed
Decide on intent:
return yinstead ofh + y)Files
tergent/engram.py:156tergent/model.py:130-133