Text Generation
Transformers
Safetensors
English
weblinx
text-generation-inference
web-agents
agents
Instructions to use McGill-NLP/flan-t5-base-weblinx with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use McGill-NLP/flan-t5-base-weblinx with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="McGill-NLP/flan-t5-base-weblinx")# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("McGill-NLP/flan-t5-base-weblinx", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use McGill-NLP/flan-t5-base-weblinx with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "McGill-NLP/flan-t5-base-weblinx" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "McGill-NLP/flan-t5-base-weblinx", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/McGill-NLP/flan-t5-base-weblinx
- SGLang
How to use McGill-NLP/flan-t5-base-weblinx 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 "McGill-NLP/flan-t5-base-weblinx" \ --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": "McGill-NLP/flan-t5-base-weblinx", "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 "McGill-NLP/flan-t5-base-weblinx" \ --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": "McGill-NLP/flan-t5-base-weblinx", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use McGill-NLP/flan-t5-base-weblinx with Docker Model Runner:
docker model run hf.co/McGill-NLP/flan-t5-base-weblinx
xhluca commited on
Commit ·
dcd1ad6
1
Parent(s): cb8d1cf
Add model, tokenizer, and config files, input records.
Browse files- config.json +3 -0
- generation_config.json +3 -0
- input_records_trunc.json +3 -0
- model.safetensors +3 -0
- special_tokens_map.json +3 -0
- spiece.model +3 -0
- tokenizer.json +3 -0
- tokenizer_config.json +3 -0
- trainer_state.json +3 -0
- training_args.bin +3 -0
config.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:b63653af15c5fcbf1fc58efe47f897f1575fb2f433b94b4cbf924e1502cf18e3
|
| 3 |
+
size 1558
|
generation_config.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:8e1f5fe6985d189e6afadfc6aa83d9ff25d57e7637490f614fffb35f4076d1c3
|
| 3 |
+
size 142
|
input_records_trunc.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:83e63cfe9a01be5fc4e5dcc6a6736a934e452950665253875e1c8bf019e177ba
|
| 3 |
+
size 118708057
|
model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:686200e4b2dc4f94a11a21d00d80c58977a221bafdcad6f6f7939211a4e3de05
|
| 3 |
+
size 495189552
|
special_tokens_map.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:5c87151ef0f72a99d1f766a4c418bd2a1f90aaa30a8e22fe5eca9641daebb64f
|
| 3 |
+
size 2201
|
spiece.model
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:d60acb128cf7b7f2536e8f38a5b18a05535c9e14c7a355904270e15b0945ea86
|
| 3 |
+
size 791656
|
tokenizer.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:6e1cae6a6e7c807a4bc6079069e8c3ef744e0ee29d573c2660717a1f6dedacba
|
| 3 |
+
size 2422291
|
tokenizer_config.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:6fa625547e73f7a565e5fa7f6cc0b89e61c521c15816c8415238f639fa5b9e21
|
| 3 |
+
size 20771
|
trainer_state.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:16fefc908440907c606354de838ea9361c4ef05e8dd69c819e37c68afc403d40
|
| 3 |
+
size 1369
|
training_args.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:fd2bfe2d7c810ab64945f68adc7043d750c34e2370d7f3657afde4f2fe8231ab
|
| 3 |
+
size 4411
|