Skip to content

Add openelm adapter tests#1383

Open
chandrudp29 wants to merge 3 commits into
TransformerLensOrg:devfrom
chandrudp29:add-openelm-adapter-tests
Open

Add openelm adapter tests#1383
chandrudp29 wants to merge 3 commits into
TransformerLensOrg:devfrom
chandrudp29:add-openelm-adapter-tests

Conversation

@chandrudp29

Copy link
Copy Markdown

Description

Adds unit tests for OpenElmArchitectureAdapter as part of the test backfill effort in #1302.

Covers:

  • Config attributes: RMS normalization, rotary positional embeddings, gated MLP, uses_rms_norm, LLaMA-2 tokenizer proxy
  • Component mapping: BlockBridge, AttentionBridge with combined QKV (qkv_proj), MLPBridge with ffn/proj_1/proj_2 naming, RMSNormalizationBridge with OpenELM-specific norm names
  • Verifies no top-level pos_embed or rotary_emb (OpenELM RoPE is per-layer)
  • Verifies weight_processing_conversions is empty (native HF attention handles all per-layer dimension variants)

All 33 tests pass locally.

Type of change

  • New feature (non-breaking change which adds functionality)

Checklist

  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

chandrudp29 and others added 3 commits June 13, 2026 13:37
Covers config attributes (rotary positional embeddings, parallel attn/mlp,
no prepend BOS), component mapping bridge types and HF module names, all 7
weight conversion keys with shared source key validation.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Covers config attributes (RMS norm, rotary embeddings, gated MLP, LLaMA-2
tokenizer proxy), component mapping bridge types and HF module names, and
verifies weight_processing_conversions is empty (native attention handles
all per-layer dimension variants internally).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
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.

1 participant