Back to search

University of British Columbia

Structured representations for inspectable AI : knowledge graphs and latent trees

Abstract

dc:description

This thesis investigates whether forcing models through structured representations improves performance while providing inspectable intermediate states, through two case studies: knowledge graphs for bug triage and tree-structured reasoning for mathematical problem solving. GitHub issues are converted to typed knowledge graphs by extracting relations from the issue using REBEL-LARGE for relation extraction, and using BERT embeddings to represent entities in the graph. A human assessment of the quality of the resulting graphs has shown that 48% have limited detail; specifically, they do not capture implicit developer consensus, or the content of multi-turn arguments. While there is an apparent gap in this regard, we find that using features based on the graph structure to train classifiers results in a higher macro F1 score (0.4762 vs. 0.3564) than when training using only the text-based baseline. The structured format of the knowledge graph allows maintainers to review what drives their triage decisions, however, it remains unclear if this will result in better human comprehension. Dynamic Compute Tree Modeling (DCTM) injects 32 parallel latent nodes at layer six of GPT-2, learning tree structure through Gumbel-annealed parent prediction. Operation-conditioned adapters prove essential, achieving a 20.7% validation loss over the baseline on mixed reasoning tasks. Mid-layer injection works best, consistent with findings that middle layers contain abstract task-agnostic representations. Systematic generalization experiments show 12-20 point improvements on out-of-distribution tests, though 32-node capacity constrains performance on complex problems. Analysis of learned structures reveals moderate operation alignment (55-65%), with trees providing coarse-grained inspection points through structural consistency metrics. These findings indicate that even imperfect structured representations can outperform unstructured approaches in certain contexts. Graphs with 48% coverage gaps improved classification by 33.6%, and tree structures with partial operation alignment maintained advantages on out-of-distribution tests. This work establishes design principles for structured interventions, including mid-layer composition, sparsity priors, and task-appropriate representation choice, offering pathways toward AI systems that expose their intermediate computations for human inspection.

Degree

thesis:*
Name thesis:degree_name
Master of Science - MSc
Level thesis:degree_level
master's
Discipline thesis:degree_discipline
Computer Science
Grantor dc:publisher
University of British Columbia
Year dc:date
2026

Author and committee

dc:creator, dc:contributor.*
Author dc:creator
  • Thoma, Ethan
Contributors dc:contributor
  • Rodríguez-Pérez, Gema

Rights

dc:rights
Statement dc:rights
  • Attribution-NonCommercial-NoDerivatives 4.0 International
Language dc:language
eng

Identifiers

dc:identifier.*
Handle dc:identifier
http://hdl.handle.net/2429/93547

Chain of custody

source
Harvested from
University of British Columbia
Base URL
circle.library.ubc.ca/oai/request
Last updated
2026-11-19
Source record
OAI-PMH GetRecord
related terms
citation

Thoma, Ethan. Structured representations for inspectable AI : knowledge graphs and latent trees. master's thesis, University of British Columbia, 2026. http://hdl.handle.net/2429/93547