Text Generation
Transformers
PyTorch
TensorBoard
code
gpt2
Generated from Trainer
codegen
assembly
custom_code
text-generation-inference
Instructions to use muhtasham/santacoder-finetuned-the-stack-cobol with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use muhtasham/santacoder-finetuned-the-stack-cobol with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="muhtasham/santacoder-finetuned-the-stack-cobol", trust_remote_code=True)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("muhtasham/santacoder-finetuned-the-stack-cobol", trust_remote_code=True) model = AutoModelForCausalLM.from_pretrained("muhtasham/santacoder-finetuned-the-stack-cobol", trust_remote_code=True) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use muhtasham/santacoder-finetuned-the-stack-cobol with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "muhtasham/santacoder-finetuned-the-stack-cobol" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "muhtasham/santacoder-finetuned-the-stack-cobol", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/muhtasham/santacoder-finetuned-the-stack-cobol
- SGLang
How to use muhtasham/santacoder-finetuned-the-stack-cobol 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 "muhtasham/santacoder-finetuned-the-stack-cobol" \ --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": "muhtasham/santacoder-finetuned-the-stack-cobol", "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 "muhtasham/santacoder-finetuned-the-stack-cobol" \ --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": "muhtasham/santacoder-finetuned-the-stack-cobol", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use muhtasham/santacoder-finetuned-the-stack-cobol with Docker Model Runner:
docker model run hf.co/muhtasham/santacoder-finetuned-the-stack-cobol
Update README.md
Browse files
README.md
CHANGED
|
@@ -9,10 +9,11 @@ model-index:
|
|
| 9 |
- name: santacoder-finetuned-the-stack-cobol
|
| 10 |
results: []
|
| 11 |
datasets:
|
| 12 |
-
|
| 13 |
language:
|
| 14 |
-
|
| 15 |
pipeline_tag: text-generation
|
|
|
|
| 16 |
---
|
| 17 |
|
| 18 |
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
|
@@ -75,4 +76,4 @@ The following hyperparameters were used during training:
|
|
| 75 |
- Transformers 4.26.0
|
| 76 |
- Pytorch 1.13.1+cu116
|
| 77 |
- Datasets 2.9.0
|
| 78 |
-
- Tokenizers 0.13.2
|
|
|
|
| 9 |
- name: santacoder-finetuned-the-stack-cobol
|
| 10 |
results: []
|
| 11 |
datasets:
|
| 12 |
+
- bigcode/the-stack-dedup
|
| 13 |
language:
|
| 14 |
+
- code
|
| 15 |
pipeline_tag: text-generation
|
| 16 |
+
library_name: transformers
|
| 17 |
---
|
| 18 |
|
| 19 |
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
|
|
|
| 76 |
- Transformers 4.26.0
|
| 77 |
- Pytorch 1.13.1+cu116
|
| 78 |
- Datasets 2.9.0
|
| 79 |
+
- Tokenizers 0.13.2
|