# Fine tuning multi\[class\] classification

**URL:** </static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Ffine-tuning-multi-class-classification%2F89664%3E%5C
**Category:** Beginners\
**Created:** [May 31, 2024, 9:11pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Ffine-tuning-multi-class-classification%2F89664 "2024-05-31T21:11:38Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Abasov](https://avatars.discourse-cdn.com/v4/letter/a/35a633/32.png) [@Abasov](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2FAbasov)%5C
**Post date:** [May 31, 2024, 9:11pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Ffine-tuning-multi-class-classification%2F89664%2F1 "2024-05-31T21:11:38Z")

</div>

Hello everyone,  
I would like to fine tune a LLM model for country code or country name classification.  
example: I live in England  
answer: GB or Great Britain

Labels will be all county code in the world.

Any advice ? which LLM can I take for this task ?

---

<div class="post-metadata">

**Author:** ![nielsr](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/nielsr/32/39617_2.png) [@nielsr](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2Fnielsr)%5C
**Post date:** [June 1, 2024, 10:19am UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Ffine-tuning-multi-class-classification%2F89664%2F2 "2024-06-01T10:19:57Z")

</div>

Hi,

An LLM might be a bit of an overkill for this task, you might get good results by fine-tuning a BERT-like text classifier. Also, if a sentence can only belong to one class, the task is actually called multi-class classification instead of multi-label.

See the task guide: [Text classification](https://huggingface.co/docs/transformers/tasks/sequence_classification)

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/hellohellohello/original/2X/d/de4155eb4aa4108ecb32a1389d7cc37ae69f88b7.png) [@system](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2Fsystem)%5C
**Post date:** [June 1, 2024, 10:20pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Ffine-tuning-multi-class-classification%2F89664%2F3 "2024-06-01T22:20:49Z")

</div>

Closed on June 1, 2024, 10:20pm UTC

This topic was automatically closed 12 hours after the last reply. New replies are no longer allowed.
