Image-Text-to-Text
Transformers
Safetensors
English
gamescaling
game-agent
embodied-agent
keyboard-mouse
continued-pretraining
qwen3_5
Instructions to use THUSI-Lab/GameScaling with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use THUSI-Lab/GameScaling with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="THUSI-Lab/GameScaling")# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("THUSI-Lab/GameScaling", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use THUSI-Lab/GameScaling with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "THUSI-Lab/GameScaling" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "THUSI-Lab/GameScaling", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/THUSI-Lab/GameScaling
- SGLang
How to use THUSI-Lab/GameScaling 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 "THUSI-Lab/GameScaling" \ --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": "THUSI-Lab/GameScaling", "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 "THUSI-Lab/GameScaling" \ --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": "THUSI-Lab/GameScaling", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use THUSI-Lab/GameScaling with Docker Model Runner:
docker model run hf.co/THUSI-Lab/GameScaling
Single <think>-prefilled prompt format, no-reasoning mode, full Doom example; drop benchmark presets
893fd86 verified Download gamescaling/keymaps.py from THUSI-Lab/GameScaling: direct link, hf CLI and curl.
- Browser
- Download file 2.58 kB
-
https://huggingface.co/THUSI-Lab/GameScaling/resolve/main/gamescaling/keymaps.py
- Command line
-
hf download hf://THUSI-Lab/GameScaling/gamescaling/keymaps.py
-
curl -L -o keymaps.py https://huggingface.co/THUSI-Lab/GameScaling/resolve/main/gamescaling/keymaps.py
2.58 kB
| """Training key vocabulary -> the key names of common input backends. | |
| Mouse buttons (`LB` / `RB` / `MB`) are not keyboard keys; every table below | |
| leaves them out and backends handle them through `MOUSE_BUTTONS`. | |
| """ | |
| from __future__ import annotations | |
| from .action import LETTER_KEYS | |
| MOUSE_BUTTONS: dict[str, str] = {"LB": "left", "RB": "right", "MB": "middle"} | |
| # Unreal Engine 5 FKey names. Left variants are | |
| # used for the L/R-merged modifier tokens. | |
| TO_UE5: dict[str, str] = { | |
| **{c: c for c in LETTER_KEYS}, | |
| "zero": "Zero", "one": "One", "two": "Two", "three": "Three", "four": "Four", | |
| "five": "Five", "six": "Six", "seven": "Seven", "eight": "Eight", "nine": "Nine", | |
| "One": "F1", "Two": "F2", "Three": "F3", "Four": "F4", "Five": "F5", "Six": "F6", | |
| "Seven": "F7", "Eight": "F8", "Nine": "F9", "Ten": "F10", "Eleven": "F11", | |
| "Twelve": "F12", | |
| "Shift": "LeftShift", "Ctrl": "LeftControl", "Alt": "LeftAlt", "Tab": "Tab", | |
| "Caps": "CapsLock", "Esc": "Escape", "Space": "SpaceBar", "Enter": "Enter", | |
| "Back": "BackSpace", "Delete": "Delete", "Insert": "Insert", "Home": "Home", | |
| "End": "End", "Pause": "Pause", | |
| "Up": "Up", "Down": "Down", "Left": "Left", "Right": "Right", | |
| "Equal": "Equals", "Minus": "Hyphen", "Period": "Period", "Slash": "Slash", | |
| "Quote": "Apostrophe", | |
| } | |
| # Playwright `page.keyboard` names (browser games). Letters are lower case. | |
| TO_PLAYWRIGHT: dict[str, str] = { | |
| **{c: c.lower() for c in LETTER_KEYS}, | |
| "zero": "0", "one": "1", "two": "2", "three": "3", "four": "4", | |
| "five": "5", "six": "6", "seven": "7", "eight": "8", "nine": "9", | |
| "One": "F1", "Two": "F2", "Three": "F3", "Four": "F4", "Five": "F5", "Six": "F6", | |
| "Seven": "F7", "Eight": "F8", "Nine": "F9", "Ten": "F10", "Eleven": "F11", | |
| "Twelve": "F12", | |
| "Shift": "Shift", "Ctrl": "Control", "Alt": "Alt", "Tab": "Tab", "Caps": "CapsLock", | |
| "Esc": "Escape", "Space": "Space", "Enter": "Enter", "Back": "Backspace", | |
| "Delete": "Delete", "Insert": "Insert", "Home": "Home", "End": "End", "Pause": "Pause", | |
| "Up": "ArrowUp", "Down": "ArrowDown", "Left": "ArrowLeft", "Right": "ArrowRight", | |
| "Equal": "Equal", "Minus": "Minus", "Period": "Period", "Slash": "Slash", | |
| "Quote": "Quote", | |
| } | |
| # Playwright name -> training token, for rewriting a game's documented controls | |
| # into the vocabulary the model emits. | |
| PLAYWRIGHT_TO_TOKEN: dict[str, str] = { | |
| "ArrowLeft": "Left", "ArrowRight": "Right", "ArrowUp": "Up", "ArrowDown": "Down", | |
| "Escape": "Esc", "CapsLock": "Caps", "Control": "Ctrl", "Backspace": "Back", | |
| } | |