1gate_mode: hidden
2dtype: bfloat16
3experts:
4 - source_model: epfl-llm/meditron-7b
5 positive_prompts:
6 - "How does sleep affect cardiovascular health?"
7 - "When discussing diabetes management, the key factors to consider are"
8 - "The differential diagnosis for a headache with visual aura could include"
9 negative_prompts:
10 - "What are the environmental impacts of deforestation?"
11 - "The recent advancements in artificial intelligence have led to developments in"
12 - source_model: chaoyi-wu/PMC_LLAMA_7B_10_epoch
13 positive_prompts:
14 - "How would you explain the importance of hypertension management to a patient?"
15 - "Describe the recovery process after knee replacement surgery in layman's terms."
16 negative_prompts:
17 - "Recommend a good recipe for a vegetarian lasagna."
18 - "The recent advancements in artificial intelligence have led to developments in"
19 - "The fundamental concepts in economics include ideas like supply and demand, which explain"
20 - source_model: allenai/tulu-2-dpo-7b
21 positive_prompts:
22 - "Here is a funny joke for you -"
23 - "When considering the ethical implications of artificial intelligence, one must take into account"
24 - "In strategic planning, a company must analyze its strengths and weaknesses, which involves"
25 - "Understanding consumer behavior in marketing requires considering factors like"
26 - "The debate on climate change solutions hinges on arguments that"
27 negative_prompts:
28 - "In discussing dietary adjustments for managing hypertension, it's crucial to emphasize"
29 - "For early detection of melanoma, dermatologists recommend that patients regularly check their skin for"
30 - "Explaining the importance of vaccination, a healthcare professional should highlight"
31 - source_model: microsoft/Orca-2-7b
32 positive_prompts:
33 - "Given the riddle above,"
34 - "Given the above context deduce the outcome:"
35 - "The logical flaw in the above paragraph is"
36 negative_prompts:
37 - "In discussing dietary adjustments for managing hypertension, it's crucial to emphasize"
38 - "For early detection of melanoma, dermatologists recommend that patients regularly check their skin for"
39 - "Explaining the importance of vaccination, a healthcare professional should highlight"
1!pip install -qU transformers bitsandbytes accelerate
2
3from transformers import AutoTokenizer
4import transformers
5import torch
6
7model = "Technoculture/Mediquad-20B"
8
9tokenizer = AutoTokenizer.from_pretrained(model)
10pipeline = transformers.pipeline(
11 "text-generation",
12 model=model,
13 model_kwargs={"torch_dtype": torch.float16, "load_in_4bit": True},
14)
15
16messages = [{"role": "user", "content": "Explain what a Mixture of Experts is in less than 100 words."}]
17prompt = pipeline.tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
18outputs = pipeline(prompt, max_new_tokens=256, do_sample=True, temperature=0.7, top_k=50, top_p=0.95)
19print(outputs[0]["generated_text"])