AI-assisted research, methods, software and teaching

Peter Sørensen

Center for Quantitative Genetics and Genomics, Aarhus University

What is AI?

Term Meaning
Artificial intelligence The broad field of building systems that perform tasks associated with human intelligence
Machine learning and deep learning Methods that learn patterns from data. Deep learning uses neural networks with many layers
Generative AI Models that generate text, code, images, audio or other content
AI assistants and agents Systems built around generative AI that can work with users, files and tools. Agents can carry out multistep tasks

This presentation focuses on AI assistants and agents used for data analysis, method and software development, and teaching.

How researchers use generative AI

Activity Examples
Writing and communication Draft, revise, translate and shorten text
Literature work Find relevant papers, summarise them and compare their conclusions
Data analysis Inspect data, write code, make figures and explain results
Teaching Develop slides, exercises, examples and explanations
Administration Prepare emails, meeting notes, plans and reports

Writing and literature review are common entry points. The same technology can also contribute directly to mathematical, analytical and software work.

Areas of AI-assisted work

Area Example output Reusable result
Data analysis An analysis script and report A reproducible analysis workflow
Method development A statistical model or algorithm A clearly defined method with validation evidence
Software development R and C++ code, interfaces and documentation Tested and maintainable software components
Teaching Slides, simulations and worked examples Editable teaching materials

AI can help with mathematical reasoning, coding, analysis and documentation. Researchers set the scientific direction, review the decisions and determine what evidence is sufficient.

Platforms developed with AI assistance

Platform Purpose
gsuite Statistical models, numerical computation and user interfaces
gsim Simulation of genetic data and assessment of methods
gact Data integration, annotation, analysis and interpretation
gteach Shared tools and materials for teaching

AI has contributed to developing the platforms themselves. The resulting infrastructure can now support further work with AI assistants.

From numerical algorithms to an analysis package

Layer Components in and around gsuite
Numerical computation Sparse solves and the inverse entries needed for model calculations
Native C++ and shared libraries Solver interfaces, reuse of calculations and diagnostics
Reusable model components Covariance models, estimation, prediction and computational tasks
R interface Model specification and results through gfit() and gvc()

The solver infrastructure uses established numerical libraries: CHOLMOD / SuiteSparse and PARDISO.

From a scientific question to a model

A scientific question leads to model specification and identification of required blocks. Available blocks are combined; missing blocks are developed and checked. The assembled model is validated before fitting, inspection and reporting.

Each extension can add capabilities that other models can reuse.

A shared collection of building blocks

REML and Bayesian analyses select model components, computational components and analysis tasks from a reusable collection, with AI assistance to identify, combine, implement and check.

Existing capabilities can be combined and extended to support new models and methods.

Developing gsuite with AI

Mathematics and design

  • Discuss the model and its assumptions
  • Derive the required computations
  • Compare algorithms and special cases
  • Decide what to implement or reuse

Implementation and review

  • Work directly with the R and C++ code
  • Compile and run focused checks
  • Inspect failures and revise the approach
  • Retain reviewed code and documentation

AI assistance connects statistical ideas with their implementation.

Checking the calculations

Check Concrete example from the work
Small reference calculations Compare the efficient selected inverse with dense and scalar references in C++
Computational behaviour Check factor reuse, thread agreement and retained solves
Independent software comparison Compare matched pedigree models with DMU on 50,000 animals
User workflow Fit models through R and inspect summaries, predictions and diagnostics

In the saved DMU comparison, covariance estimates differed by less than \(4.3\times10^{-8}\).

Historical comparison: gsuite 0.29.0 and DMU 5.6; three frozen pedigree models. Results and scope

gsuite versus DMU: agreement and runtime

Single trait: gsuite 80.9 seconds and DMU 178.4. Multitrait: 105.6 and 818.5. Longitudinal: 386.9 and 1182.7.

Numerical agreement

50,000 animals

Maximum covariance-estimate difference below \(4.3\times10^{-8}\).

Prediction correlations essentially 1 on 1,000 preselected animals.

Competitive runtime on these three tested models.

gsuite 0.29.0 and DMU 5.6. Each bar represents one execution. The work boundaries differ: gsuite fitting versus DMU preprocessing and fitting.

A pedigree analysis as a conversation

How much genetic variation is present in body weight, and how accurately can breeding values be predicted?

Work through the analysis

  1. Check pedigree, observations and missing values
  2. Discuss fixed effects and genetic effects
  3. Fit the model and check convergence
  4. Inspect estimates and predictions
  5. Save the R script, figures and report

Keep the model explicit

fit <- gfit(
  formula = BW ~ sex + cohort + herd + (1 | id),
  data = data,
  pedigree = pedigree,
  task = "reml",
  control = fit_control
)
summary(fit)

Ordinary R data frames; a model that can be reviewed and rerun.

A concrete case: GWAS summary statistics

The question: can existing building blocks support a family of methods for heritability and genetic correlation?

Analysis Implemented method families
Genome-wide and annotation-based LDSC, GNOVA, SumHer
Regional HESS/rho-HESS, SUPERGNOVA, LAVA
Conditional relationships LAVA regression and partial genetic correlations

Native calculations in gcorr, reusable LD resources in gmat, numerical components in gsolve, and a common gsuite R interface.

The outcome includes working examples, diagnostics and documented limits.

How the researcher and assistant worked

Step Researcher Assistant
Define the next capability Set the scientific question and scope Inspect equations and existing components
Implement and check Review assumptions and challenge results Write native code; compare small numerical oracles
Connect and evaluate Decide what is supported and what needs investigation Add the R interface, examples and simulations

Short, reviewed steps: specify → implement → test → discuss → commit.

The checks included independent calculations, selected upstream comparisons, R/native agreement and simulated data with known truth.

What the development record shows

Date in 2026 Recorded work
21 August Initial native LDSC core already in place
11 September LDSC extensions and reference comparisons
12–13 September Additional method families, multivariate extensions and evaluations
14 September LDlist, R interfaces, aligned results and the simulation tutorial

Latest package tests: 2,264 checks passed.

20 simulated datasets: about 5.4 minutes, including data generation, LD preparation and fitting.

Calendar dates describe recorded development; human hours and time saved were not measured.

How much assistant time did this take?

Saved task records from 11–14 September 2026:

Work Recorded time
Native methods, discussion and evaluations 10 h 24 min
LD reference resources, R interfaces and package checks 4 h
Simulation examples, website updates and slides 35 min
Total assistant task time About 15 hours

From method development to a shared R interface and worked examples, using existing computational building blocks.

The simulations also reveal differences

Across 20 datasets, LDSC and SumHer have similar heritability errors, GNOVA has greater variability, and SUPERGNOVA has downward mean regional covariance errors relative to HESS and LAVA.

All 1,380 expected point estimates were available. The SUPERGNOVA shift gives a specific result to investigate.

What could become a research contribution?

Status Concrete example
Reusable infrastructure, implemented Shared LD resources, named covariance results and common numerical components
Native extension, implemented Annotation-specific genetic regression and partial correlations from GNOVA covariance estimates
Research question to evaluate Do conditional genetic relationships differ between annotations?

Existing methods can become building blocks for new questions.

Statistical novelty still needs a literature comparison and evidence. Shared code alone is not a new statistical method.

Where is AI taking research?

What is likely to change

  • Writing, coding and analysis will become faster
  • More groups will develop advanced methods and software
  • AI assistants will perform increasingly complex tasks
  • Research roles and expectations will change

Questions for the programme

  • Which expertise and resources will distinguish the programme?
  • How can AI be combined with the available data and infrastructure?
  • Which capabilities should be developed and shared?
  • How should training, review and responsibility change?

What needs to change now for the programme to remain scientifically distinctive as AI becomes part of research?