Views
No views yet

### 한국어: {sentence}</끝>
### 영어:### 영어: {sentence}</끝>
### 한국어:1from vllm import LLM, SamplingParams
2
3def make_prompt(data):
4 prompts = []
5 for line in data:
6 prompts.append(f"### 영어: {line}</끝>\n### 한국어:")
7 return prompts
8
9texts = [
10 "Hello world!",
11 "Nice to meet you!"
12]
13
14prompts = make_prompt(texts)
15
16sampling_params = SamplingParams(temperature=0.01, stop=["</끝>"], max_tokens=700)
17
18llm = LLM(model="squarelike/Gugugo-koen-7B-V1.1-AWQ", quantization="awq", dtype="half")
19
20outputs = llm.generate(prompts, sampling_params)
21
22# Print the outputs.
23for output in outputs:
24 print(output.outputs[0].text)