Text Generation
Transformers
PyTorch
English
t5
text2text-generation
SQL
plSQL
english
text-generation-inference
Instructions to use MRNH/flan-t5-large-PLsql with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use MRNH/flan-t5-large-PLsql with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="MRNH/flan-t5-large-PLsql")# Load model directly from transformers import AutoTokenizer, AutoModelForSeq2SeqLM tokenizer = AutoTokenizer.from_pretrained("MRNH/flan-t5-large-PLsql") model = AutoModelForSeq2SeqLM.from_pretrained("MRNH/flan-t5-large-PLsql") - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use MRNH/flan-t5-large-PLsql with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "MRNH/flan-t5-large-PLsql" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "MRNH/flan-t5-large-PLsql", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/MRNH/flan-t5-large-PLsql
- SGLang
How to use MRNH/flan-t5-large-PLsql 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 "MRNH/flan-t5-large-PLsql" \ --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": "MRNH/flan-t5-large-PLsql", "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 "MRNH/flan-t5-large-PLsql" \ --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": "MRNH/flan-t5-large-PLsql", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use MRNH/flan-t5-large-PLsql with Docker Model Runner:
docker model run hf.co/MRNH/flan-t5-large-PLsql
Upload config.json with huggingface_hub
Browse files- config.json +85 -0
config.json
ADDED
|
@@ -0,0 +1,85 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"vocab_size": 32107,
|
| 3 |
+
"d_model": 1024,
|
| 4 |
+
"d_kv": 64,
|
| 5 |
+
"d_ff": 2816,
|
| 6 |
+
"num_layers": 24,
|
| 7 |
+
"num_decoder_layers": 24,
|
| 8 |
+
"num_heads": 16,
|
| 9 |
+
"relative_attention_num_buckets": 32,
|
| 10 |
+
"relative_attention_max_distance": 128,
|
| 11 |
+
"dropout_rate": 0.1,
|
| 12 |
+
"classifier_dropout": 0.0,
|
| 13 |
+
"layer_norm_epsilon": 1e-06,
|
| 14 |
+
"initializer_factor": 1.0,
|
| 15 |
+
"feed_forward_proj": "gated-gelu",
|
| 16 |
+
"use_cache": true,
|
| 17 |
+
"dense_act_fn": "gelu_new",
|
| 18 |
+
"is_gated_act": true,
|
| 19 |
+
"return_dict": true,
|
| 20 |
+
"output_hidden_states": false,
|
| 21 |
+
"output_attentions": false,
|
| 22 |
+
"torchscript": false,
|
| 23 |
+
"torch_dtype": null,
|
| 24 |
+
"use_bfloat16": false,
|
| 25 |
+
"tf_legacy_loss": false,
|
| 26 |
+
"pruned_heads": {},
|
| 27 |
+
"tie_word_embeddings": false,
|
| 28 |
+
"is_encoder_decoder": true,
|
| 29 |
+
"is_decoder": false,
|
| 30 |
+
"cross_attention_hidden_size": null,
|
| 31 |
+
"add_cross_attention": false,
|
| 32 |
+
"tie_encoder_decoder": false,
|
| 33 |
+
"max_length": 20,
|
| 34 |
+
"min_length": 0,
|
| 35 |
+
"do_sample": false,
|
| 36 |
+
"early_stopping": false,
|
| 37 |
+
"num_beams": 1,
|
| 38 |
+
"num_beam_groups": 1,
|
| 39 |
+
"diversity_penalty": 0.0,
|
| 40 |
+
"temperature": 1.0,
|
| 41 |
+
"top_k": 50,
|
| 42 |
+
"top_p": 1.0,
|
| 43 |
+
"typical_p": 1.0,
|
| 44 |
+
"repetition_penalty": 1.0,
|
| 45 |
+
"length_penalty": 1.0,
|
| 46 |
+
"no_repeat_ngram_size": 0,
|
| 47 |
+
"encoder_no_repeat_ngram_size": 0,
|
| 48 |
+
"bad_words_ids": null,
|
| 49 |
+
"num_return_sequences": 1,
|
| 50 |
+
"chunk_size_feed_forward": 0,
|
| 51 |
+
"output_scores": false,
|
| 52 |
+
"return_dict_in_generate": false,
|
| 53 |
+
"forced_bos_token_id": null,
|
| 54 |
+
"forced_eos_token_id": null,
|
| 55 |
+
"remove_invalid_values": false,
|
| 56 |
+
"exponential_decay_length_penalty": null,
|
| 57 |
+
"suppress_tokens": null,
|
| 58 |
+
"begin_suppress_tokens": null,
|
| 59 |
+
"architectures": [
|
| 60 |
+
"T5ForConditionalGeneration"
|
| 61 |
+
],
|
| 62 |
+
"finetuning_task": null,
|
| 63 |
+
"id2label": {
|
| 64 |
+
"0": "LABEL_0",
|
| 65 |
+
"1": "LABEL_1"
|
| 66 |
+
},
|
| 67 |
+
"label2id": {
|
| 68 |
+
"LABEL_0": 0,
|
| 69 |
+
"LABEL_1": 1
|
| 70 |
+
},
|
| 71 |
+
"tokenizer_class": null,
|
| 72 |
+
"prefix": null,
|
| 73 |
+
"bos_token_id": null,
|
| 74 |
+
"pad_token_id": 0,
|
| 75 |
+
"eos_token_id": 1,
|
| 76 |
+
"sep_token_id": null,
|
| 77 |
+
"decoder_start_token_id": 0,
|
| 78 |
+
"task_specific_params": null,
|
| 79 |
+
"problem_type": null,
|
| 80 |
+
"_name_or_path": "google/flan-t5-large",
|
| 81 |
+
"transformers_version": "4.33.3",
|
| 82 |
+
"model_type": "t5",
|
| 83 |
+
"n_positions": 512,
|
| 84 |
+
"output_past": true
|
| 85 |
+
}
|