I am generally interested in mathematical structures in computer science, specifically, the so-called ‘theory B’ of theoretical computer science.
My work so far spans dependently typed programming, programming languages, logic, and automata theory, employing logical and categorical methods.
Recently, I have been exploring the computational and logical aspects of type theory, particularly through the lens of Curry-Howard correspondence.
I have worked on both the theory and practice of programming languages using Agda, a proof assistant and a dependently typed language.
This approach allows me to produce reliable, reproducible, and sometimes useful results.
🎤 Invited Talk
From Datatype-Generic Programming to Language-Generic Programming
Workshop on Type-Driven Development (TyDe 2025), Singapore, Singapore, 2025
From Datatype Genericity to Language Genericity WG6 Meeting of European Research Network on Formal Proofs, Leuven, Belgium, 2024
Foundations of Mathematics, Topoi, and Functional Programming Languages
Math Club, Department of Mathematics, National Taiwan University, Taiwan, 2023
💰 Funding
2025–2027, Principal investigator, Theory, Applications, and Implementation of Inductive Types, funded by NSTC (114-2222-E-001-001-MY3, TWD$2,181,000)
2020–2023, Unnamed, Type-theoretic foundations for metaprogramming, funded by NSTC (109-2222-E-001-002-MY3, TWD$2,851,000, PI: Hsiang-Shang Ko)
🏅 Award
EATCS Best Paper Award at the 42nd International Symposium on Mathematical Foundations of Computer Science, 2017
PhD Studentship from the UK EPSRC Project Coalgebraic Logic—Extending the Scope, 2009
I have funding available to hire self-motivated research assistants to join me at Academia Sinica.
If you are interested in the research topics of my recent work, please feel free to drop me an email with a brief statement and your résumé to initiate a conversation.
For Chinese applicants, please note that only short-term student visits can be accommodated due to the current geopolitical circumstances.
Can we formalise type theory intrinsically without any compromise? A case study in Cubical Agda
Chen, Liang-Ting, Nordvall Forsberg, Fredrik, and Tsai, Tzu-Chun
We present an intrinsic representation of type theory in the proof assistant Cubical Agda, inspired by Awodey’s natural models of type theory. The initial natural model is defined as quotient inductive-inductive-recursive types, leading us to a syntax accepted by Cubical Agda without using any transports, postulates, or custom rewrite rules. We formalise some meta-properties such as the standard model, normalisation by evaluation for typed terms, and strictification constructions. Since our formalisation is carried out using Cubical Agda's native support for quotient inductive types, all our constructions compute at a reasonable speed. When we try to develop more sophisticated metatheory, however, the 'transport hell' problem reappears. Ultimately, it remains a considerable struggle to develop the metatheory of type theory using an intrinsic representation that lacks strict equations. The effort required is about the same whether or not the notion of natural model is used.
15th ACM SIGPLAN International Conference on Certified Programs and Proofs (CPP), 2026
There has been much progress in designing bidirectional type systems and associated type synthesis algorithms, but mainly on a case-by-case basis. To remedy the situation, this paper develops a general and formal theory of bidirectional typing for simply typed languages: for every signature that specifies a mode-correct bidirectionally typed language, there exists a proof-relevant type synthesiser which, given an input abstract syntax tree, constructs a typing derivation if any, gives its refutation if not, or reports that the input does not have enough type annotations. Sufficient conditions for deriving a type synthesiser such as soundness, completeness, and mode-correctness are studied universally for all signatures. We propose a preprocessing step called mode decoration, which helps the user to deal with missing type annotations. The entire theory is formally implemented in Agda, so we provide a verified generator of proof-relevant type synthesisers as a by-product of our formalism.
33rd European Symposium on Programming (ESOP), 2024
Ko, Hsiang-Shang, Chen, Liang-Ting, and Lin, Tzu-Chi
Datatype-generic programming is natural and useful in dependently typed languages such as Agda. However, datatype-generic libraries in Agda are not reused as much as they should be, because traditionally they work only on datatypes decoded from a library’s own version of datatype descriptions; this means that different generic libraries cannot be used together, and they do not work on native datatypes, which are preferred by the practical Agda programmer for better language support and access to other libraries. Based on elaborator reflection, we present a framework in Agda featuring a set of general metaprograms for instantiating datatype-generic programs as, and for, a useful range of native datatypes and functions — including universe-polymorphic ones — in programmer-friendly and customisable forms. We expect that datatype-generic libraries built with our framework will be more attractive to the practical Agda programmer. As the elaborator reflection features used by our framework become more widespread, our design can be ported to other languages too.
27th ACM SIGPLAN International Conference on Functional Programming (ICFP), 2022