AngelaKkkkkkkkk commited on
Commit
301751c
1 Parent(s): f3b6d6e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +10 -11
app.py CHANGED
@@ -1,12 +1,11 @@
1
- # Load and run the model:
2
- vllm serve "Tann-dev/sex-chat-dirty-girlfriend"
3
 
4
- # Call the server using curl:
5
- curl -X POST "http://localhost:8000/v1/chat/completions" \
6
- -H "Content-Type: application/json" \
7
- --data '{
8
- "model": "Tann-dev/sex-chat-dirty-girlfriend"
9
- "messages": [
10
- {"role": "user", "content": "Hello!"}
11
- ]
12
- }'
 
1
+ import subprocess
 
2
 
3
+ # Check if vllm is installed
4
+ try:
5
+ result = subprocess.run(["pip", "show", "vllm"], capture_output=True, text=True)
6
+ if "Name: vllm" in result.stdout:
7
+ print("vllm is installed!")
8
+ else:
9
+ print("vllm is not installed!")
10
+ except Exception as e:
11
+ print(f"Error checking vllm installation: {e}")