{"id":21887782,"url":"https://github.com/arjuntheprogrammer/finetune-flan-t5-text-classification","last_synced_at":"2026-05-19T03:44:31.753Z","repository":{"id":244153869,"uuid":"814263208","full_name":"arjuntheprogrammer/finetune-flan-t5-text-classification","owner":"arjuntheprogrammer","description":"Finetune Flan-t5 for Text Classification","archived":false,"fork":false,"pushed_at":"2024-06-13T02:37:29.000Z","size":260,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-26T20:29:22.166Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/arjuntheprogrammer.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-06-12T16:50:28.000Z","updated_at":"2024-12-03T12:00:56.000Z","dependencies_parsed_at":"2024-06-13T06:28:58.304Z","dependency_job_id":null,"html_url":"https://github.com/arjuntheprogrammer/finetune-flan-t5-text-classification","commit_stats":null,"previous_names":["arjuntheprogrammer/finetune-flan-t5-text-classification"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arjuntheprogrammer%2Ffinetune-flan-t5-text-classification","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arjuntheprogrammer%2Ffinetune-flan-t5-text-classification/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arjuntheprogrammer%2Ffinetune-flan-t5-text-classification/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arjuntheprogrammer%2Ffinetune-flan-t5-text-classification/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/arjuntheprogrammer","download_url":"https://codeload.github.com/arjuntheprogrammer/finetune-flan-t5-text-classification/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244895088,"owners_count":20527833,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-28T11:12:30.738Z","updated_at":"2026-05-19T03:44:26.714Z","avatar_url":"https://github.com/arjuntheprogrammer.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# FLAN-T5-BASE IMDB TEXT-CLASSIFICATION\n\nThis model is a fine-tuned version of [google/flan-t5-base](https://huggingface.co/google/flan-t5-base) on the [IMDB](https://huggingface.co/datasets/imdb) dataset.\n\n![flan-t5](https://github.com/philschmid/deep-learning-pytorch-huggingface/blob/main/assets/flan-t5.png?raw=1)\n\n## Model description\n\nIn this implementation, using the **Flan T5 large language model**, we performed the Text Classification task on the IMDB dataset and obtained a very good **accuracy of 93%**.\n\n\n## Training and evaluation data\n\nThis model was trained on the imdb train dataset with 25,000 data and then tested and evaluated on the imdb test dataset with 25,000 data.\n\nIt achieves the following results on the evaluation set:\n\n- Loss: 0.0786\n- F1: 94.9518\n- Gen Len: 2.4939\n\n\nOutput\n\n```cmd\n               precision    recall  f1-score   support\n\n           0       0.97      0.72      0.83     12500\n           1       0.78      0.98      0.87     12500\n\n    accuracy                           0.85     25000\n   macro avg       0.87      0.85      0.85     25000\nweighted avg       0.87      0.85      0.85     25000\n\n```\n\n---\n\n## Training procedure\n\n### TRAINING LOGS\n\nTraining Time: 26 minutes\n\nGPU Memory: 11500 MiB\n\n![alt text](image.png)\n\n### Training hyperparameters\n\nThe following hyperparameters were used during training:\n\n- learning_rate: 0.0003\n- train_batch_size: 8\n- eval_batch_size: 8\n- seed: 42\n- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08\n- lr_scheduler_type: linear\n- num_epochs: 2\n\n### Training results\n\n| Training Loss | Epoch | Step |\n|:-------------:|:-----:|:----:|\n| 0.099900      | 1.0   | 3125 |\n| 0.044300      | 2.0   | 6250 |\n\n\n### Framework versions\n\n- Transformers 4.28.1\n- Pytorch 2.0.0+cu118\n- Datasets 2.12.0\n- Tokenizers 0.13.3\n\n---\n\n### UPLOADED FINETUNED MODEL ON HF\n\n\u003chttps://huggingface.co/arjuntheprogrammer/flan-t5-base-imdb-text-classification\u003e\n\n---\n\n## YT RECORDING\n\n[![Flan T5 BASE Finetuning](https://img.youtube.com/vi/Bt00OthyE4U/0.jpg)](https://youtu.be/Bt00OthyE4U)\n\n---\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Farjuntheprogrammer%2Ffinetune-flan-t5-text-classification","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Farjuntheprogrammer%2Ffinetune-flan-t5-text-classification","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Farjuntheprogrammer%2Ffinetune-flan-t5-text-classification/lists"}