Instructions to use jiluoaaron/MeGan-R512-CrossFit_UnifiedQA-nn2n-lr1e-6 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use jiluoaaron/MeGan-R512-CrossFit_UnifiedQA-nn2n-lr1e-6 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="jiluoaaron/MeGan-R512-CrossFit_UnifiedQA-nn2n-lr1e-6")# Load model directly from transformers import AutoTokenizer, LlamaForCausalLM_sharedHyper tokenizer = AutoTokenizer.from_pretrained("jiluoaaron/MeGan-R512-CrossFit_UnifiedQA-nn2n-lr1e-6") model = LlamaForCausalLM_sharedHyper.from_pretrained("jiluoaaron/MeGan-R512-CrossFit_UnifiedQA-nn2n-lr1e-6") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use jiluoaaron/MeGan-R512-CrossFit_UnifiedQA-nn2n-lr1e-6 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "jiluoaaron/MeGan-R512-CrossFit_UnifiedQA-nn2n-lr1e-6" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "jiluoaaron/MeGan-R512-CrossFit_UnifiedQA-nn2n-lr1e-6", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/jiluoaaron/MeGan-R512-CrossFit_UnifiedQA-nn2n-lr1e-6
- SGLang
How to use jiluoaaron/MeGan-R512-CrossFit_UnifiedQA-nn2n-lr1e-6 with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "jiluoaaron/MeGan-R512-CrossFit_UnifiedQA-nn2n-lr1e-6" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "jiluoaaron/MeGan-R512-CrossFit_UnifiedQA-nn2n-lr1e-6", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "jiluoaaron/MeGan-R512-CrossFit_UnifiedQA-nn2n-lr1e-6" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "jiluoaaron/MeGan-R512-CrossFit_UnifiedQA-nn2n-lr1e-6", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use jiluoaaron/MeGan-R512-CrossFit_UnifiedQA-nn2n-lr1e-6 with Docker Model Runner:
docker model run hf.co/jiluoaaron/MeGan-R512-CrossFit_UnifiedQA-nn2n-lr1e-6
MeGan (meta_swiglu) - CrossFit & UnifiedQA SFT
This model is a fine-tuned version of Llama-3.1-8B-Instruct implementing the meta-gating mechanism proposed in Learn-To-Learn on Arbitrary Textual Conditioning: A Hypernetwork-Driven Meta-Gated LLM.
- GitHub Repository: MeGan
- Dataset: CrossFit and UnifiedQA (Hugging Face Dataset)
Model description
Conventional LLMs may suffer from corpus heterogeneity and subtle condition changes. This work activates the meta-signal of $\beta$ within the SwiGLU blocks, resulting in a meta-gating mechanism that adaptively adjusts the nonlinearity of FFN. A hypernetwork is employed which dynamically produces $\beta$ on textual conditions, providing meta-controllability on LLMs.
This checkpoint is trained on a subset (non_nli_to_nli) of CrossFit and UnifiedQA.
Training procedure
Training hyperparameters
The following hyperparameters were used during training:
- learning_rate: 0.0001
- train_batch_size: 1
- eval_batch_size: 8
- seed: 42
- distributed_type: multi-GPU
- num_devices: 32
- total_train_batch_size: 32
- total_eval_batch_size: 256
- optimizer: Use adamw_torch with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
- lr_scheduler_type: cosine
- lr_scheduler_warmup_ratio: 0.1
- num_epochs: 1.0
Framework versions
- Transformers 4.46.1
- Pytorch 2.3.0+cu121
- Datasets 2.20.0
- Tokenizers 0.20.3
Citation
If you find this work useful, please consider citing:
@article{ji2026learntolearn,
title={Learn-to-learn on Arbitrary Textual Conditioning: A Hypernetwork-Driven Meta-Gated LLM},
author={Luo Ji and Qi Qin and Ningyuan Xi and Teng Chen and Qingqing Gu and Hongyan Li},
journal={arXiv preprint arXiv:2605.01973},
year={2026}
}
- Downloads last month
- 79