How to make ad hoc proof automation less ad hoc
Most interactive theorem provers provide support for some form of user-customizable proof automation. In a number of popular systems, such as Coq and Isabelle, this automation is achieved primarily through tactics , which are programmed in a separate language from that of the prover's base logi...
Gespeichert in:
Veröffentlicht in: | SIGPLAN notices 2011-09, Vol.46 (9), p.163-175 |
---|---|
Hauptverfasser: | , , , |
Format: | Artikel |
Sprache: | eng |
Online-Zugang: | Volltext |
Tags: |
Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
|
container_end_page | 175 |
---|---|
container_issue | 9 |
container_start_page | 163 |
container_title | SIGPLAN notices |
container_volume | 46 |
creator | Gonthier, Georges Ziliani, Beta Nanevski, Aleksandar Dreyer, Derek |
description | Most interactive theorem provers provide support for some form of user-customizable proof automation. In a number of popular systems, such as Coq and Isabelle, this automation is achieved primarily through
tactics
, which are programmed in a separate language from that of the prover's base logic. While tactics are clearly useful in practice, they can be difficult to maintain and compose because, unlike lemmas, their behavior cannot be specified within the expressive type system of the prover itself.
We propose a novel approach to proof automation in Coq that allows the user to specify the behavior of custom automated routines in terms of Coq's own type system. Our approach involves a sophisticated application of Coq's
canonical structures
, which generalize Haskell type classes and facilitate a flexible style of dependently-typed logic programming. Specifically, just as Haskell type classes are used to infer the canonical implementation of an overloaded term at a given type, canonical structures can be used to infer the canonical
proof
of an overloaded
lemma
for a given instantiation of its parameters. We present a series of design patterns for canonical structure programming that enable one to carefully and predictably coax Coq's type inference engine into triggering the execution of user-supplied algorithms during unification, and we illustrate these patterns through several realistic examples drawn from Hoare Type Theory. We assume no prior knowledge of Coq and describe the relevant aspects of Coq type inference from first principles. |
doi_str_mv | 10.1145/2034574.2034798 |
format | Article |
fullrecord | <record><control><sourceid>crossref</sourceid><recordid>TN_cdi_crossref_primary_10_1145_2034574_2034798</recordid><sourceformat>XML</sourceformat><sourcesystem>PC</sourcesystem><sourcerecordid>10_1145_2034574_2034798</sourcerecordid><originalsourceid>FETCH-LOGICAL-c312t-617dd655c385979228135d6cdb5214571dd04c1839c4953d9783955dced714db3</originalsourceid><addsrcrecordid>eNotj8FKAzEURYMoOFbXbvMD03kvL2-SLKWoLRTc6HpIkxmsdkxJRsS_t8VZnQsXLvcIcY-wRNTcKCDNRi_PNM5eiAqZbY3YwqWogFpVI2m4FjelfAAAgbKVaNbpR05Jjv6zlz7K9xTkMac0SP89pdFP-_QlD30pc3krrgZ_KP3dzIV4e3p8Xa3r7cvzZvWwrQOhmuoWTYwtcyDLzjilLBLHNsQdq9NZgzGCDmjJBe2YojOnyBxDHw3quKOFaP53Q06l5H7ojnk_-vzbIXRn32727WZf-gMb3kUj</addsrcrecordid><sourcetype>Aggregation Database</sourcetype><iscdi>true</iscdi><recordtype>article</recordtype></control><display><type>article</type><title>How to make ad hoc proof automation less ad hoc</title><source>ACM Digital Library</source><creator>Gonthier, Georges ; Ziliani, Beta ; Nanevski, Aleksandar ; Dreyer, Derek</creator><creatorcontrib>Gonthier, Georges ; Ziliani, Beta ; Nanevski, Aleksandar ; Dreyer, Derek</creatorcontrib><description>Most interactive theorem provers provide support for some form of user-customizable proof automation. In a number of popular systems, such as Coq and Isabelle, this automation is achieved primarily through
tactics
, which are programmed in a separate language from that of the prover's base logic. While tactics are clearly useful in practice, they can be difficult to maintain and compose because, unlike lemmas, their behavior cannot be specified within the expressive type system of the prover itself.
We propose a novel approach to proof automation in Coq that allows the user to specify the behavior of custom automated routines in terms of Coq's own type system. Our approach involves a sophisticated application of Coq's
canonical structures
, which generalize Haskell type classes and facilitate a flexible style of dependently-typed logic programming. Specifically, just as Haskell type classes are used to infer the canonical implementation of an overloaded term at a given type, canonical structures can be used to infer the canonical
proof
of an overloaded
lemma
for a given instantiation of its parameters. We present a series of design patterns for canonical structure programming that enable one to carefully and predictably coax Coq's type inference engine into triggering the execution of user-supplied algorithms during unification, and we illustrate these patterns through several realistic examples drawn from Hoare Type Theory. We assume no prior knowledge of Coq and describe the relevant aspects of Coq type inference from first principles.</description><identifier>ISSN: 0362-1340</identifier><identifier>EISSN: 1558-1160</identifier><identifier>DOI: 10.1145/2034574.2034798</identifier><language>eng</language><ispartof>SIGPLAN notices, 2011-09, Vol.46 (9), p.163-175</ispartof><oa>free_for_read</oa><woscitedreferencessubscribed>false</woscitedreferencessubscribed><citedby>FETCH-LOGICAL-c312t-617dd655c385979228135d6cdb5214571dd04c1839c4953d9783955dced714db3</citedby><cites>FETCH-LOGICAL-c312t-617dd655c385979228135d6cdb5214571dd04c1839c4953d9783955dced714db3</cites></display><links><openurl>$$Topenurl_article</openurl><openurlfulltext>$$Topenurlfull_article</openurlfulltext><thumbnail>$$Tsyndetics_thumb_exl</thumbnail><link.rule.ids>314,780,784,27924,27925</link.rule.ids></links><search><creatorcontrib>Gonthier, Georges</creatorcontrib><creatorcontrib>Ziliani, Beta</creatorcontrib><creatorcontrib>Nanevski, Aleksandar</creatorcontrib><creatorcontrib>Dreyer, Derek</creatorcontrib><title>How to make ad hoc proof automation less ad hoc</title><title>SIGPLAN notices</title><description>Most interactive theorem provers provide support for some form of user-customizable proof automation. In a number of popular systems, such as Coq and Isabelle, this automation is achieved primarily through
tactics
, which are programmed in a separate language from that of the prover's base logic. While tactics are clearly useful in practice, they can be difficult to maintain and compose because, unlike lemmas, their behavior cannot be specified within the expressive type system of the prover itself.
We propose a novel approach to proof automation in Coq that allows the user to specify the behavior of custom automated routines in terms of Coq's own type system. Our approach involves a sophisticated application of Coq's
canonical structures
, which generalize Haskell type classes and facilitate a flexible style of dependently-typed logic programming. Specifically, just as Haskell type classes are used to infer the canonical implementation of an overloaded term at a given type, canonical structures can be used to infer the canonical
proof
of an overloaded
lemma
for a given instantiation of its parameters. We present a series of design patterns for canonical structure programming that enable one to carefully and predictably coax Coq's type inference engine into triggering the execution of user-supplied algorithms during unification, and we illustrate these patterns through several realistic examples drawn from Hoare Type Theory. We assume no prior knowledge of Coq and describe the relevant aspects of Coq type inference from first principles.</description><issn>0362-1340</issn><issn>1558-1160</issn><fulltext>true</fulltext><rsrctype>article</rsrctype><creationdate>2011</creationdate><recordtype>article</recordtype><recordid>eNotj8FKAzEURYMoOFbXbvMD03kvL2-SLKWoLRTc6HpIkxmsdkxJRsS_t8VZnQsXLvcIcY-wRNTcKCDNRi_PNM5eiAqZbY3YwqWogFpVI2m4FjelfAAAgbKVaNbpR05Jjv6zlz7K9xTkMac0SP89pdFP-_QlD30pc3krrgZ_KP3dzIV4e3p8Xa3r7cvzZvWwrQOhmuoWTYwtcyDLzjilLBLHNsQdq9NZgzGCDmjJBe2YojOnyBxDHw3quKOFaP53Q06l5H7ojnk_-vzbIXRn32727WZf-gMb3kUj</recordid><startdate>20110901</startdate><enddate>20110901</enddate><creator>Gonthier, Georges</creator><creator>Ziliani, Beta</creator><creator>Nanevski, Aleksandar</creator><creator>Dreyer, Derek</creator><scope>AAYXX</scope><scope>CITATION</scope></search><sort><creationdate>20110901</creationdate><title>How to make ad hoc proof automation less ad hoc</title><author>Gonthier, Georges ; Ziliani, Beta ; Nanevski, Aleksandar ; Dreyer, Derek</author></sort><facets><frbrtype>5</frbrtype><frbrgroupid>cdi_FETCH-LOGICAL-c312t-617dd655c385979228135d6cdb5214571dd04c1839c4953d9783955dced714db3</frbrgroupid><rsrctype>articles</rsrctype><prefilter>articles</prefilter><language>eng</language><creationdate>2011</creationdate><toplevel>online_resources</toplevel><creatorcontrib>Gonthier, Georges</creatorcontrib><creatorcontrib>Ziliani, Beta</creatorcontrib><creatorcontrib>Nanevski, Aleksandar</creatorcontrib><creatorcontrib>Dreyer, Derek</creatorcontrib><collection>CrossRef</collection><jtitle>SIGPLAN notices</jtitle></facets><delivery><delcategory>Remote Search Resource</delcategory><fulltext>fulltext</fulltext></delivery><addata><au>Gonthier, Georges</au><au>Ziliani, Beta</au><au>Nanevski, Aleksandar</au><au>Dreyer, Derek</au><format>journal</format><genre>article</genre><ristype>JOUR</ristype><atitle>How to make ad hoc proof automation less ad hoc</atitle><jtitle>SIGPLAN notices</jtitle><date>2011-09-01</date><risdate>2011</risdate><volume>46</volume><issue>9</issue><spage>163</spage><epage>175</epage><pages>163-175</pages><issn>0362-1340</issn><eissn>1558-1160</eissn><abstract>Most interactive theorem provers provide support for some form of user-customizable proof automation. In a number of popular systems, such as Coq and Isabelle, this automation is achieved primarily through
tactics
, which are programmed in a separate language from that of the prover's base logic. While tactics are clearly useful in practice, they can be difficult to maintain and compose because, unlike lemmas, their behavior cannot be specified within the expressive type system of the prover itself.
We propose a novel approach to proof automation in Coq that allows the user to specify the behavior of custom automated routines in terms of Coq's own type system. Our approach involves a sophisticated application of Coq's
canonical structures
, which generalize Haskell type classes and facilitate a flexible style of dependently-typed logic programming. Specifically, just as Haskell type classes are used to infer the canonical implementation of an overloaded term at a given type, canonical structures can be used to infer the canonical
proof
of an overloaded
lemma
for a given instantiation of its parameters. We present a series of design patterns for canonical structure programming that enable one to carefully and predictably coax Coq's type inference engine into triggering the execution of user-supplied algorithms during unification, and we illustrate these patterns through several realistic examples drawn from Hoare Type Theory. We assume no prior knowledge of Coq and describe the relevant aspects of Coq type inference from first principles.</abstract><doi>10.1145/2034574.2034798</doi><tpages>13</tpages><oa>free_for_read</oa></addata></record> |
fulltext | fulltext |
identifier | ISSN: 0362-1340 |
ispartof | SIGPLAN notices, 2011-09, Vol.46 (9), p.163-175 |
issn | 0362-1340 1558-1160 |
language | eng |
recordid | cdi_crossref_primary_10_1145_2034574_2034798 |
source | ACM Digital Library |
title | How to make ad hoc proof automation less ad hoc |
url | https://sfx.bib-bvb.de/sfx_tum?ctx_ver=Z39.88-2004&ctx_enc=info:ofi/enc:UTF-8&ctx_tim=2024-12-21T05%3A25%3A35IST&url_ver=Z39.88-2004&url_ctx_fmt=infofi/fmt:kev:mtx:ctx&rfr_id=info:sid/primo.exlibrisgroup.com:primo3-Article-crossref&rft_val_fmt=info:ofi/fmt:kev:mtx:journal&rft.genre=article&rft.atitle=How%20to%20make%20ad%20hoc%20proof%20automation%20less%20ad%20hoc&rft.jtitle=SIGPLAN%20notices&rft.au=Gonthier,%20Georges&rft.date=2011-09-01&rft.volume=46&rft.issue=9&rft.spage=163&rft.epage=175&rft.pages=163-175&rft.issn=0362-1340&rft.eissn=1558-1160&rft_id=info:doi/10.1145/2034574.2034798&rft_dat=%3Ccrossref%3E10_1145_2034574_2034798%3C/crossref%3E%3Curl%3E%3C/url%3E&disable_directlink=true&sfx.directlink=off&sfx.report_link=0&rft_id=info:oai/&rft_id=info:pmid/&rfr_iscdi=true |