Text Generation
Transformers
PyTorch
gptj
8bit
8-bit precision
quantization
compression
chatbot
dialogue
conversation
Instructions to use ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps") model = AutoModelForCausalLM.from_pretrained("ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps") - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps
- SGLang
How to use ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps 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 "ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps" \ --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": "ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps", "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 "ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps" \ --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": "ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps with Docker Model Runner:
docker model run hf.co/ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps
add sharded model
Browse files
config.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
| 1 |
{
|
| 2 |
-
"_name_or_path": "
|
| 3 |
"activation_function": "gelu_new",
|
| 4 |
"architectures": [
|
| 5 |
"GPTJForCausalLM"
|
|
@@ -39,7 +39,7 @@
|
|
| 39 |
"tie_word_embeddings": false,
|
| 40 |
"tokenizer_class": "GPT2Tokenizer",
|
| 41 |
"torch_dtype": "float32",
|
| 42 |
-
"transformers_version": "4.
|
| 43 |
"use_cache": true,
|
| 44 |
"vocab_size": 50400
|
| 45 |
}
|
|
|
|
| 1 |
{
|
| 2 |
+
"_name_or_path": "ethzanalytics/gpt-j-8bit-KILT_WoW_10k_steps",
|
| 3 |
"activation_function": "gelu_new",
|
| 4 |
"architectures": [
|
| 5 |
"GPTJForCausalLM"
|
|
|
|
| 39 |
"tie_word_embeddings": false,
|
| 40 |
"tokenizer_class": "GPT2Tokenizer",
|
| 41 |
"torch_dtype": "float32",
|
| 42 |
+
"transformers_version": "4.24.0",
|
| 43 |
"use_cache": true,
|
| 44 |
"vocab_size": 50400
|
| 45 |
}
|
pytorch_model.bin → pytorch_model-00001-of-00004.bin
RENAMED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:ec031cf083fb0d0fe954087834cbc6fa2db5af0a444a9692a17c68d99cfdce59
|
| 3 |
+
size 1935755141
|
pytorch_model-00002-of-00004.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:80ecdaf7d110c1ea743cb9acefce2b69bd2c221415d49134dfd15c025892d246
|
| 3 |
+
size 1998326687
|
pytorch_model-00003-of-00004.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:f8b0d5b66533a8d18bd055e54c4ddd35635941afa15c12395840dab783d17b69
|
| 3 |
+
size 1935237323
|
pytorch_model-00004-of-00004.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:b160162aa155ce043628c0df616b464d43dce79a0ef9fd9977ed1dcedba76017
|
| 3 |
+
size 342775340
|
pytorch_model.bin.index.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:e199a7a6fbf4ce58a1a7ad18dfaddc8e3949cbd5d3c902c3c48743a54664e6fd
|
| 3 |
+
size 82123
|