Skip to content

jmg764/Personality-Type-Prediction-Using-Multi-Label-Classification

Repository files navigation

Personality Type Prediction Using Multi-Label Classification

Code can be found in this notebook.

Background

Carl Jung, founder of the field of analytical psychology, formulated a personality theory aiming to categorize people based on how they process information. He identified two types of cognitive functions: two perception functions known as sensation and intuition, and two judgement functions known as thinking and feeling. The functions within each pair are considered to be opposites of each other.

drawing

Additionally, these four functions operate in conjunction with either an introverted or extroverted attitude. This results in eight functional variations, or personality types: extroverted sensing (Se), introverted sensing (Si), extroverted intuition (Ne), introverted intuition (Ni), extroverted feeling (Fe), introverted feeling (Fi), extroverted thinking (Te), and introverted thinking (Ti).

All four cognitive functions are used at different times depending on the circumstances. However, one of the four functions tend to be used more frequently than the other three in a more conscious and confident way. This dominant function is supported by two auxiliary functions. The dominant and first auxiliary are referred to as the two primary cognitive functions, and are of different cognitive function type: for example, if the dominant function is a judging type, then the first auxillary will be a perceiving type and vice versa. The fourth and least conscious function, often referred to as the inferior function, is always the opposite of the dominant function in terms of cognitive function and attitude. For example, an extroverted thinking dominant function would be balanced by an introverted feeling inferior function. Jung theorized that the dominant function characterizes conscious behavior, while the inferior function is repressed and characterizes unconscious behavior.

Jung's personality theory formed the basis of the Myers-Briggs Type Indicator (MBTI) which is a widely used method of self-categorization of personality type through an introspective questionnaire. The relationships between MBTI type and Jungian cognitive functions are shown below. Primary cognitive functions are highlighted in green.

drawing

Objective

The objective is to develop a machine learning model which can can accurately predict a person's two primary cognitive functions based off of what they have written. In doing so, the following multi-label classification techniques are implemented and compared:

  1. Problem transformation, algorithm adaptation, and ensemble approaches
    1. Problem transformation approaches
      • Binary relevance
      • Classifier chain
      • Label powerset
    2. Algorithm adaptation approaches
      • Multi-label k-nearest neighbors (MLkNN)
      • Multi-label hierarchical ARAM neural network (MLARAM)
    3. Ensembles of classifiers
      • Random label space partitioning with label powerset (RAkELd)
  2. Neural networks using Keras
    • Long short-term memory networks (LSTM)
    • 1D convolutional neural networks (CNN)
  3. Bidirectional Encoder Representations from Transformers (BERT)

The dataset used contains a large selection of people's MBTI personality types and text they have written on a forum called Personality Cafe: a community dedicated to discussion about personality types.

About

Explores personality type prediction using several scikit-multilearn multi-label classifiers, LSTM, CNN, and BERT.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •