Instructions to use nayohyun/koelectra with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use nayohyun/koelectra with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="nayohyun/koelectra")# Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("nayohyun/koelectra") model = AutoModelForSequenceClassification.from_pretrained("nayohyun/koelectra") - Notebooks
- Google Colab
- Kaggle
KoElectra_model
Browse files- README.md +71 -0
- config.json +34 -0
- model.safetensors +3 -0
- training_args.bin +3 -0
README.md
ADDED
|
@@ -0,0 +1,71 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
library_name: transformers
|
| 3 |
+
license: apache-2.0
|
| 4 |
+
base_model: monologg/koelectra-base-v3-discriminator
|
| 5 |
+
tags:
|
| 6 |
+
- generated_from_trainer
|
| 7 |
+
metrics:
|
| 8 |
+
- accuracy
|
| 9 |
+
model-index:
|
| 10 |
+
- name: koelectra
|
| 11 |
+
results: []
|
| 12 |
+
---
|
| 13 |
+
|
| 14 |
+
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
| 15 |
+
should probably proofread and complete it, then remove this comment. -->
|
| 16 |
+
|
| 17 |
+
# koelectra
|
| 18 |
+
|
| 19 |
+
This model is a fine-tuned version of [monologg/koelectra-base-v3-discriminator](https://huggingface.co/monologg/koelectra-base-v3-discriminator) on the None dataset.
|
| 20 |
+
It achieves the following results on the evaluation set:
|
| 21 |
+
- Loss: 0.7666
|
| 22 |
+
- Accuracy: 0.845
|
| 23 |
+
|
| 24 |
+
## Model description
|
| 25 |
+
|
| 26 |
+
More information needed
|
| 27 |
+
|
| 28 |
+
## Intended uses & limitations
|
| 29 |
+
|
| 30 |
+
More information needed
|
| 31 |
+
|
| 32 |
+
## Training and evaluation data
|
| 33 |
+
|
| 34 |
+
More information needed
|
| 35 |
+
|
| 36 |
+
## Training procedure
|
| 37 |
+
|
| 38 |
+
### Training hyperparameters
|
| 39 |
+
|
| 40 |
+
The following hyperparameters were used during training:
|
| 41 |
+
- learning_rate: 2e-05
|
| 42 |
+
- train_batch_size: 16
|
| 43 |
+
- eval_batch_size: 16
|
| 44 |
+
- seed: 42
|
| 45 |
+
- optimizer: Use OptimizerNames.ADAMW_TORCH_FUSED with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
|
| 46 |
+
- lr_scheduler_type: linear
|
| 47 |
+
- num_epochs: 10
|
| 48 |
+
- mixed_precision_training: Native AMP
|
| 49 |
+
|
| 50 |
+
### Training results
|
| 51 |
+
|
| 52 |
+
| Training Loss | Epoch | Step | Validation Loss | Accuracy |
|
| 53 |
+
|:-------------:|:-----:|:----:|:---------------:|:--------:|
|
| 54 |
+
| No log | 1.0 | 100 | 0.4784 | 0.795 |
|
| 55 |
+
| No log | 2.0 | 200 | 0.3960 | 0.8425 |
|
| 56 |
+
| No log | 3.0 | 300 | 0.4802 | 0.845 |
|
| 57 |
+
| No log | 4.0 | 400 | 0.5323 | 0.84 |
|
| 58 |
+
| 0.3144 | 5.0 | 500 | 0.5620 | 0.8575 |
|
| 59 |
+
| 0.3144 | 6.0 | 600 | 0.6230 | 0.845 |
|
| 60 |
+
| 0.3144 | 7.0 | 700 | 0.6707 | 0.84 |
|
| 61 |
+
| 0.3144 | 8.0 | 800 | 0.7672 | 0.84 |
|
| 62 |
+
| 0.3144 | 9.0 | 900 | 0.7634 | 0.8375 |
|
| 63 |
+
| 0.0559 | 10.0 | 1000 | 0.7666 | 0.845 |
|
| 64 |
+
|
| 65 |
+
|
| 66 |
+
### Framework versions
|
| 67 |
+
|
| 68 |
+
- Transformers 5.0.0
|
| 69 |
+
- Pytorch 2.10.0+cu128
|
| 70 |
+
- Datasets 4.0.0
|
| 71 |
+
- Tokenizers 0.22.2
|
config.json
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"add_cross_attention": false,
|
| 3 |
+
"architectures": [
|
| 4 |
+
"ElectraForSequenceClassification"
|
| 5 |
+
],
|
| 6 |
+
"attention_probs_dropout_prob": 0.1,
|
| 7 |
+
"bos_token_id": null,
|
| 8 |
+
"classifier_dropout": null,
|
| 9 |
+
"dtype": "float32",
|
| 10 |
+
"embedding_size": 768,
|
| 11 |
+
"eos_token_id": null,
|
| 12 |
+
"hidden_act": "gelu",
|
| 13 |
+
"hidden_dropout_prob": 0.1,
|
| 14 |
+
"hidden_size": 768,
|
| 15 |
+
"initializer_range": 0.02,
|
| 16 |
+
"intermediate_size": 3072,
|
| 17 |
+
"is_decoder": false,
|
| 18 |
+
"layer_norm_eps": 1e-12,
|
| 19 |
+
"max_position_embeddings": 512,
|
| 20 |
+
"model_type": "electra",
|
| 21 |
+
"num_attention_heads": 12,
|
| 22 |
+
"num_hidden_layers": 12,
|
| 23 |
+
"pad_token_id": 0,
|
| 24 |
+
"problem_type": "single_label_classification",
|
| 25 |
+
"summary_activation": "gelu",
|
| 26 |
+
"summary_last_dropout": 0.1,
|
| 27 |
+
"summary_type": "first",
|
| 28 |
+
"summary_use_proj": true,
|
| 29 |
+
"tie_word_embeddings": true,
|
| 30 |
+
"transformers_version": "5.0.0",
|
| 31 |
+
"type_vocab_size": 2,
|
| 32 |
+
"use_cache": false,
|
| 33 |
+
"vocab_size": 35000
|
| 34 |
+
}
|
model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:4a6cb54f351cc433a128ab4681c3e7791419240270ca70c50e224380d12d5adc
|
| 3 |
+
size 451715648
|
training_args.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:57aa1363571a8c4583f81faf15841d101a59c826b93b2ce54ba0e1f918887b1d
|
| 3 |
+
size 5201
|