Instructions to use BikoRiko/Gpt-Classification with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use BikoRiko/Gpt-Classification with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="BikoRiko/Gpt-Classification")# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("BikoRiko/Gpt-Classification", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Update README.md
Browse files
README.md
CHANGED
|
@@ -1,3 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
# GPT-Classification: Custom Transformer for Text Classification
|
| 2 |
|
| 3 |
This model is a custom **Transformer-based classifier** built from scratch using PyTorch. Unlike standard pre-trained models, this was designed with a specific focus on understanding character-level patterns for short to medium-length text classification.
|
|
@@ -29,4 +40,4 @@ This model is a custom **Transformer-based classifier** built from scratch using
|
|
| 29 |
1. Load the `config.json` to reconstruct the `stoi` mapping and model hyperparameters.
|
| 30 |
2. Initialize the `GPTClassification` class with the saved hyperparameters.
|
| 31 |
3. Load the weights using `torch.load('model.pt')`.
|
| 32 |
-
4. Ensure input strings are encoded using the character map and padded/truncated to 128 characters.
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: mit
|
| 3 |
+
language:
|
| 4 |
+
- en
|
| 5 |
+
pipeline_tag: text-classification
|
| 6 |
+
library_name: transformers
|
| 7 |
+
tags:
|
| 8 |
+
- custom_dataset
|
| 9 |
+
- High_quality
|
| 10 |
+
- Gpt
|
| 11 |
+
---
|
| 12 |
# GPT-Classification: Custom Transformer for Text Classification
|
| 13 |
|
| 14 |
This model is a custom **Transformer-based classifier** built from scratch using PyTorch. Unlike standard pre-trained models, this was designed with a specific focus on understanding character-level patterns for short to medium-length text classification.
|
|
|
|
| 40 |
1. Load the `config.json` to reconstruct the `stoi` mapping and model hyperparameters.
|
| 41 |
2. Initialize the `GPTClassification` class with the saved hyperparameters.
|
| 42 |
3. Load the weights using `torch.load('model.pt')`.
|
| 43 |
+
4. Ensure input strings are encoded using the character map and padded/truncated to 128 characters.
|