Declarative Pearl: Rigged Contracts

被引:0
|
作者
Vandenbroucke, Alexander [1 ]
Schrijvers, Tom [1 ]
机构
[1] Katholieke Univ Leuven, Leuven, Belgium
来源
FUNCTIONAL AND LOGIC PROGRAMMING, FLOPS 2024 | 2024年 / 14659卷
关键词
semiring; financial contract; domain-specific language;
D O I
10.1007/978-981-97-2300-3_6
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Over 20 years ago, Peyton Jones et al. embarked on an adventure in financial engineering with their functional pearl on "Composing Contracts". They introduced a combinator library-a domain-specific language-for precisely describing complex financial contracts and a formal denotational semantics for computing their value, for which they briefly sketched an implementation. This paper reworks the design of their library to make the central datatype of contracts less ad-hoc by giving it a well-understood algebraic structure: the semiring. Then, interpreting a contract's worth as a generic semiring homomorphism directly gives rise to a natural semantics for contracts, of which computing the (monetary) value is but one instance.
引用
收藏
页码:99 / 114
页数:16
相关论文
共 22 条
  • [21] Contract text markup language: A regularization method for extracting legal elements towards smart contracts
    Fan Y.
    Wang D.
    Lin H.
    Chen E.
    He X.
    Zhu Y.
    Gongcheng Kexue Xuebao/Chinese Journal of Engineering, 2024, 46 (01): : 109 - 119
  • [22] A THEORETICAL ANALYSIS IN CHOOSING BETWEEN PROFIT-LOSS SHARING AND INTEREST-BASED CONTRACTS: A SIMPLE GAME MODEL
    Gholami, Reza
    Abdul-Rahman, Aisyah
    Said, Fathin Faizah
    Nor, Nor Ghani Md
    ISRA INTERNATIONAL JOURNAL OF ISLAMIC FINANCE, 2023, 15 (03) : 115 - 141