How to Leverage Digit Embeddings to Represent Numbers?

Fuente: arXiv
Salvato in:
Dettagli Bibliografici
Autori principali: Sivakumar, Jasivan Alex, Moosavi, Nafise Sadat
Natura: Preprint
Pubblicazione: 2024
Soggetti:
Accesso online:
Tags: Aggiungi Tag
Nessun Tag, puoi essere il primo ad aggiungerne!!
_version_ 1866929623465459712
author Sivakumar, Jasivan Alex
Moosavi, Nafise Sadat
author_facet Sivakumar, Jasivan Alex
Moosavi, Nafise Sadat
contents Within numerical reasoning, understanding numbers themselves is still a challenge for existing language models. Simple generalisations, such as solving 100+200 instead of 1+2, can substantially affect model performance (Sivakumar and Moosavi, 2023). Among various techniques, character-level embeddings of numbers have emerged as a promising approach to improve number representation. However, this method has limitations as it leaves the task of aggregating digit representations to the model, which lacks direct supervision for this process. In this paper, we explore the use of mathematical priors to compute aggregated digit embeddings and explicitly incorporate these aggregates into transformer models. This can be achieved either by adding a special token to the input embeddings or by introducing an additional loss function to enhance correct predictions. We evaluate the effectiveness of incorporating this explicit aggregation, analysing its strengths and shortcomings, and discuss future directions to better benefit from this approach. Our methods, while simple, are compatible with any pretrained model, easy to implement, and have been made publicly available.
format Preprint
id arxiv_https___arxiv_org_abs_2407_00894
institution arXiv
publishDate 2024
record_format arxiv
spellingShingle How to Leverage Digit Embeddings to Represent Numbers?
Sivakumar, Jasivan Alex
Moosavi, Nafise Sadat
Computation and Language
Within numerical reasoning, understanding numbers themselves is still a challenge for existing language models. Simple generalisations, such as solving 100+200 instead of 1+2, can substantially affect model performance (Sivakumar and Moosavi, 2023). Among various techniques, character-level embeddings of numbers have emerged as a promising approach to improve number representation. However, this method has limitations as it leaves the task of aggregating digit representations to the model, which lacks direct supervision for this process. In this paper, we explore the use of mathematical priors to compute aggregated digit embeddings and explicitly incorporate these aggregates into transformer models. This can be achieved either by adding a special token to the input embeddings or by introducing an additional loss function to enhance correct predictions. We evaluate the effectiveness of incorporating this explicit aggregation, analysing its strengths and shortcomings, and discuss future directions to better benefit from this approach. Our methods, while simple, are compatible with any pretrained model, easy to implement, and have been made publicly available.
title How to Leverage Digit Embeddings to Represent Numbers?
topic Computation and Language
url https://arxiv.org/abs/2407.00894