Text Generation
PEFT
Safetensors
Transformers
lora
research-prototype
failed-promotion
not-ready-for-deployment
Instructions to use minagayid/ELLM with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use minagayid/ELLM with PEFT:
from peft import PeftModel from transformers import AutoModelForCausalLM base_model = AutoModelForCausalLM.from_pretrained("HuggingFaceTB/SmolLM2-135M-Instruct") model = PeftModel.from_pretrained(base_model, "minagayid/ELLM") - Transformers
How to use minagayid/ELLM with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="minagayid/ELLM")# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("minagayid/ELLM", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use minagayid/ELLM with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "minagayid/ELLM" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "minagayid/ELLM", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/minagayid/ELLM
- SGLang
How to use minagayid/ELLM 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 "minagayid/ELLM" \ --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": "minagayid/ELLM", "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 "minagayid/ELLM" \ --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": "minagayid/ELLM", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use minagayid/ELLM with Docker Model Runner:
docker model run hf.co/minagayid/ELLM
Download cli.py from minagayid/ELLM: direct link, hf CLI and curl.
- Browser
- Download file 1.32 kB
-
https://huggingface.co/minagayid/ELLM/resolve/main/cli.py
- Command line
-
hf download hf://minagayid/ELLM/cli.py
-
curl -L -o cli.py https://huggingface.co/minagayid/ELLM/resolve/main/cli.py
1.32 kB
| from __future__ import annotations | |
| import argparse | |
| import json | |
| from pathlib import Path | |
| from .demo import main as demo_main | |
| from .health import health_dict | |
| def main(argv: list[str] | None = None) -> int: | |
| parser = argparse.ArgumentParser(prog="ellm") | |
| sub = parser.add_subparsers(dest="command", required=True) | |
| sub.add_parser("health", help="print a dependency-light health report") | |
| sub.add_parser("demo", help="run the fail-closed synthetic gate demo") | |
| verify = sub.add_parser("verify-ledger", help="verify an evidence ledger hash chain") | |
| verify.add_argument("path", type=Path) | |
| args = parser.parse_args(argv) | |
| if args.command == "health": | |
| print(json.dumps(health_dict(), indent=2, sort_keys=True)) | |
| return 0 | |
| if args.command == "demo": | |
| demo_main() | |
| return 0 | |
| if args.command == "verify-ledger": | |
| from .ledger import EvidenceLedger | |
| from .policy import SourcePolicy | |
| # Verification does not ingest data, so an intentionally minimal policy suffices. | |
| ledger = EvidenceLedger(args.path, SourcePolicy(frozenset({"invalid.local"}))) | |
| print(json.dumps({"path": str(args.path), "records": ledger.verify_chain()}, sort_keys=True)) | |
| return 0 | |
| return 2 | |
| if __name__ == "__main__": | |
| raise SystemExit(main()) | |