Skip to content

Add LFM2.5 1.2B support with CI integration#17509

Open
larryliu0820 wants to merge 3 commits intomainfrom
add-lfm2.5-support
Open

Add LFM2.5 1.2B support with CI integration#17509
larryliu0820 wants to merge 3 commits intomainfrom
add-lfm2.5-support

Conversation

@larryliu0820
Copy link
Contributor

@larryliu0820 larryliu0820 commented Feb 17, 2026

This adds support for exporting LiquidAI's LFM2.5-1.2B-Instruct model, which features improved training (28T tokens vs 10T) and extended context support (32K tokens).

Changes:

  • Add lfm2_5_1_2b model configuration (examples/models/lfm2/config/lfm2_5_1_2b_config.json)
  • Register lfm2_5_1_2b in EXECUTORCH_DEFINED_MODELS and HUGGING_FACE_REPO_IDS
  • Add lfm2_5_1_2b to ModelType enum
  • Update README with LFM2.5 export examples and extended context usage
  • Add CI test for lfm2_5_1_2b in test_torchao_huggingface_checkpoints.sh
  • Add lfm2_5_1_2b to trunk.yml test matrix (XNNPACK and TorchAO backends)

The model uses the same hybrid architecture as LFM2 (convolution + attention layers) with 16 layers and 8192 FFN dimension. Can be exported with custom max_seq_length and max_context_length for extended context support.

Fixes #17439

@pytorch-bot
Copy link

pytorch-bot bot commented Feb 17, 2026

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/17509

Note: Links to docs will display an error until the docs builds have been completed.

❌ 5 New Failures

As of commit f998ad1 with merge base b69cb70 (image):

NEW FAILURES - The following jobs have failed:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@meta-cla meta-cla bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Feb 17, 2026
@larryliu0820 larryliu0820 marked this pull request as ready for review February 17, 2026 22:19
@larryliu0820 larryliu0820 added the release notes: llm Changes to llm utilities label Feb 17, 2026
larryliu0820 and others added 3 commits February 19, 2026 05:27
This adds support for exporting LiquidAI's LFM2.5-1.2B-Instruct model,
which features improved training (28T tokens vs 10T) and extended context
support (32K tokens).

Changes:
- Add lfm2_5_1_2b model configuration (examples/models/lfm2/config/lfm2_5_1_2b_config.json)
- Register lfm2_5_1_2b in EXECUTORCH_DEFINED_MODELS and HUGGING_FACE_REPO_IDS
- Add lfm2_5_1_2b to ModelType enum
- Update README with LFM2.5 export examples and extended context usage
- Add CI test for lfm2_5_1_2b in test_torchao_huggingface_checkpoints.sh
- Add lfm2_5_1_2b to trunk.yml test matrix (XNNPACK and TorchAO backends)

The model uses the same hybrid architecture as LFM2 (convolution + attention
layers) with 16 layers and 8192 FFN dimension. Can be exported with custom
max_seq_length and max_context_length for extended context support.

Fixes #17439

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
The CI was failing because the huggingface-cli command wasn't available.
Changed to use 'hf download' to match qwen3_4b and phi_4_mini.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
The convert_weights script couldn't be executed as a module because it was
missing the main() function and __main__ block. Added argparse CLI interface
matching other model converters (qwen3, phi_4_mini).

Tested successfully:
- Converted LFM2.5-1.2B-Instruct checkpoint (2.2GB output)
- CLI arguments work correctly

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. release notes: llm Changes to llm utilities

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Error when exporting LiquidAI/LFM2.5-1.2B-Instruct

2 participants

Comments