English

Alice or Bob?: Process Polymorphism in Choreographies

Programming Languages 2023-03-09 v1

Abstract

We present PolyChorλ\lambda, a language for higher-order functional \emph{choreographic programming} -- an emerging paradigm by which programmers write the desired cooperative behaviour of a system of communicating processes and then compile it into distributed implementations for each process, a translation called \emph{endpoint projection}. Unlike its predecessor, Chorλ\lambda, PolyChorλ\lambda has both type and \emph{process} polymorphism inspired by System Fω_\omega. That is, PolyChorλ\lambda is the first (higher-order) functional choreographic language which gives programmers the ability to write generic choreographies and determine the participants at runtime. This novel combination of features also allows PolyChorλ\lambda processes to communicate \emph{distributed values}, leading to a new and intuitive way to write delegation. While some of the functional features of PolyChorλ\lambda give it a weaker correspondence between the semantics of choreographies and their endpoint-projected concurrent systems than some other choreographic languages, we still get the hallmark end result of choreographic programming: projected programs are deadlock-free by design.

Keywords

Cite

@article{arxiv.2303.04678,
  title  = {Alice or Bob?: Process Polymorphism in Choreographies},
  author = {Eva Graversen and Andrew K. Hirsch and Fabrizio Montesi},
  journal= {arXiv preprint arXiv:2303.04678},
  year   = {2023}
}

Comments

In submission to JFP

R2 v1 2026-06-28T09:07:41.462Z