In Norway, where psychological disorders cause roughly 20% of all sick leave and cost the nation billions, this work is especially critical. The core challenge this master's project addresses is the slow, subjective process clinicians face when analyzing patient-generated text for diagnostic clues. To address this, the project aims to develop a local-only, privacy-preserving AI helper. This tool scans the patient's Timeline, highlights clinically relevant phrases, and proposes a ranked list of likely diagnostic codes with simple explanations the therapist can use or disregard. Because no information leaves the hospital's secure network, sensitive patient stories remain completely private. The result is a fast, consistent tool that nudges therapists toward the right clinical questions, potentially shortening assessment times for the very people who wait the longest for specialist care.
Objective and Methodology
The goal of this master thesis is to design, train, and package a natural language model that reads a patient's Timeline, extracts symptom and duration phrases, ranks up to five likely ICD-10 codes, and justifies each suggestion in a short sentence. This project, which is a close collaboration with the Mental Health & Addiction division at Oslo University Hospital, will be built using the Norwegian large language model, NorBERT4 (https://huggingface.co/ltg/norbert4-base).
The project first step will focus on a literature review covering three key areas: adapting language models for clinical text, automatically coding mental health records to ICD-10, and explainable AI techniques. Insights from this review will guide the subsequent technical work. A research corpus will then be generated by using a large language model's API to create synthetic patient timelines. To ensure clinical realism, these generated texts will be reviewed, validated, and assigned a likely ICD-10 diagnosis by clinicians. This synthetic, privacy-preserving, dataset will then be used to fine-tune the diagnostic model.
Model development will focus on fine-tuning NorBERT4, in a supervised phase to map symptom phrases to diagnostic codes. For transparency, a lightweight explanation module will leverage the model’s internal attention patterns to highlight the text passages responsible for each suggestion. Training progress will be monitored using standard accuracy and F-score metrics, with early-stopping employed to prevent overfitting.
Expected Outcomes
By the end of the master, a self-contained decision-support prototype that turns a patient’s Timeline into ranked, explainable diagnostic cues that can run locally (no cloud upload for data-privacy concerns). The real goal here is to make therapy sessions more focused. Instead of the clinician spending valuable time sorting through notes, the tool handles that initial analysis. This creates more efficient and consistent evaluations, accelerating the delivery of appropriate care to vulnerable patients facing long waits.
[1] World Health Organization. (2022, June 8). Mental disorders. https://www.who.int/news-room/fact-sheets/detail/mental-disorders