Classification of Purchase Invoices to Analytic Accounts with Machine Learning

Loading...
Thumbnail Image

URL

Journal Title

Journal ISSN

Volume Title

Sähkötekniikan korkeakoulu | Master's thesis

Date

2023-01-23

Department

Major/Subject

Control, Robotics and Autonomous Systems

Mcode

ELEC3025

Degree programme

AEE - Master’s Programme in Automation and Electrical Engineering (TS2013)

Language

en

Pages

47

Series

Abstract

The process of analytic account selection for invoices is time-consuming and expensive. These problems can be diminished with an automated system for selecting the analytic accounts on the invoices. The aim of this thesis is to implement a software system for classifying purchase invoice accounting lines into analytic account in Odoo ERP system. The proposed software uses machine learning methodology as analytic account selection is essentially a multi-class text classification problem. The proposed accuracy goal set is 90% as it is an indicated threshold in a related invoice account selection problem. The thesis investigates the current text classification algorithms and compares them empirically with each other. The selected algorithms are Multinomial Naive Bayes, Logistic Regression, Linear and Non-linear Support Vector Machines (SVM), k-Nearest Neighbor, Decision Tree, Random Forest, Perceptron and Multilayer Perceptrons (MLP). Additionally a primitive Odoo module is created to use this software system in an Odoo server for automatic analytic account selection. The features of the data contain textual descriptions of an invoice line which require the text data preprocessing before transferred into the models. The results indicate the best performing models are Logistic Regression, linear SVM and MLP where the linear SVM is the most effective overall. This model is optimized even further where a test instance reached an accuracy of 88% at best. However empirically the macro averages (precision, recall and F1-score) for an average instance is around 0.80. The thesis presents a functional Odoo module where the training and prediction of analytic accounts can be done within an Odoo server. The Odoo user interface allows to train a model, show the scores of different classes and predict analytic accounts for lines.

Analyyttisten tilien valinta laskuille on aikaa vievää sekä kallista. Näitä ongelmia voidaan vähentää automaattisella laskujen analyyttisten tilien valintajärjestelmällä. Tämän diplomityö pyrkii implementoimaan tietokoneohjelman ostolaskujen kirjanpitorivien analyyttisten tilien luokittelemiseen Odoo tuotannonohjausjärjestelmässä. Ehdotettu ohjelmisto käyttää koneoppimetodologiaa, sillä tilien valinta on ensisijaisesti moniluokka tekstinluokitteluongelma. Ehdotettu täsmällisyystavoite on 90 %, sillä se on raja-arvo vastaavanlaisessa tilinvalinta ongelmassa. Tämä diplomityö tutkii nykyisiä tekstinluokittelu algoritmeja ja vertailee niitä empiirisesti toisiinsa. Valitut algoritmit ovat Naiivi Bayes, Logistinen Regressio, Lineaarinen ja Epälineaarinen Tukivektorikone, kNN, Päätöspuu, Satunnainen Metsä, Perseptroni sekä Monikerroksinen Perseptroni. Lisäksi luodaan alkeellinen Odoo moduuli, jossa tätä järjestelmää voidaan käyttää Odoo serverillä automaattiseen analyyttisen tilin valintaan. Data sisältää kirjallista kuvausta kirjanpitoriveillä, jonka takia järjestelmä vaatii tekstin esikäsittelyä ennen siirtoa malleihin. Tulokset viittaavat, että parhaiten toimivat mallit ovat Logistinen Regressio, Lineaarinen Tukivektorikone sekä Monikerroksinen Perseptroni, jossa Lineaarinen Tukivektorikone on kaikista tehokkain. Tämä malli optimoidaan edelleen, jonka johdosta testi-instanssi saavutti 88 % täsmällisyys parhaimmillaan. Kuitenkin empiirisesti nämä makrokeskiarvot (tarkkuus, herkkyys ja F1-pisteet) ovat keskimäärin noin 0,80. Diplomityö esittää toimivan Odoo moduulin, jossa analyyttisten tilien kouluttaminen ja ennustaminen voidaan tehdä Odoo serverillä. Odoo käyttöliittymä mahdollistaa mallin koulutuksen, testitulosten näyttämisen eri luokille sekä analyyttisten tilien ennustamisen kirjanpitoriveille.

Description

Supervisor

Jung, Alexander

Thesis advisor

Heino, Petri

Keywords

purchase invoice, analytic account, software automation, machine learning, odoo, support vector machine

Other note

Citation