Spaces:
Runtime error
Runtime error
Testing vllm
Browse files
main.py
CHANGED
@@ -1,8 +1,16 @@
|
|
1 |
from fastapi import FastAPI
|
|
|
2 |
|
3 |
app = FastAPI()
|
4 |
|
5 |
|
6 |
@app.get("/")
|
7 |
def read_root():
|
8 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
from fastapi import FastAPI
|
2 |
+
from vllm import LLM, SamplingParams
|
3 |
|
4 |
app = FastAPI()
|
5 |
|
6 |
|
7 |
@app.get("/")
|
8 |
def read_root():
|
9 |
+
prompts = [
|
10 |
+
"Hello, my name is",
|
11 |
+
"The president of the United States is",
|
12 |
+
"The capital of France is",
|
13 |
+
"The future of AI is",
|
14 |
+
]
|
15 |
+
sampling_params = SamplingParams(temperature=0.8, top_p=0.95)
|
16 |
+
return {"output": sampling_params}
|