Instructions to use huggingtweets/clamtime with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use huggingtweets/clamtime with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="huggingtweets/clamtime")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("huggingtweets/clamtime") model = AutoModelForCausalLM.from_pretrained("huggingtweets/clamtime") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use huggingtweets/clamtime with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "huggingtweets/clamtime" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "huggingtweets/clamtime", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/huggingtweets/clamtime
- SGLang
How to use huggingtweets/clamtime 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 "huggingtweets/clamtime" \ --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": "huggingtweets/clamtime", "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 "huggingtweets/clamtime" \ --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": "huggingtweets/clamtime", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use huggingtweets/clamtime with Docker Model Runner:
docker model run hf.co/huggingtweets/clamtime
New model from https://wandb.ai/wandb/huggingtweets/runs/10x8dyea
Browse files- README.md +10 -10
- config.json +1 -1
- pytorch_model.bin +2 -2
- tokenizer_config.json +1 -1
- training_args.bin +2 -2
README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
| 1 |
---
|
| 2 |
language: en
|
| 3 |
-
thumbnail: https://
|
| 4 |
tags:
|
| 5 |
- huggingtweets
|
| 6 |
widget:
|
|
@@ -8,7 +8,7 @@ widget:
|
|
| 8 |
---
|
| 9 |
|
| 10 |
<div>
|
| 11 |
-
<div style="width: 132px; height:132px; border-radius: 50%; background-size: cover; background-image: url('https://pbs.twimg.com/profile_images/
|
| 12 |
</div>
|
| 13 |
<div style="margin-top: 8px; font-size: 19px; font-weight: 800">clementine!!!! 𓆏 🤖 AI Bot </div>
|
| 14 |
<div style="font-size: 15px">@clamtime bot</div>
|
|
@@ -24,7 +24,7 @@ The model uses the following pipeline.
|
|
| 24 |
|
| 25 |

|
| 26 |
|
| 27 |
-
To understand how the model was developed, check the [W&B report](https://
|
| 28 |
|
| 29 |
## Training data
|
| 30 |
|
|
@@ -32,20 +32,20 @@ The model was trained on [@clamtime's tweets](https://twitter.com/clamtime).
|
|
| 32 |
|
| 33 |
| Data | Quantity |
|
| 34 |
| --- | --- |
|
| 35 |
-
| Tweets downloaded |
|
| 36 |
-
| Retweets |
|
| 37 |
-
| Short tweets |
|
| 38 |
-
| Tweets kept |
|
| 39 |
|
| 40 |
-
[Explore the data](https://wandb.ai/wandb/huggingtweets/runs/
|
| 41 |
|
| 42 |
## Training procedure
|
| 43 |
|
| 44 |
The model is based on a pre-trained [GPT-2](https://huggingface.co/gpt2) which is fine-tuned on @clamtime's tweets.
|
| 45 |
|
| 46 |
-
Hyperparameters and metrics are recorded in the [W&B training run](https://wandb.ai/wandb/huggingtweets/runs/
|
| 47 |
|
| 48 |
-
At the end of training, [the final model](https://wandb.ai/wandb/huggingtweets/runs/
|
| 49 |
|
| 50 |
## How to use
|
| 51 |
|
|
|
|
| 1 |
---
|
| 2 |
language: en
|
| 3 |
+
thumbnail: https://github.com/borisdayma/huggingtweets/blob/master/img/logo.png?raw=true
|
| 4 |
tags:
|
| 5 |
- huggingtweets
|
| 6 |
widget:
|
|
|
|
| 8 |
---
|
| 9 |
|
| 10 |
<div>
|
| 11 |
+
<div style="width: 132px; height:132px; border-radius: 50%; background-size: cover; background-image: url('https://pbs.twimg.com/profile_images/1384662289777893379/s2NlrjMS_400x400.jpg')">
|
| 12 |
</div>
|
| 13 |
<div style="margin-top: 8px; font-size: 19px; font-weight: 800">clementine!!!! 𓆏 🤖 AI Bot </div>
|
| 14 |
<div style="font-size: 15px">@clamtime bot</div>
|
|
|
|
| 24 |
|
| 25 |

|
| 26 |
|
| 27 |
+
To understand how the model was developed, check the [W&B report](https://wandb.ai/wandb/huggingtweets/reports/HuggingTweets-Train-a-Model-to-Generate-Tweets--VmlldzoxMTY5MjI).
|
| 28 |
|
| 29 |
## Training data
|
| 30 |
|
|
|
|
| 32 |
|
| 33 |
| Data | Quantity |
|
| 34 |
| --- | --- |
|
| 35 |
+
| Tweets downloaded | 3169 |
|
| 36 |
+
| Retweets | 711 |
|
| 37 |
+
| Short tweets | 586 |
|
| 38 |
+
| Tweets kept | 1872 |
|
| 39 |
|
| 40 |
+
[Explore the data](https://wandb.ai/wandb/huggingtweets/runs/3qzb1bqs/artifacts), which is tracked with [W&B artifacts](https://docs.wandb.com/artifacts) at every step of the pipeline.
|
| 41 |
|
| 42 |
## Training procedure
|
| 43 |
|
| 44 |
The model is based on a pre-trained [GPT-2](https://huggingface.co/gpt2) which is fine-tuned on @clamtime's tweets.
|
| 45 |
|
| 46 |
+
Hyperparameters and metrics are recorded in the [W&B training run](https://wandb.ai/wandb/huggingtweets/runs/10x8dyea) for full transparency and reproducibility.
|
| 47 |
|
| 48 |
+
At the end of training, [the final model](https://wandb.ai/wandb/huggingtweets/runs/10x8dyea/artifacts) is logged and versioned.
|
| 49 |
|
| 50 |
## How to use
|
| 51 |
|
config.json
CHANGED
|
@@ -34,7 +34,7 @@
|
|
| 34 |
"top_p": 0.95
|
| 35 |
}
|
| 36 |
},
|
| 37 |
-
"transformers_version": "4.
|
| 38 |
"use_cache": true,
|
| 39 |
"vocab_size": 50257
|
| 40 |
}
|
|
|
|
| 34 |
"top_p": 0.95
|
| 35 |
}
|
| 36 |
},
|
| 37 |
+
"transformers_version": "4.5.1",
|
| 38 |
"use_cache": true,
|
| 39 |
"vocab_size": 50257
|
| 40 |
}
|
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:f4d84dbb5b4408c4542c35f3a006a557757ff1b52b114b524746999b3178988b
|
| 3 |
+
size 510408315
|
tokenizer_config.json
CHANGED
|
@@ -1 +1 @@
|
|
| 1 |
-
{"unk_token": "<|endoftext|>", "bos_token": "<|endoftext|>", "eos_token": "<|endoftext|>", "add_prefix_space": false, "model_max_length": 1024, "name_or_path": "gpt2"}
|
|
|
|
| 1 |
+
{"unk_token": "<|endoftext|>", "bos_token": "<|endoftext|>", "eos_token": "<|endoftext|>", "add_prefix_space": false, "model_max_length": 1024, "special_tokens_map_file": null, "name_or_path": "gpt2"}
|
training_args.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:6cc7249caa6617a4daa1128f9be664853fdff4c48fec9703c17145f3b3fa6fdf
|
| 3 |
+
size 2351
|