Hippo-6B is a cutting-edge, transformer-based language model designed to provide state-of-the-art performance across a wide range of natural language processing tasks. With 6.2 billion parameters, Hippo-6B strikes a balance between computational efficiency and high performance, making it a versatile model for various applications.
1# Libraries installation
2# pip install -q transformers accelerate flash-attn
3
4import torch
5from transformers import AutoModelForCausalLM, AutoTokenizer, pipeline
6
7torch.random.manual_seed(0)
8modelName = "Drenel/Hippo-6B"
9
10model = AutoModelForCausalLM.from_pretrained(modelName, device_map="cuda",torch_dtype="auto",trust_remote_code=True)
11tokenizer = AutoTokenizer.from_pretrained(modelName)
12
13messages = [
14 {"role": "user", "content": "What is the capital of France? <|end|><|assistant|>"},
15]
16
17pipe = pipeline("text-generation", model=model, tokenizer=tokenizer)
18generation_args = {"max_new_tokens": 50, "return_full_text": False, "temperature": 0.7, "do_sample": False, "top_k": 50, "top_p": 0.95}
19output = pipe(messages, **generation_args)
20print(output[0]['generated_text'])
Hippo-6B is distributed under the Apache-2.0.