Instructions to use Connorvr/TeachingGen with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Connorvr/TeachingGen with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Connorvr/TeachingGen")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Connorvr/TeachingGen") model = AutoModelForCausalLM.from_pretrained("Connorvr/TeachingGen") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Connorvr/TeachingGen with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Connorvr/TeachingGen" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Connorvr/TeachingGen", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/Connorvr/TeachingGen
- SGLang
How to use Connorvr/TeachingGen 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 "Connorvr/TeachingGen" \ --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": "Connorvr/TeachingGen", "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 "Connorvr/TeachingGen" \ --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": "Connorvr/TeachingGen", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use Connorvr/TeachingGen with Docker Model Runner:
docker model run hf.co/Connorvr/TeachingGen
Expanded training set
Browse files- README.md +5 -5
- config.json +1 -1
- pytorch_model.bin +2 -2
- tokenizer.json +0 -0
- training_args.bin +1 -1
README.md
CHANGED
|
@@ -32,8 +32,8 @@ More information needed
|
|
| 32 |
|
| 33 |
The following hyperparameters were used during training:
|
| 34 |
- learning_rate: 5e-05
|
| 35 |
-
- train_batch_size:
|
| 36 |
-
- eval_batch_size:
|
| 37 |
- seed: 42
|
| 38 |
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
|
| 39 |
- lr_scheduler_type: linear
|
|
@@ -45,7 +45,7 @@ The following hyperparameters were used during training:
|
|
| 45 |
|
| 46 |
### Framework versions
|
| 47 |
|
| 48 |
-
- Transformers 4.
|
| 49 |
- Pytorch 1.6.0
|
| 50 |
-
- Datasets
|
| 51 |
-
- Tokenizers 0.
|
|
|
|
| 32 |
|
| 33 |
The following hyperparameters were used during training:
|
| 34 |
- learning_rate: 5e-05
|
| 35 |
+
- train_batch_size: 1
|
| 36 |
+
- eval_batch_size: 1
|
| 37 |
- seed: 42
|
| 38 |
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
|
| 39 |
- lr_scheduler_type: linear
|
|
|
|
| 45 |
|
| 46 |
### Framework versions
|
| 47 |
|
| 48 |
+
- Transformers 4.18.0.dev0
|
| 49 |
- Pytorch 1.6.0
|
| 50 |
+
- Datasets 2.0.0
|
| 51 |
+
- Tokenizers 0.11.6
|
config.json
CHANGED
|
@@ -33,7 +33,7 @@
|
|
| 33 |
}
|
| 34 |
},
|
| 35 |
"torch_dtype": "float32",
|
| 36 |
-
"transformers_version": "4.
|
| 37 |
"use_cache": true,
|
| 38 |
"vocab_size": 50257
|
| 39 |
}
|
|
|
|
| 33 |
}
|
| 34 |
},
|
| 35 |
"torch_dtype": "float32",
|
| 36 |
+
"transformers_version": "4.18.0.dev0",
|
| 37 |
"use_cache": true,
|
| 38 |
"vocab_size": 50257
|
| 39 |
}
|
pytorch_model.bin
CHANGED
|
@@ -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:f55d9715b34c2adfa7600e4be375ac3aa19de04fcd91d8b9d0db21bd2f794334
|
| 3 |
+
size 510408891
|
tokenizer.json
CHANGED
|
The diff for this file is too large to render.
See raw diff
|
|
|
training_args.bin
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 2991
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:e7615dbd844831478bffcb4976fc9cf2e2f11ef00aadb7d272122b7c4cf5baf1
|
| 3 |
size 2991
|