Qwen2.5 14 B Merge

mergekit-community

Introduction

QWEN2.5-14B-MERGE is a composite pre-trained language model resulting from the integration of multiple models using the mergekit tool. It leverages the strengths of several foundational models to enhance performance for text generation tasks.

Architecture

The QWEN2.5-14B-MERGE model is constructed using the Model Stock merge method. The base model for this merge is Qwen/Qwen2.5-14B. The architecture includes contributions from various models, each bringing unique capabilities to the merged entity. These models include:

  • VAGOsolutions/SauerkrautLM-v2-14b-SFT
  • rombodawg/Rombos-LLM-V2.6-Qwen-14b
  • huihui-ai/Qwen2.5-14B-Instruct-abliterated-v2
  • arcee-ai/SuperNova-Medius
  • arcee-ai/Virtuoso-Small

Training

The model employs a YAML configuration specifying the integration of different models, with normalization enabled and the data type set to bfloat16. This configuration ensures the combined model retains the strengths of each component while optimizing performance and memory usage.

Guide: Running Locally

To run QWEN2.5-14B-MERGE locally, follow these steps:

  1. Install Dependencies: Ensure you have Python installed, along with the transformers library.

    pip install transformers
    
  2. Clone the Repository: Download the model from its Hugging Face repository.

    git clone https://huggingface.co/mergekit-community/Qwen2.5-14B-Merge
    
  3. Load the Model: Use the transformers library to load the model.

    from transformers import AutoModelForCausalLM, AutoTokenizer
    
    tokenizer = AutoTokenizer.from_pretrained("mergekit-community/Qwen2.5-14B-Merge")
    model = AutoModelForCausalLM.from_pretrained("mergekit-community/Qwen2.5-14B-Merge")
    
  4. Inference: Perform text generation using the model.

    input_text = "Once upon a time"
    inputs = tokenizer(input_text, return_tensors="pt")
    outputs = model.generate(**inputs)
    print(tokenizer.decode(outputs[0], skip_special_tokens=True))
    

For enhanced performance, consider using cloud GPUs like those provided by AWS, Google Cloud, or Azure, as these resources can significantly speed up inference times for large models.

License

The QWEN2.5-14B-MERGE model is distributed under the terms specified by Hugging Face and the individual licenses of the component models. Ensure compliance with these licenses when using the model.

More Related APIs in Text Generation