Views
No views yet

Below is an instruction that describes a task. Write a response that appropriately completes the request.
### Instruction:
{prompt}
### Response:
cc-by-nc-4.0, and this quantization has therefore used that same license.TheBloke/Dawn-v2-70B-AWQ.Dawn-v2-70B-AWQ--quantization awq parameter.python3 -m vllm.entrypoints.api_server --model TheBloke/Dawn-v2-70B-AWQ --quantization awqquantization=awq.1from vllm import LLM, SamplingParams
2
3prompts = [
4 "Tell me about AI",
5 "Write a story about llamas",
6 "What is 291 - 150?",
7 "How much wood would a woodchuck chuck if a woodchuck could chuck wood?",
8]
9prompt_template=f'''Below is an instruction that describes a task. Write a response that appropriately completes the request.
10
11### Instruction:
12{prompt}
13
14### Response:
15'''
16
17prompts = [prompt_template.format(prompt=prompt) for prompt in prompts]
18
19sampling_params = SamplingParams(temperature=0.8, top_p=0.95)
20
21llm = LLM(model="TheBloke/Dawn-v2-70B-AWQ", quantization="awq", dtype="auto")
22
23outputs = llm.generate(prompts, sampling_params)
24
25# Print the outputs.
26for output in outputs:
27 prompt = output.prompt
28 generated_text = output.outputs[0].text
29 print(f"Prompt: {prompt!r}, Generated text: {generated_text!r}")ghcr.io/huggingface/text-generation-inference:1.1.0--model-id TheBloke/Dawn-v2-70B-AWQ --port 3000 --quantize awq --max-input-length 3696 --max-total-tokens 4096 --max-batch-prefill-tokens 4096pip3 install huggingface-hub1from huggingface_hub import InferenceClient
2
3endpoint_url = "https://your-endpoint-url-here"
4
5prompt = "Tell me about AI"
6prompt_template=f'''Below is an instruction that describes a task. Write a response that appropriately completes the request.
7
8### Instruction:
9{prompt}
10
11### Response:
12'''
13
14client = InferenceClient(endpoint_url)
15response = client.text_generation(prompt,
16 max_new_tokens=128,
17 do_sample=True,
18 temperature=0.7,
19 top_p=0.95,
20 top_k=40,
21 repetition_penalty=1.1)
22
23print(f"Model output: ", response)pip3 install autoawq1pip3 uninstall -y autoawq
2git clone https://github.com/casper-hansen/AutoAWQ
3cd AutoAWQ
4pip3 install .1from awq import AutoAWQForCausalLM
2from transformers import AutoTokenizer
3
4model_name_or_path = "TheBloke/Dawn-v2-70B-AWQ"
5
6# Load tokenizer
7tokenizer = AutoTokenizer.from_pretrained(model_name_or_path, trust_remote_code=False)
8# Load model
9model = AutoAWQForCausalLM.from_quantized(model_name_or_path, fuse_layers=True,
10 trust_remote_code=False, safetensors=True)
11
12prompt = "Tell me about AI"
13prompt_template=f'''Below is an instruction that describes a task. Write a response that appropriately completes the request.
14
15### Instruction:
16{prompt}
17
18### Response:
19'''
20
21print("*** Running model.generate:")
22
23token_input = tokenizer(
24 prompt_template,
25 return_tensors='pt'
26).input_ids.cuda()
27
28# Generate output
29generation_output = model.generate(
30 token_input,
31 do_sample=True,
32 temperature=0.7,
33 top_p=0.95,
34 top_k=40,
35 max_new_tokens=512
36)
37
38# Get the tokens from the output, decode them, print them
39token_output = generation_output[0]
40text_output = tokenizer.decode(token_output)
41print("LLM output: ", text_output)
42
43"""
44# Inference should be possible with transformers pipeline as well in future
45# But currently this is not yet supported by AutoAWQ (correct as of September 25th 2023)
46from transformers import pipeline
47
48print("*** Pipeline:")
49pipe = pipeline(
50 "text-generation",
51 model=model,
52 tokenizer=tokenizer,
53 max_new_tokens=512,
54 do_sample=True,
55 temperature=0.7,
56 top_p=0.95,
57 top_k=40,
58 repetition_penalty=1.1
59)
60
61print(pipe(prompt_template)[0]['generated_text'])
62"""Loader: AutoAWQ.
!mergekit-layershuffle ./Dawn-v2-70B \
--model Sao10K/Euryale-1.3-L2-70B --weight 0.3 \
--model Xwin-LM/Xwin-LM-70B-V0.1 --weight 0.2 \
--model ehartford/Samantha-1.11-70b --weight 0.1 \
--model NousResearch/Nous-Hermes-Llama2-70b --weight 0.05 \
--model augtoma/qCammel-70-x --weight 0.05 \
--model jondurbin/airoboros-l2-c70b-3.1.2 --weight 0.2 \
--model fangloveskari/ORCA_LLaMA_70B_QLoRA --weight 0.1 \
--write-yaml Dawn-v2-70B.yaml
=========================
merge_method: passthrough
slices:
- sources:
- layer_range:
- 0
- 1
model: fangloveskari/ORCA_LLaMA_70B_QLoRA
- sources:
- layer_range:
- 1
- 2
model: jondurbin/airoboros-l2-c70b-3.1.2
- sources:
- layer_range:
- 2
- 3
model: Sao10K/Euryale-1.3-L2-70B
- sources:
- layer_range:
- 3
- 4
model: jondurbin/airoboros-l2-c70b-3.1.2
- sources:
- layer_range:
- 4
- 5
model: fangloveskari/ORCA_LLaMA_70B_QLoRA
- sources:
- layer_range:
- 5
- 6
model: ehartford/Samantha-1.11-70b
- sources:
- layer_range:
- 6
- 8
model: Xwin-LM/Xwin-LM-70B-V0.1
- sources:
- layer_range:
- 8
- 9
model: ehartford/Samantha-1.11-70b
- sources:
- layer_range:
- 9
- 10
model: Sao10K/Euryale-1.3-L2-70B
- sources:
- layer_range:
- 10
- 11
model: ehartford/Samantha-1.11-70b
- sources:
- layer_range:
- 11
- 12
model: jondurbin/airoboros-l2-c70b-3.1.2
- sources:
- layer_range:
- 12
- 13
model: fangloveskari/ORCA_LLaMA_70B_QLoRA
- sources:
- layer_range:
- 13
- 14
model: Sao10K/Euryale-1.3-L2-70B
- sources:
- layer_range:
- 14
- 15
model: fangloveskari/ORCA_LLaMA_70B_QLoRA
- sources:
- layer_range:
- 15
- 16
model: Sao10K/Euryale-1.3-L2-70B
- sources:
- layer_range:
- 16
- 17
model: fangloveskari/ORCA_LLaMA_70B_QLoRA
- sources:
- layer_range:
- 17
- 18
model: jondurbin/airoboros-l2-c70b-3.1.2
- sources:
- layer_range:
- 18
- 19
model: NousResearch/Nous-Hermes-Llama2-70b
- sources:
- layer_range:
- 19
- 20
model: Xwin-LM/Xwin-LM-70B-V0.1
- sources:
- layer_range:
- 20
- 21
model: Sao10K/Euryale-1.3-L2-70B
- sources:
- layer_range:
- 21
- 22
model: ehartford/Samantha-1.11-70b
- sources:
- layer_range:
- 22
- 23
model: jondurbin/airoboros-l2-c70b-3.1.2
- sources:
- layer_range:
- 23
- 24
model: augtoma/qCammel-70-x
- sources:
- layer_range:
- 24
- 25
model: Sao10K/Euryale-1.3-L2-70B
- sources:
- layer_range:
- 25
- 27
model: jondurbin/airoboros-l2-c70b-3.1.2
- sources:
- layer_range:
- 27
- 28
model: Xwin-LM/Xwin-LM-70B-V0.1
- sources:
- layer_range:
- 28
- 29
model: ehartford/Samantha-1.11-70b
- sources:
- layer_range:
- 29
- 30
model: Sao10K/Euryale-1.3-L2-70B
- sources:
- layer_range:
- 30
- 32
model: Xwin-LM/Xwin-LM-70B-V0.1
- sources:
- layer_range:
- 32
- 33
model: ehartford/Samantha-1.11-70b
- sources:
- layer_range:
- 33
- 34
model: augtoma/qCammel-70-x
- sources:
- layer_range:
- 34
- 35
model: Xwin-LM/Xwin-LM-70B-V0.1
- sources:
- layer_range:
- 35
- 37
model: Sao10K/Euryale-1.3-L2-70B
- sources:
- layer_range:
- 37
- 38
model: jondurbin/airoboros-l2-c70b-3.1.2
- sources:
- layer_range:
- 38
- 39
model: ehartford/Samantha-1.11-70b
- sources:
- layer_range:
- 39
- 40
model: augtoma/qCammel-70-x
- sources:
- layer_range:
- 40
- 41
model: Xwin-LM/Xwin-LM-70B-V0.1
- sources:
- layer_range:
- 41
- 42
model: ehartford/Samantha-1.11-70b
- sources:
- layer_range:
- 42
- 43
model: Sao10K/Euryale-1.3-L2-70B
- sources:
- layer_range:
- 43
- 44
model: Xwin-LM/Xwin-LM-70B-V0.1
- sources:
- layer_range:
- 44
- 45
model: NousResearch/Nous-Hermes-Llama2-70b
- sources:
- layer_range:
- 45
- 46
model: jondurbin/airoboros-l2-c70b-3.1.2
- sources:
- layer_range:
- 46
- 48
model: ehartford/Samantha-1.11-70b
- sources:
- layer_range:
- 48
- 49
model: Sao10K/Euryale-1.3-L2-70B
- sources:
- layer_range:
- 49
- 50
model: Xwin-LM/Xwin-LM-70B-V0.1
- sources:
- layer_range:
- 50
- 51
model: jondurbin/airoboros-l2-c70b-3.1.2
- sources:
- layer_range:
- 51
- 54
model: fangloveskari/ORCA_LLaMA_70B_QLoRA
- sources:
- layer_range:
- 54
- 55
model: jondurbin/airoboros-l2-c70b-3.1.2
- sources:
- layer_range:
- 55
- 56
model: fangloveskari/ORCA_LLaMA_70B_QLoRA
- sources:
- layer_range:
- 56
- 58
model: jondurbin/airoboros-l2-c70b-3.1.2
- sources:
- layer_range:
- 58
- 59
model: Sao10K/Euryale-1.3-L2-70B
- sources:
- layer_range:
- 59
- 60
model: Xwin-LM/Xwin-LM-70B-V0.1
- sources:
- layer_range:
- 60
- 62
model: jondurbin/airoboros-l2-c70b-3.1.2
- sources:
- layer_range:
- 62
- 63
model: Xwin-LM/Xwin-LM-70B-V0.1
- sources:
- layer_range:
- 63
- 64
model: fangloveskari/ORCA_LLaMA_70B_QLoRA
- sources:
- layer_range:
- 64
- 65
model: NousResearch/Nous-Hermes-Llama2-70b
- sources:
- layer_range:
- 65
- 66
model: Sao10K/Euryale-1.3-L2-70B
- sources:
- layer_range:
- 66
- 67
model: Xwin-LM/Xwin-LM-70B-V0.1
- sources:
- layer_range:
- 67
- 68
model: augtoma/qCammel-70-x
- sources:
- layer_range:
- 68
- 70
model: Xwin-LM/Xwin-LM-70B-V0.1
- sources:
- layer_range:
- 70
- 71
model: augtoma/qCammel-70-x
- sources:
- layer_range:
- 71
- 72
model: Xwin-LM/Xwin-LM-70B-V0.1
- sources:
- layer_range:
- 72
- 73
model: Sao10K/Euryale-1.3-L2-70B
- sources:
- layer_range:
- 73
- 75
model: jondurbin/airoboros-l2-c70b-3.1.2
- sources:
- layer_range:
- 75
- 76
model: Sao10K/Euryale-1.3-L2-70B
- sources:
- layer_range:
- 76
- 77
model: augtoma/qCammel-70-x
- sources:
- layer_range:
- 77
- 78
model: Xwin-LM/Xwin-LM-70B-V0.1
- sources:
- layer_range:
- 78
- 79
model: NousResearch/Nous-Hermes-Llama2-70b
- sources:
- layer_range:
- 79
- 80
model: Xwin-LM/Xwin-LM-70B-V0.1
=========================
=> Applying Doctor-Shotgun/limarpv3-llama2-70b-qlora x 0.35Below is an instruction that describes a task. Write a response that appropriately completes the request.
### Instruction:
{prompt}
### Response: