Image-Text-to-Text
Transformers
Safetensors
GGUF
English
minicpmv4_6
minicpm-v
vision-language
multimodal
image-to-text
lora
rune-goblin
runelang
gradio
game-ai
spell-recognition
conversational
Instructions to use ASHu2/goblinV1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use ASHu2/goblinV1 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="ASHu2/goblinV1") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] pipe(text=messages)# Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("ASHu2/goblinV1") model = AutoModelForMultimodalLM.from_pretrained("ASHu2/goblinV1", device_map="auto") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] inputs = processor.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(processor.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use ASHu2/goblinV1 with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf ASHu2/goblinV1:Q4_K_M # Run inference directly in the terminal: llama cli -hf ASHu2/goblinV1:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf ASHu2/goblinV1:Q4_K_M # Run inference directly in the terminal: llama cli -hf ASHu2/goblinV1:Q4_K_M
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf ASHu2/goblinV1:Q4_K_M # Run inference directly in the terminal: ./llama-cli -hf ASHu2/goblinV1:Q4_K_M
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf ASHu2/goblinV1:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama-cli -hf ASHu2/goblinV1:Q4_K_M
Use Docker
docker model run hf.co/ASHu2/goblinV1:Q4_K_M
- LM Studio
- Jan
- vLLM
How to use ASHu2/goblinV1 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "ASHu2/goblinV1" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "ASHu2/goblinV1", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker
docker model run hf.co/ASHu2/goblinV1:Q4_K_M
- SGLang
How to use ASHu2/goblinV1 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 "ASHu2/goblinV1" \ --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": "ASHu2/goblinV1", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'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 "ASHu2/goblinV1" \ --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": "ASHu2/goblinV1", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }' - Ollama
How to use ASHu2/goblinV1 with Ollama:
ollama run hf.co/ASHu2/goblinV1:Q4_K_M
- Unsloth Studio
How to use ASHu2/goblinV1 with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for ASHu2/goblinV1 to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for ASHu2/goblinV1 to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for ASHu2/goblinV1 to start chatting
- Pi
How to use ASHu2/goblinV1 with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf ASHu2/goblinV1:Q4_K_M
Configure the model in Pi
# Install Pi: npm install -g @earendil-works/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "ASHu2/goblinV1:Q4_K_M" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use ASHu2/goblinV1 with Docker Model Runner:
docker model run hf.co/ASHu2/goblinV1:Q4_K_M
- Lemonade
How to use ASHu2/goblinV1 with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull ASHu2/goblinV1:Q4_K_M
Run and chat with the model
lemonade run user.goblinV1-Q4_K_M
List all available models
lemonade list
- Hermes Agent
How to use ASHu2/goblinV1 with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf ASHu2/goblinV1:Q4_K_M
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default ASHu2/goblinV1:Q4_K_M
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use ASHu2/goblinV1 with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf ASHu2/goblinV1:Q4_K_M
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "ASHu2/goblinV1:Q4_K_M" \ --custom-provider-id llama-cpp \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
Update README.md
Browse files
README.md
CHANGED
|
@@ -1,203 +1,527 @@
|
|
| 1 |
---
|
| 2 |
license: apache-2.0
|
|
|
|
| 3 |
datasets:
|
| 4 |
- ASHu2/rune_goblin_visual_dataset
|
| 5 |
language:
|
| 6 |
- en
|
| 7 |
-
|
| 8 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9 |
---
|
| 10 |
-
# Model Card for Model ID
|
| 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 |
-
- **Paper [optional]:** [More Information Needed]
|
| 38 |
-
- **Demo [optional]:** [More Information Needed]
|
| 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 |
|
| 101 |
-
|
| 102 |
|
| 103 |
-
|
| 104 |
|
| 105 |
-
|
| 106 |
|
| 107 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 108 |
|
| 109 |
-
|
| 110 |
|
| 111 |
-
|
| 112 |
|
| 113 |
-
##
|
| 114 |
|
| 115 |
-
|
| 116 |
|
| 117 |
-
|
| 118 |
|
| 119 |
-
|
|
|
|
|
|
|
| 120 |
|
| 121 |
-
|
| 122 |
|
| 123 |
-
|
| 124 |
|
| 125 |
-
##
|
| 126 |
|
| 127 |
-
|
| 128 |
|
| 129 |
-
|
| 130 |
|
| 131 |
-
|
| 132 |
|
| 133 |
-
|
| 134 |
|
| 135 |
-
|
| 136 |
|
|
|
|
| 137 |
|
|
|
|
|
|
|
|
|
|
| 138 |
|
| 139 |
-
|
| 140 |
|
| 141 |
-
|
| 142 |
|
| 143 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 144 |
|
| 145 |
-
|
| 146 |
|
| 147 |
-
|
| 148 |
|
| 149 |
-
|
| 150 |
|
| 151 |
-
|
| 152 |
-
-
|
| 153 |
-
|
| 154 |
-
- **Compute Region:** [More Information Needed]
|
| 155 |
-
- **Carbon Emitted:** [More Information Needed]
|
| 156 |
|
| 157 |
-
|
| 158 |
|
| 159 |
-
|
|
|
|
|
|
|
| 160 |
|
| 161 |
-
|
| 162 |
|
| 163 |
-
|
| 164 |
|
| 165 |
-
|
| 166 |
|
| 167 |
-
|
| 168 |
|
| 169 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 170 |
|
| 171 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 172 |
|
| 173 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 174 |
|
| 175 |
-
|
|
|
|
|
|
|
| 176 |
|
| 177 |
-
|
| 178 |
|
| 179 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 180 |
|
| 181 |
-
|
| 182 |
|
| 183 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 184 |
|
| 185 |
-
|
| 186 |
|
| 187 |
-
##
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 188 |
|
| 189 |
-
|
| 190 |
|
| 191 |
-
|
| 192 |
|
| 193 |
-
|
| 194 |
|
| 195 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 196 |
|
| 197 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 198 |
|
| 199 |
-
|
| 200 |
|
| 201 |
-
|
| 202 |
|
| 203 |
-
|
|
|
|
| 1 |
---
|
| 2 |
license: apache-2.0
|
| 3 |
+
base_model: openbmb/MiniCPM-V-4.6
|
| 4 |
datasets:
|
| 5 |
- ASHu2/rune_goblin_visual_dataset
|
| 6 |
language:
|
| 7 |
- en
|
| 8 |
+
library_name: transformers
|
| 9 |
+
pipeline_tag: image-text-to-text
|
| 10 |
+
tags:
|
| 11 |
+
- minicpmv4_6
|
| 12 |
+
- minicpm-v
|
| 13 |
+
- vision-language
|
| 14 |
+
- multimodal
|
| 15 |
+
- image-to-text
|
| 16 |
+
- safetensors
|
| 17 |
+
- gguf
|
| 18 |
+
- lora
|
| 19 |
+
- rune-goblin
|
| 20 |
+
- runelang
|
| 21 |
+
- gradio
|
| 22 |
+
- game-ai
|
| 23 |
+
- spell-recognition
|
| 24 |
---
|
|
|
|
| 25 |
|
| 26 |
+
# GoblinV1
|
| 27 |
|
| 28 |
+
**GoblinV1** is a fine-tuned vision-language model for **Rune Goblin**, an AI dungeon crawler where players draw spell glyphs and the model interprets those drawings as magic.
|
| 29 |
|
| 30 |
+
The model is fine-tuned from **OpenBMB MiniCPM-V-4.6** to read hand-drawn **RuneLang** glyphs and produce structured JSON describing detected runes, ambiguity, spell metadata, and visual presentation hints.
|
| 31 |
|
| 32 |
+
It is not a generic chatbot.
|
| 33 |
|
| 34 |
+
It is a tiny cursed spell reader.
|
| 35 |
|
| 36 |
+
> Draw better runes, get stronger magic.
|
| 37 |
+
> Draw cursed doodles, suffer beautifully.
|
| 38 |
|
| 39 |
+
---
|
| 40 |
|
| 41 |
+
## Model Summary
|
| 42 |
+
|
| 43 |
+
| Field | Value |
|
| 44 |
+
|---|---|
|
| 45 |
+
| Model name | `ASHu2/goblinV1` |
|
| 46 |
+
| Base model | `openbmb/MiniCPM-V-4.6` |
|
| 47 |
+
| Model type | Vision-language / image-to-text |
|
| 48 |
+
| Architecture | MiniCPM-V 4.6 / `minicpmv4_6` |
|
| 49 |
+
| Fine-tuning method | LoRA fine-tuning, merged/exported |
|
| 50 |
+
| Primary format | Safetensors |
|
| 51 |
+
| Quantized format | GGUF |
|
| 52 |
+
| Language | English |
|
| 53 |
+
| License | Apache-2.0 |
|
| 54 |
+
| Dataset | `ASHu2/rune_goblin_visual_dataset` |
|
| 55 |
+
| Primary use case | Hand-drawn rune interpretation for Rune Goblin |
|
| 56 |
|
| 57 |
+
---
|
| 58 |
|
| 59 |
+
## What This Model Does
|
| 60 |
|
| 61 |
+
GoblinV1 reads a player-drawn spell image and returns structured spell interpretation metadata.
|
|
|
|
|
|
|
| 62 |
|
| 63 |
+
The model is trained to identify:
|
| 64 |
|
| 65 |
+
- drawn RuneLang glyphs
|
| 66 |
+
- ambiguous or messy rune shapes
|
| 67 |
+
- confidence of the visual reading
|
| 68 |
+
- spell name and spell type
|
| 69 |
+
- colors, shape, motion, particles, and sound tags
|
| 70 |
+
- presentation hints for game VFX
|
| 71 |
+
- weird, funny, cursed spell flavor consistent with Rune Goblin
|
| 72 |
|
| 73 |
+
The model is designed to act as the **rune reader and spell presentation planner**.
|
| 74 |
|
| 75 |
+
The game engine should still own final combat balance, HP changes, boss rules, inventory state, and durable quest state.
|
| 76 |
|
| 77 |
+
---
|
| 78 |
|
| 79 |
+
## Rune Goblin
|
| 80 |
|
| 81 |
+
Rune Goblin is a Gradio-based AI dungeon crawler where the player draws their own spells.
|
| 82 |
|
| 83 |
+
Instead of selecting “fireball” from a fixed menu, the player draws symbolic glyphs. GoblinV1 reads the glyphs and converts them into spell interpretation JSON.
|
| 84 |
|
| 85 |
+
Example RuneLang meanings:
|
| 86 |
|
| 87 |
+
| Rune | Meaning |
|
| 88 |
+
|---|---|
|
| 89 |
+
| Flame | burn, danger, passion |
|
| 90 |
+
| Leaf | healing, growth, poison |
|
| 91 |
+
| Bone | fear, decay, skeletons |
|
| 92 |
+
| Spiral | time, confusion, loops |
|
| 93 |
+
| Eye | reveal, inspect, prophecy |
|
| 94 |
+
| Mirror | reflect, copy, reverse |
|
| 95 |
+
| Circle | shield, trap, containment |
|
| 96 |
+
| Broken Mark | curse modifier |
|
| 97 |
+
| Bell | summon, alarm, attention |
|
| 98 |
+
| Coin | trade, greed, sacrifice |
|
| 99 |
|
| 100 |
+
Example combinations:
|
| 101 |
|
| 102 |
+
| Combination | Meaning |
|
| 103 |
+
|---|---|
|
| 104 |
+
| Flame + Circle | burning shield |
|
| 105 |
+
| Spiral + Eye | prophecy / foresight |
|
| 106 |
+
| Bone + Dots | skeleton swarm |
|
| 107 |
+
| Mirror + Jagged | reflect damage |
|
| 108 |
+
| Leaf + Bone | healing with decay risk |
|
| 109 |
+
| Broken + Any Rune | stronger effect with cursed side effect |
|
| 110 |
|
| 111 |
+
---
|
| 112 |
|
| 113 |
+
## Expected Input
|
| 114 |
|
| 115 |
+
The model expects an image containing a hand-drawn RuneLang spell.
|
| 116 |
|
| 117 |
+
The image usually contains 1-4 glyphs drawn by the player on a canvas.
|
| 118 |
|
| 119 |
+
The prompt should instruct the model to return JSON only.
|
| 120 |
|
| 121 |
+
Example prompt:
|
| 122 |
|
| 123 |
+
```text
|
| 124 |
+
Look at this drawn RuneLang spell. Identify the runes, ambiguity, confidence, and produce spell presentation metadata: name, type, colors, shape, motion, grandeur, particles, and sound tags. Return valid JSON only.
|
| 125 |
+
```
|
| 126 |
|
| 127 |
+
---
|
| 128 |
|
| 129 |
+
## Expected Output
|
| 130 |
+
|
| 131 |
+
GoblinV1 should return JSON in this style:
|
| 132 |
+
|
| 133 |
+
```json
|
| 134 |
+
{
|
| 135 |
+
"visual_reading": {
|
| 136 |
+
"detected_runes": ["flame", "circle"],
|
| 137 |
+
"ambiguous_runes": [],
|
| 138 |
+
"confidence": 0.91,
|
| 139 |
+
"layout": "left_to_right"
|
| 140 |
+
},
|
| 141 |
+
"spell": {
|
| 142 |
+
"spell_name": "Ember Lunchbox Ward",
|
| 143 |
+
"spell_type": "fire_defense",
|
| 144 |
+
"rune_combo": ["flame", "circle"],
|
| 145 |
+
"summary": "A circular flame ward forms around the player.",
|
| 146 |
+
"colors": ["orange", "red", "gold"],
|
| 147 |
+
"shape": "burning circular shield",
|
| 148 |
+
"motion": "slow clockwise rotation with pulsing embers",
|
| 149 |
+
"grandeur": "medium",
|
| 150 |
+
"particles": ["embers", "sparks", "heat shimmer"],
|
| 151 |
+
"sound_tags": ["crackle", "whoosh", "low hum"]
|
| 152 |
+
}
|
| 153 |
+
}
|
| 154 |
+
```
|
| 155 |
|
| 156 |
+
---
|
| 157 |
|
| 158 |
+
## Important Design Boundary
|
| 159 |
|
| 160 |
+
GoblinV1 is intentionally **not** responsible for final game-state authority.
|
| 161 |
|
| 162 |
+
The model may suggest spell interpretation and presentation metadata, but the game engine should decide:
|
| 163 |
|
| 164 |
+
- final HP changes
|
| 165 |
+
- damage numbers
|
| 166 |
+
- cooldowns
|
| 167 |
+
- boss immunity rules
|
| 168 |
+
- quest state
|
| 169 |
+
- inventory changes
|
| 170 |
+
- progression unlocks
|
| 171 |
+
- anti-cheat and validation logic
|
| 172 |
|
| 173 |
+
Recommended architecture:
|
| 174 |
|
| 175 |
+
```text
|
| 176 |
+
Player drawing
|
| 177 |
+
↓
|
| 178 |
+
GoblinV1 vision model
|
| 179 |
+
↓
|
| 180 |
+
Rune + spell JSON
|
| 181 |
+
↓
|
| 182 |
+
Game engine validates / clamps / balances
|
| 183 |
+
↓
|
| 184 |
+
Final spell effect is applied
|
| 185 |
+
```
|
| 186 |
|
| 187 |
+
This keeps Rune Goblin fun and expressive while preventing model hallucinations from breaking combat balance.
|
| 188 |
|
| 189 |
+
---
|
| 190 |
|
| 191 |
+
## Training Data
|
| 192 |
|
| 193 |
+
GoblinV1 was fine-tuned on `ASHu2/rune_goblin_visual_dataset`, a custom visual instruction dataset for Rune Goblin.
|
| 194 |
|
| 195 |
+
The dataset contains hand-drawn or synthetic RuneLang spell images paired with structured chat-style targets.
|
| 196 |
|
| 197 |
+
Each example teaches the model to:
|
| 198 |
|
| 199 |
+
- read visual glyphs
|
| 200 |
+
- map glyphs to RuneLang symbols
|
| 201 |
+
- handle messy or ambiguous drawings
|
| 202 |
+
- follow RuneLang combination rules
|
| 203 |
+
- return valid JSON
|
| 204 |
+
- preserve the game’s cursed-comedic tone
|
| 205 |
|
| 206 |
+
The dataset uses image paths and conversational messages containing a system prompt, user prompt, and assistant JSON target.
|
| 207 |
|
| 208 |
+
---
|
| 209 |
|
| 210 |
+
## Training Objective
|
| 211 |
|
| 212 |
+
The objective is not general image captioning.
|
| 213 |
|
| 214 |
+
The model is trained for:
|
| 215 |
|
| 216 |
+
```text
|
| 217 |
+
drawn rune image + instruction → structured spell interpretation JSON
|
| 218 |
+
```
|
| 219 |
|
| 220 |
+
The model learns the custom RuneLang vocabulary and the relationship between visual glyphs and spell presentation.
|
| 221 |
|
| 222 |
+
---
|
| 223 |
|
| 224 |
+
## Model Formats
|
| 225 |
|
| 226 |
+
This repository includes multiple usable formats.
|
| 227 |
|
| 228 |
+
### Safetensors
|
| 229 |
|
| 230 |
+
Use this for normal Transformers-based inference or deployment.
|
| 231 |
|
| 232 |
+
### GGUF
|
| 233 |
|
| 234 |
+
A quantized GGUF version is included for local inference experiments with llama.cpp-compatible runtimes.
|
| 235 |
|
| 236 |
+
Example GGUF file:
|
| 237 |
|
| 238 |
+
```text
|
| 239 |
+
gguf/rune-goblin-v46-Q4_K_M.gguf
|
| 240 |
+
```
|
| 241 |
|
| 242 |
+
If using the GGUF model for vision tasks, make sure your runtime supports MiniCPM-V style multimodal inference and loads the required vision/projector files when needed.
|
| 243 |
|
| 244 |
+
---
|
| 245 |
|
| 246 |
+
## Basic Transformers Usage
|
| 247 |
+
|
| 248 |
+
Install dependencies:
|
| 249 |
+
|
| 250 |
+
```bash
|
| 251 |
+
pip install torch torchvision pillow transformers accelerate
|
| 252 |
+
```
|
| 253 |
+
|
| 254 |
+
Example usage:
|
| 255 |
+
|
| 256 |
+
```python
|
| 257 |
+
from PIL import Image
|
| 258 |
+
import torch
|
| 259 |
+
from transformers import AutoProcessor, AutoModelForImageTextToText
|
| 260 |
+
|
| 261 |
+
model_id = "ASHu2/goblinV1"
|
| 262 |
+
|
| 263 |
+
processor = AutoProcessor.from_pretrained(
|
| 264 |
+
model_id,
|
| 265 |
+
trust_remote_code=True
|
| 266 |
+
)
|
| 267 |
+
|
| 268 |
+
model = AutoModelForImageTextToText.from_pretrained(
|
| 269 |
+
model_id,
|
| 270 |
+
torch_dtype=torch.bfloat16,
|
| 271 |
+
device_map="auto",
|
| 272 |
+
trust_remote_code=True
|
| 273 |
+
)
|
| 274 |
+
|
| 275 |
+
image = Image.open("example_rune.png").convert("RGB")
|
| 276 |
+
|
| 277 |
+
messages = [
|
| 278 |
+
{
|
| 279 |
+
"role": "user",
|
| 280 |
+
"content": [
|
| 281 |
+
{"type": "image", "image": image},
|
| 282 |
+
{
|
| 283 |
+
"type": "text",
|
| 284 |
+
"text": (
|
| 285 |
+
"Look at this drawn RuneLang spell. "
|
| 286 |
+
"Identify the runes, ambiguity, confidence, and produce spell presentation metadata. "
|
| 287 |
+
"Return valid JSON only."
|
| 288 |
+
)
|
| 289 |
+
}
|
| 290 |
+
]
|
| 291 |
+
}
|
| 292 |
+
]
|
| 293 |
+
|
| 294 |
+
inputs = processor.apply_chat_template(
|
| 295 |
+
messages,
|
| 296 |
+
add_generation_prompt=True,
|
| 297 |
+
tokenize=True,
|
| 298 |
+
return_dict=True,
|
| 299 |
+
return_tensors="pt"
|
| 300 |
+
).to(model.device)
|
| 301 |
+
|
| 302 |
+
with torch.no_grad():
|
| 303 |
+
output_ids = model.generate(
|
| 304 |
+
**inputs,
|
| 305 |
+
max_new_tokens=512,
|
| 306 |
+
do_sample=False
|
| 307 |
+
)
|
| 308 |
+
|
| 309 |
+
generated = output_ids[0][inputs["input_ids"].shape[-1]:]
|
| 310 |
+
text = processor.decode(generated, skip_special_tokens=True)
|
| 311 |
+
|
| 312 |
+
print(text)
|
| 313 |
+
```
|
| 314 |
|
| 315 |
+
---
|
| 316 |
|
| 317 |
+
## llama.cpp / GGUF Usage
|
| 318 |
|
| 319 |
+
If using a compatible llama.cpp build:
|
| 320 |
|
| 321 |
+
```bash
|
| 322 |
+
llama-server -hf ASHu2/goblinV1:Q4_K_M
|
| 323 |
+
```
|
|
|
|
|
|
|
| 324 |
|
| 325 |
+
Or run directly:
|
| 326 |
|
| 327 |
+
```bash
|
| 328 |
+
llama-cli -hf ASHu2/goblinV1:Q4_K_M
|
| 329 |
+
```
|
| 330 |
|
| 331 |
+
For multimodal inference, ensure your client/runtime supports MiniCPM-V and any required vision projector configuration.
|
| 332 |
|
| 333 |
+
---
|
| 334 |
|
| 335 |
+
## Intended Use
|
| 336 |
|
| 337 |
+
GoblinV1 is intended for:
|
| 338 |
|
| 339 |
+
- Rune Goblin gameplay
|
| 340 |
+
- hand-drawn spell glyph interpretation
|
| 341 |
+
- visual rune recognition
|
| 342 |
+
- experimental AI game mechanics
|
| 343 |
+
- structured JSON generation from fantasy glyph images
|
| 344 |
+
- small-model multimodal game prototypes
|
| 345 |
|
| 346 |
+
---
|
| 347 |
+
|
| 348 |
+
## Out-of-Scope Use
|
| 349 |
+
|
| 350 |
+
GoblinV1 is not intended for:
|
| 351 |
|
| 352 |
+
- safety-critical image understanding
|
| 353 |
+
- medical, legal, financial, or security decisions
|
| 354 |
+
- general OCR benchmarking
|
| 355 |
+
- real-world symbol recognition systems
|
| 356 |
+
- moderation or surveillance
|
| 357 |
+
- authoritative factual QA
|
| 358 |
+
- replacing deterministic game rules
|
| 359 |
|
| 360 |
+
---
|
| 361 |
+
|
| 362 |
+
## Limitations
|
| 363 |
|
| 364 |
+
GoblinV1 may:
|
| 365 |
|
| 366 |
+
- misread very messy drawings
|
| 367 |
+
- confuse visually similar glyphs
|
| 368 |
+
- produce malformed JSON in some cases
|
| 369 |
+
- invent spell details outside the intended schema
|
| 370 |
+
- overfit to Rune Goblin-style symbols
|
| 371 |
+
- perform poorly on non-RuneLang images
|
| 372 |
+
- require game-engine validation before applying effects
|
| 373 |
|
| 374 |
+
Recommended production safeguards:
|
| 375 |
|
| 376 |
+
- validate output JSON
|
| 377 |
+
- retry once on invalid output
|
| 378 |
+
- clamp all numeric values in the game engine
|
| 379 |
+
- reject unknown runes
|
| 380 |
+
- keep final state transitions deterministic
|
| 381 |
+
- log ambiguous readings for future dataset improvement
|
| 382 |
|
| 383 |
+
---
|
| 384 |
|
| 385 |
+
## Suggested Evaluation
|
| 386 |
+
|
| 387 |
+
Recommended metrics:
|
| 388 |
+
|
| 389 |
+
| Metric | Goal |
|
| 390 |
+
|---|---|
|
| 391 |
+
| Valid JSON rate | >95% |
|
| 392 |
+
| Rune detection accuracy | >85% |
|
| 393 |
+
| Ambiguity detection quality | Manual review |
|
| 394 |
+
| Schema compliance | >95% |
|
| 395 |
+
| Unknown rune rejection | High |
|
| 396 |
+
| Latency | Playable for Gradio |
|
| 397 |
+
| Cursed-fantasy tone consistency | Manual review |
|
| 398 |
+
|
| 399 |
+
Suggested test cases:
|
| 400 |
+
|
| 401 |
+
```text
|
| 402 |
+
flame + circle
|
| 403 |
+
spiral + eye
|
| 404 |
+
bone + dots
|
| 405 |
+
mirror + jagged
|
| 406 |
+
leaf + bone
|
| 407 |
+
broken + coin
|
| 408 |
+
messy flame vs leaf
|
| 409 |
+
partial / incomplete glyph
|
| 410 |
+
empty canvas
|
| 411 |
+
```
|
| 412 |
+
|
| 413 |
+
---
|
| 414 |
+
|
| 415 |
+
## Example Output
|
| 416 |
+
|
| 417 |
+
```json
|
| 418 |
+
{
|
| 419 |
+
"visual_reading": {
|
| 420 |
+
"detected_runes": ["spiral", "eye", "broken_mark"],
|
| 421 |
+
"ambiguous_runes": [
|
| 422 |
+
{
|
| 423 |
+
"candidates": ["spiral", "wave"],
|
| 424 |
+
"reason": "curved repeated stroke could indicate either looping time or water/emotion"
|
| 425 |
+
}
|
| 426 |
+
],
|
| 427 |
+
"confidence": 0.82,
|
| 428 |
+
"layout": "clustered"
|
| 429 |
+
},
|
| 430 |
+
"spell": {
|
| 431 |
+
"spell_name": "Cursed Foresight Loop",
|
| 432 |
+
"spell_type": "prophecy_curse",
|
| 433 |
+
"rune_combo": ["spiral", "eye", "broken_mark"],
|
| 434 |
+
"summary": "The spell reveals a possible future, then immediately makes it worse.",
|
| 435 |
+
"colors": ["violet", "black", "pale blue"],
|
| 436 |
+
"shape": "floating eye inside a cracked spiral",
|
| 437 |
+
"motion": "spiral contracts inward while the eye flickers",
|
| 438 |
+
"grandeur": "high",
|
| 439 |
+
"particles": ["purple sparks", "black motes", "thin time-rings"],
|
| 440 |
+
"sound_tags": ["whisper", "glass-crack", "reverse-chime"]
|
| 441 |
+
}
|
| 442 |
+
}
|
| 443 |
+
```
|
| 444 |
+
|
| 445 |
+
---
|
| 446 |
|
| 447 |
+
## Deployment Notes
|
| 448 |
|
| 449 |
+
GoblinV1 can be used as the model backend for a Gradio game.
|
| 450 |
|
| 451 |
+
Recommended serving layout:
|
| 452 |
|
| 453 |
+
```text
|
| 454 |
+
Gradio UI / Canvas
|
| 455 |
+
↓
|
| 456 |
+
Image preprocessing
|
| 457 |
+
↓
|
| 458 |
+
GoblinV1 inference
|
| 459 |
+
↓
|
| 460 |
+
JSON parsing + validation
|
| 461 |
+
↓
|
| 462 |
+
Rune Goblin game engine
|
| 463 |
+
↓
|
| 464 |
+
Updated battle state + animation
|
| 465 |
+
```
|
| 466 |
|
| 467 |
+
For GPU deployment, use the Safetensors model with Transformers.
|
| 468 |
+
|
| 469 |
+
For lightweight/local experiments, use the GGUF export with a compatible llama.cpp runtime.
|
| 470 |
+
|
| 471 |
+
---
|
| 472 |
+
|
| 473 |
+
## Related Project
|
| 474 |
+
|
| 475 |
+
GoblinV1 powers the Rune Goblin dungeon crawler.
|
| 476 |
+
|
| 477 |
+
Rune Goblin is an AI game where players draw spells, explore maps, fight bosses, trigger cursed outcomes, and unlock stronger effects by drawing clearer runes.
|
| 478 |
+
|
| 479 |
+
Links:
|
| 480 |
+
|
| 481 |
+
- Game/demo: https://huggingface.co/spaces/build-small-hackathon/Rune-Goblin
|
| 482 |
+
- Model: https://huggingface.co/ASHu2/goblinV1
|
| 483 |
+
- Dataset: https://huggingface.co/datasets/ASHu2/rune_goblin_visual_dataset
|
| 484 |
+
|
| 485 |
+
---
|
| 486 |
+
|
| 487 |
+
## Citation
|
| 488 |
+
|
| 489 |
+
If you use this model, please cite:
|
| 490 |
+
|
| 491 |
+
```bibtex
|
| 492 |
+
@misc{goblinv1_2026,
|
| 493 |
+
title = {GoblinV1: A Fine-Tuned MiniCPM-V Rune Reader for Rune Goblin},
|
| 494 |
+
author = {Ashutosh Mishra},
|
| 495 |
+
year = {2026},
|
| 496 |
+
publisher = {Hugging Face},
|
| 497 |
+
howpublished = {https://huggingface.co/ASHu2/goblinV1}
|
| 498 |
+
}
|
| 499 |
+
```
|
| 500 |
+
|
| 501 |
+
Base model:
|
| 502 |
+
|
| 503 |
+
```bibtex
|
| 504 |
+
@misc{minicpmv46_2026,
|
| 505 |
+
title = {MiniCPM-V 4.6},
|
| 506 |
+
author = {OpenBMB},
|
| 507 |
+
year = {2026},
|
| 508 |
+
publisher = {Hugging Face},
|
| 509 |
+
howpublished = {https://huggingface.co/openbmb/MiniCPM-V-4.6}
|
| 510 |
+
}
|
| 511 |
+
```
|
| 512 |
+
|
| 513 |
+
---
|
| 514 |
+
|
| 515 |
+
## License
|
| 516 |
+
|
| 517 |
+
This model is released under the Apache-2.0 license.
|
| 518 |
+
|
| 519 |
+
Please also follow the license and usage terms of the base model `openbmb/MiniCPM-V-4.6`.
|
| 520 |
+
|
| 521 |
+
---
|
| 522 |
|
| 523 |
+
## Acknowledgements
|
| 524 |
|
| 525 |
+
GoblinV1 is built on top of OpenBMB MiniCPM-V-4.6.
|
| 526 |
|
| 527 |
+
Thanks to the open-source multimodal model community, Hugging Face, Gradio, Modal, llama.cpp, and the cursed little goblin inside every ambiguous doodle.
|