Instructions to use zai-org/GLM-5.1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use zai-org/GLM-5.1 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="zai-org/GLM-5.1") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("zai-org/GLM-5.1") model = AutoModelForCausalLM.from_pretrained("zai-org/GLM-5.1") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Inference
- HuggingChat
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use zai-org/GLM-5.1 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "zai-org/GLM-5.1" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "zai-org/GLM-5.1", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/zai-org/GLM-5.1
- SGLang
How to use zai-org/GLM-5.1 with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "zai-org/GLM-5.1" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "zai-org/GLM-5.1", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "zai-org/GLM-5.1" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "zai-org/GLM-5.1", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use zai-org/GLM-5.1 with Docker Model Runner:
docker model run hf.co/zai-org/GLM-5.1
Upload ULTIMATE TRADING PRO X.html
#39
by RathodGururaj - opened
- ULTIMATE TRADING PRO X.html +195 -0
ULTIMATE TRADING PRO X.html
ADDED
|
@@ -0,0 +1,195 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<!DOCTYPE html><html lang="en">
|
| 2 |
+
<head>
|
| 3 |
+
<meta charset="UTF-8">
|
| 4 |
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
| 5 |
+
<title>ULTIMATE TRADING PRO</title><style>
|
| 6 |
+
|
| 7 |
+
:root{
|
| 8 |
+
--bg:#050810;
|
| 9 |
+
--card:#0d1620;
|
| 10 |
+
--card2:#112033;
|
| 11 |
+
--text:#e8f0ff;
|
| 12 |
+
--muted:#7a8fa8;
|
| 13 |
+
--cyan:#00d9ff;
|
| 14 |
+
--green:#00ff99;
|
| 15 |
+
--red:#ff4757;
|
| 16 |
+
--orange:#ffa500;
|
| 17 |
+
--line:rgba(255,255,255,.06);
|
| 18 |
+
}
|
| 19 |
+
|
| 20 |
+
*{
|
| 21 |
+
margin:0;
|
| 22 |
+
padding:0;
|
| 23 |
+
box-sizing:border-box;
|
| 24 |
+
font-family:'Segoe UI',sans-serif;
|
| 25 |
+
}
|
| 26 |
+
|
| 27 |
+
body{
|
| 28 |
+
background:linear-gradient(135deg,#050810,#0a1220);
|
| 29 |
+
color:var(--text);
|
| 30 |
+
padding:12px;
|
| 31 |
+
}
|
| 32 |
+
|
| 33 |
+
.header{
|
| 34 |
+
display:flex;
|
| 35 |
+
justify-content:space-between;
|
| 36 |
+
align-items:center;
|
| 37 |
+
margin-bottom:15px;
|
| 38 |
+
flex-wrap:wrap;
|
| 39 |
+
}
|
| 40 |
+
|
| 41 |
+
.brand h1{
|
| 42 |
+
color:var(--cyan);
|
| 43 |
+
font-size:28px;
|
| 44 |
+
}
|
| 45 |
+
|
| 46 |
+
.brand p{
|
| 47 |
+
font-size:12px;
|
| 48 |
+
color:var(--muted);
|
| 49 |
+
}
|
| 50 |
+
|
| 51 |
+
.clock{
|
| 52 |
+
padding:10px 15px;
|
| 53 |
+
background:rgba(0,217,255,.1);
|
| 54 |
+
border:1px solid var(--line);
|
| 55 |
+
border-radius:10px;
|
| 56 |
+
}
|
| 57 |
+
|
| 58 |
+
.grid-2{
|
| 59 |
+
display:grid;
|
| 60 |
+
grid-template-columns:1fr 1fr;
|
| 61 |
+
gap:12px;
|
| 62 |
+
}
|
| 63 |
+
|
| 64 |
+
.grid-3{
|
| 65 |
+
display:grid;
|
| 66 |
+
grid-template-columns:1fr 1fr 1fr;
|
| 67 |
+
gap:12px;
|
| 68 |
+
}
|
| 69 |
+
|
| 70 |
+
.card{
|
| 71 |
+
background:linear-gradient(145deg,#0d1620,#112033);
|
| 72 |
+
padding:14px;
|
| 73 |
+
border-radius:12px;
|
| 74 |
+
border:1px solid var(--line);
|
| 75 |
+
margin-bottom:12px;
|
| 76 |
+
}
|
| 77 |
+
|
| 78 |
+
.card-title{
|
| 79 |
+
font-size:12px;
|
| 80 |
+
font-weight:bold;
|
| 81 |
+
color:var(--cyan);
|
| 82 |
+
margin-bottom:10px;
|
| 83 |
+
}
|
| 84 |
+
|
| 85 |
+
.big{
|
| 86 |
+
font-size:28px;
|
| 87 |
+
font-weight:bold;
|
| 88 |
+
}
|
| 89 |
+
|
| 90 |
+
.green{color:var(--green);}
|
| 91 |
+
.red{color:var(--red);}
|
| 92 |
+
.orange{color:var(--orange);}
|
| 93 |
+
|
| 94 |
+
.metric{
|
| 95 |
+
padding:10px;
|
| 96 |
+
background:rgba(255,255,255,.03);
|
| 97 |
+
border-radius:8px;
|
| 98 |
+
margin-top:8px;
|
| 99 |
+
}
|
| 100 |
+
|
| 101 |
+
.metric-label{
|
| 102 |
+
font-size:11px;
|
| 103 |
+
color:var(--muted);
|
| 104 |
+
}
|
| 105 |
+
|
| 106 |
+
.metric-value{
|
| 107 |
+
font-size:18px;
|
| 108 |
+
font-weight:bold;
|
| 109 |
+
margin-top:4px;
|
| 110 |
+
}
|
| 111 |
+
|
| 112 |
+
.chart-area{
|
| 113 |
+
height:450px;
|
| 114 |
+
background:#07111d;
|
| 115 |
+
border-radius:10px;
|
| 116 |
+
border:1px solid var(--line);
|
| 117 |
+
display:flex;
|
| 118 |
+
align-items:center;
|
| 119 |
+
justify-content:center;
|
| 120 |
+
}
|
| 121 |
+
|
| 122 |
+
.signal-box{
|
| 123 |
+
padding:12px;
|
| 124 |
+
border-radius:10px;
|
| 125 |
+
text-align:center;
|
| 126 |
+
font-weight:bold;
|
| 127 |
+
font-size:20px;
|
| 128 |
+
}
|
| 129 |
+
|
| 130 |
+
.buy{
|
| 131 |
+
background:rgba(0,255,153,.15);
|
| 132 |
+
border:1px solid rgba(0,255,153,.3);
|
| 133 |
+
color:var(--green);
|
| 134 |
+
}
|
| 135 |
+
|
| 136 |
+
.sell{
|
| 137 |
+
background:rgba(255,71,87,.15);
|
| 138 |
+
border:1px solid rgba(255,71,87,.3);
|
| 139 |
+
color:var(--red);
|
| 140 |
+
}
|
| 141 |
+
|
| 142 |
+
.wait{
|
| 143 |
+
background:rgba(255,165,0,.15);
|
| 144 |
+
border:1px solid rgba(255,165,0,.3);
|
| 145 |
+
color:var(--orange);
|
| 146 |
+
}
|
| 147 |
+
|
| 148 |
+
@media(max-width:768px){
|
| 149 |
+
|
| 150 |
+
.grid-2{
|
| 151 |
+
grid-template-columns:1fr;
|
| 152 |
+
}
|
| 153 |
+
|
| 154 |
+
.grid-3{
|
| 155 |
+
grid-template-columns:1fr;
|
| 156 |
+
}
|
| 157 |
+
|
| 158 |
+
}
|
| 159 |
+
|
| 160 |
+
</style></head><body><div class="header"><div class="brand">
|
| 161 |
+
<h1>⚡ ULTIMATE TRADING PRO</h1>
|
| 162 |
+
<p>Professional Trading Dashboard</p>
|
| 163 |
+
</div><div class="clock">
|
| 164 |
+
<div id="date">--</div>
|
| 165 |
+
<div id="time">--</div>
|
| 166 |
+
</div></div><div class="grid-3"><div class="card">
|
| 167 |
+
<div class="card-title">NIFTY 50</div>
|
| 168 |
+
<div class="big green" id="niftyPrice">Loading...</div>
|
| 169 |
+
</div><div class="card">
|
| 170 |
+
<div class="card-title">BANK NIFTY</div>
|
| 171 |
+
<div class="big green" id="bankPrice">Loading...</div>
|
| 172 |
+
</div><div class="card">
|
| 173 |
+
<div class="card-title">INDIA VIX</div>
|
| 174 |
+
<div class="big orange" id="vixPrice">Loading...</div>
|
| 175 |
+
</div></div><div class="card"><div class="card-title">
|
| 176 |
+
LIVE CHART
|
| 177 |
+
</div><div id="chart" class="chart-area">TradingView Chart Here
|
| 178 |
+
|
| 179 |
+
</div></div><div class="grid-2"><div class="card"><div class="card-title">
|
| 180 |
+
AI SIGNAL ENGINE
|
| 181 |
+
</div><div class="metric">
|
| 182 |
+
<div class="metric-label">SuperTrend 1</div>
|
| 183 |
+
<div class="metric-value green">GREEN</div>
|
| 184 |
+
</div><div class="metric">
|
| 185 |
+
<div class="metric-label">SuperTrend 2</div>
|
| 186 |
+
<div class="metric-value green">GREEN</div>
|
| 187 |
+
</div><div class="metric">
|
| 188 |
+
<div class="metric-label">RSI</div>
|
| 189 |
+
<div class="metric-value">62</div>
|
| 190 |
+
</div></div><div class="card"><div class="card-title">
|
| 191 |
+
FINAL SIGNAL
|
| 192 |
+
</div><div class="signal-box buy">
|
| 193 |
+
BUY
|
| 194 |
+
</div></div></div></body>
|
| 195 |
+
</html>
|