diff --git a/404.html b/404.html new file mode 100644 index 0000000..571d8ad --- /dev/null +++ b/404.html @@ -0,0 +1,25 @@ + + + + + + 404 | Aya Prover + + + + + + + + + + + + + + +
+ + + + \ No newline at end of file diff --git a/CNAME b/CNAME new file mode 100644 index 0000000..17a0123 --- /dev/null +++ b/CNAME @@ -0,0 +1 @@ +www.aya-prover.org diff --git a/assets/app.JlQ-9LnW.js b/assets/app.JlQ-9LnW.js new file mode 100644 index 0000000..2485f17 --- /dev/null +++ b/assets/app.JlQ-9LnW.js @@ -0,0 +1 @@ +import{R as i}from"./chunks/theme.CNpb5bEr.js";import{R as o,a4 as u,a5 as c,a6 as l,a7 as f,a8 as d,a9 as m,aa as h,ab as g,ac as A,ad as v,d as P,u as R,v as w,s as y,ae as C,af as b,ag as E,a3 as S}from"./chunks/framework.CoXjB5sU.js";function p(e){if(e.extends){const a=p(e.extends);return{...a,...e,async enhanceApp(t){a.enhanceApp&&await a.enhanceApp(t),e.enhanceApp&&await e.enhanceApp(t)}}}return e}const s=p(i),T=P({name:"VitePressApp",setup(){const{site:e,lang:a,dir:t}=R();return w(()=>{y(()=>{document.documentElement.lang=a.value,document.documentElement.dir=t.value})}),e.value.router.prefetchLinks&&C(),b(),E(),s.setup&&s.setup(),()=>S(s.Layout)}});async function D(){globalThis.__VITEPRESS__=!0;const e=j(),a=_();a.provide(c,e);const t=l(e.route);return a.provide(f,t),a.component("Content",d),a.component("ClientOnly",m),Object.defineProperties(a.config.globalProperties,{$frontmatter:{get(){return t.frontmatter.value}},$params:{get(){return t.page.value.params}}}),s.enhanceApp&&await s.enhanceApp({app:a,router:e,siteData:h}),{app:a,router:e,data:t}}function _(){return g(T)}function j(){let e=o,a;return A(t=>{let n=v(t),r=null;return n&&(e&&(a=n),(e||a===n)&&(n=n.replace(/\.js$/,".lean.js")),r=import(n)),o&&(e=!1),r},s.NotFound)}o&&D().then(({app:e,router:a,data:t})=>{a.go().then(()=>{u(a.route,t.site),e.mount("#app")})});export{D as createApp}; diff --git a/assets/blog_binops.md.CdTTQPUm.js b/assets/blog_binops.md.CdTTQPUm.js new file mode 100644 index 0000000..aea1e71 --- /dev/null +++ b/assets/blog_binops.md.CdTTQPUm.js @@ -0,0 +1,12 @@ +import{_ as a,c as t,a2 as n,o as s}from"./chunks/framework.CoXjB5sU.js";const m=JSON.parse('{"title":"Binary operators in Aya","description":"","frontmatter":{},"headers":[],"relativePath":"blog/binops.md","filePath":"blog/binops.md","lastUpdated":1717413547000}'),i={name:"blog/binops.md"};function o(r,e,p,c,l,d){return s(),t("div",null,e[0]||(e[0]=[n(`

Binary operators in Aya

We have designed a binary operator system in Aya which happens to be (we didn't copy!) very similar to Rhombus (a.k.a. Racket 2) and Swift 5.7.

TL;DR: it supports making any identifier a custom operator with precedences specified by a partial ordering. Left and right associativities are supported.

The precedence and associativity information is bound to a name, not a definition. This means we can import a name from another module with changes to its name, associativity, and precedence. Importing with renaming is an established feature, but changing associativity and precedence is not that popular (though implemented in Agda already).

Here are some code examples (implementations are omitted for simplicity):

-- Left-associative
+def infixl + (x y : Nat) : Nat => {??}
+-- Left-associative, bind tighter than +
+def infixl * (x y : Nat) : Nat => {??} tighter +
+-- Prefix operator
+def fixl ! (x : Nat) : Nat => {??}
+-- Postfix operator
+def fixr ? (x : Nat) : Nat => {??}

The tighter keyword works like this: when there are expressions like a * b + c which may either mean (a * b) + c or a * (b + c), we will put the tighter operator in the parenthesis. In case we found the two operators share the same priority, Aya will report an error.

With imports, it looks like this:

open import Primitives using (
+  invol       as fixl  ~  tighter =, \\/, /\\,
+  intervalMin as infix /\\ tighter \\/,
+  intervalMax as infix \\/,
+)

Specifying operator precedences with a partial ordering is way better than with a number. In Haskell, if we already have infix 3 + and infix 4 * and we hope to add a new operator which has higher precedence than + but lower than *, it's going to be impossible. Agda introduced float-point precedence levels to address the issue, but I think it does not solve the essential problem: that I have to lookup the numbers (of existing operator precedences) every time I write a new operator.

In the future, we plan to support mixfix operators as in Agda (the current framework can support mixfix easily, but abusing mixfix notations can harm readability).

`,11)]))}const f=a(i,[["render",o]]);export{m as __pageData,f as default}; diff --git a/assets/blog_binops.md.CdTTQPUm.lean.js b/assets/blog_binops.md.CdTTQPUm.lean.js new file mode 100644 index 0000000..aea1e71 --- /dev/null +++ b/assets/blog_binops.md.CdTTQPUm.lean.js @@ -0,0 +1,12 @@ +import{_ as a,c as t,a2 as n,o as s}from"./chunks/framework.CoXjB5sU.js";const m=JSON.parse('{"title":"Binary operators in Aya","description":"","frontmatter":{},"headers":[],"relativePath":"blog/binops.md","filePath":"blog/binops.md","lastUpdated":1717413547000}'),i={name:"blog/binops.md"};function o(r,e,p,c,l,d){return s(),t("div",null,e[0]||(e[0]=[n(`

Binary operators in Aya

We have designed a binary operator system in Aya which happens to be (we didn't copy!) very similar to Rhombus (a.k.a. Racket 2) and Swift 5.7.

TL;DR: it supports making any identifier a custom operator with precedences specified by a partial ordering. Left and right associativities are supported.

The precedence and associativity information is bound to a name, not a definition. This means we can import a name from another module with changes to its name, associativity, and precedence. Importing with renaming is an established feature, but changing associativity and precedence is not that popular (though implemented in Agda already).

Here are some code examples (implementations are omitted for simplicity):

-- Left-associative
+def infixl + (x y : Nat) : Nat => {??}
+-- Left-associative, bind tighter than +
+def infixl * (x y : Nat) : Nat => {??} tighter +
+-- Prefix operator
+def fixl ! (x : Nat) : Nat => {??}
+-- Postfix operator
+def fixr ? (x : Nat) : Nat => {??}

The tighter keyword works like this: when there are expressions like a * b + c which may either mean (a * b) + c or a * (b + c), we will put the tighter operator in the parenthesis. In case we found the two operators share the same priority, Aya will report an error.

With imports, it looks like this:

open import Primitives using (
+  invol       as fixl  ~  tighter =, \\/, /\\,
+  intervalMin as infix /\\ tighter \\/,
+  intervalMax as infix \\/,
+)

Specifying operator precedences with a partial ordering is way better than with a number. In Haskell, if we already have infix 3 + and infix 4 * and we hope to add a new operator which has higher precedence than + but lower than *, it's going to be impossible. Agda introduced float-point precedence levels to address the issue, but I think it does not solve the essential problem: that I have to lookup the numbers (of existing operator precedences) every time I write a new operator.

In the future, we plan to support mixfix operators as in Agda (the current framework can support mixfix easily, but abusing mixfix notations can harm readability).

`,11)]))}const f=a(i,[["render",o]]);export{m as __pageData,f as default}; diff --git a/assets/blog_bye-hott.md.BrkJeJl8.js b/assets/blog_bye-hott.md.BrkJeJl8.js new file mode 100644 index 0000000..9b01bba --- /dev/null +++ b/assets/blog_bye-hott.md.BrkJeJl8.js @@ -0,0 +1 @@ +import{_ as t,c as a,a2 as i,o}from"./chunks/framework.CoXjB5sU.js";const d=JSON.parse('{"title":"Moving away from univalent type theory","description":"","frontmatter":{},"headers":[],"relativePath":"blog/bye-hott.md","filePath":"blog/bye-hott.md","lastUpdated":1710300019000}'),n={name:"blog/bye-hott.md"};function s(r,e,l,p,c,h){return o(),a("div",null,e[0]||(e[0]=[i('

Moving away from univalent type theory

Aya is now moving away from univalent type theory.

Note that this does not mean we are moving away from cubical type theory -- we are trying to adapt an extensional version cubical type theory, called XTT, which is a cubical approach towards observational equality (the idea is due to Altenkirch and McBride): the equality type a =_A b is no longer defined uniformly for all types A, but rather defined by assuming a closed (inductive-recursive) universe, and defining a type family (A : Type) -> A -> A -> Type by casing on what A is. For function types, we can define it as pointwise equality, which makes function extensionality true by definition.

In case of cubical, this is automatic, due to how path types are defined.

The reference for XTT can be found in the paper A Cubical Language for Bishop Sets by Sterling, Angiuli, and Gratzer. This paper has a previous version which has a universe hierarchy, called Cubical Syntax for Reflection-Free Extensional Equality, by the same authors.

We plan to use XTT as the basis for Aya's type theory. We will change the following in v0.30 Aya:

  1. We will implement a universe à la Tarski to reuse the type checking of subtypes and paths.
  2. The impredicative Prop universe will be removed due to the complications it caused.
  3. The binding representation will be changed to locally nameless. By that we can make closed term completely serializable.
  4. We will try to implement definition-level controlling unfolding. This has a several advantages: the type checking order of bodies can be inferred from the annotations, and we can detect more cycles instead of reporting errors due to not being able to unfold unchecked function.
  5. We wish to remove implicitness information from core terms, and keep them a feature related to function calls. Π\\Pi-types should not know the name of the parameter, which is natural due to α\\alpha-equality. This means named arguments will only work for direct function calls.

Yes, the last two items indicate a major change in the implementation of Aya, which is essentially a rewrite of the type checker. We took this chance to revisit a couple of old issues and fix them. Currently, we have suceeded in extracting a Java module for the syntax definition from the type checker module, which will benefit third-party libraries who want to deal with serialized Aya terms.

We will not adapt the following features from XTT:

  1. Partial elements are first-class citizens, i.e. they have manifest "cubical" phases. Instead we will have first class total elements and use a Partial type to represent partial elements.
  2. Intervals are not types. We will adapt the 2LTT-style solution from Cubical Agda, which has some universes to classify exo-types.
  3. The type-case operator will remain internal to the type checker. While this might be useful in the future development related to metaprogramming, we do not see any immediate use for it except for implementing the computation of generalized coercion.
  4. As we already said, we do not intend to add an impredicative Prop universe, while the XTT paper said they intend to add it. We encourage the users to embrace the axiom of propositional resizing, which makes not just Props to be impredicative, but also all h-props (e.g. types that are provably props) to be impredicative.

The development is still in a private work-in-progress repository, which we will open-source and be ported to the main repo once we can compile this website with the new type checker, which implies complete support for inductive types except for the positivity checker.

We will also have to rewrite some guides about higher inductive types, and instead use some quotient type examples.

From that, we will start considering support for classes with extensions, and try to formalize some mathematics and do some real-world programming with Aya, partially bootstrapping the type checker.

Stay tuned!

',14)]))}const u=t(n,[["render",s]]);export{d as __pageData,u as default}; diff --git a/assets/blog_bye-hott.md.BrkJeJl8.lean.js b/assets/blog_bye-hott.md.BrkJeJl8.lean.js new file mode 100644 index 0000000..9b01bba --- /dev/null +++ b/assets/blog_bye-hott.md.BrkJeJl8.lean.js @@ -0,0 +1 @@ +import{_ as t,c as a,a2 as i,o}from"./chunks/framework.CoXjB5sU.js";const d=JSON.parse('{"title":"Moving away from univalent type theory","description":"","frontmatter":{},"headers":[],"relativePath":"blog/bye-hott.md","filePath":"blog/bye-hott.md","lastUpdated":1710300019000}'),n={name:"blog/bye-hott.md"};function s(r,e,l,p,c,h){return o(),a("div",null,e[0]||(e[0]=[i('

Moving away from univalent type theory

Aya is now moving away from univalent type theory.

Note that this does not mean we are moving away from cubical type theory -- we are trying to adapt an extensional version cubical type theory, called XTT, which is a cubical approach towards observational equality (the idea is due to Altenkirch and McBride): the equality type a =_A b is no longer defined uniformly for all types A, but rather defined by assuming a closed (inductive-recursive) universe, and defining a type family (A : Type) -> A -> A -> Type by casing on what A is. For function types, we can define it as pointwise equality, which makes function extensionality true by definition.

In case of cubical, this is automatic, due to how path types are defined.

The reference for XTT can be found in the paper A Cubical Language for Bishop Sets by Sterling, Angiuli, and Gratzer. This paper has a previous version which has a universe hierarchy, called Cubical Syntax for Reflection-Free Extensional Equality, by the same authors.

We plan to use XTT as the basis for Aya's type theory. We will change the following in v0.30 Aya:

  1. We will implement a universe à la Tarski to reuse the type checking of subtypes and paths.
  2. The impredicative Prop universe will be removed due to the complications it caused.
  3. The binding representation will be changed to locally nameless. By that we can make closed term completely serializable.
  4. We will try to implement definition-level controlling unfolding. This has a several advantages: the type checking order of bodies can be inferred from the annotations, and we can detect more cycles instead of reporting errors due to not being able to unfold unchecked function.
  5. We wish to remove implicitness information from core terms, and keep them a feature related to function calls. Π\\Pi-types should not know the name of the parameter, which is natural due to α\\alpha-equality. This means named arguments will only work for direct function calls.

Yes, the last two items indicate a major change in the implementation of Aya, which is essentially a rewrite of the type checker. We took this chance to revisit a couple of old issues and fix them. Currently, we have suceeded in extracting a Java module for the syntax definition from the type checker module, which will benefit third-party libraries who want to deal with serialized Aya terms.

We will not adapt the following features from XTT:

  1. Partial elements are first-class citizens, i.e. they have manifest "cubical" phases. Instead we will have first class total elements and use a Partial type to represent partial elements.
  2. Intervals are not types. We will adapt the 2LTT-style solution from Cubical Agda, which has some universes to classify exo-types.
  3. The type-case operator will remain internal to the type checker. While this might be useful in the future development related to metaprogramming, we do not see any immediate use for it except for implementing the computation of generalized coercion.
  4. As we already said, we do not intend to add an impredicative Prop universe, while the XTT paper said they intend to add it. We encourage the users to embrace the axiom of propositional resizing, which makes not just Props to be impredicative, but also all h-props (e.g. types that are provably props) to be impredicative.

The development is still in a private work-in-progress repository, which we will open-source and be ported to the main repo once we can compile this website with the new type checker, which implies complete support for inductive types except for the positivity checker.

We will also have to rewrite some guides about higher inductive types, and instead use some quotient type examples.

From that, we will start considering support for classes with extensions, and try to formalize some mathematics and do some real-world programming with Aya, partially bootstrapping the type checker.

Stay tuned!

',14)]))}const u=t(n,[["render",s]]);export{d as __pageData,u as default}; diff --git a/assets/blog_class-defeq.md.B5iu-E0L.js b/assets/blog_class-defeq.md.B5iu-E0L.js new file mode 100644 index 0000000..1e3d9a2 --- /dev/null +++ b/assets/blog_class-defeq.md.B5iu-E0L.js @@ -0,0 +1,12 @@ +import{_ as s,c as e,a2 as t,o as n}from"./chunks/framework.CoXjB5sU.js";const h=JSON.parse('{"title":"Class extension with definitional projection","description":"","frontmatter":{},"headers":[],"relativePath":"blog/class-defeq.md","filePath":"blog/class-defeq.md","lastUpdated":1679761681000}'),o={name:"blog/class-defeq.md"};function i(p,a,l,c,r,m){return n(),e("div",null,a[0]||(a[0]=[t(`

Class extension with definitional projection

We want a class system with the following basic capabilities:

To add more flexibility to it, we want the following feature.

Anonymous extensions

Suppose we have a class Precat for precategories (written in pseudocode):

class Precat
+| Ob : Type
+| Hom : Ob -> Ob -> Type
+| Hom-set (A B : Ob) : isSet (Hom A B)
+| id (A : Ob) : Hom A A
+| ....

Suppose the syntax for creating an instance of a class is new Precat { Ob := .., Hom := .., ... }. I want the following:

This is called anonymous class extension, already implemented in the Arend language. As a syntactic sugar, we may write Precat { Ob := Group } as Precat Group, where the application is ordered the same as the fields in the class definition.

Definitional projection

We further want definitional projection:

This concludes the basic features of the class system. To implement this, it may seem that we need to have access to types in the normalizer, which makes it very heavy (in contrast to the lightweight normalizer you can have for plain MLTT).

Implementation

A uniform implementation of this definitional projection requires the definitional equality to commute with substitution, say, we may have

A:PrecatA.Ob:U{A : \\text{Precat} ⊢ A.\\text{Ob} : \\mathcal U}

This is a normal form. Then, we have Grp : Precat Group (so Grp.Ob is definitionally equal to Group), and we may perform the substitution [Grp/A][\\text{Grp} / \\text{A}] on the above normal form:

Grp:Precat GroupGrp.Ob:U\\text{Grp} : \\text{Precat}~\\text{Group} ⊢ \\text{Grp}.\\text{Ob} : \\mathcal U

We want the above to be equal to Group as well. Without access to contexts, it seems really hard!

Here's a trick: whenever we see A : Precat Group, we elaborate it into (the idea is similar to an η-expansion):

A ==> new Precat
+  { Ob := Group
+  , Hom := A.Hom
+  , Hom-set := A.Hom-set
+  , id := A.id
+  , ...
+  }

By that, we will never have A.Ob in the source language, because it always gets elaborated into Group directly. In case we partially know about A from the type, we really elaborate the type information right into the core term. So, we don't even have a chance to touch the bare A (not being projected) in the core language, and anything of a class type is always in an introduction form.

This should implement the definitional projection feature without even modifying the MLTT normalizer.

The idea of this feature comes from the treatment of extension types inspired from cooltt, see relevant post.

`,25)]))}const u=s(o,[["render",i]]);export{h as __pageData,u as default}; diff --git a/assets/blog_class-defeq.md.B5iu-E0L.lean.js b/assets/blog_class-defeq.md.B5iu-E0L.lean.js new file mode 100644 index 0000000..1e3d9a2 --- /dev/null +++ b/assets/blog_class-defeq.md.B5iu-E0L.lean.js @@ -0,0 +1,12 @@ +import{_ as s,c as e,a2 as t,o as n}from"./chunks/framework.CoXjB5sU.js";const h=JSON.parse('{"title":"Class extension with definitional projection","description":"","frontmatter":{},"headers":[],"relativePath":"blog/class-defeq.md","filePath":"blog/class-defeq.md","lastUpdated":1679761681000}'),o={name:"blog/class-defeq.md"};function i(p,a,l,c,r,m){return n(),e("div",null,a[0]||(a[0]=[t(`

Class extension with definitional projection

We want a class system with the following basic capabilities:

To add more flexibility to it, we want the following feature.

Anonymous extensions

Suppose we have a class Precat for precategories (written in pseudocode):

class Precat
+| Ob : Type
+| Hom : Ob -> Ob -> Type
+| Hom-set (A B : Ob) : isSet (Hom A B)
+| id (A : Ob) : Hom A A
+| ....

Suppose the syntax for creating an instance of a class is new Precat { Ob := .., Hom := .., ... }. I want the following:

This is called anonymous class extension, already implemented in the Arend language. As a syntactic sugar, we may write Precat { Ob := Group } as Precat Group, where the application is ordered the same as the fields in the class definition.

Definitional projection

We further want definitional projection:

This concludes the basic features of the class system. To implement this, it may seem that we need to have access to types in the normalizer, which makes it very heavy (in contrast to the lightweight normalizer you can have for plain MLTT).

Implementation

A uniform implementation of this definitional projection requires the definitional equality to commute with substitution, say, we may have

A:PrecatA.Ob:U{A : \\text{Precat} ⊢ A.\\text{Ob} : \\mathcal U}

This is a normal form. Then, we have Grp : Precat Group (so Grp.Ob is definitionally equal to Group), and we may perform the substitution [Grp/A][\\text{Grp} / \\text{A}] on the above normal form:

Grp:Precat GroupGrp.Ob:U\\text{Grp} : \\text{Precat}~\\text{Group} ⊢ \\text{Grp}.\\text{Ob} : \\mathcal U

We want the above to be equal to Group as well. Without access to contexts, it seems really hard!

Here's a trick: whenever we see A : Precat Group, we elaborate it into (the idea is similar to an η-expansion):

A ==> new Precat
+  { Ob := Group
+  , Hom := A.Hom
+  , Hom-set := A.Hom-set
+  , id := A.id
+  , ...
+  }

By that, we will never have A.Ob in the source language, because it always gets elaborated into Group directly. In case we partially know about A from the type, we really elaborate the type information right into the core term. So, we don't even have a chance to touch the bare A (not being projected) in the core language, and anything of a class type is always in an introduction form.

This should implement the definitional projection feature without even modifying the MLTT normalizer.

The idea of this feature comes from the treatment of extension types inspired from cooltt, see relevant post.

`,25)]))}const u=s(o,[["render",i]]);export{h as __pageData,u as default}; diff --git a/assets/blog_extended-pruning.md.CVuBUw6d.js b/assets/blog_extended-pruning.md.CVuBUw6d.js new file mode 100644 index 0000000..98e44b3 --- /dev/null +++ b/assets/blog_extended-pruning.md.CVuBUw6d.js @@ -0,0 +1,51 @@ +import{_ as z,c as w,j as s,a as e,a2 as V,o as _}from"./chunks/framework.CoXjB5sU.js";const C={mounted(){const h=new Map;function d(l){const a=l.querySelectorAll("a[href]");for(const n of a){const o=n.href,r=h.get(o)??new Set;r.add(n),h.set(o,r)}for(const n of a)n.onmouseover=function(){for(const o of h.get(this.href))o.classList.add("hover-highlight")},n.onmouseout=function(){for(const o of h.get(this.href))o.classList.remove("hover-highlight")}}function y(l){return decodeURIComponent(atob(l).split("").map(function(a){return"%"+("00"+a.charCodeAt(0).toString(16)).slice(-2)}).join(""))}const f=(l=>{const a={};return(...n)=>{const o=JSON.stringify(n);return a[o]=a[o]||l(...n)}})(y);class m{constructor(){this.list=[]}dismiss(a){a&&(a.remove(),this.list=this.list.filter(n=>n!==a))}dismissIfNotUsed(a){a&&(a.markedForDismissal=!0,setTimeout(()=>{!a.userIsThinking&&this.allowAutoDismissal(a)&&this.dismiss(a)},1e3))}allowAutoDismissal(a){return a.markedForDismissal&&!a.userClicked}fireAutoDismissalFor(a){let n=this.list.find(o=>o.userCreatedFrom===a);this.dismissIfNotUsed(n)}createHoverFor(a,n,o){let r=this.list.find(i=>i.userCreatedFrom===a);if(r&&r.userClicked)return r;let b=[];const x=this.list.filter(i=>{if(this.allowAutoDismissal(i))return b.push(i),!1;const p=i.userCreatedFrom,u=a;let c=u;for(;c;){if(c===p)return!0;c=c.parentElement}for(c=p;c;){if(c===u)return!0;c=c.parentElement}return!1});b.forEach(i=>this.dismiss(i));let t=document.createElement("div");t.userCreatedFrom=a,t.innerHTML="×"+f(n),t.classList.add("AyaTooltipPopup"),d(t);let A=this;if(t.handleEvent=function(i){if(i.type==="click"){this.userClicked=!0,this.markedForDismissal=!1;let p=this.children[0];if(!p)return;let u=this;p.style.visibility="visible",p.addEventListener("click",c=>A.dismiss(u))}i.type==="mouseover"&&(this.userIsThinking=!0),i.type==="mouseout"&&(this.userIsThinking=!1,A.dismissIfNotUsed(this))},t.addEventListener("click",t),t.addEventListener("mouseover",t),t.addEventListener("mouseout",t),o.appendChild(t),t.style.left=`${a.offsetLeft}px`,x.length===0){const i=a.getBoundingClientRect(),p=t.getBoundingClientRect();i.bottom+p.height+30>window.innerHeight?t.style.top=`calc(${a.offsetTop-p.height+8}px - 3em)`:t.style.top=`${a.offsetTop+a.offsetHeight+8}px`}else{const i=Math.max(...x.map(p=>p.offsetTop+p.offsetHeight));t.style.top=`${i+8}px`}return this.list.push(t),t}}let v=new m;function g(l){return function(){let a=this;const n=a.getAttribute("data-tooltip-text");n&&(l?v.createHoverFor(a,n,document.body):v.fireAutoDismissalFor(a))}}d(document);{let l=document.getElementsByClassName("aya-tooltip");for(let a=0;aThis is the equality between two sized vectors: (xs ++ (ys ++ zs)) and ((xs ++ ys) ++ zs), the left hand side has type Vec (xs.size ++ (ys.size ++ zs.size)) A, and the right hand side has type Vec ((xs.size ++ ys.size) ++ zs.size).

So, the equality type is heterogeneous, and I introduce a type Vec (+-assoc i) A for it, where +-assoc is the associativity.

So this should type check, right? But pattern unification fails! I've left the two sides of +-assoc implicit, so I'm supposed to infer what numbers' associativity I care about, using pattern unification.

Then, pattern unification fails because the constraints are generated from cubical boundaries, where the "interval" variable is substituted to its sides. So, we have this type (the Path is called PathP in Agda):

Γ ­⊢ Path (fn i => Vec (+-assoc i) Nat) vecA vecB

Note the type of +-assoc is Fn (o p q : Nat) → ((o + p) + q) = (o + (p + q)).

So elaboration inserts metavariables:

Γ ­⊢ Path (fn i => Vec (+-assoc {?} {?} {?} i) Nat) vecA vecB

Where these metavariables have the following scope:

Γ , i : I ­⊢ ? : Nat

Note that the i : I binding is in-scope. So the metavariables with their spines added together becomes:

Γ ­⊢ Path (fn i => Vec (+-assoc {?a Γ i} {?b Γ i} {?c Γ i} i) Nat) vecA vecB

Then, we get the following tycking problems, according to the rules of Path:

vecA : Vec (+-assoc {?a Γ 0} {?b Γ 0} {?c Γ 0} 0) Nat
+vecB : Vec (+-assoc {?a Γ 1} {?b Γ 1} {?c Γ 1} 1) Nat

Look at the spines of all of these metavariables. None of them are in pattern fragment. So every equality constraint cannot be solved by pattern, because they're always equality after a substitution!

This can be solved by further extending your algorithm with pruning or a constraint system with a "lax" mode of solving metas when your equations rely essentially on non-pattern equations, but I feel it has defeated the point of finding the most general solution, which I used to believe to be the purpose of pattern unification....

Case Study

Right now Aya will try to prune these non-pattern arguments out and try to solve them. This obviously generates non-unique solutions, but I think it will be useful in practice.

In Agda, the following code is in the library:

++-assoc : ∀ {m n k} (xs : Vec A m) (ys : Vec A n) (zs : Vec A k) →
+          PathP (λ i → Vec A (+-assoc m n k (~ i)))
+          ((xs ++ ys) ++ zs) (xs ++ ys ++ zs)
+++-assoc {m = zero} [] ys zs = refl
+++-assoc {m = suc m} (x ∷ xs) ys zs i = x ∷ ++-assoc xs ys zs i

However, if we replace the m with _, Agda will fail with the following error:

Failed to solve the following constraints:
+  _41 (xs = (x ∷ xs)) (ys = ys) (zs = zs) = x ∷ ++-assoc xs ys zs i1
+    : Vec A
+      (+-assoc (_m_39 (xs = (x ∷ xs)) (ys = ys) (zs = zs) (i = i1)) n k
+       (~ i1))
+    (blocked on any(_41, _57))
+  _40 (xs = (x ∷ xs)) (ys = ys) (zs = zs) = x ∷ ++-assoc xs ys zs i0
+    : Vec A
+      (+-assoc (_m_39 (xs = (x ∷ xs)) (ys = ys) (zs = zs) (i = i0)) n k
+       (~ i0))
+    (blocked on any(_40, _57))
+  +-assoc (_m_39 (xs = xs) (ys = ys) (zs = zs) (i = i)) n k (~ i)
+    = _n_49
+    : ℕ
+    (blocked on _n_49)
+  +-assoc (_m_39 (xs = (x ∷ xs)) (ys = ys) (zs = zs) (i = i)) n k
+  (~ i)
+    = ℕ.suc _n_49
+    : ℕ
+    (blocked on _m_39)
+  _40 (xs = []) (ys = ys) (zs = zs)
+    = _41 (xs = []) (ys = ys) (zs = zs)
+    : _x.A_43
+    (blocked on any(_40, _41))
+  _x.A_43
+    = Vec A
+      (+-assoc (_m_39 (xs = []) (ys = ys) (zs = zs) (i = i)) n k (~ i))
+    : Type
+    (blocked on _x.A_43)
+  _m_39 (i = i0) = m : ℕ (blocked on _m_39)
+  _m_39 (i = i1) + (n + k) = m + (n + k) : ℕ (blocked on _m_39)

In Aya, this will raise the following warning:

  6 │       def ++-assoc-type (xs : Vec n A) (ys : Vec m A) (zs : Vec o A)
+  7 │         => Path (fn i => Vec (+-assoc i) A)
+  8 │         (xs ++ (ys ++ zs))
+    │          ╰──────────────╯ ?a n A m o xs ys zs 0 >= n, ?b n A m o xs ys zs 0 >= m,
+                                ?c n A m o xs ys zs 0 >= o
+  9 │         ((xs ++ ys) ++ zs)
+    │          ╰──────────────╯
+    │          ╰──────────────╯ ?a n A m o xs ys zs 1 >= n, ?b n A m o xs ys zs 1 >= m,
+                                ?c n A m o xs ys zs 1 >= o
+
+Info: Solving equation(s) with not very general solution(s)

The inline equations are the type checking problems that Aya did something bad to solve.

Conor McBride told me pattern unification is a good algorithm, but the problem of interest might not be what we think it is. It is good for undergraduate induction, i.e. the object being induct on is a variable, and the motive of such induction is pattern. This is an enlightening perspective! But now that we have more problems, I think we might want to extend it. Just think about how many people use --lossy-unification in Agda.

`,26)]))}const P=z(C,[["render",L]]);export{I as __pageData,P as default}; diff --git a/assets/blog_extended-pruning.md.CVuBUw6d.lean.js b/assets/blog_extended-pruning.md.CVuBUw6d.lean.js new file mode 100644 index 0000000..98e44b3 --- /dev/null +++ b/assets/blog_extended-pruning.md.CVuBUw6d.lean.js @@ -0,0 +1,51 @@ +import{_ as z,c as w,j as s,a as e,a2 as V,o as _}from"./chunks/framework.CoXjB5sU.js";const C={mounted(){const h=new Map;function d(l){const a=l.querySelectorAll("a[href]");for(const n of a){const o=n.href,r=h.get(o)??new Set;r.add(n),h.set(o,r)}for(const n of a)n.onmouseover=function(){for(const o of h.get(this.href))o.classList.add("hover-highlight")},n.onmouseout=function(){for(const o of h.get(this.href))o.classList.remove("hover-highlight")}}function y(l){return decodeURIComponent(atob(l).split("").map(function(a){return"%"+("00"+a.charCodeAt(0).toString(16)).slice(-2)}).join(""))}const f=(l=>{const a={};return(...n)=>{const o=JSON.stringify(n);return a[o]=a[o]||l(...n)}})(y);class m{constructor(){this.list=[]}dismiss(a){a&&(a.remove(),this.list=this.list.filter(n=>n!==a))}dismissIfNotUsed(a){a&&(a.markedForDismissal=!0,setTimeout(()=>{!a.userIsThinking&&this.allowAutoDismissal(a)&&this.dismiss(a)},1e3))}allowAutoDismissal(a){return a.markedForDismissal&&!a.userClicked}fireAutoDismissalFor(a){let n=this.list.find(o=>o.userCreatedFrom===a);this.dismissIfNotUsed(n)}createHoverFor(a,n,o){let r=this.list.find(i=>i.userCreatedFrom===a);if(r&&r.userClicked)return r;let b=[];const x=this.list.filter(i=>{if(this.allowAutoDismissal(i))return b.push(i),!1;const p=i.userCreatedFrom,u=a;let c=u;for(;c;){if(c===p)return!0;c=c.parentElement}for(c=p;c;){if(c===u)return!0;c=c.parentElement}return!1});b.forEach(i=>this.dismiss(i));let t=document.createElement("div");t.userCreatedFrom=a,t.innerHTML="×"+f(n),t.classList.add("AyaTooltipPopup"),d(t);let A=this;if(t.handleEvent=function(i){if(i.type==="click"){this.userClicked=!0,this.markedForDismissal=!1;let p=this.children[0];if(!p)return;let u=this;p.style.visibility="visible",p.addEventListener("click",c=>A.dismiss(u))}i.type==="mouseover"&&(this.userIsThinking=!0),i.type==="mouseout"&&(this.userIsThinking=!1,A.dismissIfNotUsed(this))},t.addEventListener("click",t),t.addEventListener("mouseover",t),t.addEventListener("mouseout",t),o.appendChild(t),t.style.left=`${a.offsetLeft}px`,x.length===0){const i=a.getBoundingClientRect(),p=t.getBoundingClientRect();i.bottom+p.height+30>window.innerHeight?t.style.top=`calc(${a.offsetTop-p.height+8}px - 3em)`:t.style.top=`${a.offsetTop+a.offsetHeight+8}px`}else{const i=Math.max(...x.map(p=>p.offsetTop+p.offsetHeight));t.style.top=`${i+8}px`}return this.list.push(t),t}}let v=new m;function g(l){return function(){let a=this;const n=a.getAttribute("data-tooltip-text");n&&(l?v.createHoverFor(a,n,document.body):v.fireAutoDismissalFor(a))}}d(document);{let l=document.getElementsByClassName("aya-tooltip");for(let a=0;aThis is the equality between two sized vectors: (xs ++ (ys ++ zs)) and ((xs ++ ys) ++ zs), the left hand side has type Vec (xs.size ++ (ys.size ++ zs.size)) A, and the right hand side has type Vec ((xs.size ++ ys.size) ++ zs.size).

So, the equality type is heterogeneous, and I introduce a type Vec (+-assoc i) A for it, where +-assoc is the associativity.

So this should type check, right? But pattern unification fails! I've left the two sides of +-assoc implicit, so I'm supposed to infer what numbers' associativity I care about, using pattern unification.

Then, pattern unification fails because the constraints are generated from cubical boundaries, where the "interval" variable is substituted to its sides. So, we have this type (the Path is called PathP in Agda):

Γ ­⊢ Path (fn i => Vec (+-assoc i) Nat) vecA vecB

Note the type of +-assoc is Fn (o p q : Nat) → ((o + p) + q) = (o + (p + q)).

So elaboration inserts metavariables:

Γ ­⊢ Path (fn i => Vec (+-assoc {?} {?} {?} i) Nat) vecA vecB

Where these metavariables have the following scope:

Γ , i : I ­⊢ ? : Nat

Note that the i : I binding is in-scope. So the metavariables with their spines added together becomes:

Γ ­⊢ Path (fn i => Vec (+-assoc {?a Γ i} {?b Γ i} {?c Γ i} i) Nat) vecA vecB

Then, we get the following tycking problems, according to the rules of Path:

vecA : Vec (+-assoc {?a Γ 0} {?b Γ 0} {?c Γ 0} 0) Nat
+vecB : Vec (+-assoc {?a Γ 1} {?b Γ 1} {?c Γ 1} 1) Nat

Look at the spines of all of these metavariables. None of them are in pattern fragment. So every equality constraint cannot be solved by pattern, because they're always equality after a substitution!

This can be solved by further extending your algorithm with pruning or a constraint system with a "lax" mode of solving metas when your equations rely essentially on non-pattern equations, but I feel it has defeated the point of finding the most general solution, which I used to believe to be the purpose of pattern unification....

Case Study

Right now Aya will try to prune these non-pattern arguments out and try to solve them. This obviously generates non-unique solutions, but I think it will be useful in practice.

In Agda, the following code is in the library:

++-assoc : ∀ {m n k} (xs : Vec A m) (ys : Vec A n) (zs : Vec A k) →
+          PathP (λ i → Vec A (+-assoc m n k (~ i)))
+          ((xs ++ ys) ++ zs) (xs ++ ys ++ zs)
+++-assoc {m = zero} [] ys zs = refl
+++-assoc {m = suc m} (x ∷ xs) ys zs i = x ∷ ++-assoc xs ys zs i

However, if we replace the m with _, Agda will fail with the following error:

Failed to solve the following constraints:
+  _41 (xs = (x ∷ xs)) (ys = ys) (zs = zs) = x ∷ ++-assoc xs ys zs i1
+    : Vec A
+      (+-assoc (_m_39 (xs = (x ∷ xs)) (ys = ys) (zs = zs) (i = i1)) n k
+       (~ i1))
+    (blocked on any(_41, _57))
+  _40 (xs = (x ∷ xs)) (ys = ys) (zs = zs) = x ∷ ++-assoc xs ys zs i0
+    : Vec A
+      (+-assoc (_m_39 (xs = (x ∷ xs)) (ys = ys) (zs = zs) (i = i0)) n k
+       (~ i0))
+    (blocked on any(_40, _57))
+  +-assoc (_m_39 (xs = xs) (ys = ys) (zs = zs) (i = i)) n k (~ i)
+    = _n_49
+    : ℕ
+    (blocked on _n_49)
+  +-assoc (_m_39 (xs = (x ∷ xs)) (ys = ys) (zs = zs) (i = i)) n k
+  (~ i)
+    = ℕ.suc _n_49
+    : ℕ
+    (blocked on _m_39)
+  _40 (xs = []) (ys = ys) (zs = zs)
+    = _41 (xs = []) (ys = ys) (zs = zs)
+    : _x.A_43
+    (blocked on any(_40, _41))
+  _x.A_43
+    = Vec A
+      (+-assoc (_m_39 (xs = []) (ys = ys) (zs = zs) (i = i)) n k (~ i))
+    : Type
+    (blocked on _x.A_43)
+  _m_39 (i = i0) = m : ℕ (blocked on _m_39)
+  _m_39 (i = i1) + (n + k) = m + (n + k) : ℕ (blocked on _m_39)

In Aya, this will raise the following warning:

  6 │       def ++-assoc-type (xs : Vec n A) (ys : Vec m A) (zs : Vec o A)
+  7 │         => Path (fn i => Vec (+-assoc i) A)
+  8 │         (xs ++ (ys ++ zs))
+    │          ╰──────────────╯ ?a n A m o xs ys zs 0 >= n, ?b n A m o xs ys zs 0 >= m,
+                                ?c n A m o xs ys zs 0 >= o
+  9 │         ((xs ++ ys) ++ zs)
+    │          ╰──────────────╯
+    │          ╰──────────────╯ ?a n A m o xs ys zs 1 >= n, ?b n A m o xs ys zs 1 >= m,
+                                ?c n A m o xs ys zs 1 >= o
+
+Info: Solving equation(s) with not very general solution(s)

The inline equations are the type checking problems that Aya did something bad to solve.

Conor McBride told me pattern unification is a good algorithm, but the problem of interest might not be what we think it is. It is good for undergraduate induction, i.e. the object being induct on is a variable, and the motive of such induction is pattern. This is an enlightening perspective! But now that we have more problems, I think we might want to extend it. Just think about how many people use --lossy-unification in Agda.

`,26)]))}const P=z(C,[["render",L]]);export{I as __pageData,P as default}; diff --git a/assets/blog_ind-prop.md.gSiorRXd.js b/assets/blog_ind-prop.md.gSiorRXd.js new file mode 100644 index 0000000..f29a332 --- /dev/null +++ b/assets/blog_ind-prop.md.gSiorRXd.js @@ -0,0 +1,18 @@ +import{_ as a,c as i,a2 as s,o as t}from"./chunks/framework.CoXjB5sU.js";const k=JSON.parse('{"title":"Impredicative Props are hard","description":"","frontmatter":{},"headers":[],"relativePath":"blog/ind-prop.md","filePath":"blog/ind-prop.md","lastUpdated":1718905368000}'),n={name:"blog/ind-prop.md"};function o(p,e,r,l,h,d){return t(),i("div",null,e[0]||(e[0]=[s(`

Impredicative Props are hard

Throughout this blog post, I will use the term Prop to mean the type of propositions, which does not have to be strict, but has the property that it cannot eliminate to Type.

Motivation

Long time ago I wrote a PASE question regarding definitional irrelevance. An important pro of Prop in my opinion is that it is more convenient to be turned impredicative. Mathematicians want impredicativity for various reasons, one thing being that it is natural to have a proposition being a quantification over types, which I think is true.

Now I want to point out several reasons to avoid Prop and impredicativity based on Prop. Note that I'm not asking you to get rid of impredicativity in general!

Ad-hoc termination rules of impredicative Prop

There is another related PASE question regarding termination. You don't have to read it, I'll paraphrase the example.

Usually, for structural induction, we have the notion of "comparing term size". For instance, if we have a pattern suc n, then recursively call the function itself with n on the same position is considered good, because we think n < suc n. But consider the following example.

It makes sense to define the following type:

haskell
data BrouwerTree
+  = Leaf Bool
+  | Branch (Nat -> BrouwerTree)

and have the following structural-induction:

haskell
left :: BrouwerTree -> Bool
+left (Leaf b) = b
+left (Branch xs) = left (xs 0)

Note that in the clause of left (Branch xs), the recursive call left (xs 0) is considered smaller, in other words, we think xs 0 < Branch xs.

This assumption is called 'predicative assumption'. As you may tell from the name, it can only be made on things that are predicative, and we know Prop is usually impredicative, so we should not allow this. At this point, you might expect a proof of false using predicative assumption on Prop, which I'll show in this blog post.

Note that allowing such recursion pattern is very important! The famous W-type is also using this assumption.

A counterexample with Prop looks like this (since we need to talk about universes and dependent types, we start using Agda syntax instead of Haskell):

data Bad : Prop where
+  branch : ((P : Prop) → P → P) → Bad
+
+bad : Bad
+bad = branch (λ P p → p)
+
+no-bad : Bad → ⊥
+no-bad (branch x) = no-bad (x Bad bad)
+
+very-bad : ⊥
+very-bad = no-bad bad

Notice that the no-bad (branch x) clause uses the recursion no-bad (x Bad bad), which is only valid with the predicative assumption. So, having this predicative assumption actually proves false for Prop, so for Prop, we need to patch the termination checker to ban this rule. So, how hard is it to patch the termination checker?

Coq and Lean have a similar problem, but they are generating eliminators for inductive definitions, so they can generate the correct eliminator for Prop, instead of patching the termination checker. Then, Coq carefully implements a comparison function for size-decreasing arguments (this means eliminators are not the "most primitive" thing in Coq, but the termination checker is also part of it. I got this piece of information from Lysxia and Meven Lennon-Bertrand). In Coq, the eliminator for Bad is

Bad_ind : forall P : Prop,
+    ((forall p : Prop, p -> p) -> P) ->
+    Bad -> P

Note that there is no recursive arguments, so there is no recursion allowed.

Now, this sounds like just adding some if statements to the termination checker, but the situation is actually worse. In Agda, metavariables are pervasive, like the following code is partially accepted:

data Bad : Prop where
+  b : ((P : { }0) → P → P) → Bad

Agda will not fail on this code, but then what to do in the termination checker is really unclear. If you're using a termination checker, you want to get rid of impredicativity of Prop! This eliminates the need of a universe-based irrelevance.

Alternative ways to impredicativity

We may use axioms to get impredicativity. Suppose we define (since we no longer have it in the language) Prop := Σ (A : Type) (isProp A), there are two different axioms that imply impredicativity of Prop:

If we think of the right way of doing math is to work with classical axioms, why on earth are we forging a weaker theorem as part of the language?

`,28)]))}const u=a(n,[["render",o]]);export{k as __pageData,u as default}; diff --git a/assets/blog_ind-prop.md.gSiorRXd.lean.js b/assets/blog_ind-prop.md.gSiorRXd.lean.js new file mode 100644 index 0000000..f29a332 --- /dev/null +++ b/assets/blog_ind-prop.md.gSiorRXd.lean.js @@ -0,0 +1,18 @@ +import{_ as a,c as i,a2 as s,o as t}from"./chunks/framework.CoXjB5sU.js";const k=JSON.parse('{"title":"Impredicative Props are hard","description":"","frontmatter":{},"headers":[],"relativePath":"blog/ind-prop.md","filePath":"blog/ind-prop.md","lastUpdated":1718905368000}'),n={name:"blog/ind-prop.md"};function o(p,e,r,l,h,d){return t(),i("div",null,e[0]||(e[0]=[s(`

Impredicative Props are hard

Throughout this blog post, I will use the term Prop to mean the type of propositions, which does not have to be strict, but has the property that it cannot eliminate to Type.

Motivation

Long time ago I wrote a PASE question regarding definitional irrelevance. An important pro of Prop in my opinion is that it is more convenient to be turned impredicative. Mathematicians want impredicativity for various reasons, one thing being that it is natural to have a proposition being a quantification over types, which I think is true.

Now I want to point out several reasons to avoid Prop and impredicativity based on Prop. Note that I'm not asking you to get rid of impredicativity in general!

Ad-hoc termination rules of impredicative Prop

There is another related PASE question regarding termination. You don't have to read it, I'll paraphrase the example.

Usually, for structural induction, we have the notion of "comparing term size". For instance, if we have a pattern suc n, then recursively call the function itself with n on the same position is considered good, because we think n < suc n. But consider the following example.

It makes sense to define the following type:

haskell
data BrouwerTree
+  = Leaf Bool
+  | Branch (Nat -> BrouwerTree)

and have the following structural-induction:

haskell
left :: BrouwerTree -> Bool
+left (Leaf b) = b
+left (Branch xs) = left (xs 0)

Note that in the clause of left (Branch xs), the recursive call left (xs 0) is considered smaller, in other words, we think xs 0 < Branch xs.

This assumption is called 'predicative assumption'. As you may tell from the name, it can only be made on things that are predicative, and we know Prop is usually impredicative, so we should not allow this. At this point, you might expect a proof of false using predicative assumption on Prop, which I'll show in this blog post.

Note that allowing such recursion pattern is very important! The famous W-type is also using this assumption.

A counterexample with Prop looks like this (since we need to talk about universes and dependent types, we start using Agda syntax instead of Haskell):

data Bad : Prop where
+  branch : ((P : Prop) → P → P) → Bad
+
+bad : Bad
+bad = branch (λ P p → p)
+
+no-bad : Bad → ⊥
+no-bad (branch x) = no-bad (x Bad bad)
+
+very-bad : ⊥
+very-bad = no-bad bad

Notice that the no-bad (branch x) clause uses the recursion no-bad (x Bad bad), which is only valid with the predicative assumption. So, having this predicative assumption actually proves false for Prop, so for Prop, we need to patch the termination checker to ban this rule. So, how hard is it to patch the termination checker?

Coq and Lean have a similar problem, but they are generating eliminators for inductive definitions, so they can generate the correct eliminator for Prop, instead of patching the termination checker. Then, Coq carefully implements a comparison function for size-decreasing arguments (this means eliminators are not the "most primitive" thing in Coq, but the termination checker is also part of it. I got this piece of information from Lysxia and Meven Lennon-Bertrand). In Coq, the eliminator for Bad is

Bad_ind : forall P : Prop,
+    ((forall p : Prop, p -> p) -> P) ->
+    Bad -> P

Note that there is no recursive arguments, so there is no recursion allowed.

Now, this sounds like just adding some if statements to the termination checker, but the situation is actually worse. In Agda, metavariables are pervasive, like the following code is partially accepted:

data Bad : Prop where
+  b : ((P : { }0) → P → P) → Bad

Agda will not fail on this code, but then what to do in the termination checker is really unclear. If you're using a termination checker, you want to get rid of impredicativity of Prop! This eliminates the need of a universe-based irrelevance.

Alternative ways to impredicativity

We may use axioms to get impredicativity. Suppose we define (since we no longer have it in the language) Prop := Σ (A : Type) (isProp A), there are two different axioms that imply impredicativity of Prop:

If we think of the right way of doing math is to work with classical axioms, why on earth are we forging a weaker theorem as part of the language?

`,28)]))}const u=a(n,[["render",o]]);export{k as __pageData,u as default}; diff --git a/assets/blog_index-unification.md.8JIbTjsd.js b/assets/blog_index-unification.md.8JIbTjsd.js new file mode 100644 index 0000000..62015c1 --- /dev/null +++ b/assets/blog_index-unification.md.8JIbTjsd.js @@ -0,0 +1,7 @@ +import{_ as t,c as a,a2 as n,o}from"./chunks/framework.CoXjB5sU.js";const u=JSON.parse('{"title":"Index unification and forced patterns in Aya","description":"","frontmatter":{},"headers":[],"relativePath":"blog/index-unification.md","filePath":"blog/index-unification.md","lastUpdated":1661920240000}'),i={name:"blog/index-unification.md"};function s(c,e,d,r,l,p){return o(),a("div",null,e[0]||(e[0]=[n(`

Index unification and forced patterns in Aya

Aya implements a version of index unification algorithm that allows emission of obvious patterns. Here's an example. Consider the famous "sized-vector" Vec (n : Nat) (A : Type) definition, and we can perform some pattern matching:

len : ∀ {A} -> (n : Nat) -> Vec n A -> Nat
+len a vnil = 0
+len a (vcons _ x) = suc (len _ x)

This code may seem obviously correct, but why would I write about it if it's so simple? 😉 Let's run the type checking in our head, clause by clause and pattern by pattern.

  1. The first pattern in the first clause, a, is a valid pattern for Nat. This means we will substitute the codomain of the pattern matching with [a/n], where n is the corresponding name in the telescope and a is the term corresponding to the pattern.
  2. The second pattern in the first clause, vnil, is a pattern for Vec zero A. However, the expected type is Vec a A, which does not match the type of the pattern.

So, here is the problem! The well-typed version of the program is actually:

len : ∀ {A} -> (n : Nat) -> Vec n A -> Nat
+len zero vnil = 0
+len (suc a) (vcons _ x) = suc (len a x)

However, isn't it obvious that the first pattern in the first clause must be zero? It would be nice if the type checker can figure this out by itself. In fact, both Agda and Idris can do this! In Agda, the feature is called "dotted patterns" in the documentation and "inaccessible patterns" in the paper. I will prefer calling it "forced patterns" because the patterns are actually accessible (in the sense that the bindings in the patterns are used) and does not use the Agda dot syntax.

Forced patterns are not easy to implement. The simplest pattern type checking algorithm can be quite straightforward: we check the type of the pattern, add the bindings to the context so we can type the rest of the telescope, and check the body of the clause. With forced patterns, we will need to change the existing well-typed variable patterns into constructor patterns, so the algorithm becomes stateful.

In Aya, I introduced the concept of "meta patteriables" which is a funny reference to "meta variables" used in unification in conversion check.

The so-called "meta patteriables"

Related PR: #198

When we see a variable pattern, we transform it into a MetaPat which is a "unification variable" pattern that can be "solved" into another pattern. A reference to a MetaPat is converted into a special meta variable that has a mutable reference to the MetaPat (this can be replaced by a mutable map in the type checking state when you need purity, but I prefer mutable references for implementation simplicity).

When we are type checking a pattern of type D a for D an indexed inductive family and the expected type is D b where b is the special meta variable, we claim that b is solved to a, and the MetaPat that corresponds to b will be transformed into a when we finalize the type checking results.

There are two more cases to deal with:

  1. In case a MetaPat is not "solved", we just let it be a variable pattern.
  2. In case a MetaPat is "solved" more than once, we must make sure the solutions are identical.

Note that a MetaPat may contain bindings, but these bindings are already from the current context, so we do not need to add them again to the context.

Now, let's run the new algorithm:

len : ∀ {A} -> (n : Nat) -> Vec n A -> Nat
+len a vnil = 0
+len a (vcons _ x) = suc (len _ x)
  1. The first pattern in the first clause, a, is a valid pattern for Nat, so we generate a MetaPat(a) and substitute the codomain with MetaPatRef(a), e.g. Vec MetaPatRef(a) A -> Nat.
  2. The second pattern in the first clause, vnil, is a pattern for Vec zero A. The expected type is Vec MetaPatRef(a) A, and we solve MetaPat(a) to zero.
  3. Now we check the body and finalize the clause. Since a is solved to zero, we generate the well-typed clause len zero vnil = 0 which is exactly what we need.

Thanks for reading!

`,21)]))}const f=t(i,[["render",s]]);export{u as __pageData,f as default}; diff --git a/assets/blog_index-unification.md.8JIbTjsd.lean.js b/assets/blog_index-unification.md.8JIbTjsd.lean.js new file mode 100644 index 0000000..62015c1 --- /dev/null +++ b/assets/blog_index-unification.md.8JIbTjsd.lean.js @@ -0,0 +1,7 @@ +import{_ as t,c as a,a2 as n,o}from"./chunks/framework.CoXjB5sU.js";const u=JSON.parse('{"title":"Index unification and forced patterns in Aya","description":"","frontmatter":{},"headers":[],"relativePath":"blog/index-unification.md","filePath":"blog/index-unification.md","lastUpdated":1661920240000}'),i={name:"blog/index-unification.md"};function s(c,e,d,r,l,p){return o(),a("div",null,e[0]||(e[0]=[n(`

Index unification and forced patterns in Aya

Aya implements a version of index unification algorithm that allows emission of obvious patterns. Here's an example. Consider the famous "sized-vector" Vec (n : Nat) (A : Type) definition, and we can perform some pattern matching:

len : ∀ {A} -> (n : Nat) -> Vec n A -> Nat
+len a vnil = 0
+len a (vcons _ x) = suc (len _ x)

This code may seem obviously correct, but why would I write about it if it's so simple? 😉 Let's run the type checking in our head, clause by clause and pattern by pattern.

  1. The first pattern in the first clause, a, is a valid pattern for Nat. This means we will substitute the codomain of the pattern matching with [a/n], where n is the corresponding name in the telescope and a is the term corresponding to the pattern.
  2. The second pattern in the first clause, vnil, is a pattern for Vec zero A. However, the expected type is Vec a A, which does not match the type of the pattern.

So, here is the problem! The well-typed version of the program is actually:

len : ∀ {A} -> (n : Nat) -> Vec n A -> Nat
+len zero vnil = 0
+len (suc a) (vcons _ x) = suc (len a x)

However, isn't it obvious that the first pattern in the first clause must be zero? It would be nice if the type checker can figure this out by itself. In fact, both Agda and Idris can do this! In Agda, the feature is called "dotted patterns" in the documentation and "inaccessible patterns" in the paper. I will prefer calling it "forced patterns" because the patterns are actually accessible (in the sense that the bindings in the patterns are used) and does not use the Agda dot syntax.

Forced patterns are not easy to implement. The simplest pattern type checking algorithm can be quite straightforward: we check the type of the pattern, add the bindings to the context so we can type the rest of the telescope, and check the body of the clause. With forced patterns, we will need to change the existing well-typed variable patterns into constructor patterns, so the algorithm becomes stateful.

In Aya, I introduced the concept of "meta patteriables" which is a funny reference to "meta variables" used in unification in conversion check.

The so-called "meta patteriables"

Related PR: #198

When we see a variable pattern, we transform it into a MetaPat which is a "unification variable" pattern that can be "solved" into another pattern. A reference to a MetaPat is converted into a special meta variable that has a mutable reference to the MetaPat (this can be replaced by a mutable map in the type checking state when you need purity, but I prefer mutable references for implementation simplicity).

When we are type checking a pattern of type D a for D an indexed inductive family and the expected type is D b where b is the special meta variable, we claim that b is solved to a, and the MetaPat that corresponds to b will be transformed into a when we finalize the type checking results.

There are two more cases to deal with:

  1. In case a MetaPat is not "solved", we just let it be a variable pattern.
  2. In case a MetaPat is "solved" more than once, we must make sure the solutions are identical.

Note that a MetaPat may contain bindings, but these bindings are already from the current context, so we do not need to add them again to the context.

Now, let's run the new algorithm:

len : ∀ {A} -> (n : Nat) -> Vec n A -> Nat
+len a vnil = 0
+len a (vcons _ x) = suc (len _ x)
  1. The first pattern in the first clause, a, is a valid pattern for Nat, so we generate a MetaPat(a) and substitute the codomain with MetaPatRef(a), e.g. Vec MetaPatRef(a) A -> Nat.
  2. The second pattern in the first clause, vnil, is a pattern for Vec zero A. The expected type is Vec MetaPatRef(a) A, and we solve MetaPat(a) to zero.
  3. Now we check the body and finalize the clause. Since a is solved to zero, we generate the well-typed clause len zero vnil = 0 which is exactly what we need.

Thanks for reading!

`,21)]))}const f=t(i,[["render",s]]);export{u as __pageData,f as default}; diff --git a/assets/blog_index.md.DFYRtLrm.js b/assets/blog_index.md.DFYRtLrm.js new file mode 100644 index 0000000..5ac2d80 --- /dev/null +++ b/assets/blog_index.md.DFYRtLrm.js @@ -0,0 +1 @@ +import{_ as t,c as o,j as e,a as s,o as r}from"./chunks/framework.CoXjB5sU.js";const f=JSON.parse('{"title":"Aya blogs","description":"","frontmatter":{},"headers":[],"relativePath":"blog/index.md","filePath":"blog/index.md","lastUpdated":1662566075000}'),n={name:"blog/index.md"};function l(i,a,d,c,p,b){return r(),o("div",null,a[0]||(a[0]=[e("h1",{id:"aya-blogs",tabindex:"-1"},[s("Aya blogs "),e("a",{class:"header-anchor",href:"#aya-blogs","aria-label":'Permalink to "Aya blogs"'},"​")],-1),e("p",null,"See the sidebar 👈 for the list of blog posts.",-1),e("p",null,"Note that some posts are written before some breaking syntax changes. The code examples may not work with the latest version of Aya.",-1)]))}const h=t(n,[["render",l]]);export{f as __pageData,h as default}; diff --git a/assets/blog_index.md.DFYRtLrm.lean.js b/assets/blog_index.md.DFYRtLrm.lean.js new file mode 100644 index 0000000..5ac2d80 --- /dev/null +++ b/assets/blog_index.md.DFYRtLrm.lean.js @@ -0,0 +1 @@ +import{_ as t,c as o,j as e,a as s,o as r}from"./chunks/framework.CoXjB5sU.js";const f=JSON.parse('{"title":"Aya blogs","description":"","frontmatter":{},"headers":[],"relativePath":"blog/index.md","filePath":"blog/index.md","lastUpdated":1662566075000}'),n={name:"blog/index.md"};function l(i,a,d,c,p,b){return r(),o("div",null,a[0]||(a[0]=[e("h1",{id:"aya-blogs",tabindex:"-1"},[s("Aya blogs "),e("a",{class:"header-anchor",href:"#aya-blogs","aria-label":'Permalink to "Aya blogs"'},"​")],-1),e("p",null,"See the sidebar 👈 for the list of blog posts.",-1),e("p",null,"Note that some posts are written before some breaking syntax changes. The code examples may not work with the latest version of Aya.",-1)]))}const h=t(n,[["render",l]]);export{f as __pageData,h as default}; diff --git a/assets/blog_lang-exts.md.DfBlE6eJ.js b/assets/blog_lang-exts.md.DfBlE6eJ.js new file mode 100644 index 0000000..82971cf --- /dev/null +++ b/assets/blog_lang-exts.md.DfBlE6eJ.js @@ -0,0 +1 @@ +import{_ as a,c as t,a2 as s,o as i}from"./chunks/framework.CoXjB5sU.js";const g=JSON.parse('{"title":"Haskell or Agda style extensions","description":"","frontmatter":{},"headers":[],"relativePath":"blog/lang-exts.md","filePath":"blog/lang-exts.md","lastUpdated":1662566075000}'),o={name:"blog/lang-exts.md"};function n(r,e,l,c,u,d){return i(),t("div",null,e[0]||(e[0]=[s('

Haskell or Agda style extensions

In Haskell, you can do {-# LANGUAGE TypeFamilies #-}, and similarly in Agda you can {-# OPTIONS --two-levels #-}. These "pragma" can also be specified via command line arguments. Since Haskell is too weak and even basic features need extensions, I'll be avoiding talking about it and stick to Agda.

Agda's extensions

The purpose of these pragma is threefold:

One special pragma is to ensure that no known inconsistent flag or combination of flags is turned on -- --safe. Let's discuss it later.

The current status of Agda libraries, that having separate cubical, HoTT library, and standard library, implementing the basic features individually, is a significant evidence that Agda is barely a programming language, but a collection of programming languages that share a lot in common and have good interoperability. Each flag that enables a certain language feature makes Agda a different language, and it is difficult in general to make two different language source-to-source compatible (see Kotlin-Java, Scala-Java, etc).

It is good to keep your language evolving like Agda (adding new features aggressively), and indeed Agda is the proof assistant with the richest set of language features I've known so far. However, this also negatively impacts Agda's reputation to some extent, that people say it's an experiment in type theory. Well, maybe it's not a negative impact, but it prevents big customers (such as Mathematicians looking for a tool to formalize math) from choosing the language. At least, we don't want this to happen to our language.

Aya's choice?

So, we will not introduce any "feature" flags, and will have only one base library. Aya will be one language, its features are its features. If we decide on removing a feature, then we remove it from the language (not going to keep it as an optional flag). If we decide on adding a feature, we add it and it should be available without any options.

It should still be encouraged to add some fancy, experimental features, but I think they should stay in branches or forks and will be either enlisted to the language or abandoned eventually.

However, the "parameters" part is not as bad. For example, it is very easy to allow type-in-type in the type checker -- we just disable the level solver. This is useful when the level solver prevents us from experimenting something classical using our language features but unfortunately the level solver is just unhappy with something minor. We can also like tweak the conversion checking algorithm we use, like we can use a simpler one that only solves first-order equations or we can enable the full-blown pattern unification algorithm. Verbosity levels, can also be seen as such parameter, and it's extremely useful for debugging the compiler. So we can apply that.

Safe flag?

To be honest, it's hard to decide on a semantic of the word "safe", and relate that to the Agda pragma --safe. To me, it means "logical consistency", and if we can set --safe as the last argument of an Agda file, it should be guaranteed by Agda that it cannot provide you a proof of false. There are many related discussion in the Agda issue tracker that talks 'bout how should --safe behave. Sometimes it fits my guess (for logical consistency), sometimes it implies more stuffs.

Anyway, a "logical consistency" flag seems useful, and will probably appear in Aya.

For disabling or enabling some checks, if we disable a check that is required to be consistent, then it should break --safe. I think we will of course enable all of these checks by default, so exploiting the disabledness of a check can lead to inconsistency eventually. So, we can use an "unsafe" flag to ensure that our language is only unsafe when we want it to be. It is quite meaningful as well to have an "unsafe" mode, from a real-world programming perspective.

Conclusion

We'll have a language, with some flags that tweaks the parameters of some algorithms (which are no-harm), and some flags for disabling some checks (which will lead to an error at the end of tycking), and an unsafe flag that enables a set of features such as sorry and suppresses the error of disabling checks.

Library Design

Speaking of the base library design, I have some vague ideas in mind. I'd like it to be split into three parts (not sure if we're gonna make it three modules inside one stdlib or three standalone libraries):

Then, we can use these libraries on-demand.

',22)]))}const f=a(o,[["render",n]]);export{g as __pageData,f as default}; diff --git a/assets/blog_lang-exts.md.DfBlE6eJ.lean.js b/assets/blog_lang-exts.md.DfBlE6eJ.lean.js new file mode 100644 index 0000000..82971cf --- /dev/null +++ b/assets/blog_lang-exts.md.DfBlE6eJ.lean.js @@ -0,0 +1 @@ +import{_ as a,c as t,a2 as s,o as i}from"./chunks/framework.CoXjB5sU.js";const g=JSON.parse('{"title":"Haskell or Agda style extensions","description":"","frontmatter":{},"headers":[],"relativePath":"blog/lang-exts.md","filePath":"blog/lang-exts.md","lastUpdated":1662566075000}'),o={name:"blog/lang-exts.md"};function n(r,e,l,c,u,d){return i(),t("div",null,e[0]||(e[0]=[s('

Haskell or Agda style extensions

In Haskell, you can do {-# LANGUAGE TypeFamilies #-}, and similarly in Agda you can {-# OPTIONS --two-levels #-}. These "pragma" can also be specified via command line arguments. Since Haskell is too weak and even basic features need extensions, I'll be avoiding talking about it and stick to Agda.

Agda's extensions

The purpose of these pragma is threefold:

One special pragma is to ensure that no known inconsistent flag or combination of flags is turned on -- --safe. Let's discuss it later.

The current status of Agda libraries, that having separate cubical, HoTT library, and standard library, implementing the basic features individually, is a significant evidence that Agda is barely a programming language, but a collection of programming languages that share a lot in common and have good interoperability. Each flag that enables a certain language feature makes Agda a different language, and it is difficult in general to make two different language source-to-source compatible (see Kotlin-Java, Scala-Java, etc).

It is good to keep your language evolving like Agda (adding new features aggressively), and indeed Agda is the proof assistant with the richest set of language features I've known so far. However, this also negatively impacts Agda's reputation to some extent, that people say it's an experiment in type theory. Well, maybe it's not a negative impact, but it prevents big customers (such as Mathematicians looking for a tool to formalize math) from choosing the language. At least, we don't want this to happen to our language.

Aya's choice?

So, we will not introduce any "feature" flags, and will have only one base library. Aya will be one language, its features are its features. If we decide on removing a feature, then we remove it from the language (not going to keep it as an optional flag). If we decide on adding a feature, we add it and it should be available without any options.

It should still be encouraged to add some fancy, experimental features, but I think they should stay in branches or forks and will be either enlisted to the language or abandoned eventually.

However, the "parameters" part is not as bad. For example, it is very easy to allow type-in-type in the type checker -- we just disable the level solver. This is useful when the level solver prevents us from experimenting something classical using our language features but unfortunately the level solver is just unhappy with something minor. We can also like tweak the conversion checking algorithm we use, like we can use a simpler one that only solves first-order equations or we can enable the full-blown pattern unification algorithm. Verbosity levels, can also be seen as such parameter, and it's extremely useful for debugging the compiler. So we can apply that.

Safe flag?

To be honest, it's hard to decide on a semantic of the word "safe", and relate that to the Agda pragma --safe. To me, it means "logical consistency", and if we can set --safe as the last argument of an Agda file, it should be guaranteed by Agda that it cannot provide you a proof of false. There are many related discussion in the Agda issue tracker that talks 'bout how should --safe behave. Sometimes it fits my guess (for logical consistency), sometimes it implies more stuffs.

Anyway, a "logical consistency" flag seems useful, and will probably appear in Aya.

For disabling or enabling some checks, if we disable a check that is required to be consistent, then it should break --safe. I think we will of course enable all of these checks by default, so exploiting the disabledness of a check can lead to inconsistency eventually. So, we can use an "unsafe" flag to ensure that our language is only unsafe when we want it to be. It is quite meaningful as well to have an "unsafe" mode, from a real-world programming perspective.

Conclusion

We'll have a language, with some flags that tweaks the parameters of some algorithms (which are no-harm), and some flags for disabling some checks (which will lead to an error at the end of tycking), and an unsafe flag that enables a set of features such as sorry and suppresses the error of disabling checks.

Library Design

Speaking of the base library design, I have some vague ideas in mind. I'd like it to be split into three parts (not sure if we're gonna make it three modules inside one stdlib or three standalone libraries):

Then, we can use these libraries on-demand.

',22)]))}const f=a(o,[["render",n]]);export{g as __pageData,f as default}; diff --git a/assets/blog_path-elab.md.DMxfi4CO.js b/assets/blog_path-elab.md.DMxfi4CO.js new file mode 100644 index 0000000..e44e2bc --- /dev/null +++ b/assets/blog_path-elab.md.DMxfi4CO.js @@ -0,0 +1,21 @@ +import{_ as a,c as t,a2 as n,o as s}from"./chunks/framework.CoXjB5sU.js";const u=JSON.parse('{"title":"Elaboration of the \\"extension\\" type","description":"","frontmatter":{},"headers":[],"relativePath":"blog/path-elab.md","filePath":"blog/path-elab.md","lastUpdated":1679673438000}'),i={name:"blog/path-elab.md"};function o(p,e,l,r,c,h){return s(),t("div",null,e[0]||(e[0]=[n(`

Elaboration of the "extension" type

Aya uses the so-called "extension" type (probably first-appeared here) as a generalized version of path type.

Instead of using the conventional path type, as in Cubical Agda:

This type looks good, but it does not scale to higher dimensions. Consider, for example, the type of a square with four faces specified (from Agda's cubical library):

Square :
+  {a₀₀ a₀₁ : A} (a₀₋ : a₀₀ ≡ a₀₁)
+  {a₁₀ a₁₁ : A} (a₁₋ : a₁₀ ≡ a₁₁)
+  (a₋₀ : a₀₀ ≡ a₁₀) (a₋₁ : a₀₁ ≡ a₁₁)
+  → Type _
+Square a₀₋ a₁₋ a₋₀ a₋₁ = PathP (λ i → a₋₀ i ≡ a₋₁ i) a₀₋ a₁₋

It gets even worse when the type is heterogeneous:

SquareP :
+  (A : I → I → Type ℓ)
+  {a₀₀ : A i0 i0} {a₀₁ : A i0 i1} (a₀₋ : PathP (λ j → A i0 j) a₀₀ a₀₁)
+  {a₁₀ : A i1 i0} {a₁₁ : A i1 i1} (a₁₋ : PathP (λ j → A i1 j) a₁₀ a₁₁)
+  (a₋₀ : PathP (λ i → A i i0) a₀₀ a₁₀) (a₋₁ : PathP (λ i → A i i1) a₀₁ a₁₁)
+  → Type ℓ
+SquareP A a₀₋ a₁₋ a₋₀ a₋₁ = PathP (λ i → PathP (λ j → A i j) (a₋₀ i) (a₋₁ i)) a₀₋ a₁₋

We have decided to use a partial element to represent these faces, and so we can freely add or delete these a face, without having to explicitly write down all faces for generality. This leads to the following syntax:

--------  ↓ type           ↓ the "i = 0" end is b
+[| i |] (A i) {| i := a | ~ i := b |}
+-- ^ interval         ^ the "i = 1" end is a

The above type is equivalent to PathP (λ i → A i) a b. We may use this to simplify the type signature of path concatenation:

def concat {A : Type}
+  (p : [| i |] A {| |})
+  (q : [| i |] A {| ~ i := p 1 |})
+  : [| i |] A {| ~ i := p 0 | i := q 1 |}

It has fewer parameters than the conventional version:

def concat {A : Type}
+  {a b c : A}
+  (p : Path A a b)
+  (q : Path A b c)
+  : Path A a c

Now, how to implement this type? We have decided to overload lambdas and expressions as Cubical Agda did, but we have encountered several problems. Here's the story, in chronological order.

Below, we use "type checking" and we actually mean "elaboration".

First attempt

Principle: do not annotate the terms (including variable references) with types, because this is going to harm efficiency and the code that tries to generate terms (now they'll have to generate the types as well, pain!).

Problem: reduction of path application is type-directed, like p 1 will reduce according to the type of p.

Solution: annotate the path applications instead. Every time we do type checking & we get a term of path type, we "η-expand" it into a normal lambda expression with a path application inside. This secures the reduction of path applications.

New Problem: we expand too much. In case we want to check the type of term against a path type, the term is actually η-expanded and has a Π-type. So, we have the manually write path lambdas everywhere, e.g. given p : Path A a b, and only λ i → p i is a valid term of type Path A a b, not p (which is internally a lambda).

Lesson: we need to preserve the types somehow, generate path applications only when necessary.

Second attempt

New Solution: when checking something against a path type, we directly apply the boundary checks, instead of trying to invoke synthesize and unify the types. This eliminates a lot of λ i → p i problems.

New Problem: this is incompatible with implicit arguments. Consider the following problem:

The new solution will try to apply the boundary before inserting the implicit arguments, which leads to type-incorrect terms.

Lesson: we probably should not change the bidirectional type checking algorithm too much.

Third attempt

New Solution: the type information is known in the bidirectional type checking anyway, so we only generate path applications during the type checking of application terms.

This has worked so far, with some unsolved problems (yet to be discussed):

If you have any thoughts, feel free to reach out :)

Update (2023-03-24)

The implementation has been updated to solve some the above problems partially. Essentially, we need to do one thing: coercive subtyping. Since the type checking already respects the type (say, does not change the type), it remains to insert an η-expansion when the subtyping is invoked. We also need to store the boundary information in the path application term to have simple normalization algorithm.

Carlo Angiuli told me that in cooltt, the path type is decoded (in the sense of the universe à la Tarski el operator) into a Π-type that returns a cubical subtype, and since el is not required to be injective, this should be fine. At first, I was worried about the fibrancy of the path type, because a Π-type into a subtype is not fibrant, but it turns out that this is unrelated. We don't talk about the fibrancy of the types, but only the fibrancy of the type codes.

`,36)]))}const b=a(i,[["render",o]]);export{u as __pageData,b as default}; diff --git a/assets/blog_path-elab.md.DMxfi4CO.lean.js b/assets/blog_path-elab.md.DMxfi4CO.lean.js new file mode 100644 index 0000000..e44e2bc --- /dev/null +++ b/assets/blog_path-elab.md.DMxfi4CO.lean.js @@ -0,0 +1,21 @@ +import{_ as a,c as t,a2 as n,o as s}from"./chunks/framework.CoXjB5sU.js";const u=JSON.parse('{"title":"Elaboration of the \\"extension\\" type","description":"","frontmatter":{},"headers":[],"relativePath":"blog/path-elab.md","filePath":"blog/path-elab.md","lastUpdated":1679673438000}'),i={name:"blog/path-elab.md"};function o(p,e,l,r,c,h){return s(),t("div",null,e[0]||(e[0]=[n(`

Elaboration of the "extension" type

Aya uses the so-called "extension" type (probably first-appeared here) as a generalized version of path type.

Instead of using the conventional path type, as in Cubical Agda:

This type looks good, but it does not scale to higher dimensions. Consider, for example, the type of a square with four faces specified (from Agda's cubical library):

Square :
+  {a₀₀ a₀₁ : A} (a₀₋ : a₀₀ ≡ a₀₁)
+  {a₁₀ a₁₁ : A} (a₁₋ : a₁₀ ≡ a₁₁)
+  (a₋₀ : a₀₀ ≡ a₁₀) (a₋₁ : a₀₁ ≡ a₁₁)
+  → Type _
+Square a₀₋ a₁₋ a₋₀ a₋₁ = PathP (λ i → a₋₀ i ≡ a₋₁ i) a₀₋ a₁₋

It gets even worse when the type is heterogeneous:

SquareP :
+  (A : I → I → Type ℓ)
+  {a₀₀ : A i0 i0} {a₀₁ : A i0 i1} (a₀₋ : PathP (λ j → A i0 j) a₀₀ a₀₁)
+  {a₁₀ : A i1 i0} {a₁₁ : A i1 i1} (a₁₋ : PathP (λ j → A i1 j) a₁₀ a₁₁)
+  (a₋₀ : PathP (λ i → A i i0) a₀₀ a₁₀) (a₋₁ : PathP (λ i → A i i1) a₀₁ a₁₁)
+  → Type ℓ
+SquareP A a₀₋ a₁₋ a₋₀ a₋₁ = PathP (λ i → PathP (λ j → A i j) (a₋₀ i) (a₋₁ i)) a₀₋ a₁₋

We have decided to use a partial element to represent these faces, and so we can freely add or delete these a face, without having to explicitly write down all faces for generality. This leads to the following syntax:

--------  ↓ type           ↓ the "i = 0" end is b
+[| i |] (A i) {| i := a | ~ i := b |}
+-- ^ interval         ^ the "i = 1" end is a

The above type is equivalent to PathP (λ i → A i) a b. We may use this to simplify the type signature of path concatenation:

def concat {A : Type}
+  (p : [| i |] A {| |})
+  (q : [| i |] A {| ~ i := p 1 |})
+  : [| i |] A {| ~ i := p 0 | i := q 1 |}

It has fewer parameters than the conventional version:

def concat {A : Type}
+  {a b c : A}
+  (p : Path A a b)
+  (q : Path A b c)
+  : Path A a c

Now, how to implement this type? We have decided to overload lambdas and expressions as Cubical Agda did, but we have encountered several problems. Here's the story, in chronological order.

Below, we use "type checking" and we actually mean "elaboration".

First attempt

Principle: do not annotate the terms (including variable references) with types, because this is going to harm efficiency and the code that tries to generate terms (now they'll have to generate the types as well, pain!).

Problem: reduction of path application is type-directed, like p 1 will reduce according to the type of p.

Solution: annotate the path applications instead. Every time we do type checking & we get a term of path type, we "η-expand" it into a normal lambda expression with a path application inside. This secures the reduction of path applications.

New Problem: we expand too much. In case we want to check the type of term against a path type, the term is actually η-expanded and has a Π-type. So, we have the manually write path lambdas everywhere, e.g. given p : Path A a b, and only λ i → p i is a valid term of type Path A a b, not p (which is internally a lambda).

Lesson: we need to preserve the types somehow, generate path applications only when necessary.

Second attempt

New Solution: when checking something against a path type, we directly apply the boundary checks, instead of trying to invoke synthesize and unify the types. This eliminates a lot of λ i → p i problems.

New Problem: this is incompatible with implicit arguments. Consider the following problem:

The new solution will try to apply the boundary before inserting the implicit arguments, which leads to type-incorrect terms.

Lesson: we probably should not change the bidirectional type checking algorithm too much.

Third attempt

New Solution: the type information is known in the bidirectional type checking anyway, so we only generate path applications during the type checking of application terms.

This has worked so far, with some unsolved problems (yet to be discussed):

If you have any thoughts, feel free to reach out :)

Update (2023-03-24)

The implementation has been updated to solve some the above problems partially. Essentially, we need to do one thing: coercive subtyping. Since the type checking already respects the type (say, does not change the type), it remains to insert an η-expansion when the subtyping is invoked. We also need to store the boundary information in the path application term to have simple normalization algorithm.

Carlo Angiuli told me that in cooltt, the path type is decoded (in the sense of the universe à la Tarski el operator) into a Π-type that returns a cubical subtype, and since el is not required to be injective, this should be fine. At first, I was worried about the fibrancy of the path type, because a Π-type into a subtype is not fibrant, but it turns out that this is unrelated. We don't talk about the fibrancy of the types, but only the fibrancy of the type codes.

`,36)]))}const b=a(i,[["render",o]]);export{u as __pageData,b as default}; diff --git a/assets/blog_pathcon-elab.md.qxT9XSmx.js b/assets/blog_pathcon-elab.md.qxT9XSmx.js new file mode 100644 index 0000000..3fae429 --- /dev/null +++ b/assets/blog_pathcon-elab.md.qxT9XSmx.js @@ -0,0 +1,10 @@ +import{_ as t,c as m,a2 as a,j as s,a as l,o as e}from"./chunks/framework.CoXjB5sU.js";const d=JSON.parse('{"title":"Elaboration of path constructors","description":"","frontmatter":{},"headers":[],"relativePath":"blog/pathcon-elab.md","filePath":"blog/pathcon-elab.md","lastUpdated":1717138752000}'),p={name:"blog/pathcon-elab.md"};function r(c,n,i,o,h,g){return e(),m("div",null,n[0]||(n[0]=[a('

Elaboration of path constructors

This is not a blog post, but a reference for developers and type theory implementers.

Content below assumes knowledge on cubical type theory, for example the extension type and higher inductive types.

Syntax

Flattening

Used in higher inductive type elaboration.

A[i]X{}AΠ(x:X)Yflatten(A):=A\\newcommand{\\flattenOp}[1]{\\textsf{flatten}(#1)} \\cfrac{A \\ne [\\overline i] X\\set{\\cdots} \\quad A\\ne Π(x:X)→ Y} {\\flattenOp{A} := A}

flatten(X):=[j]Y{φu}flatten([i]X{φu}):=[i,j]Y{φu @ j,φu}\\newcommand{\\flattenOp}[1]{\\textsf{flatten}(#1)} \\cfrac {\\flattenOp{X}:=[\\overline j] Y\\set{\\overline{φ'↦ u'}}} {\\flattenOp{[\\overline i] X\\set{\\overline{φ↦ u}}} := [\\overline i,\\overline j] Y\\set{\\overline{φ'↦ u'~@~\\overline j},\\overline{φ↦ u}}}

flatten(Π(x:X)Y):=Π(x:X)flatten(Y)\\newcommand{\\flattenOp}[1]{\\textsf{flatten}(#1)} \\cfrac{} {\\flattenOp{Π(x:X)→ Y}:=Π(x:X)→ \\flattenOp{Y}}

Example

',11),s("p",{class:"katex-block"},[s("span",{class:"katex-display"},[s("span",{class:"katex"},[s("span",{class:"katex-mathml"},[s("math",{xmlns:"http://www.w3.org/1998/Math/MathML",display:"block"},[s("semantics",null,[s("mtable",{rowspacing:"0.25em",columnalign:"right left",columnspacing:"0em"},[s("mtr",null,[s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mtext",{mathvariant:"sans-serif"},"isProp"),s("mo",{stretchy:"false"},"("),s("mi",null,"A"),s("mo",{stretchy:"false"},")")])])]),s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mrow"),s("mo",null,":"),s("mo",null,"="),s("mi",{mathvariant:"normal"},"Π"),s("mo",{stretchy:"false"},"("),s("mi",null,"a"),s("mtext",null," "),s("mi",null,"b"),s("mo",null,":"),s("mi",null,"A"),s("mo",{stretchy:"false"},")"),s("mo",null,"→"),s("mo",{stretchy:"false"},"["),s("mi",null,"i"),s("mo",{stretchy:"false"},"]"),s("mi",null,"A"),s("mo",{stretchy:"false"},"{"),s("mtext",null," "),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"a"),s("mo",{separator:"true"},","),s("mi",{mathvariant:"normal"},"¬"),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"b"),s("mtext",null," "),s("mo",{stretchy:"false"},"}")])])])]),s("mtr",null,[s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mtext",{mathvariant:"sans-serif"},"isSet"),s("mo",{stretchy:"false"},"("),s("mi",null,"A"),s("mo",{stretchy:"false"},")")])])]),s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mrow"),s("mo",null,":"),s("mo",null,"="),s("mi",{mathvariant:"normal"},"Π"),s("mo",{stretchy:"false"},"("),s("mi",null,"a"),s("mtext",null," "),s("mi",null,"b"),s("mo",null,":"),s("mi",null,"A"),s("mo",{stretchy:"false"},")"),s("mo",null,"→"),s("mtext",{mathvariant:"sans-serif"},"isProp"),s("mo",{stretchy:"false"},"("),s("mo",{stretchy:"false"},"["),s("mi",null,"i"),s("mo",{stretchy:"false"},"]"),s("mi",null,"A"),s("mo",{stretchy:"false"},"{"),s("mtext",null," "),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"a"),s("mo",{separator:"true"},","),s("mi",{mathvariant:"normal"},"¬"),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"b"),s("mtext",null," "),s("mo",{stretchy:"false"},"}"),s("mo",{stretchy:"false"},")")])])])])]),s("annotation",{encoding:"application/x-tex"},"\\begin{align*} \\textsf{isProp}(A)&:=Π(a~b:A) → [i]A\\set{i↦ a,¬ i↦ b}\\\\ \\textsf{isSet}(A)&:=Π(a~b:A)→\\textsf{isProp}([i]A\\set{i↦ a,¬ i↦ b})\\\\ \\end{align*} ")])])]),s("span",{class:"katex-html","aria-hidden":"true"},[s("span",{class:"base"},[s("span",{class:"strut",style:{height:"3em","vertical-align":"-1.25em"}}),s("span",{class:"mord"},[s("span",{class:"mtable"},[s("span",{class:"col-align-r"},[s("span",{class:"vlist-t vlist-t2"},[s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.75em"}},[s("span",{style:{top:"-3.91em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord text"},[s("span",{class:"mord textsf"},"isProp")]),s("span",{class:"mopen"},"("),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mclose"},")")])]),s("span",{style:{top:"-2.41em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord text"},[s("span",{class:"mord textsf"},"isSet")]),s("span",{class:"mopen"},"("),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mclose"},")")])])]),s("span",{class:"vlist-s"},"​")]),s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.25em"}},[s("span")])])])]),s("span",{class:"col-align-l"},[s("span",{class:"vlist-t vlist-t2"},[s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.75em"}},[s("span",{style:{top:"-3.91em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord"}),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},":="),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord"},"Π"),s("span",{class:"mopen"},"("),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},":"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mclose"},")"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"→"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mopen"},"["),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mclose"},"]"),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mopen"},"{"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord"},"¬"),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mclose"},"}")])]),s("span",{style:{top:"-2.41em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord"}),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},":="),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord"},"Π"),s("span",{class:"mopen"},"("),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},":"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mclose"},")"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"→"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord text"},[s("span",{class:"mord textsf"},"isProp")]),s("span",{class:"mopen"},"(["),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mclose"},"]"),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mopen"},"{"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord"},"¬"),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mclose"},"})")])])]),s("span",{class:"vlist-s"},"​")]),s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.25em"}},[s("span")])])])])])])])])])])],-1),s("p",null,[l("So the normal form of "),s("code",null,"isSet"),l(" is:")],-1),s("p",{class:"katex-block"},[s("span",{class:"katex-display"},[s("span",{class:"katex"},[s("span",{class:"katex-mathml"},[s("math",{xmlns:"http://www.w3.org/1998/Math/MathML",display:"block"},[s("semantics",null,[s("mtable",{rowspacing:"0.25em",columnalign:"right left",columnspacing:"0em"},[s("mtr",null,[s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mi",{mathvariant:"normal"},"Π"),s("mo",{stretchy:"false"},"("),s("mi",null,"a"),s("mtext",null," "),s("mi",null,"b"),s("mo",null,":"),s("mi",null,"A"),s("mo",{stretchy:"false"},")")])])]),s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mrow"),s("mo",null,"→"),s("mi",{mathvariant:"normal"},"Π"),s("mo",{stretchy:"false"},"("),s("mi",null,"p"),s("mtext",null," "),s("mi",null,"q"),s("mo",null,":"),s("mo",{stretchy:"false"},"["),s("mi",null,"i"),s("mo",{stretchy:"false"},"]"),s("mi",null,"A"),s("mo",{stretchy:"false"},"{"),s("mtext",null," "),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"a"),s("mo",{separator:"true"},","),s("mi",{mathvariant:"normal"},"¬"),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"b"),s("mtext",null," "),s("mo",{stretchy:"false"},"}"),s("mo",{stretchy:"false"},")")])])])]),s("mtr",null,[s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow")])]),s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mrow"),s("mo",null,"→"),s("mo",{fence:"false",stretchy:"true",minsize:"1.2em",maxsize:"1.2em"},"["),s("mi",null,"j"),s("mo",{fence:"false",stretchy:"true",minsize:"1.2em",maxsize:"1.2em"},"]"),s("mo",{fence:"false",stretchy:"true",minsize:"1.2em",maxsize:"1.2em"},"("),s("mo",{stretchy:"false"},"["),s("mi",null,"i"),s("mo",{stretchy:"false"},"]"),s("mi",null,"A"),s("mo",{stretchy:"false"},"{"),s("mtext",null," "),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"a"),s("mo",{separator:"true"},","),s("mi",{mathvariant:"normal"},"¬"),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"b"),s("mtext",null," "),s("mo",{stretchy:"false"},"}"),s("mo",{fence:"false",stretchy:"true",minsize:"1.2em",maxsize:"1.2em"},")"),s("mrow",null,[s("mo",{fence:"true"},"{"),s("mtext",null," "),s("mi",null,"j"),s("mo",null,"↦"),s("mi",null,"q"),s("mo",{separator:"true"},","),s("mi",{mathvariant:"normal"},"¬"),s("mi",null,"j"),s("mo",null,"↦"),s("mi",null,"p"),s("mtext",null," "),s("mo",{fence:"true"},"}")])])])])])]),s("annotation",{encoding:"application/x-tex"},"\\begin{align*} Π(a~b:A)&→Π(p~q:[i]A\\set{i↦ a,¬ i↦ b})\\\\ &→ \\big[j\\big] \\big([i]A\\set{i↦ a,¬ i↦ b}\\big) \\Set{j↦ q, ¬ j↦ p}\\\\ \\end{align*} ")])])]),s("span",{class:"katex-html","aria-hidden":"true"},[s("span",{class:"base"},[s("span",{class:"strut",style:{height:"3.01em","vertical-align":"-1.255em"}}),s("span",{class:"mord"},[s("span",{class:"mtable"},[s("span",{class:"col-align-r"},[s("span",{class:"vlist-t vlist-t2"},[s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.755em"}},[s("span",{style:{top:"-3.915em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord"},"Π"),s("span",{class:"mopen"},"("),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},":"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mclose"},")")])]),s("span",{style:{top:"-2.405em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"})])]),s("span",{class:"vlist-s"},"​")]),s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.255em"}},[s("span")])])])]),s("span",{class:"col-align-l"},[s("span",{class:"vlist-t vlist-t2"},[s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.755em"}},[s("span",{style:{top:"-3.915em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord"}),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"→"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord"},"Π"),s("span",{class:"mopen"},"("),s("span",{class:"mord mathnormal"},"p"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal",style:{"margin-right":"0.03588em"}},"q"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},":"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mopen"},"["),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mclose"},"]"),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mopen"},"{"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord"},"¬"),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mclose"},"})")])]),s("span",{style:{top:"-2.405em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord"}),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"→"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord"},[s("span",{class:"delimsizing size1"},"[")]),s("span",{class:"mord mathnormal",style:{"margin-right":"0.05724em"}},"j"),s("span",{class:"mord"},[s("span",{class:"delimsizing size1"},"]")]),s("span",{class:"mord"},[s("span",{class:"delimsizing size1"},"(")]),s("span",{class:"mopen"},"["),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mclose"},"]"),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mopen"},"{"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord"},"¬"),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mclose"},"}"),s("span",{class:"mord"},[s("span",{class:"delimsizing size1"},")")]),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"minner"},[s("span",{class:"mopen delimcenter",style:{top:"0em"}},"{"),s("span",{class:"mspace",style:{"margin-right":"0.2222em"}}),s("span",{class:"mord mathnormal",style:{"margin-right":"0.05724em"}},"j"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal",style:{"margin-right":"0.03588em"}},"q"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord"},"¬"),s("span",{class:"mord mathnormal",style:{"margin-right":"0.05724em"}},"j"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"p"),s("span",{class:"mspace",style:{"margin-right":"0.2222em"}}),s("span",{class:"mclose delimcenter",style:{top:"0em"}},"}")])])])]),s("span",{class:"vlist-s"},"​")]),s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.255em"}},[s("span")])])])])])])])])])])],-1),a('

And flattenOp(isSet(A))\\textsf{flattenOp}(\\textsf{isSet}(A)) is:

',1),s("p",{class:"katex-block"},[s("span",{class:"katex-display"},[s("span",{class:"katex"},[s("span",{class:"katex-mathml"},[s("math",{xmlns:"http://www.w3.org/1998/Math/MathML",display:"block"},[s("semantics",null,[s("mtable",{rowspacing:"0.25em",columnalign:"right left",columnspacing:"0em"},[s("mtr",null,[s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mi",{mathvariant:"normal"},"Π"),s("mo",{stretchy:"false"},"("),s("mi",null,"a"),s("mtext",null," "),s("mi",null,"b"),s("mo",null,":"),s("mi",null,"A"),s("mo",{stretchy:"false"},")")])])]),s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mrow"),s("mo",null,"→"),s("mi",{mathvariant:"normal"},"Π"),s("mo",{stretchy:"false"},"("),s("mi",null,"p"),s("mtext",null," "),s("mi",null,"q"),s("mo",null,":"),s("mo",{stretchy:"false"},"["),s("mi",null,"i"),s("mo",{stretchy:"false"},"]"),s("mi",null,"A"),s("mo",{stretchy:"false"},"{"),s("mtext",null," "),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"a"),s("mo",{separator:"true"},","),s("mi",{mathvariant:"normal"},"¬"),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"b"),s("mtext",null," "),s("mo",{stretchy:"false"},"}"),s("mo",{stretchy:"false"},")")])])])]),s("mtr",null,[s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow")])]),s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mrow"),s("mo",null,"→"),s("mo",{fence:"false",stretchy:"true",minsize:"1.2em",maxsize:"1.2em"},"["),s("mi",null,"j"),s("mtext",null," "),s("mi",null,"i"),s("mo",{fence:"false",stretchy:"true",minsize:"1.2em",maxsize:"1.2em"},"]"),s("mi",null,"A"),s("mrow",null,[s("mo",{fence:"true"},"{"),s("mtext",null," "),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"a"),s("mo",{separator:"true"},","),s("mi",{mathvariant:"normal"},"¬"),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"b"),s("mo",{separator:"true"},","),s("mi",null,"j"),s("mo",null,"↦"),s("mi",null,"q"),s("mtext",null," "),s("mi",{mathvariant:"normal"},"@"),s("mtext",null," "),s("mi",null,"i"),s("mo",{separator:"true"},","),s("mi",{mathvariant:"normal"},"¬"),s("mi",null,"j"),s("mo",null,"↦"),s("mi",null,"p"),s("mtext",null," "),s("mi",{mathvariant:"normal"},"@"),s("mtext",null," "),s("mi",null,"i"),s("mtext",null," "),s("mo",{fence:"true"},"}")])])])])])]),s("annotation",{encoding:"application/x-tex"},"\\begin{align*} Π(a~b:A)&→Π(p~q:[i]A\\set{i↦ a,¬ i↦ b})\\\\ &→ \\big[j~i\\big] A \\Set{i↦ a,¬ i↦ b,j↦ q~@~i, ¬ j↦ p~@~i}\\\\ \\end{align*} ")])])]),s("span",{class:"katex-html","aria-hidden":"true"},[s("span",{class:"base"},[s("span",{class:"strut",style:{height:"3.01em","vertical-align":"-1.255em"}}),s("span",{class:"mord"},[s("span",{class:"mtable"},[s("span",{class:"col-align-r"},[s("span",{class:"vlist-t vlist-t2"},[s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.755em"}},[s("span",{style:{top:"-3.915em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord"},"Π"),s("span",{class:"mopen"},"("),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},":"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mclose"},")")])]),s("span",{style:{top:"-2.405em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"})])]),s("span",{class:"vlist-s"},"​")]),s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.255em"}},[s("span")])])])]),s("span",{class:"col-align-l"},[s("span",{class:"vlist-t vlist-t2"},[s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.755em"}},[s("span",{style:{top:"-3.915em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord"}),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"→"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord"},"Π"),s("span",{class:"mopen"},"("),s("span",{class:"mord mathnormal"},"p"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal",style:{"margin-right":"0.03588em"}},"q"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},":"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mopen"},"["),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mclose"},"]"),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mopen"},"{"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord"},"¬"),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mclose"},"})")])]),s("span",{style:{top:"-2.405em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord"}),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"→"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord"},[s("span",{class:"delimsizing size1"},"[")]),s("span",{class:"mord mathnormal",style:{"margin-right":"0.05724em"}},"j"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mord"},[s("span",{class:"delimsizing size1"},"]")]),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"minner"},[s("span",{class:"mopen delimcenter",style:{top:"0em"}},"{"),s("span",{class:"mspace",style:{"margin-right":"0.2222em"}}),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord"},"¬"),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord mathnormal",style:{"margin-right":"0.05724em"}},"j"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal",style:{"margin-right":"0.03588em"}},"q"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord"},"@"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord"},"¬"),s("span",{class:"mord mathnormal",style:{"margin-right":"0.05724em"}},"j"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"p"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord"},"@"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2222em"}}),s("span",{class:"mclose delimcenter",style:{top:"0em"}},"}")])])])]),s("span",{class:"vlist-s"},"​")]),s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.255em"}},[s("span")])])])])])])])])])])],-1),a(`

So for example, set truncation from HoTT looks like this:

inductive SetTrunc (A : Type)
+| mk : A -> SetTrunc A
+| trunc : isSet (SetTrunc A)

The trunc constructor is elaborated to cubical syntax by flattening the type and attach the partial on the return type to the constructor, something like this:

trunc : Π (a b : SetTrunc A)
+    -> (p q : a = b)
+    -> (j i : I) -> SetTrunc A
+  { i = 1 -> a
+  ; i = 0 -> b
+  ; j = 1 -> q @ i
+  ; j = 0 -> p @ i
+  }

Aya is currently working on the so-called IApplyConfluence problem for recursive higher inductive types like SetTrunc, see this question which is a problem I'm wrapping my head around at the moment. More details will be posted later.

`,5)]))}const u=t(p,[["render",r]]);export{d as __pageData,u as default}; diff --git a/assets/blog_pathcon-elab.md.qxT9XSmx.lean.js b/assets/blog_pathcon-elab.md.qxT9XSmx.lean.js new file mode 100644 index 0000000..3fae429 --- /dev/null +++ b/assets/blog_pathcon-elab.md.qxT9XSmx.lean.js @@ -0,0 +1,10 @@ +import{_ as t,c as m,a2 as a,j as s,a as l,o as e}from"./chunks/framework.CoXjB5sU.js";const d=JSON.parse('{"title":"Elaboration of path constructors","description":"","frontmatter":{},"headers":[],"relativePath":"blog/pathcon-elab.md","filePath":"blog/pathcon-elab.md","lastUpdated":1717138752000}'),p={name:"blog/pathcon-elab.md"};function r(c,n,i,o,h,g){return e(),m("div",null,n[0]||(n[0]=[a('

Elaboration of path constructors

This is not a blog post, but a reference for developers and type theory implementers.

Content below assumes knowledge on cubical type theory, for example the extension type and higher inductive types.

Syntax

Flattening

Used in higher inductive type elaboration.

A[i]X{}AΠ(x:X)Yflatten(A):=A\\newcommand{\\flattenOp}[1]{\\textsf{flatten}(#1)} \\cfrac{A \\ne [\\overline i] X\\set{\\cdots} \\quad A\\ne Π(x:X)→ Y} {\\flattenOp{A} := A}

flatten(X):=[j]Y{φu}flatten([i]X{φu}):=[i,j]Y{φu @ j,φu}\\newcommand{\\flattenOp}[1]{\\textsf{flatten}(#1)} \\cfrac {\\flattenOp{X}:=[\\overline j] Y\\set{\\overline{φ'↦ u'}}} {\\flattenOp{[\\overline i] X\\set{\\overline{φ↦ u}}} := [\\overline i,\\overline j] Y\\set{\\overline{φ'↦ u'~@~\\overline j},\\overline{φ↦ u}}}

flatten(Π(x:X)Y):=Π(x:X)flatten(Y)\\newcommand{\\flattenOp}[1]{\\textsf{flatten}(#1)} \\cfrac{} {\\flattenOp{Π(x:X)→ Y}:=Π(x:X)→ \\flattenOp{Y}}

Example

',11),s("p",{class:"katex-block"},[s("span",{class:"katex-display"},[s("span",{class:"katex"},[s("span",{class:"katex-mathml"},[s("math",{xmlns:"http://www.w3.org/1998/Math/MathML",display:"block"},[s("semantics",null,[s("mtable",{rowspacing:"0.25em",columnalign:"right left",columnspacing:"0em"},[s("mtr",null,[s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mtext",{mathvariant:"sans-serif"},"isProp"),s("mo",{stretchy:"false"},"("),s("mi",null,"A"),s("mo",{stretchy:"false"},")")])])]),s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mrow"),s("mo",null,":"),s("mo",null,"="),s("mi",{mathvariant:"normal"},"Π"),s("mo",{stretchy:"false"},"("),s("mi",null,"a"),s("mtext",null," "),s("mi",null,"b"),s("mo",null,":"),s("mi",null,"A"),s("mo",{stretchy:"false"},")"),s("mo",null,"→"),s("mo",{stretchy:"false"},"["),s("mi",null,"i"),s("mo",{stretchy:"false"},"]"),s("mi",null,"A"),s("mo",{stretchy:"false"},"{"),s("mtext",null," "),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"a"),s("mo",{separator:"true"},","),s("mi",{mathvariant:"normal"},"¬"),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"b"),s("mtext",null," "),s("mo",{stretchy:"false"},"}")])])])]),s("mtr",null,[s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mtext",{mathvariant:"sans-serif"},"isSet"),s("mo",{stretchy:"false"},"("),s("mi",null,"A"),s("mo",{stretchy:"false"},")")])])]),s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mrow"),s("mo",null,":"),s("mo",null,"="),s("mi",{mathvariant:"normal"},"Π"),s("mo",{stretchy:"false"},"("),s("mi",null,"a"),s("mtext",null," "),s("mi",null,"b"),s("mo",null,":"),s("mi",null,"A"),s("mo",{stretchy:"false"},")"),s("mo",null,"→"),s("mtext",{mathvariant:"sans-serif"},"isProp"),s("mo",{stretchy:"false"},"("),s("mo",{stretchy:"false"},"["),s("mi",null,"i"),s("mo",{stretchy:"false"},"]"),s("mi",null,"A"),s("mo",{stretchy:"false"},"{"),s("mtext",null," "),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"a"),s("mo",{separator:"true"},","),s("mi",{mathvariant:"normal"},"¬"),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"b"),s("mtext",null," "),s("mo",{stretchy:"false"},"}"),s("mo",{stretchy:"false"},")")])])])])]),s("annotation",{encoding:"application/x-tex"},"\\begin{align*} \\textsf{isProp}(A)&:=Π(a~b:A) → [i]A\\set{i↦ a,¬ i↦ b}\\\\ \\textsf{isSet}(A)&:=Π(a~b:A)→\\textsf{isProp}([i]A\\set{i↦ a,¬ i↦ b})\\\\ \\end{align*} ")])])]),s("span",{class:"katex-html","aria-hidden":"true"},[s("span",{class:"base"},[s("span",{class:"strut",style:{height:"3em","vertical-align":"-1.25em"}}),s("span",{class:"mord"},[s("span",{class:"mtable"},[s("span",{class:"col-align-r"},[s("span",{class:"vlist-t vlist-t2"},[s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.75em"}},[s("span",{style:{top:"-3.91em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord text"},[s("span",{class:"mord textsf"},"isProp")]),s("span",{class:"mopen"},"("),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mclose"},")")])]),s("span",{style:{top:"-2.41em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord text"},[s("span",{class:"mord textsf"},"isSet")]),s("span",{class:"mopen"},"("),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mclose"},")")])])]),s("span",{class:"vlist-s"},"​")]),s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.25em"}},[s("span")])])])]),s("span",{class:"col-align-l"},[s("span",{class:"vlist-t vlist-t2"},[s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.75em"}},[s("span",{style:{top:"-3.91em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord"}),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},":="),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord"},"Π"),s("span",{class:"mopen"},"("),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},":"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mclose"},")"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"→"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mopen"},"["),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mclose"},"]"),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mopen"},"{"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord"},"¬"),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mclose"},"}")])]),s("span",{style:{top:"-2.41em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord"}),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},":="),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord"},"Π"),s("span",{class:"mopen"},"("),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},":"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mclose"},")"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"→"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord text"},[s("span",{class:"mord textsf"},"isProp")]),s("span",{class:"mopen"},"(["),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mclose"},"]"),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mopen"},"{"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord"},"¬"),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mclose"},"})")])])]),s("span",{class:"vlist-s"},"​")]),s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.25em"}},[s("span")])])])])])])])])])])],-1),s("p",null,[l("So the normal form of "),s("code",null,"isSet"),l(" is:")],-1),s("p",{class:"katex-block"},[s("span",{class:"katex-display"},[s("span",{class:"katex"},[s("span",{class:"katex-mathml"},[s("math",{xmlns:"http://www.w3.org/1998/Math/MathML",display:"block"},[s("semantics",null,[s("mtable",{rowspacing:"0.25em",columnalign:"right left",columnspacing:"0em"},[s("mtr",null,[s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mi",{mathvariant:"normal"},"Π"),s("mo",{stretchy:"false"},"("),s("mi",null,"a"),s("mtext",null," "),s("mi",null,"b"),s("mo",null,":"),s("mi",null,"A"),s("mo",{stretchy:"false"},")")])])]),s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mrow"),s("mo",null,"→"),s("mi",{mathvariant:"normal"},"Π"),s("mo",{stretchy:"false"},"("),s("mi",null,"p"),s("mtext",null," "),s("mi",null,"q"),s("mo",null,":"),s("mo",{stretchy:"false"},"["),s("mi",null,"i"),s("mo",{stretchy:"false"},"]"),s("mi",null,"A"),s("mo",{stretchy:"false"},"{"),s("mtext",null," "),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"a"),s("mo",{separator:"true"},","),s("mi",{mathvariant:"normal"},"¬"),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"b"),s("mtext",null," "),s("mo",{stretchy:"false"},"}"),s("mo",{stretchy:"false"},")")])])])]),s("mtr",null,[s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow")])]),s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mrow"),s("mo",null,"→"),s("mo",{fence:"false",stretchy:"true",minsize:"1.2em",maxsize:"1.2em"},"["),s("mi",null,"j"),s("mo",{fence:"false",stretchy:"true",minsize:"1.2em",maxsize:"1.2em"},"]"),s("mo",{fence:"false",stretchy:"true",minsize:"1.2em",maxsize:"1.2em"},"("),s("mo",{stretchy:"false"},"["),s("mi",null,"i"),s("mo",{stretchy:"false"},"]"),s("mi",null,"A"),s("mo",{stretchy:"false"},"{"),s("mtext",null," "),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"a"),s("mo",{separator:"true"},","),s("mi",{mathvariant:"normal"},"¬"),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"b"),s("mtext",null," "),s("mo",{stretchy:"false"},"}"),s("mo",{fence:"false",stretchy:"true",minsize:"1.2em",maxsize:"1.2em"},")"),s("mrow",null,[s("mo",{fence:"true"},"{"),s("mtext",null," "),s("mi",null,"j"),s("mo",null,"↦"),s("mi",null,"q"),s("mo",{separator:"true"},","),s("mi",{mathvariant:"normal"},"¬"),s("mi",null,"j"),s("mo",null,"↦"),s("mi",null,"p"),s("mtext",null," "),s("mo",{fence:"true"},"}")])])])])])]),s("annotation",{encoding:"application/x-tex"},"\\begin{align*} Π(a~b:A)&→Π(p~q:[i]A\\set{i↦ a,¬ i↦ b})\\\\ &→ \\big[j\\big] \\big([i]A\\set{i↦ a,¬ i↦ b}\\big) \\Set{j↦ q, ¬ j↦ p}\\\\ \\end{align*} ")])])]),s("span",{class:"katex-html","aria-hidden":"true"},[s("span",{class:"base"},[s("span",{class:"strut",style:{height:"3.01em","vertical-align":"-1.255em"}}),s("span",{class:"mord"},[s("span",{class:"mtable"},[s("span",{class:"col-align-r"},[s("span",{class:"vlist-t vlist-t2"},[s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.755em"}},[s("span",{style:{top:"-3.915em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord"},"Π"),s("span",{class:"mopen"},"("),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},":"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mclose"},")")])]),s("span",{style:{top:"-2.405em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"})])]),s("span",{class:"vlist-s"},"​")]),s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.255em"}},[s("span")])])])]),s("span",{class:"col-align-l"},[s("span",{class:"vlist-t vlist-t2"},[s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.755em"}},[s("span",{style:{top:"-3.915em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord"}),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"→"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord"},"Π"),s("span",{class:"mopen"},"("),s("span",{class:"mord mathnormal"},"p"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal",style:{"margin-right":"0.03588em"}},"q"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},":"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mopen"},"["),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mclose"},"]"),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mopen"},"{"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord"},"¬"),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mclose"},"})")])]),s("span",{style:{top:"-2.405em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord"}),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"→"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord"},[s("span",{class:"delimsizing size1"},"[")]),s("span",{class:"mord mathnormal",style:{"margin-right":"0.05724em"}},"j"),s("span",{class:"mord"},[s("span",{class:"delimsizing size1"},"]")]),s("span",{class:"mord"},[s("span",{class:"delimsizing size1"},"(")]),s("span",{class:"mopen"},"["),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mclose"},"]"),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mopen"},"{"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord"},"¬"),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mclose"},"}"),s("span",{class:"mord"},[s("span",{class:"delimsizing size1"},")")]),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"minner"},[s("span",{class:"mopen delimcenter",style:{top:"0em"}},"{"),s("span",{class:"mspace",style:{"margin-right":"0.2222em"}}),s("span",{class:"mord mathnormal",style:{"margin-right":"0.05724em"}},"j"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal",style:{"margin-right":"0.03588em"}},"q"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord"},"¬"),s("span",{class:"mord mathnormal",style:{"margin-right":"0.05724em"}},"j"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"p"),s("span",{class:"mspace",style:{"margin-right":"0.2222em"}}),s("span",{class:"mclose delimcenter",style:{top:"0em"}},"}")])])])]),s("span",{class:"vlist-s"},"​")]),s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.255em"}},[s("span")])])])])])])])])])])],-1),a('

And flattenOp(isSet(A))\\textsf{flattenOp}(\\textsf{isSet}(A)) is:

',1),s("p",{class:"katex-block"},[s("span",{class:"katex-display"},[s("span",{class:"katex"},[s("span",{class:"katex-mathml"},[s("math",{xmlns:"http://www.w3.org/1998/Math/MathML",display:"block"},[s("semantics",null,[s("mtable",{rowspacing:"0.25em",columnalign:"right left",columnspacing:"0em"},[s("mtr",null,[s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mi",{mathvariant:"normal"},"Π"),s("mo",{stretchy:"false"},"("),s("mi",null,"a"),s("mtext",null," "),s("mi",null,"b"),s("mo",null,":"),s("mi",null,"A"),s("mo",{stretchy:"false"},")")])])]),s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mrow"),s("mo",null,"→"),s("mi",{mathvariant:"normal"},"Π"),s("mo",{stretchy:"false"},"("),s("mi",null,"p"),s("mtext",null," "),s("mi",null,"q"),s("mo",null,":"),s("mo",{stretchy:"false"},"["),s("mi",null,"i"),s("mo",{stretchy:"false"},"]"),s("mi",null,"A"),s("mo",{stretchy:"false"},"{"),s("mtext",null," "),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"a"),s("mo",{separator:"true"},","),s("mi",{mathvariant:"normal"},"¬"),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"b"),s("mtext",null," "),s("mo",{stretchy:"false"},"}"),s("mo",{stretchy:"false"},")")])])])]),s("mtr",null,[s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow")])]),s("mtd",null,[s("mstyle",{scriptlevel:"0",displaystyle:"true"},[s("mrow",null,[s("mrow"),s("mo",null,"→"),s("mo",{fence:"false",stretchy:"true",minsize:"1.2em",maxsize:"1.2em"},"["),s("mi",null,"j"),s("mtext",null," "),s("mi",null,"i"),s("mo",{fence:"false",stretchy:"true",minsize:"1.2em",maxsize:"1.2em"},"]"),s("mi",null,"A"),s("mrow",null,[s("mo",{fence:"true"},"{"),s("mtext",null," "),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"a"),s("mo",{separator:"true"},","),s("mi",{mathvariant:"normal"},"¬"),s("mi",null,"i"),s("mo",null,"↦"),s("mi",null,"b"),s("mo",{separator:"true"},","),s("mi",null,"j"),s("mo",null,"↦"),s("mi",null,"q"),s("mtext",null," "),s("mi",{mathvariant:"normal"},"@"),s("mtext",null," "),s("mi",null,"i"),s("mo",{separator:"true"},","),s("mi",{mathvariant:"normal"},"¬"),s("mi",null,"j"),s("mo",null,"↦"),s("mi",null,"p"),s("mtext",null," "),s("mi",{mathvariant:"normal"},"@"),s("mtext",null," "),s("mi",null,"i"),s("mtext",null," "),s("mo",{fence:"true"},"}")])])])])])]),s("annotation",{encoding:"application/x-tex"},"\\begin{align*} Π(a~b:A)&→Π(p~q:[i]A\\set{i↦ a,¬ i↦ b})\\\\ &→ \\big[j~i\\big] A \\Set{i↦ a,¬ i↦ b,j↦ q~@~i, ¬ j↦ p~@~i}\\\\ \\end{align*} ")])])]),s("span",{class:"katex-html","aria-hidden":"true"},[s("span",{class:"base"},[s("span",{class:"strut",style:{height:"3.01em","vertical-align":"-1.255em"}}),s("span",{class:"mord"},[s("span",{class:"mtable"},[s("span",{class:"col-align-r"},[s("span",{class:"vlist-t vlist-t2"},[s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.755em"}},[s("span",{style:{top:"-3.915em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord"},"Π"),s("span",{class:"mopen"},"("),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},":"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mclose"},")")])]),s("span",{style:{top:"-2.405em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"})])]),s("span",{class:"vlist-s"},"​")]),s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.255em"}},[s("span")])])])]),s("span",{class:"col-align-l"},[s("span",{class:"vlist-t vlist-t2"},[s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.755em"}},[s("span",{style:{top:"-3.915em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord"}),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"→"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord"},"Π"),s("span",{class:"mopen"},"("),s("span",{class:"mord mathnormal"},"p"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal",style:{"margin-right":"0.03588em"}},"q"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},":"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mopen"},"["),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mclose"},"]"),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mopen"},"{"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord"},"¬"),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mclose"},"})")])]),s("span",{style:{top:"-2.405em"}},[s("span",{class:"pstrut",style:{height:"3em"}}),s("span",{class:"mord"},[s("span",{class:"mord"}),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"→"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord"},[s("span",{class:"delimsizing size1"},"[")]),s("span",{class:"mord mathnormal",style:{"margin-right":"0.05724em"}},"j"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mord"},[s("span",{class:"delimsizing size1"},"]")]),s("span",{class:"mord mathnormal"},"A"),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"minner"},[s("span",{class:"mopen delimcenter",style:{top:"0em"}},"{"),s("span",{class:"mspace",style:{"margin-right":"0.2222em"}}),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"a"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord"},"¬"),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"b"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord mathnormal",style:{"margin-right":"0.05724em"}},"j"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal",style:{"margin-right":"0.03588em"}},"q"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord"},"@"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mpunct"},","),s("span",{class:"mspace",style:{"margin-right":"0.1667em"}}),s("span",{class:"mord"},"¬"),s("span",{class:"mord mathnormal",style:{"margin-right":"0.05724em"}},"j"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mrel"},"↦"),s("span",{class:"mspace",style:{"margin-right":"0.2778em"}}),s("span",{class:"mord mathnormal"},"p"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord"},"@"),s("span",{class:"mspace nobreak"}," "),s("span",{class:"mord mathnormal"},"i"),s("span",{class:"mspace",style:{"margin-right":"0.2222em"}}),s("span",{class:"mclose delimcenter",style:{top:"0em"}},"}")])])])]),s("span",{class:"vlist-s"},"​")]),s("span",{class:"vlist-r"},[s("span",{class:"vlist",style:{height:"1.255em"}},[s("span")])])])])])])])])])])],-1),a(`

So for example, set truncation from HoTT looks like this:

inductive SetTrunc (A : Type)
+| mk : A -> SetTrunc A
+| trunc : isSet (SetTrunc A)

The trunc constructor is elaborated to cubical syntax by flattening the type and attach the partial on the return type to the constructor, something like this:

trunc : Π (a b : SetTrunc A)
+    -> (p q : a = b)
+    -> (j i : I) -> SetTrunc A
+  { i = 1 -> a
+  ; i = 0 -> b
+  ; j = 1 -> q @ i
+  ; j = 0 -> p @ i
+  }

Aya is currently working on the so-called IApplyConfluence problem for recursive higher inductive types like SetTrunc, see this question which is a problem I'm wrapping my head around at the moment. More details will be posted later.

`,5)]))}const u=t(p,[["render",r]]);export{d as __pageData,u as default}; diff --git a/assets/blog_redirect.md.dnCf5fLC.js b/assets/blog_redirect.md.dnCf5fLC.js new file mode 100644 index 0000000..bdce93e --- /dev/null +++ b/assets/blog_redirect.md.dnCf5fLC.js @@ -0,0 +1 @@ +import{_ as a,c as o,j as e,a as r,o as s}from"./chunks/framework.CoXjB5sU.js";const h=JSON.parse('{"title":"","description":"","frontmatter":{},"headers":[],"relativePath":"blog/redirect.md","filePath":"blog/redirect.md","lastUpdated":1627270192000}'),n={name:"blog/redirect.md"};function l(d,t,p,c,i,m){return s(),o("div",null,t[0]||(t[0]=[e("p",null,"Hi OSSRH managers,",-1),e("p",null,[r("I'm Tesla Zhang and I own this aya-prover.org domain. I claim that it's me who created "),e("a",{href:"https://issues.sonatype.org/browse/OSSRH-71525",target:"_blank",rel:"noreferrer"},"OSSRH-71525"),r(". It's for the project "),e("a",{href:"https://github.com/aya-prover/aya-dev",target:"_blank",rel:"noreferrer"},"aya-prover"),r(".")],-1),e("p",null,"Thank you!",-1)]))}const g=a(n,[["render",l]]);export{h as __pageData,g as default}; diff --git a/assets/blog_redirect.md.dnCf5fLC.lean.js b/assets/blog_redirect.md.dnCf5fLC.lean.js new file mode 100644 index 0000000..bdce93e --- /dev/null +++ b/assets/blog_redirect.md.dnCf5fLC.lean.js @@ -0,0 +1 @@ +import{_ as a,c as o,j as e,a as r,o as s}from"./chunks/framework.CoXjB5sU.js";const h=JSON.parse('{"title":"","description":"","frontmatter":{},"headers":[],"relativePath":"blog/redirect.md","filePath":"blog/redirect.md","lastUpdated":1627270192000}'),n={name:"blog/redirect.md"};function l(d,t,p,c,i,m){return s(),o("div",null,t[0]||(t[0]=[e("p",null,"Hi OSSRH managers,",-1),e("p",null,[r("I'm Tesla Zhang and I own this aya-prover.org domain. I claim that it's me who created "),e("a",{href:"https://issues.sonatype.org/browse/OSSRH-71525",target:"_blank",rel:"noreferrer"},"OSSRH-71525"),r(". It's for the project "),e("a",{href:"https://github.com/aya-prover/aya-dev",target:"_blank",rel:"noreferrer"},"aya-prover"),r(".")],-1),e("p",null,"Thank you!",-1)]))}const g=a(n,[["render",l]]);export{h as __pageData,g as default}; diff --git a/assets/blog_tt-in-tt-qiit.md.DGl7KXmS.js b/assets/blog_tt-in-tt-qiit.md.DGl7KXmS.js new file mode 100644 index 0000000..5a3130e --- /dev/null +++ b/assets/blog_tt-in-tt-qiit.md.DGl7KXmS.js @@ -0,0 +1,67 @@ +import{_ as V,c as A,a2 as i,j as a,a as s,o as g}from"./chunks/framework.CoXjB5sU.js";const w={mounted(){const p=new Map;function v(l){const e=l.querySelectorAll("a[href]");for(const r of e){const n=r.href,y=p.get(n)??new Set;y.add(r),p.set(n,y)}for(const r of e)r.onmouseover=function(){for(const n of p.get(this.href))n.classList.add("hover-highlight")},r.onmouseout=function(){for(const n of p.get(this.href))n.classList.remove("hover-highlight")}}function x(l){return decodeURIComponent(atob(l).split("").map(function(e){return"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)}).join(""))}const f=(l=>{const e={};return(...r)=>{const n=JSON.stringify(r);return e[n]=e[n]||l(...r)}})(x);class d{constructor(){this.list=[]}dismiss(e){e&&(e.remove(),this.list=this.list.filter(r=>r!==e))}dismissIfNotUsed(e){e&&(e.markedForDismissal=!0,setTimeout(()=>{!e.userIsThinking&&this.allowAutoDismissal(e)&&this.dismiss(e)},1e3))}allowAutoDismissal(e){return e.markedForDismissal&&!e.userClicked}fireAutoDismissalFor(e){let r=this.list.find(n=>n.userCreatedFrom===e);this.dismissIfNotUsed(r)}createHoverFor(e,r,n){let y=this.list.find(o=>o.userCreatedFrom===e);if(y&&y.userClicked)return y;let M=[];const C=this.list.filter(o=>{if(this.allowAutoDismissal(o))return M.push(o),!1;const c=o.userCreatedFrom,m=e;let h=m;for(;h;){if(h===c)return!0;h=h.parentElement}for(h=c;h;){if(h===m)return!0;h=h.parentElement}return!1});M.forEach(o=>this.dismiss(o));let t=document.createElement("div");t.userCreatedFrom=e,t.innerHTML="×"+f(r),t.classList.add("AyaTooltipPopup"),v(t);let b=this;if(t.handleEvent=function(o){if(o.type==="click"){this.userClicked=!0,this.markedForDismissal=!1;let c=this.children[0];if(!c)return;let m=this;c.style.visibility="visible",c.addEventListener("click",h=>b.dismiss(m))}o.type==="mouseover"&&(this.userIsThinking=!0),o.type==="mouseout"&&(this.userIsThinking=!1,b.dismissIfNotUsed(this))},t.addEventListener("click",t),t.addEventListener("mouseover",t),t.addEventListener("mouseout",t),n.appendChild(t),t.style.left=`${e.offsetLeft}px`,C.length===0){const o=e.getBoundingClientRect(),c=t.getBoundingClientRect();o.bottom+c.height+30>window.innerHeight?t.style.top=`calc(${e.offsetTop-c.height+8}px - 3em)`:t.style.top=`${e.offsetTop+e.offsetHeight+8}px`}else{const o=Math.max(...C.map(c=>c.offsetTop+c.offsetHeight));t.style.top=`${o+8}px`}return this.list.push(t),t}}let u=new d;function T(l){return function(){let e=this;const r=e.getAttribute("data-tooltip-text");r&&(l?u.createHoverFor(e,r,document.body):u.fireAutoDismissalFor(e))}}v(document);{let l=document.getElementsByClassName("aya-tooltip");for(let e=0;eType Theory in Type Theory using Quotient Inductive Types

Link to the paper.

Here's a self-contained full definition.

Prelude

',4),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"prim"),s(),a("a",{id:"Mian-I",class:"aya-hover","aya-hover-text":"ISet",href:"#Mian-I"},[a("span",{class:"Primitive"},"I")]),s(` +`),a("span",{class:"Keyword"},"prim"),s(),a("a",{id:"Mian-Path",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Path"},[a("span",{class:"Primitive"},"Path")]),s(` +`),a("span",{class:"Keyword"},"prim"),s(),a("a",{id:"Mian-coe",class:"aya-hover","aya-hover-text":"A r → A s",href:"#Mian-coe"},[a("span",{class:"Primitive"},"coe")]),s(` + +`),a("span",{class:"Keyword"},"variable"),s(),a("a",{id:"v1932274274",href:"#v1932274274"},[a("span",{class:"Generalized"},"A")]),s(),a("a",{id:"v1309238149",href:"#v1309238149"},[a("span",{class:"Generalized"},"B")]),s(" : "),a("span",{class:"Keyword"},"Type"),s(` +`),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"Keyword"},"infix"),s(),a("a",{id:"Mian-3d",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(" ("),a("a",{id:"v760357227",class:"aya-hover","aya-hover-text":"A",href:"#v760357227"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v37926966",class:"aya-hover","aya-hover-text":"A",href:"#v37926966"},[a("span",{class:"LocalVar"},"b")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1932274274"},[a("span",{class:"Generalized"},"A")]),s(") : "),a("span",{class:"Keyword"},"Type"),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Path"},[a("span",{class:"Primitive"},"Path")]),s(" ("),a("span",{class:"Keyword"},"\\"),a("a",{id:"v570794077",href:"#v570794077"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1932274274"},[a("span",{class:"Generalized"},"A")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v760357227"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v37926966"},[a("span",{class:"LocalVar"},"b")]),s(` +`),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-refl",class:"aya-hover","aya-hover-text":"a = a",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(" {"),a("a",{id:"v1963862935",class:"aya-hover","aya-hover-text":"A",href:"#v1963862935"},[a("span",{class:"LocalVar"},"a")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1932274274"},[a("span",{class:"Generalized"},"A")]),s("} : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1963862935"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1963862935"},[a("span",{class:"LocalVar"},"a")]),s(" ⇒ "),a("span",{class:"Keyword"},"\\"),a("a",{id:"v1928301845",href:"#v1928301845"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1963862935"},[a("span",{class:"LocalVar"},"a")]),s(` +`),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-pmap",class:"aya-hover","aya-hover-text":"f a = f b",href:"#Mian-pmap"},[a("span",{class:"Fn"},"pmap")]),s(" ("),a("a",{id:"v2130192211",class:"aya-hover","aya-hover-text":"A → B",href:"#v2130192211"},[a("span",{class:"LocalVar"},"f")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1932274274"},[a("span",{class:"Generalized"},"A")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1309238149"},[a("span",{class:"Generalized"},"B")]),s(") {"),a("a",{id:"v990897274",class:"aya-hover","aya-hover-text":"A",href:"#v990897274"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v539690370",class:"aya-hover","aya-hover-text":"A",href:"#v539690370"},[a("span",{class:"LocalVar"},"b")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1932274274"},[a("span",{class:"Generalized"},"A")]),s("} ("),a("a",{id:"v480490520",class:"aya-hover","aya-hover-text":"a = b",href:"#v480490520"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v990897274"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v539690370"},[a("span",{class:"LocalVar"},"b")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v2130192211"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v990897274"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v2130192211"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v539690370"},[a("span",{class:"LocalVar"},"b")]),s(" ⇒ "),a("span",{class:"Keyword"},"\\"),a("a",{id:"v1789452565",href:"#v1789452565"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v2130192211"},[a("span",{class:"LocalVar"},"f")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v480490520"},[a("span",{class:"LocalVar"},"p")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v1789452565"},[a("span",{class:"LocalVar"},"i")]),s(`) + +`),a("span",{class:"Comment"},"// Copied from Carlo Angiuli's thesis"),s(` +`),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-transport",class:"aya-hover","aya-hover-text":"B b",href:"#Mian-transport"},[a("span",{class:"Fn"},"transport")]),s(" {"),a("a",{id:"v1902237905",class:"aya-hover","aya-hover-text":"A",href:"#v1902237905"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v1961002599",class:"aya-hover","aya-hover-text":"A",href:"#v1961002599"},[a("span",{class:"LocalVar"},"b")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1932274274"},[a("span",{class:"Generalized"},"A")]),s("} ("),a("a",{id:"v485937598",class:"aya-hover","aya-hover-text":"A → Type 0",href:"#v485937598"},[a("span",{class:"LocalVar"},"B")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1932274274"},[a("span",{class:"Generalized"},"A")]),s(" → "),a("span",{class:"Keyword"},"Type"),s(") ("),a("a",{id:"v434398524",class:"aya-hover","aya-hover-text":"a = b",href:"#v434398524"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1902237905"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1961002599"},[a("span",{class:"LocalVar"},"b")]),s(") ("),a("a",{id:"v2035616217",class:"aya-hover","aya-hover-text":"B a",href:"#v2035616217"},[a("span",{class:"LocalVar"},"x")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v485937598"},[a("span",{class:"LocalVar"},"B")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1902237905"},[a("span",{class:"LocalVar"},"a")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v485937598"},[a("span",{class:"LocalVar"},"B")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1961002599"},[a("span",{class:"LocalVar"},"b")]),s(` + ⇒ `),a("a",{class:"aya-hover","aya-hover-text":"B b",href:"#Mian-coe"},[a("span",{class:"Primitive"},"coe")]),s(" 0 1 ("),a("span",{class:"Keyword"},"\\"),a("a",{id:"v1595938139",href:"#v1595938139"},[a("span",{class:"LocalVar"},"y")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v485937598"},[a("span",{class:"LocalVar"},"B")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v434398524"},[a("span",{class:"LocalVar"},"p")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v1595938139"},[a("span",{class:"LocalVar"},"y")]),s(")) "),a("a",{class:"aya-hover","aya-hover-text":"B a",href:"#v2035616217"},[a("span",{class:"LocalVar"},"x")])]),s(` +`)],-1),a("h2",{id:"context",tabindex:"-1"},[s("Context "),a("a",{class:"header-anchor",href:"#context","aria-label":'Permalink to "Context"'},"​")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Con",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s(" : "),a("span",{class:"Keyword"},"Type"),s(` +| `),a("a",{id:"Mian-Con-•",class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-•"},[a("span",{class:"Constructor"},"•")]),s(` +| `),a("span",{class:"Keyword"},"infix"),s(),a("a",{id:"Mian-Con-▷",class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(" ("),a("a",{id:"v225672073",class:"aya-hover","aya-hover-text":"Con",href:"#v225672073"},[a("span",{class:"LocalVar"},"Γ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v225672073"},[a("span",{class:"LocalVar"},"Γ")]),s(")")]),s(` +`)],-1),i('

An instance of the type Con corresponds to the ΓΓ in the judgment Γ ctxΓ~\\text{ctx}, and these constructors correspond (on-the-nose) to:

 ctxΓ ctxΓA typeΓA ctx\\cfrac{}{·~\\text{ctx}} \\quad \\cfrac{Γ~\\text{ctx} \\quad Γ⊢A~\\text{type}}{Γ \\vartriangleright A~\\text{ctx}}

It uses the judgment ΓA typeΓ⊢A~\\text{type}, which is defined below.

Types

',4),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Ty",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(" ("),a("a",{id:"v1261031890",class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s(") : "),a("span",{class:"Keyword"},"Type"),s(` +| `),a("a",{id:"Mian-Ty-U",class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-U"},[a("span",{class:"Constructor"},"U")]),s(` +| `),a("a",{id:"Mian-Ty-Π",class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(" ("),a("a",{id:"v1823409783",class:"aya-hover","aya-hover-text":"Ty Γ",href:"#v1823409783"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(") ("),a("a",{id:"v1428475041",class:"aya-hover","aya-hover-text":"Ty (Γ ▷ A)",href:"#v1428475041"},[a("span",{class:"LocalVar"},"B")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#v1823409783"},[a("span",{class:"LocalVar"},"A")]),s(`)) +| `),a("a",{id:"Mian-Ty-El",class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-El"},[a("span",{class:"Constructor"},"El")]),s(" ("),a("a",{id:"v661119548",class:"aya-hover","aya-hover-text":"Tm Γ U",href:"#v661119548"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-U"},[a("span",{class:"Constructor"},"U")]),s(`) +| `),a("a",{id:"Mian-Ty-Subst",class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(" {"),a("a",{id:"v335708295",class:"aya-hover","aya-hover-text":"Con",href:"#v335708295"},[a("span",{class:"LocalVar"},"Δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v335708295"},[a("span",{class:"LocalVar"},"Δ")]),s(") ("),a("a",{id:"v480903748",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v480903748"},[a("span",{class:"LocalVar"},"s")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v335708295"},[a("span",{class:"LocalVar"},"Δ")]),s(`) +| `),a("a",{id:"Mian-Ty-SubId",class:"aya-hover","aya-hover-text":"Subst A (id refl) = A",href:"#Mian-Ty-SubId"},[a("span",{class:"Constructor"},"SubId")]),s(" {"),a("a",{id:"v391183339",class:"aya-hover","aya-hover-text":"Ty Γ",href:"#v391183339"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s("} : "),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#v391183339"},[a("span",{class:"LocalVar"},"A")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Γ << Γ",href:"#Mian-3c3c-id"},[a("span",{class:"Constructor"},"id")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ = Γ",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#v391183339"},[a("span",{class:"LocalVar"},"A")]),s(` +| `),a("a",{id:"Mian-Ty-SubAss",class:"aya-hover","aya-hover-text":"Subst (Subst A δ) θ = Subst A (δ ∘ θ)",href:"#Mian-Ty-SubAss"},[a("span",{class:"Constructor"},"SubAss")]),s(" {"),a("a",{id:"v1894601438",class:"aya-hover","aya-hover-text":"Con",href:"#v1894601438"},[a("span",{class:"LocalVar"},"Δ")]),s(),a("a",{id:"v1231799381",class:"aya-hover","aya-hover-text":"Con",href:"#v1231799381"},[a("span",{class:"LocalVar"},"Θ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} {"),a("a",{id:"v1497377679",class:"aya-hover","aya-hover-text":"Ty Θ",href:"#v1497377679"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1231799381"},[a("span",{class:"LocalVar"},"Θ")]),s("} {"),a("a",{id:"v1904783235",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1904783235"},[a("span",{class:"LocalVar"},"θ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1894601438"},[a("span",{class:"LocalVar"},"Δ")]),s("} {"),a("a",{id:"v1810458830",class:"aya-hover","aya-hover-text":"Δ << Θ",href:"#v1810458830"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1894601438"},[a("span",{class:"LocalVar"},"Δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1231799381"},[a("span",{class:"LocalVar"},"Θ")]),s(`} + : `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Θ",href:"#v1497377679"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Δ << Θ",href:"#v1810458830"},[a("span",{class:"LocalVar"},"δ")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1904783235"},[a("span",{class:"LocalVar"},"θ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Θ",href:"#v1497377679"},[a("span",{class:"LocalVar"},"A")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Δ << Θ",href:"#v1810458830"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?Γ Γ Δ Θ A θ δ << ?Δ Γ Δ Θ A θ δ",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1904783235"},[a("span",{class:"LocalVar"},"θ")]),s(`) +| `),a("a",{id:"Mian-Ty-SubU",class:"aya-hover","aya-hover-text":"Subst U δ = U",href:"#Mian-Ty-SubU"},[a("span",{class:"Constructor"},"SubU")]),s(" {"),a("a",{id:"v899543194",class:"aya-hover","aya-hover-text":"Con",href:"#v899543194"},[a("span",{class:"LocalVar"},"Δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} ("),a("a",{id:"v1138697171",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1138697171"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v899543194"},[a("span",{class:"LocalVar"},"Δ")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#Mian-Ty-U"},[a("span",{class:"Constructor"},"U")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1138697171"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-U"},[a("span",{class:"Constructor"},"U")]),s(` +| `),a("a",{id:"Mian-Ty-SubEl",class:"aya-hover","aya-hover-text":"Subst (El a) δ = El (transport (Tm Γ) (SubU δ) (sub a))",href:"#Mian-Ty-SubEl"},[a("span",{class:"Constructor"},"SubEl")]),s(" {"),a("a",{id:"v120360571",class:"aya-hover","aya-hover-text":"Con",href:"#v120360571"},[a("span",{class:"LocalVar"},"Δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} {"),a("a",{id:"v1710814638",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1710814638"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v120360571"},[a("span",{class:"LocalVar"},"Δ")]),s("} {"),a("a",{id:"v944140566",class:"aya-hover","aya-hover-text":"Tm Δ U",href:"#v944140566"},[a("span",{class:"LocalVar"},"a")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v120360571"},[a("span",{class:"LocalVar"},"Δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#Mian-Ty-U"},[a("span",{class:"Constructor"},"U")]),s(`} + : `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#Mian-Ty-El"},[a("span",{class:"Constructor"},"El")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm Δ U",href:"#v944140566"},[a("span",{class:"LocalVar"},"a")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1710814638"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-El"},[a("span",{class:"Constructor"},"El")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Tm Γ U",href:"#Mian-transport"},[a("span",{class:"Fn"},"transport")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ → Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YxMjYxMDMxODkwIj48c3BhbiBjbGFzcz0iTG9jYWxWYXIiPs6TPC9zcGFuPjwvYT48L2NvZGU+CjwvcHJlPgo="},"_"),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"I → Ty Γ",href:"#Mian-Ty-SubU"},[a("span",{class:"Constructor"},"SubU")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1710814638"},[a("span",{class:"LocalVar"},"δ")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Tm Γ (Subst U δ)",href:"#Mian-Tm-sub"},[a("span",{class:"Constructor"},"sub")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm Δ U",href:"#v944140566"},[a("span",{class:"LocalVar"},"a")]),s(`)) +| `),a("a",{id:"Mian-Ty-SubΠ",class:"aya-hover","aya-hover-text":"Subst (Π A B) σ = Π (Subst A σ) (Subst B (ext σ A))",href:"#Mian-Ty-SubΠ"},[a("span",{class:"Constructor"},"SubΠ")]),s(" {"),a("a",{id:"v403174823",class:"aya-hover","aya-hover-text":"Con",href:"#v403174823"},[a("span",{class:"LocalVar"},"Δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} ("),a("a",{id:"v462526099",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v462526099"},[a("span",{class:"LocalVar"},"σ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v403174823"},[a("span",{class:"LocalVar"},"Δ")]),s(") {"),a("a",{id:"v2142565033",class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v2142565033"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v403174823"},[a("span",{class:"LocalVar"},"Δ")]),s("} {"),a("a",{id:"v1304589447",class:"aya-hover","aya-hover-text":"Ty (Δ ▷ A)",href:"#v1304589447"},[a("span",{class:"LocalVar"},"B")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v403174823"},[a("span",{class:"LocalVar"},"Δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v2142565033"},[a("span",{class:"LocalVar"},"A")]),s(`)} + : `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v2142565033"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty (Δ ▷ A)",href:"#v1304589447"},[a("span",{class:"LocalVar"},"B")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v462526099"},[a("span",{class:"LocalVar"},"σ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v2142565033"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v462526099"},[a("span",{class:"LocalVar"},"σ")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Ty (Γ ▷ Subst A σ)",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty (Δ ▷ A)",href:"#v1304589447"},[a("span",{class:"LocalVar"},"B")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"(Γ ▷ Subst A σ) << (Δ ▷ A)",href:"#Mian-ext"},[a("span",{class:"Fn"},"ext")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v462526099"},[a("span",{class:"LocalVar"},"σ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v2142565033"},[a("span",{class:"LocalVar"},"A")]),s("))")]),s(` +`)],-1),a("p",null,[s("The "),a("code",{class:"Aya"},[a("a",{href:"#Mian-ext"},[a("span",{class:"Fn"},"ext")])]),s(" operator corresponds to the ↑ operator in the paper:")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-ext",class:"aya-hover","aya-hover-text":"(Γ ▷ Subst A δ) << (Δ ▷ A)",href:"#Mian-ext"},[a("span",{class:"Fn"},"ext")]),s(" {"),a("a",{id:"v1515877023",class:"aya-hover","aya-hover-text":"Con",href:"#v1515877023"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{id:"v1263668904",class:"aya-hover","aya-hover-text":"Con",href:"#v1263668904"},[a("span",{class:"LocalVar"},"Δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} ("),a("a",{id:"v370475881",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v370475881"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1515877023"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1263668904"},[a("span",{class:"LocalVar"},"Δ")]),s(") ("),a("a",{id:"v1795816257",class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1795816257"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1263668904"},[a("span",{class:"LocalVar"},"Δ")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1515877023"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1795816257"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v370475881"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1263668904"},[a("span",{class:"LocalVar"},"Δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1795816257"},[a("span",{class:"LocalVar"},"A")]),s(` ⇒ + `),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v370475881"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?Γ Γ Δ δ A << ?Δ Γ Δ δ A",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"(Γ ▷ Subst A δ) << Γ",href:"#Mian-3c3c-π₁"},[a("span",{class:"Constructor"},"π₁")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"(Γ ▷ Subst A δ) << (Γ ▷ Subst A δ)",href:"#Mian-3c3c-id"},[a("span",{class:"Constructor"},"id")]),s(),a("a",{class:"aya-hover","aya-hover-text":"(Γ ▷ Subst A δ) = (Γ ▷ Subst A δ)",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"?_ Γ Δ δ A << (?Δ' Γ Δ δ A ▷ ?A Γ Δ δ A)",href:"#Mian-3c3c-∷"},[a("span",{class:"Constructor"},"∷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm (Γ ▷ Subst A δ) (Subst A (δ ∘ π₁ (id refl)))",href:"#Mian-transport"},[a("span",{class:"Fn"},"transport")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty (Γ ▷ Subst A δ) → Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YxNTE1ODc3MDIzIj48c3BhbiBjbGFzcz0iTG9jYWxWYXIiPs6TPC9zcGFuPjwvYT4gPGEgaHJlZj0iI01pYW4tQ29uLeKWtyI+PHNwYW4gY2xhc3M9IkNvbnN0cnVjdG9yIj7ilrc8L3NwYW4+PC9hPiA8c3BhbiBjbGFzcz0iQ2FsbCI+PGEgaHJlZj0iI01pYW4tVHktU3Vic3QiPjxzcGFuIGNsYXNzPSJDb25zdHJ1Y3RvciI+U3Vic3Q8L3NwYW4+PC9hPiA8YSBocmVmPSIjdjE3OTU4MTYyNTciPjxzcGFuIGNsYXNzPSJMb2NhbFZhciI+QTwvc3Bhbj48L2E+IDxhIGhyZWY9IiN2MzcwNDc1ODgxIj48c3BhbiBjbGFzcz0iTG9jYWxWYXIiPs60PC9zcGFuPjwvYT48L3NwYW4+PC9jb2RlPgo8L3ByZT4K"},"_"),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Subst (Subst A δ) (π₁ (id refl)) = Subst A (δ ∘ π₁ (id refl))",href:"#Mian-Ty-SubAss"},[a("span",{class:"Constructor"},"SubAss")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Tm (Γ ▷ Subst A δ) (Subst (Subst A δ) (π₁ (id refl)))",href:"#Mian-Tm-π₂"},[a("span",{class:"Constructor"},"π₂")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"(Γ ▷ Subst A δ) << (Γ ▷ Subst A δ)",href:"#Mian-3c3c-id"},[a("span",{class:"Constructor"},"id")]),s(),a("a",{class:"aya-hover","aya-hover-text":"(Γ ▷ Subst A δ) = (Γ ▷ Subst A δ)",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s("))")]),s(` +`)],-1),i('

An instance of the type Ty Γ corresponds to the AA in the judgment ΓA typeΓ⊢A~\\text{type}. The constructor U corresponds to the following rule:

ΓU type\\cfrac{}{Γ⊢\\mathcal{U}~\\text{type}}

I believe you already know how Π works. The constructor El computes the type corresponds to an instance of U:

ΓA:UΓEl(A) type\\cfrac{Γ⊢A:\\mathcal{U}}{Γ⊢\\text{El}(A)~\\text{type}}

Note that it uses the judgment ΓA:UΓ⊢A:\\mathcal{U}, which is defined below.

Substitution objects

',6),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("span",{class:"Keyword"},"infix"),s(),a("a",{id:"Mian-3c3c",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(" ("),a("a",{id:"v1896622931",class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s(") ("),a("a",{id:"v1401316767",class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s(") : "),a("span",{class:"Keyword"},"Type"),s(` + `),a("span",{class:"Keyword"},"tighter"),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("span",{class:"Keyword"},"looser"),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(` +| _, `),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-•"},[a("span",{class:"Constructor"},"•")]),s(" ⇒ "),a("a",{id:"Mian-3c3c-ε",class:"aya-hover","aya-hover-text":"_ << •",href:"#Mian-3c3c-ε"},[a("span",{class:"Constructor"},"ε")]),s(` +| _, `),a("a",{id:"v2123960023",class:"aya-hover","aya-hover-text":"Con",href:"#v2123960023"},[a("span",{class:"LocalVar"},"Δ'")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{id:"v201719260",class:"aya-hover","aya-hover-text":"Ty Δ'",href:"#v201719260"},[a("span",{class:"LocalVar"},"A")]),s(" ⇒ "),a("span",{class:"Keyword"},"infixr"),s(),a("a",{id:"Mian-3c3c-∷",class:"aya-hover","aya-hover-text":"_ << (Δ' ▷ A)",href:"#Mian-3c3c-∷"},[a("span",{class:"Constructor"},"∷")]),s(" ("),a("a",{id:"v1293226111",class:"aya-hover","aya-hover-text":"_ << Δ'",href:"#v1293226111"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v2123960023"},[a("span",{class:"LocalVar"},"Δ'")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty _",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ'",href:"#v201719260"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << Δ'",href:"#v1293226111"},[a("span",{class:"LocalVar"},"δ")]),s(")) "),a("span",{class:"Keyword"},"tighter"),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(` +| `),a("span",{class:"Keyword"},"infix"),s(),a("a",{id:"Mian-3c3c-∘",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(" {"),a("a",{id:"v138817329",class:"aya-hover","aya-hover-text":"Con",href:"#v138817329"},[a("span",{class:"LocalVar"},"Θ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v138817329"},[a("span",{class:"LocalVar"},"Θ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v138817329"},[a("span",{class:"LocalVar"},"Θ")]),s(") "),a("span",{class:"Keyword"},"tighter"),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << (Δ' ▷ A)",href:"#Mian-3c3c-∷"},[a("span",{class:"Constructor"},"∷")]),s(` +| `),a("a",{id:"Mian-3c3c-π₁",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#Mian-3c3c-π₁"},[a("span",{class:"Constructor"},"π₁")]),s(" {"),a("a",{id:"v1774720883",class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1774720883"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s("} ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1774720883"},[a("span",{class:"LocalVar"},"A")]),s(`) +| `),a("a",{id:"Mian-3c3c-id",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#Mian-3c3c-id"},[a("span",{class:"Constructor"},"id")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s(`) +| `),a("a",{id:"Mian-3c3c-idl•",class:"aya-hover","aya-hover-text":"(id refl ∘ s) = s",href:"#Mian-3c3c-idl•"},[a("span",{class:"Constructor"},"idl•")]),s(" {"),a("a",{id:"v1188401255",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1188401255"},[a("span",{class:"LocalVar"},"s")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s("} : "),a("a",{class:"aya-hover","aya-hover-text":"Δ << Δ",href:"#Mian-3c3c-id"},[a("span",{class:"Constructor"},"id")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Δ = Δ",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?Γ Γ Δ s << ?Δ Γ Δ s",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1188401255"},[a("span",{class:"LocalVar"},"s")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1188401255"},[a("span",{class:"LocalVar"},"s")]),s(` +| `),a("a",{id:"Mian-3c3c-idr•",class:"aya-hover","aya-hover-text":"(s ∘ id refl) = s",href:"#Mian-3c3c-idr•"},[a("span",{class:"Constructor"},"idr•")]),s(" {"),a("a",{id:"v258535644",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v258535644"},[a("span",{class:"LocalVar"},"s")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s("} : "),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v258535644"},[a("span",{class:"LocalVar"},"s")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?Γ Γ Δ s << ?Δ Γ Δ s",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Γ",href:"#Mian-3c3c-id"},[a("span",{class:"Constructor"},"id")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ = Γ",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v258535644"},[a("span",{class:"LocalVar"},"s")]),s(` +| `),a("a",{id:"Mian-3c3c-ass",class:"aya-hover","aya-hover-text":"((σ ∘ δ) ∘ ν) = (σ ∘ (δ ∘ ν))",href:"#Mian-3c3c-ass"},[a("span",{class:"Constructor"},"ass")]),s(" {"),a("a",{id:"v616674002",class:"aya-hover","aya-hover-text":"Con",href:"#v616674002"},[a("span",{class:"LocalVar"},"Θ")]),s(),a("a",{id:"v2109839984",class:"aya-hover","aya-hover-text":"Con",href:"#v2109839984"},[a("span",{class:"LocalVar"},"Ξ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} {"),a("a",{id:"v1351478315",class:"aya-hover","aya-hover-text":"Γ << Ξ",href:"#v1351478315"},[a("span",{class:"LocalVar"},"ν")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v2109839984"},[a("span",{class:"LocalVar"},"Ξ")]),s("} {"),a("a",{id:"v508512860",class:"aya-hover","aya-hover-text":"Ξ << Θ",href:"#v508512860"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v2109839984"},[a("span",{class:"LocalVar"},"Ξ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v616674002"},[a("span",{class:"LocalVar"},"Θ")]),s("} {"),a("a",{id:"v925973605",class:"aya-hover","aya-hover-text":"Θ << Δ",href:"#v925973605"},[a("span",{class:"LocalVar"},"σ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v616674002"},[a("span",{class:"LocalVar"},"Θ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s(`} + : (`),a("a",{class:"aya-hover","aya-hover-text":"Θ << Δ",href:"#v925973605"},[a("span",{class:"LocalVar"},"σ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?Γ Γ Δ Θ Ξ ν δ σ << ?Δ Γ Δ Θ Ξ ν δ σ",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ξ << Θ",href:"#v508512860"},[a("span",{class:"LocalVar"},"δ")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"?Γ Γ Δ Θ Ξ ν δ σ << ?Δ Γ Δ Θ Ξ ν δ σ",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Ξ",href:"#v1351478315"},[a("span",{class:"LocalVar"},"ν")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Θ << Δ",href:"#v925973605"},[a("span",{class:"LocalVar"},"σ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?Γ Γ Δ Θ Ξ ν δ σ << ?Δ Γ Δ Θ Ξ ν δ σ",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ξ << Θ",href:"#v508512860"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?Γ Γ Δ Θ Ξ ν δ σ << ?Δ Γ Δ Θ Ξ ν δ σ",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Ξ",href:"#v1351478315"},[a("span",{class:"LocalVar"},"ν")]),s(`) +| `),a("a",{id:"Mian-3c3c-π₁β",class:"aya-hover","aya-hover-text":"π₁ (δ ∷ t) = δ",href:"#Mian-3c3c-π₁β"},[a("span",{class:"Constructor"},"π₁β")]),s(" {"),a("a",{id:"v1777238524",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1777238524"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s("} {"),a("a",{id:"v1848289347",class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1848289347"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s("} ("),a("a",{id:"v304354378",class:"aya-hover","aya-hover-text":"Tm Γ (Subst A δ)",href:"#v304354378"},[a("span",{class:"LocalVar"},"t")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1848289347"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1777238524"},[a("span",{class:"LocalVar"},"δ")]),s(")) : "),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#Mian-3c3c-π₁"},[a("span",{class:"Constructor"},"π₁")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1777238524"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?_ Γ Δ δ A t << (?Δ' Γ Δ δ A t ▷ ?A Γ Δ δ A t)",href:"#Mian-3c3c-∷"},[a("span",{class:"Constructor"},"∷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm Γ (Subst A δ)",href:"#v304354378"},[a("span",{class:"LocalVar"},"t")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1777238524"},[a("span",{class:"LocalVar"},"δ")]),s(` +| _, _ `),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(" _ ⇒ "),a("a",{id:"Mian-3c3c-πη",class:"aya-hover","aya-hover-text":"(π₁ δ ∷ π₂ δ) = δ",href:"#Mian-3c3c-πη"},[a("span",{class:"Constructor"},"πη")]),s(" {"),a("a",{id:"v800088638",class:"aya-hover","aya-hover-text":"_ << (_ ▷ _)",href:"#v800088638"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s("} : ("),a("a",{class:"aya-hover","aya-hover-text":"_ << _",href:"#Mian-3c3c-π₁"},[a("span",{class:"Constructor"},"π₁")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << (_ ▷ _)",href:"#v800088638"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?_ _ _ _ δ << (?Δ' _ _ _ δ ▷ ?A _ _ _ δ)",href:"#Mian-3c3c-∷"},[a("span",{class:"Constructor"},"∷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst _ (π₁ δ))",href:"#Mian-Tm-π₂"},[a("span",{class:"Constructor"},"π₂")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << (_ ▷ _)",href:"#v800088638"},[a("span",{class:"LocalVar"},"δ")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << (_ ▷ _)",href:"#v800088638"},[a("span",{class:"LocalVar"},"δ")]),s(` +| _, `),a("a",{id:"v1148255190",class:"aya-hover","aya-hover-text":"Con",href:"#v1148255190"},[a("span",{class:"LocalVar"},"Δ'")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{id:"v366252104",class:"aya-hover","aya-hover-text":"Ty Δ'",href:"#v366252104"},[a("span",{class:"LocalVar"},"A")]),s(" ⇒ "),a("a",{id:"Mian-3c3c-∷∘",class:"aya-hover","aya-hover-text":"((σ ∷ t) ∘ δ) = ((σ ∘ δ) ∷ transport (Tm _) SubAss (sub t))",href:"#Mian-3c3c-∷∘"},[a("span",{class:"Constructor"},"∷∘")]),s(" {"),a("a",{id:"v1346343363",class:"aya-hover","aya-hover-text":"Con",href:"#v1346343363"},[a("span",{class:"LocalVar"},"Θ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} {"),a("a",{id:"v324169305",class:"aya-hover","aya-hover-text":"Θ << Δ'",href:"#v324169305"},[a("span",{class:"LocalVar"},"σ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1346343363"},[a("span",{class:"LocalVar"},"Θ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1148255190"},[a("span",{class:"LocalVar"},"Δ'")]),s("} {"),a("a",{id:"v573958827",class:"aya-hover","aya-hover-text":"_ << Θ",href:"#v573958827"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1346343363"},[a("span",{class:"LocalVar"},"Θ")]),s("} {"),a("a",{id:"v997033037",class:"aya-hover","aya-hover-text":"Tm Θ (Subst A σ)",href:"#v997033037"},[a("span",{class:"LocalVar"},"t")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1346343363"},[a("span",{class:"LocalVar"},"Θ")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty Θ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ'",href:"#v366252104"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Θ << Δ'",href:"#v324169305"},[a("span",{class:"LocalVar"},"σ")]),s(`)} + : (`),a("a",{class:"aya-hover","aya-hover-text":"Θ << Δ'",href:"#v324169305"},[a("span",{class:"LocalVar"},"σ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?_ Δ' A _ Θ σ δ t << (?Δ' Δ' A _ Θ σ δ t ▷ ?A Δ' A _ Θ σ δ t)",href:"#Mian-3c3c-∷"},[a("span",{class:"Constructor"},"∷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm Θ (Subst A σ)",href:"#v997033037"},[a("span",{class:"LocalVar"},"t")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"?Γ Δ' A _ Θ σ δ t << ?Δ Δ' A _ Θ σ δ t",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << Θ",href:"#v573958827"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Θ << Δ'",href:"#v324169305"},[a("span",{class:"LocalVar"},"σ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?Γ Δ' A _ Θ σ δ t << ?Δ Δ' A _ Θ σ δ t",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << Θ",href:"#v573958827"},[a("span",{class:"LocalVar"},"δ")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"?_ Δ' A _ Θ σ δ t << (?Δ' Δ' A _ Θ σ δ t ▷ ?A Δ' A _ Θ σ δ t)",href:"#Mian-3c3c-∷"},[a("span",{class:"Constructor"},"∷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst A (σ ∘ δ))",href:"#Mian-transport"},[a("span",{class:"Fn"},"transport")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty _ → Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YxODg5MDU3MDMxIj48c3BhbiBjbGFzcz0iTG9jYWxWYXIiPl88L3NwYW4+PC9hPjwvY29kZT4KPC9wcmU+Cg=="},"_"),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Subst (Subst A σ) δ = Subst A (σ ∘ δ)",href:"#Mian-Ty-SubAss"},[a("span",{class:"Constructor"},"SubAss")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst (Subst A σ) δ)",href:"#Mian-Tm-sub"},[a("span",{class:"Constructor"},"sub")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm Θ (Subst A σ)",href:"#v997033037"},[a("span",{class:"LocalVar"},"t")]),s(`) +| _, `),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-•"},[a("span",{class:"Constructor"},"•")]),s(" ⇒ "),a("a",{id:"Mian-3c3c-εη",class:"aya-hover","aya-hover-text":"δ = ε",href:"#Mian-3c3c-εη"},[a("span",{class:"Constructor"},"εη")]),s(" {"),a("a",{id:"v1345900725",class:"aya-hover","aya-hover-text":"_ << •",href:"#v1345900725"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-•"},[a("span",{class:"Constructor"},"•")]),s("} : "),a("a",{class:"aya-hover","aya-hover-text":"_ << •",href:"#v1345900725"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << •",href:"#Mian-3c3c-ε"},[a("span",{class:"Constructor"},"ε")])]),s(` +`)],-1),i('

An instance of type Γ << Δ corresponds to the σσ in the substitution typing Γσ:ΔΓ ⊢ σ : Δ.

Terms

',2),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Tm",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(" ("),a("a",{id:"v91912419",class:"aya-hover","aya-hover-text":"Con",href:"#v91912419"},[a("span",{class:"LocalVar"},"Γ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v91912419"},[a("span",{class:"LocalVar"},"Γ")]),s(") : "),a("span",{class:"Keyword"},"Type"),s(` +| _, `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(),a("a",{id:"v1807015220",class:"aya-hover","aya-hover-text":"Ty _",href:"#v1807015220"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{id:"v2107577743",class:"aya-hover","aya-hover-text":"Ty (_ ▷ A)",href:"#v2107577743"},[a("span",{class:"LocalVar"},"B")]),s(" ⇒ "),a("a",{id:"Mian-Tm-λ",class:"aya-hover","aya-hover-text":"Tm _ (Π A B)",href:"#Mian-Tm-λ"},[a("span",{class:"Constructor"},"λ")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v91912419"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty _",href:"#v1807015220"},[a("span",{class:"LocalVar"},"A")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Ty (_ ▷ A)",href:"#v2107577743"},[a("span",{class:"LocalVar"},"B")]),s(`) +| `),a("a",{id:"v102174918",class:"aya-hover","aya-hover-text":"Con",href:"#v102174918"},[a("span",{class:"LocalVar"},"Γ'")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{id:"v52514534",class:"aya-hover","aya-hover-text":"Ty Γ'",href:"#v52514534"},[a("span",{class:"LocalVar"},"A")]),s(", "),a("a",{id:"v943573036",class:"aya-hover","aya-hover-text":"Ty (Γ' ▷ A)",href:"#v943573036"},[a("span",{class:"LocalVar"},"B")]),s(" ⇒ "),a("a",{id:"Mian-Tm-app",class:"aya-hover","aya-hover-text":"Tm (Γ' ▷ A) B",href:"#Mian-Tm-app"},[a("span",{class:"Constructor"},"app")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v102174918"},[a("span",{class:"LocalVar"},"Γ'")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ'",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ'",href:"#v52514534"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty (Γ' ▷ A)",href:"#v943573036"},[a("span",{class:"LocalVar"},"B")]),s(`)) +| _, `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{id:"v1399794302",class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1399794302"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{id:"v1924949331",class:"aya-hover","aya-hover-text":"_ << Δ",href:"#v1924949331"},[a("span",{class:"LocalVar"},"δ")]),s(" ⇒ "),a("a",{id:"Mian-Tm-sub",class:"aya-hover","aya-hover-text":"Tm _ (Subst A δ)",href:"#Mian-Tm-sub"},[a("span",{class:"Constructor"},"sub")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YxMTY3MzQ4NTgiPjxzcGFuIGNsYXNzPSJMb2NhbFZhciI+zpQ8L3NwYW4+PC9hPjwvY29kZT4KPC9wcmU+Cg=="},"_"),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1399794302"},[a("span",{class:"LocalVar"},"A")]),s(`) +| _, `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{id:"v1626343059",class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1626343059"},[a("span",{class:"LocalVar"},"A")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#Mian-3c3c-π₁"},[a("span",{class:"Constructor"},"π₁")]),s(),a("a",{id:"v2032169857",class:"aya-hover","aya-hover-text":"_ << (Δ ▷ B)",href:"#v2032169857"},[a("span",{class:"LocalVar"},"δ")]),s(") ⇒ "),a("a",{id:"Mian-Tm-π₂",class:"aya-hover","aya-hover-text":"Tm _ (Subst A (π₁ δ))",href:"#Mian-Tm-π₂"},[a("span",{class:"Constructor"},"π₂")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v91912419"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3Y0NDEwMDE5NDIiPjxzcGFuIGNsYXNzPSJMb2NhbFZhciI+zpQ8L3NwYW4+PC9hPjwvY29kZT4KPC9wcmU+Cg=="},"_"),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1626343059"},[a("span",{class:"LocalVar"},"A")]),s(`) +| _, `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{id:"v2104973502",class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v2104973502"},[a("span",{class:"LocalVar"},"B")]),s(),a("a",{id:"v735937428",class:"aya-hover","aya-hover-text":"_ << Δ",href:"#v735937428"},[a("span",{class:"LocalVar"},"δ")]),s(),a("span",{class:"Keyword"},"as"),s(),a("a",{id:"v1604247316",class:"aya-hover","aya-hover-text":"Ty _",href:"#v1604247316"},[a("span",{class:"LocalVar"},"A")]),s(" ⇒ "),a("a",{id:"Mian-Tm-π₂β",class:"aya-hover","aya-hover-text":"coe 0 1 (\\ p0 ⇒ Tm _ (Subst B (π₁β t p0))) (π₂ (δ ∷ t)) = t",href:"#Mian-Tm-π₂β"},[a("span",{class:"Constructor"},"π₂β")]),s(" {"),a("a",{id:"v1753714541",class:"aya-hover","aya-hover-text":"Con",href:"#v1753714541"},[a("span",{class:"LocalVar"},"Δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} ("),a("a",{id:"v1095273238",class:"aya-hover","aya-hover-text":"Tm _ (Subst B δ)",href:"#v1095273238"},[a("span",{class:"LocalVar"},"t")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v91912419"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty _",href:"#v1604247316"},[a("span",{class:"LocalVar"},"A")]),s(`) + : `),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst B δ)",href:"#Mian-transport"},[a("span",{class:"Fn"},"transport")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty _ → Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YxNzUyNDYxMDkwIj48c3BhbiBjbGFzcz0iTG9jYWxWYXIiPl88L3NwYW4+PC9hPjwvY29kZT4KPC9wcmU+Cg=="},"_"),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Subst B (π₁ (δ ∷ t)) = Subst B δ",href:"#Mian-pmap"},[a("span",{class:"Fn"},"pmap")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"(_ << Δ) → Ty _",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v2104973502"},[a("span",{class:"LocalVar"},"B")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"I → _ << Δ",href:"#Mian-3c3c-π₁β"},[a("span",{class:"Constructor"},"π₁β")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst B δ)",href:"#v1095273238"},[a("span",{class:"LocalVar"},"t")]),s(")) ("),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst B (π₁ (δ ∷ t)))",href:"#Mian-Tm-π₂"},[a("span",{class:"Constructor"},"π₂")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"_ << Δ",href:"#v735937428"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?_ B δ _ Δ Δ t << (?Δ' B δ _ Δ Δ t ▷ ?A B δ _ Δ Δ t)",href:"#Mian-3c3c-∷"},[a("span",{class:"Constructor"},"∷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst B δ)",href:"#v1095273238"},[a("span",{class:"LocalVar"},"t")]),s(")) "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst B δ)",href:"#v1095273238"},[a("span",{class:"LocalVar"},"t")]),s(` +| _ `),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(" _, "),a("a",{id:"v873634936",class:"aya-hover","aya-hover-text":"Ty (_ ▷ _)",href:"#v873634936"},[a("span",{class:"LocalVar"},"A")]),s(" ⇒ "),a("a",{id:"Mian-Tm-Πβ",class:"aya-hover","aya-hover-text":"app (λ f) = f",href:"#Mian-Tm-Πβ"},[a("span",{class:"Constructor"},"Πβ")]),s(" ("),a("a",{id:"v1819940427",class:"aya-hover","aya-hover-text":"Tm (_ ▷ _) A",href:"#v1819940427"},[a("span",{class:"LocalVar"},"f")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v91912419"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty (_ ▷ _)",href:"#v873634936"},[a("span",{class:"LocalVar"},"A")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Tm (_ ▷ _) A",href:"#Mian-Tm-app"},[a("span",{class:"Constructor"},"app")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Π _ A)",href:"#Mian-Tm-λ"},[a("span",{class:"Constructor"},"λ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm (_ ▷ _) A",href:"#v1819940427"},[a("span",{class:"LocalVar"},"f")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm (_ ▷ _) A",href:"#v1819940427"},[a("span",{class:"LocalVar"},"f")]),s(` +| _, `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(" _ _ "),a("span",{class:"Keyword"},"as"),s(),a("a",{id:"v1399701152",class:"aya-hover","aya-hover-text":"Ty _",href:"#v1399701152"},[a("span",{class:"LocalVar"},"A")]),s(" ⇒ "),a("a",{id:"Mian-Tm-Πη",class:"aya-hover","aya-hover-text":"λ (app f) = f",href:"#Mian-Tm-Πη"},[a("span",{class:"Constructor"},"Πη")]),s(" ("),a("a",{id:"v527829831",class:"aya-hover","aya-hover-text":"Tm _ (Π _ _)",href:"#v527829831"},[a("span",{class:"LocalVar"},"f")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v91912419"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty _",href:"#v1399701152"},[a("span",{class:"LocalVar"},"A")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Π _ _)",href:"#Mian-Tm-λ"},[a("span",{class:"Constructor"},"λ")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Tm (_ ▷ _) _",href:"#Mian-Tm-app"},[a("span",{class:"Constructor"},"app")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Π _ _)",href:"#v527829831"},[a("span",{class:"LocalVar"},"f")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Π _ _)",href:"#v527829831"},[a("span",{class:"LocalVar"},"f")]),s(` +| _, `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(),a("a",{id:"v901205084",class:"aya-hover","aya-hover-text":"Ty _",href:"#v901205084"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{id:"v777457133",class:"aya-hover","aya-hover-text":"Ty (_ ▷ A)",href:"#v777457133"},[a("span",{class:"LocalVar"},"B")]),s(" ⇒ "),a("a",{id:"Mian-Tm-subλ",class:"aya-hover","aya-hover-text":`coe 0 1 (\\ p0 ⇒ Tm _ (fording p0)) (coe 0 1 (\\ p0 ⇒ Tm _ (SubΠ σ p0)) (sub (λ t))) += coe 0 1 (\\ p0 ⇒ Tm _ (fording p0)) (λ (sub t))`,href:"#Mian-Tm-subλ"},[a("span",{class:"Constructor"},"subλ")]),s(" {"),a("a",{id:"v136157810",class:"aya-hover","aya-hover-text":"Con",href:"#v136157810"},[a("span",{class:"LocalVar"},"Δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} {"),a("a",{id:"v122155649",class:"aya-hover","aya-hover-text":"_ << Δ",href:"#v122155649"},[a("span",{class:"LocalVar"},"σ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v91912419"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v136157810"},[a("span",{class:"LocalVar"},"Δ")]),s("} {"),a("a",{id:"v292138977",class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v292138977"},[a("span",{class:"LocalVar"},"A'")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v136157810"},[a("span",{class:"LocalVar"},"Δ")]),s("} {"),a("a",{id:"v748842359",class:"aya-hover","aya-hover-text":"Ty (Δ ▷ A')",href:"#v748842359"},[a("span",{class:"LocalVar"},"B'")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v136157810"},[a("span",{class:"LocalVar"},"Δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v292138977"},[a("span",{class:"LocalVar"},"A'")]),s(`)} + (`),a("a",{id:"v2112233878",class:"aya-hover","aya-hover-text":`Π (Subst A' σ) (Subst B' ((σ ∘ π₁ (id refl)) ∷ transport (Tm (_ ▷ Subst A' σ)) SubAss +(π₂ (id refl)))) = Π A B`,href:"#v2112233878"},[a("span",{class:"LocalVar"},"fording")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Ty _",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty _",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v292138977"},[a("span",{class:"LocalVar"},"A'")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << Δ",href:"#v122155649"},[a("span",{class:"LocalVar"},"σ")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Ty (_ ▷ Subst A' σ)",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty (Δ ▷ A')",href:"#v748842359"},[a("span",{class:"LocalVar"},"B'")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+KDxhIGhyZWY9IiN2MTIyMTU1NjQ5Ij48c3BhbiBjbGFzcz0iTG9jYWxWYXIiPs+DPC9zcGFuPjwvYT4gPGEgaHJlZj0iI01pYW4tM2MzYy3iiJgiPjxzcGFuIGNsYXNzPSJDb25zdHJ1Y3RvciI+4oiYPC9zcGFuPjwvYT4gPHNwYW4gY2xhc3M9IkNhbGwiPjxhIGhyZWY9IiNNaWFuLTNjM2Mtz4DigoEiPjxzcGFuIGNsYXNzPSJDb25zdHJ1Y3RvciI+z4DigoE8L3NwYW4+PC9hPiA8c3BhbiBjbGFzcz0iQ2FsbCI+KDxhIGhyZWY9IiNNaWFuLTNjM2MtaWQiPjxzcGFuIGNsYXNzPSJDb25zdHJ1Y3RvciI+aWQ8L3NwYW4+PC9hPiA8YSBocmVmPSIjTWlhbi1yZWZsIj48c3BhbiBjbGFzcz0iRm4iPnJlZmw8L3NwYW4+PC9hPik8L3NwYW4+PC9zcGFuPikgPGEgaHJlZj0iI01pYW4tM2MzYy3iiLciPjxzcGFuIGNsYXNzPSJDb25zdHJ1Y3RvciI+4oi3PC9zcGFuPjwvYT4gPHNwYW4gY2xhc3M9IkNhbGwiPjxhIGhyZWY9IiNNaWFuLXRyYW5zcG9ydCI+PHNwYW4gY2xhc3M9IkZuIj50cmFuc3BvcnQ8L3NwYW4+PC9hPiA8c3BhbiBjbGFzcz0iQ2FsbCI+KDxhIGhyZWY9IiNNaWFuLVRtIj48c3BhbiBjbGFzcz0iRGF0YSI+VG08L3NwYW4+PC9hPiAoPGEgaHJlZj0iI3YxOTMzODgwNDUiPjxzcGFuIGNsYXNzPSJMb2NhbFZhciI+Xzwvc3Bhbj48L2E+IDxhIGhyZWY9IiNNaWFuLUNvbi3ilrciPjxzcGFuIGNsYXNzPSJDb25zdHJ1Y3RvciI+4pa3PC9zcGFuPjwvYT4gPHNwYW4gY2xhc3M9IkNhbGwiPjxhIGhyZWY9IiNNaWFuLVR5LVN1YnN0Ij48c3BhbiBjbGFzcz0iQ29uc3RydWN0b3IiPlN1YnN0PC9zcGFuPjwvYT4gPGEgaHJlZj0iI3YyOTIxMzg5NzciPjxzcGFuIGNsYXNzPSJMb2NhbFZhciI+QSc8L3NwYW4+PC9hPiA8YSBocmVmPSIjdjEyMjE1NTY0OSI+PHNwYW4gY2xhc3M9IkxvY2FsVmFyIj7Pgzwvc3Bhbj48L2E+PC9zcGFuPikpPC9zcGFuPiA8YSBocmVmPSIjTWlhbi1UeS1TdWJBc3MiPjxzcGFuIGNsYXNzPSJDb25zdHJ1Y3RvciI+U3ViQXNzPC9zcGFuPjwvYT4gPHNwYW4gY2xhc3M9IkNhbGwiPig8YSBocmVmPSIjTWlhbi1UbS3PgOKCgiI+PHNwYW4gY2xhc3M9IkNvbnN0cnVjdG9yIj7PgOKCgjwvc3Bhbj48L2E+IDxzcGFuIGNsYXNzPSJDYWxsIj4oPGEgaHJlZj0iI01pYW4tM2MzYy1pZCI+PHNwYW4gY2xhc3M9IkNvbnN0cnVjdG9yIj5pZDwvc3Bhbj48L2E+IDxhIGhyZWY9IiNNaWFuLXJlZmwiPjxzcGFuIGNsYXNzPSJGbiI+cmVmbDwvc3Bhbj48L2E+KTwvc3Bhbj4pPC9zcGFuPjwvc3Bhbj48L2NvZGU+CjwvcHJlPgo="},"_"),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty _",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty _",href:"#v901205084"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty (_ ▷ A)",href:"#v777457133"},[a("span",{class:"LocalVar"},"B")]),s(") {"),a("a",{id:"v372469954",class:"aya-hover","aya-hover-text":"Tm (Δ ▷ A') B'",href:"#v372469954"},[a("span",{class:"LocalVar"},"t")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v136157810"},[a("span",{class:"LocalVar"},"Δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v292138977"},[a("span",{class:"LocalVar"},"A'")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Ty (Δ ▷ A')",href:"#v748842359"},[a("span",{class:"LocalVar"},"B'")]),s(`} + : `),a("span",{class:"Keyword"},"let"),s(),a("a",{id:"v457247584",href:"#v457247584"},[a("span",{class:"LocalVar"},"ford")]),s(" := "),a("a",{class:"aya-hover","aya-hover-text":`Tm _ (Π (Subst A' σ) (Subst B' ((σ ∘ π₁ (id refl)) ∷ transport (Tm (_ ▷ Subst A' +σ)) SubAss (π₂ (id refl))))) → Tm _ (Π A B)`,href:"#Mian-transport"},[a("span",{class:"Fn"},"transport")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty _ → Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YxOTMzODgwNDUiPjxzcGFuIGNsYXNzPSJMb2NhbFZhciI+Xzwvc3Bhbj48L2E+PC9jb2RlPgo8L3ByZT4K"},"_"),s(") "),a("a",{class:"aya-hover","aya-hover-text":`Π (Subst A' σ) (Subst B' ((σ ∘ π₁ (id refl)) ∷ transport (Tm (_ ▷ Subst A' σ)) SubAss +(π₂ (id refl)))) = Π A B`,href:"#v2112233878"},[a("span",{class:"LocalVar"},"fording")]),s(` + `),a("span",{class:"Keyword"},"in"),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Π A B)",href:"#v457247584"},[a("span",{class:"LocalVar"},"ford")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Π (Subst A' σ) (Subst B' (ext σ A')))",href:"#Mian-transport"},[a("span",{class:"Fn"},"transport")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty _ → Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YxOTMzODgwNDUiPjxzcGFuIGNsYXNzPSJMb2NhbFZhciI+Xzwvc3Bhbj48L2E+PC9jb2RlPgo8L3ByZT4K"},"_"),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"I → Ty _",href:"#Mian-Ty-SubΠ"},[a("span",{class:"Constructor"},"SubΠ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << Δ",href:"#v122155649"},[a("span",{class:"LocalVar"},"σ")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst (Π A' B') σ)",href:"#Mian-Tm-sub"},[a("span",{class:"Constructor"},"sub")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Tm Δ (Π A' B')",href:"#Mian-Tm-λ"},[a("span",{class:"Constructor"},"λ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm (Δ ▷ A') B'",href:"#v372469954"},[a("span",{class:"LocalVar"},"t")]),s(`))) + `),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Π A B)",href:"#v457247584"},[a("span",{class:"LocalVar"},"ford")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":`Tm _ (Π (Subst A' σ) (Subst B' ((σ ∘ π₁ (id refl)) ∷ transport (Tm (_ ▷ Subst A' +σ)) SubAss (π₂ (id refl)))))`,href:"#Mian-Tm-λ"},[a("span",{class:"Constructor"},"λ")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":`Tm (_ ▷ Subst A' σ) (Subst B' ((σ ∘ π₁ (id refl)) ∷ transport (Tm (_ ▷ Subst A' σ)) +SubAss (π₂ (id refl))))`,href:"#Mian-Tm-sub"},[a("span",{class:"Constructor"},"sub")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm (Δ ▷ A') B'",href:"#v372469954"},[a("span",{class:"LocalVar"},"t")]),s("))")]),s(` +`)],-1),i('

An instance of type Tm Γ A corresponds to the tt in the judgment Γt:AΓ⊢t:A.

',1)]))}const I=V(w,[["render",S]]);export{P as __pageData,I as default}; diff --git a/assets/blog_tt-in-tt-qiit.md.DGl7KXmS.lean.js b/assets/blog_tt-in-tt-qiit.md.DGl7KXmS.lean.js new file mode 100644 index 0000000..5a3130e --- /dev/null +++ b/assets/blog_tt-in-tt-qiit.md.DGl7KXmS.lean.js @@ -0,0 +1,67 @@ +import{_ as V,c as A,a2 as i,j as a,a as s,o as g}from"./chunks/framework.CoXjB5sU.js";const w={mounted(){const p=new Map;function v(l){const e=l.querySelectorAll("a[href]");for(const r of e){const n=r.href,y=p.get(n)??new Set;y.add(r),p.set(n,y)}for(const r of e)r.onmouseover=function(){for(const n of p.get(this.href))n.classList.add("hover-highlight")},r.onmouseout=function(){for(const n of p.get(this.href))n.classList.remove("hover-highlight")}}function x(l){return decodeURIComponent(atob(l).split("").map(function(e){return"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)}).join(""))}const f=(l=>{const e={};return(...r)=>{const n=JSON.stringify(r);return e[n]=e[n]||l(...r)}})(x);class d{constructor(){this.list=[]}dismiss(e){e&&(e.remove(),this.list=this.list.filter(r=>r!==e))}dismissIfNotUsed(e){e&&(e.markedForDismissal=!0,setTimeout(()=>{!e.userIsThinking&&this.allowAutoDismissal(e)&&this.dismiss(e)},1e3))}allowAutoDismissal(e){return e.markedForDismissal&&!e.userClicked}fireAutoDismissalFor(e){let r=this.list.find(n=>n.userCreatedFrom===e);this.dismissIfNotUsed(r)}createHoverFor(e,r,n){let y=this.list.find(o=>o.userCreatedFrom===e);if(y&&y.userClicked)return y;let M=[];const C=this.list.filter(o=>{if(this.allowAutoDismissal(o))return M.push(o),!1;const c=o.userCreatedFrom,m=e;let h=m;for(;h;){if(h===c)return!0;h=h.parentElement}for(h=c;h;){if(h===m)return!0;h=h.parentElement}return!1});M.forEach(o=>this.dismiss(o));let t=document.createElement("div");t.userCreatedFrom=e,t.innerHTML="×"+f(r),t.classList.add("AyaTooltipPopup"),v(t);let b=this;if(t.handleEvent=function(o){if(o.type==="click"){this.userClicked=!0,this.markedForDismissal=!1;let c=this.children[0];if(!c)return;let m=this;c.style.visibility="visible",c.addEventListener("click",h=>b.dismiss(m))}o.type==="mouseover"&&(this.userIsThinking=!0),o.type==="mouseout"&&(this.userIsThinking=!1,b.dismissIfNotUsed(this))},t.addEventListener("click",t),t.addEventListener("mouseover",t),t.addEventListener("mouseout",t),n.appendChild(t),t.style.left=`${e.offsetLeft}px`,C.length===0){const o=e.getBoundingClientRect(),c=t.getBoundingClientRect();o.bottom+c.height+30>window.innerHeight?t.style.top=`calc(${e.offsetTop-c.height+8}px - 3em)`:t.style.top=`${e.offsetTop+e.offsetHeight+8}px`}else{const o=Math.max(...C.map(c=>c.offsetTop+c.offsetHeight));t.style.top=`${o+8}px`}return this.list.push(t),t}}let u=new d;function T(l){return function(){let e=this;const r=e.getAttribute("data-tooltip-text");r&&(l?u.createHoverFor(e,r,document.body):u.fireAutoDismissalFor(e))}}v(document);{let l=document.getElementsByClassName("aya-tooltip");for(let e=0;eType Theory in Type Theory using Quotient Inductive Types

Link to the paper.

Here's a self-contained full definition.

Prelude

',4),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"prim"),s(),a("a",{id:"Mian-I",class:"aya-hover","aya-hover-text":"ISet",href:"#Mian-I"},[a("span",{class:"Primitive"},"I")]),s(` +`),a("span",{class:"Keyword"},"prim"),s(),a("a",{id:"Mian-Path",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Path"},[a("span",{class:"Primitive"},"Path")]),s(` +`),a("span",{class:"Keyword"},"prim"),s(),a("a",{id:"Mian-coe",class:"aya-hover","aya-hover-text":"A r → A s",href:"#Mian-coe"},[a("span",{class:"Primitive"},"coe")]),s(` + +`),a("span",{class:"Keyword"},"variable"),s(),a("a",{id:"v1932274274",href:"#v1932274274"},[a("span",{class:"Generalized"},"A")]),s(),a("a",{id:"v1309238149",href:"#v1309238149"},[a("span",{class:"Generalized"},"B")]),s(" : "),a("span",{class:"Keyword"},"Type"),s(` +`),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"Keyword"},"infix"),s(),a("a",{id:"Mian-3d",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(" ("),a("a",{id:"v760357227",class:"aya-hover","aya-hover-text":"A",href:"#v760357227"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v37926966",class:"aya-hover","aya-hover-text":"A",href:"#v37926966"},[a("span",{class:"LocalVar"},"b")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1932274274"},[a("span",{class:"Generalized"},"A")]),s(") : "),a("span",{class:"Keyword"},"Type"),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Path"},[a("span",{class:"Primitive"},"Path")]),s(" ("),a("span",{class:"Keyword"},"\\"),a("a",{id:"v570794077",href:"#v570794077"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1932274274"},[a("span",{class:"Generalized"},"A")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v760357227"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v37926966"},[a("span",{class:"LocalVar"},"b")]),s(` +`),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-refl",class:"aya-hover","aya-hover-text":"a = a",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(" {"),a("a",{id:"v1963862935",class:"aya-hover","aya-hover-text":"A",href:"#v1963862935"},[a("span",{class:"LocalVar"},"a")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1932274274"},[a("span",{class:"Generalized"},"A")]),s("} : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1963862935"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1963862935"},[a("span",{class:"LocalVar"},"a")]),s(" ⇒ "),a("span",{class:"Keyword"},"\\"),a("a",{id:"v1928301845",href:"#v1928301845"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1963862935"},[a("span",{class:"LocalVar"},"a")]),s(` +`),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-pmap",class:"aya-hover","aya-hover-text":"f a = f b",href:"#Mian-pmap"},[a("span",{class:"Fn"},"pmap")]),s(" ("),a("a",{id:"v2130192211",class:"aya-hover","aya-hover-text":"A → B",href:"#v2130192211"},[a("span",{class:"LocalVar"},"f")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1932274274"},[a("span",{class:"Generalized"},"A")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1309238149"},[a("span",{class:"Generalized"},"B")]),s(") {"),a("a",{id:"v990897274",class:"aya-hover","aya-hover-text":"A",href:"#v990897274"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v539690370",class:"aya-hover","aya-hover-text":"A",href:"#v539690370"},[a("span",{class:"LocalVar"},"b")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1932274274"},[a("span",{class:"Generalized"},"A")]),s("} ("),a("a",{id:"v480490520",class:"aya-hover","aya-hover-text":"a = b",href:"#v480490520"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v990897274"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v539690370"},[a("span",{class:"LocalVar"},"b")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v2130192211"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v990897274"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v2130192211"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v539690370"},[a("span",{class:"LocalVar"},"b")]),s(" ⇒ "),a("span",{class:"Keyword"},"\\"),a("a",{id:"v1789452565",href:"#v1789452565"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v2130192211"},[a("span",{class:"LocalVar"},"f")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v480490520"},[a("span",{class:"LocalVar"},"p")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v1789452565"},[a("span",{class:"LocalVar"},"i")]),s(`) + +`),a("span",{class:"Comment"},"// Copied from Carlo Angiuli's thesis"),s(` +`),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-transport",class:"aya-hover","aya-hover-text":"B b",href:"#Mian-transport"},[a("span",{class:"Fn"},"transport")]),s(" {"),a("a",{id:"v1902237905",class:"aya-hover","aya-hover-text":"A",href:"#v1902237905"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v1961002599",class:"aya-hover","aya-hover-text":"A",href:"#v1961002599"},[a("span",{class:"LocalVar"},"b")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1932274274"},[a("span",{class:"Generalized"},"A")]),s("} ("),a("a",{id:"v485937598",class:"aya-hover","aya-hover-text":"A → Type 0",href:"#v485937598"},[a("span",{class:"LocalVar"},"B")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1932274274"},[a("span",{class:"Generalized"},"A")]),s(" → "),a("span",{class:"Keyword"},"Type"),s(") ("),a("a",{id:"v434398524",class:"aya-hover","aya-hover-text":"a = b",href:"#v434398524"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1902237905"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1961002599"},[a("span",{class:"LocalVar"},"b")]),s(") ("),a("a",{id:"v2035616217",class:"aya-hover","aya-hover-text":"B a",href:"#v2035616217"},[a("span",{class:"LocalVar"},"x")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v485937598"},[a("span",{class:"LocalVar"},"B")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1902237905"},[a("span",{class:"LocalVar"},"a")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v485937598"},[a("span",{class:"LocalVar"},"B")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1961002599"},[a("span",{class:"LocalVar"},"b")]),s(` + ⇒ `),a("a",{class:"aya-hover","aya-hover-text":"B b",href:"#Mian-coe"},[a("span",{class:"Primitive"},"coe")]),s(" 0 1 ("),a("span",{class:"Keyword"},"\\"),a("a",{id:"v1595938139",href:"#v1595938139"},[a("span",{class:"LocalVar"},"y")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v485937598"},[a("span",{class:"LocalVar"},"B")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v434398524"},[a("span",{class:"LocalVar"},"p")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v1595938139"},[a("span",{class:"LocalVar"},"y")]),s(")) "),a("a",{class:"aya-hover","aya-hover-text":"B a",href:"#v2035616217"},[a("span",{class:"LocalVar"},"x")])]),s(` +`)],-1),a("h2",{id:"context",tabindex:"-1"},[s("Context "),a("a",{class:"header-anchor",href:"#context","aria-label":'Permalink to "Context"'},"​")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Con",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s(" : "),a("span",{class:"Keyword"},"Type"),s(` +| `),a("a",{id:"Mian-Con-•",class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-•"},[a("span",{class:"Constructor"},"•")]),s(` +| `),a("span",{class:"Keyword"},"infix"),s(),a("a",{id:"Mian-Con-▷",class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(" ("),a("a",{id:"v225672073",class:"aya-hover","aya-hover-text":"Con",href:"#v225672073"},[a("span",{class:"LocalVar"},"Γ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v225672073"},[a("span",{class:"LocalVar"},"Γ")]),s(")")]),s(` +`)],-1),i('

An instance of the type Con corresponds to the ΓΓ in the judgment Γ ctxΓ~\\text{ctx}, and these constructors correspond (on-the-nose) to:

 ctxΓ ctxΓA typeΓA ctx\\cfrac{}{·~\\text{ctx}} \\quad \\cfrac{Γ~\\text{ctx} \\quad Γ⊢A~\\text{type}}{Γ \\vartriangleright A~\\text{ctx}}

It uses the judgment ΓA typeΓ⊢A~\\text{type}, which is defined below.

Types

',4),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Ty",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(" ("),a("a",{id:"v1261031890",class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s(") : "),a("span",{class:"Keyword"},"Type"),s(` +| `),a("a",{id:"Mian-Ty-U",class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-U"},[a("span",{class:"Constructor"},"U")]),s(` +| `),a("a",{id:"Mian-Ty-Π",class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(" ("),a("a",{id:"v1823409783",class:"aya-hover","aya-hover-text":"Ty Γ",href:"#v1823409783"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(") ("),a("a",{id:"v1428475041",class:"aya-hover","aya-hover-text":"Ty (Γ ▷ A)",href:"#v1428475041"},[a("span",{class:"LocalVar"},"B")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#v1823409783"},[a("span",{class:"LocalVar"},"A")]),s(`)) +| `),a("a",{id:"Mian-Ty-El",class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-El"},[a("span",{class:"Constructor"},"El")]),s(" ("),a("a",{id:"v661119548",class:"aya-hover","aya-hover-text":"Tm Γ U",href:"#v661119548"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-U"},[a("span",{class:"Constructor"},"U")]),s(`) +| `),a("a",{id:"Mian-Ty-Subst",class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(" {"),a("a",{id:"v335708295",class:"aya-hover","aya-hover-text":"Con",href:"#v335708295"},[a("span",{class:"LocalVar"},"Δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v335708295"},[a("span",{class:"LocalVar"},"Δ")]),s(") ("),a("a",{id:"v480903748",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v480903748"},[a("span",{class:"LocalVar"},"s")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v335708295"},[a("span",{class:"LocalVar"},"Δ")]),s(`) +| `),a("a",{id:"Mian-Ty-SubId",class:"aya-hover","aya-hover-text":"Subst A (id refl) = A",href:"#Mian-Ty-SubId"},[a("span",{class:"Constructor"},"SubId")]),s(" {"),a("a",{id:"v391183339",class:"aya-hover","aya-hover-text":"Ty Γ",href:"#v391183339"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s("} : "),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#v391183339"},[a("span",{class:"LocalVar"},"A")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Γ << Γ",href:"#Mian-3c3c-id"},[a("span",{class:"Constructor"},"id")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ = Γ",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#v391183339"},[a("span",{class:"LocalVar"},"A")]),s(` +| `),a("a",{id:"Mian-Ty-SubAss",class:"aya-hover","aya-hover-text":"Subst (Subst A δ) θ = Subst A (δ ∘ θ)",href:"#Mian-Ty-SubAss"},[a("span",{class:"Constructor"},"SubAss")]),s(" {"),a("a",{id:"v1894601438",class:"aya-hover","aya-hover-text":"Con",href:"#v1894601438"},[a("span",{class:"LocalVar"},"Δ")]),s(),a("a",{id:"v1231799381",class:"aya-hover","aya-hover-text":"Con",href:"#v1231799381"},[a("span",{class:"LocalVar"},"Θ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} {"),a("a",{id:"v1497377679",class:"aya-hover","aya-hover-text":"Ty Θ",href:"#v1497377679"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1231799381"},[a("span",{class:"LocalVar"},"Θ")]),s("} {"),a("a",{id:"v1904783235",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1904783235"},[a("span",{class:"LocalVar"},"θ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1894601438"},[a("span",{class:"LocalVar"},"Δ")]),s("} {"),a("a",{id:"v1810458830",class:"aya-hover","aya-hover-text":"Δ << Θ",href:"#v1810458830"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1894601438"},[a("span",{class:"LocalVar"},"Δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1231799381"},[a("span",{class:"LocalVar"},"Θ")]),s(`} + : `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Θ",href:"#v1497377679"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Δ << Θ",href:"#v1810458830"},[a("span",{class:"LocalVar"},"δ")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1904783235"},[a("span",{class:"LocalVar"},"θ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Θ",href:"#v1497377679"},[a("span",{class:"LocalVar"},"A")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Δ << Θ",href:"#v1810458830"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?Γ Γ Δ Θ A θ δ << ?Δ Γ Δ Θ A θ δ",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1904783235"},[a("span",{class:"LocalVar"},"θ")]),s(`) +| `),a("a",{id:"Mian-Ty-SubU",class:"aya-hover","aya-hover-text":"Subst U δ = U",href:"#Mian-Ty-SubU"},[a("span",{class:"Constructor"},"SubU")]),s(" {"),a("a",{id:"v899543194",class:"aya-hover","aya-hover-text":"Con",href:"#v899543194"},[a("span",{class:"LocalVar"},"Δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} ("),a("a",{id:"v1138697171",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1138697171"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v899543194"},[a("span",{class:"LocalVar"},"Δ")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#Mian-Ty-U"},[a("span",{class:"Constructor"},"U")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1138697171"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-U"},[a("span",{class:"Constructor"},"U")]),s(` +| `),a("a",{id:"Mian-Ty-SubEl",class:"aya-hover","aya-hover-text":"Subst (El a) δ = El (transport (Tm Γ) (SubU δ) (sub a))",href:"#Mian-Ty-SubEl"},[a("span",{class:"Constructor"},"SubEl")]),s(" {"),a("a",{id:"v120360571",class:"aya-hover","aya-hover-text":"Con",href:"#v120360571"},[a("span",{class:"LocalVar"},"Δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} {"),a("a",{id:"v1710814638",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1710814638"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v120360571"},[a("span",{class:"LocalVar"},"Δ")]),s("} {"),a("a",{id:"v944140566",class:"aya-hover","aya-hover-text":"Tm Δ U",href:"#v944140566"},[a("span",{class:"LocalVar"},"a")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v120360571"},[a("span",{class:"LocalVar"},"Δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#Mian-Ty-U"},[a("span",{class:"Constructor"},"U")]),s(`} + : `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#Mian-Ty-El"},[a("span",{class:"Constructor"},"El")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm Δ U",href:"#v944140566"},[a("span",{class:"LocalVar"},"a")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1710814638"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-El"},[a("span",{class:"Constructor"},"El")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Tm Γ U",href:"#Mian-transport"},[a("span",{class:"Fn"},"transport")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ → Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YxMjYxMDMxODkwIj48c3BhbiBjbGFzcz0iTG9jYWxWYXIiPs6TPC9zcGFuPjwvYT48L2NvZGU+CjwvcHJlPgo="},"_"),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"I → Ty Γ",href:"#Mian-Ty-SubU"},[a("span",{class:"Constructor"},"SubU")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1710814638"},[a("span",{class:"LocalVar"},"δ")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Tm Γ (Subst U δ)",href:"#Mian-Tm-sub"},[a("span",{class:"Constructor"},"sub")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm Δ U",href:"#v944140566"},[a("span",{class:"LocalVar"},"a")]),s(`)) +| `),a("a",{id:"Mian-Ty-SubΠ",class:"aya-hover","aya-hover-text":"Subst (Π A B) σ = Π (Subst A σ) (Subst B (ext σ A))",href:"#Mian-Ty-SubΠ"},[a("span",{class:"Constructor"},"SubΠ")]),s(" {"),a("a",{id:"v403174823",class:"aya-hover","aya-hover-text":"Con",href:"#v403174823"},[a("span",{class:"LocalVar"},"Δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} ("),a("a",{id:"v462526099",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v462526099"},[a("span",{class:"LocalVar"},"σ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1261031890"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v403174823"},[a("span",{class:"LocalVar"},"Δ")]),s(") {"),a("a",{id:"v2142565033",class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v2142565033"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v403174823"},[a("span",{class:"LocalVar"},"Δ")]),s("} {"),a("a",{id:"v1304589447",class:"aya-hover","aya-hover-text":"Ty (Δ ▷ A)",href:"#v1304589447"},[a("span",{class:"LocalVar"},"B")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v403174823"},[a("span",{class:"LocalVar"},"Δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v2142565033"},[a("span",{class:"LocalVar"},"A")]),s(`)} + : `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v2142565033"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty (Δ ▷ A)",href:"#v1304589447"},[a("span",{class:"LocalVar"},"B")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v462526099"},[a("span",{class:"LocalVar"},"σ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v2142565033"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v462526099"},[a("span",{class:"LocalVar"},"σ")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Ty (Γ ▷ Subst A σ)",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty (Δ ▷ A)",href:"#v1304589447"},[a("span",{class:"LocalVar"},"B")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"(Γ ▷ Subst A σ) << (Δ ▷ A)",href:"#Mian-ext"},[a("span",{class:"Fn"},"ext")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v462526099"},[a("span",{class:"LocalVar"},"σ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v2142565033"},[a("span",{class:"LocalVar"},"A")]),s("))")]),s(` +`)],-1),a("p",null,[s("The "),a("code",{class:"Aya"},[a("a",{href:"#Mian-ext"},[a("span",{class:"Fn"},"ext")])]),s(" operator corresponds to the ↑ operator in the paper:")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-ext",class:"aya-hover","aya-hover-text":"(Γ ▷ Subst A δ) << (Δ ▷ A)",href:"#Mian-ext"},[a("span",{class:"Fn"},"ext")]),s(" {"),a("a",{id:"v1515877023",class:"aya-hover","aya-hover-text":"Con",href:"#v1515877023"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{id:"v1263668904",class:"aya-hover","aya-hover-text":"Con",href:"#v1263668904"},[a("span",{class:"LocalVar"},"Δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} ("),a("a",{id:"v370475881",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v370475881"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1515877023"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1263668904"},[a("span",{class:"LocalVar"},"Δ")]),s(") ("),a("a",{id:"v1795816257",class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1795816257"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1263668904"},[a("span",{class:"LocalVar"},"Δ")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1515877023"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1795816257"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v370475881"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1263668904"},[a("span",{class:"LocalVar"},"Δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1795816257"},[a("span",{class:"LocalVar"},"A")]),s(` ⇒ + `),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v370475881"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?Γ Γ Δ δ A << ?Δ Γ Δ δ A",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"(Γ ▷ Subst A δ) << Γ",href:"#Mian-3c3c-π₁"},[a("span",{class:"Constructor"},"π₁")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"(Γ ▷ Subst A δ) << (Γ ▷ Subst A δ)",href:"#Mian-3c3c-id"},[a("span",{class:"Constructor"},"id")]),s(),a("a",{class:"aya-hover","aya-hover-text":"(Γ ▷ Subst A δ) = (Γ ▷ Subst A δ)",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"?_ Γ Δ δ A << (?Δ' Γ Δ δ A ▷ ?A Γ Δ δ A)",href:"#Mian-3c3c-∷"},[a("span",{class:"Constructor"},"∷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm (Γ ▷ Subst A δ) (Subst A (δ ∘ π₁ (id refl)))",href:"#Mian-transport"},[a("span",{class:"Fn"},"transport")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty (Γ ▷ Subst A δ) → Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YxNTE1ODc3MDIzIj48c3BhbiBjbGFzcz0iTG9jYWxWYXIiPs6TPC9zcGFuPjwvYT4gPGEgaHJlZj0iI01pYW4tQ29uLeKWtyI+PHNwYW4gY2xhc3M9IkNvbnN0cnVjdG9yIj7ilrc8L3NwYW4+PC9hPiA8c3BhbiBjbGFzcz0iQ2FsbCI+PGEgaHJlZj0iI01pYW4tVHktU3Vic3QiPjxzcGFuIGNsYXNzPSJDb25zdHJ1Y3RvciI+U3Vic3Q8L3NwYW4+PC9hPiA8YSBocmVmPSIjdjE3OTU4MTYyNTciPjxzcGFuIGNsYXNzPSJMb2NhbFZhciI+QTwvc3Bhbj48L2E+IDxhIGhyZWY9IiN2MzcwNDc1ODgxIj48c3BhbiBjbGFzcz0iTG9jYWxWYXIiPs60PC9zcGFuPjwvYT48L3NwYW4+PC9jb2RlPgo8L3ByZT4K"},"_"),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Subst (Subst A δ) (π₁ (id refl)) = Subst A (δ ∘ π₁ (id refl))",href:"#Mian-Ty-SubAss"},[a("span",{class:"Constructor"},"SubAss")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Tm (Γ ▷ Subst A δ) (Subst (Subst A δ) (π₁ (id refl)))",href:"#Mian-Tm-π₂"},[a("span",{class:"Constructor"},"π₂")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"(Γ ▷ Subst A δ) << (Γ ▷ Subst A δ)",href:"#Mian-3c3c-id"},[a("span",{class:"Constructor"},"id")]),s(),a("a",{class:"aya-hover","aya-hover-text":"(Γ ▷ Subst A δ) = (Γ ▷ Subst A δ)",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s("))")]),s(` +`)],-1),i('

An instance of the type Ty Γ corresponds to the AA in the judgment ΓA typeΓ⊢A~\\text{type}. The constructor U corresponds to the following rule:

ΓU type\\cfrac{}{Γ⊢\\mathcal{U}~\\text{type}}

I believe you already know how Π works. The constructor El computes the type corresponds to an instance of U:

ΓA:UΓEl(A) type\\cfrac{Γ⊢A:\\mathcal{U}}{Γ⊢\\text{El}(A)~\\text{type}}

Note that it uses the judgment ΓA:UΓ⊢A:\\mathcal{U}, which is defined below.

Substitution objects

',6),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("span",{class:"Keyword"},"infix"),s(),a("a",{id:"Mian-3c3c",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(" ("),a("a",{id:"v1896622931",class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s(") ("),a("a",{id:"v1401316767",class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s(") : "),a("span",{class:"Keyword"},"Type"),s(` + `),a("span",{class:"Keyword"},"tighter"),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("span",{class:"Keyword"},"looser"),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(` +| _, `),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-•"},[a("span",{class:"Constructor"},"•")]),s(" ⇒ "),a("a",{id:"Mian-3c3c-ε",class:"aya-hover","aya-hover-text":"_ << •",href:"#Mian-3c3c-ε"},[a("span",{class:"Constructor"},"ε")]),s(` +| _, `),a("a",{id:"v2123960023",class:"aya-hover","aya-hover-text":"Con",href:"#v2123960023"},[a("span",{class:"LocalVar"},"Δ'")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{id:"v201719260",class:"aya-hover","aya-hover-text":"Ty Δ'",href:"#v201719260"},[a("span",{class:"LocalVar"},"A")]),s(" ⇒ "),a("span",{class:"Keyword"},"infixr"),s(),a("a",{id:"Mian-3c3c-∷",class:"aya-hover","aya-hover-text":"_ << (Δ' ▷ A)",href:"#Mian-3c3c-∷"},[a("span",{class:"Constructor"},"∷")]),s(" ("),a("a",{id:"v1293226111",class:"aya-hover","aya-hover-text":"_ << Δ'",href:"#v1293226111"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v2123960023"},[a("span",{class:"LocalVar"},"Δ'")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty _",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ'",href:"#v201719260"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << Δ'",href:"#v1293226111"},[a("span",{class:"LocalVar"},"δ")]),s(")) "),a("span",{class:"Keyword"},"tighter"),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(` +| `),a("span",{class:"Keyword"},"infix"),s(),a("a",{id:"Mian-3c3c-∘",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(" {"),a("a",{id:"v138817329",class:"aya-hover","aya-hover-text":"Con",href:"#v138817329"},[a("span",{class:"LocalVar"},"Θ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v138817329"},[a("span",{class:"LocalVar"},"Θ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v138817329"},[a("span",{class:"LocalVar"},"Θ")]),s(") "),a("span",{class:"Keyword"},"tighter"),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << (Δ' ▷ A)",href:"#Mian-3c3c-∷"},[a("span",{class:"Constructor"},"∷")]),s(` +| `),a("a",{id:"Mian-3c3c-π₁",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#Mian-3c3c-π₁"},[a("span",{class:"Constructor"},"π₁")]),s(" {"),a("a",{id:"v1774720883",class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1774720883"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s("} ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1774720883"},[a("span",{class:"LocalVar"},"A")]),s(`) +| `),a("a",{id:"Mian-3c3c-id",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#Mian-3c3c-id"},[a("span",{class:"Constructor"},"id")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s(`) +| `),a("a",{id:"Mian-3c3c-idl•",class:"aya-hover","aya-hover-text":"(id refl ∘ s) = s",href:"#Mian-3c3c-idl•"},[a("span",{class:"Constructor"},"idl•")]),s(" {"),a("a",{id:"v1188401255",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1188401255"},[a("span",{class:"LocalVar"},"s")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s("} : "),a("a",{class:"aya-hover","aya-hover-text":"Δ << Δ",href:"#Mian-3c3c-id"},[a("span",{class:"Constructor"},"id")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Δ = Δ",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?Γ Γ Δ s << ?Δ Γ Δ s",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1188401255"},[a("span",{class:"LocalVar"},"s")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1188401255"},[a("span",{class:"LocalVar"},"s")]),s(` +| `),a("a",{id:"Mian-3c3c-idr•",class:"aya-hover","aya-hover-text":"(s ∘ id refl) = s",href:"#Mian-3c3c-idr•"},[a("span",{class:"Constructor"},"idr•")]),s(" {"),a("a",{id:"v258535644",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v258535644"},[a("span",{class:"LocalVar"},"s")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s("} : "),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v258535644"},[a("span",{class:"LocalVar"},"s")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?Γ Γ Δ s << ?Δ Γ Δ s",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Γ",href:"#Mian-3c3c-id"},[a("span",{class:"Constructor"},"id")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ = Γ",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v258535644"},[a("span",{class:"LocalVar"},"s")]),s(` +| `),a("a",{id:"Mian-3c3c-ass",class:"aya-hover","aya-hover-text":"((σ ∘ δ) ∘ ν) = (σ ∘ (δ ∘ ν))",href:"#Mian-3c3c-ass"},[a("span",{class:"Constructor"},"ass")]),s(" {"),a("a",{id:"v616674002",class:"aya-hover","aya-hover-text":"Con",href:"#v616674002"},[a("span",{class:"LocalVar"},"Θ")]),s(),a("a",{id:"v2109839984",class:"aya-hover","aya-hover-text":"Con",href:"#v2109839984"},[a("span",{class:"LocalVar"},"Ξ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} {"),a("a",{id:"v1351478315",class:"aya-hover","aya-hover-text":"Γ << Ξ",href:"#v1351478315"},[a("span",{class:"LocalVar"},"ν")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v2109839984"},[a("span",{class:"LocalVar"},"Ξ")]),s("} {"),a("a",{id:"v508512860",class:"aya-hover","aya-hover-text":"Ξ << Θ",href:"#v508512860"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v2109839984"},[a("span",{class:"LocalVar"},"Ξ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v616674002"},[a("span",{class:"LocalVar"},"Θ")]),s("} {"),a("a",{id:"v925973605",class:"aya-hover","aya-hover-text":"Θ << Δ",href:"#v925973605"},[a("span",{class:"LocalVar"},"σ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v616674002"},[a("span",{class:"LocalVar"},"Θ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s(`} + : (`),a("a",{class:"aya-hover","aya-hover-text":"Θ << Δ",href:"#v925973605"},[a("span",{class:"LocalVar"},"σ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?Γ Γ Δ Θ Ξ ν δ σ << ?Δ Γ Δ Θ Ξ ν δ σ",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ξ << Θ",href:"#v508512860"},[a("span",{class:"LocalVar"},"δ")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"?Γ Γ Δ Θ Ξ ν δ σ << ?Δ Γ Δ Θ Ξ ν δ σ",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Ξ",href:"#v1351478315"},[a("span",{class:"LocalVar"},"ν")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Θ << Δ",href:"#v925973605"},[a("span",{class:"LocalVar"},"σ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?Γ Γ Δ Θ Ξ ν δ σ << ?Δ Γ Δ Θ Ξ ν δ σ",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ξ << Θ",href:"#v508512860"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?Γ Γ Δ Θ Ξ ν δ σ << ?Δ Γ Δ Θ Ξ ν δ σ",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Ξ",href:"#v1351478315"},[a("span",{class:"LocalVar"},"ν")]),s(`) +| `),a("a",{id:"Mian-3c3c-π₁β",class:"aya-hover","aya-hover-text":"π₁ (δ ∷ t) = δ",href:"#Mian-3c3c-π₁β"},[a("span",{class:"Constructor"},"π₁β")]),s(" {"),a("a",{id:"v1777238524",class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1777238524"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s("} {"),a("a",{id:"v1848289347",class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1848289347"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s("} ("),a("a",{id:"v304354378",class:"aya-hover","aya-hover-text":"Tm Γ (Subst A δ)",href:"#v304354378"},[a("span",{class:"LocalVar"},"t")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1848289347"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1777238524"},[a("span",{class:"LocalVar"},"δ")]),s(")) : "),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#Mian-3c3c-π₁"},[a("span",{class:"Constructor"},"π₁")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1777238524"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?_ Γ Δ δ A t << (?Δ' Γ Δ δ A t ▷ ?A Γ Δ δ A t)",href:"#Mian-3c3c-∷"},[a("span",{class:"Constructor"},"∷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm Γ (Subst A δ)",href:"#v304354378"},[a("span",{class:"LocalVar"},"t")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#v1777238524"},[a("span",{class:"LocalVar"},"δ")]),s(` +| _, _ `),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(" _ ⇒ "),a("a",{id:"Mian-3c3c-πη",class:"aya-hover","aya-hover-text":"(π₁ δ ∷ π₂ δ) = δ",href:"#Mian-3c3c-πη"},[a("span",{class:"Constructor"},"πη")]),s(" {"),a("a",{id:"v800088638",class:"aya-hover","aya-hover-text":"_ << (_ ▷ _)",href:"#v800088638"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1401316767"},[a("span",{class:"LocalVar"},"Δ")]),s("} : ("),a("a",{class:"aya-hover","aya-hover-text":"_ << _",href:"#Mian-3c3c-π₁"},[a("span",{class:"Constructor"},"π₁")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << (_ ▷ _)",href:"#v800088638"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?_ _ _ _ δ << (?Δ' _ _ _ δ ▷ ?A _ _ _ δ)",href:"#Mian-3c3c-∷"},[a("span",{class:"Constructor"},"∷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst _ (π₁ δ))",href:"#Mian-Tm-π₂"},[a("span",{class:"Constructor"},"π₂")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << (_ ▷ _)",href:"#v800088638"},[a("span",{class:"LocalVar"},"δ")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << (_ ▷ _)",href:"#v800088638"},[a("span",{class:"LocalVar"},"δ")]),s(` +| _, `),a("a",{id:"v1148255190",class:"aya-hover","aya-hover-text":"Con",href:"#v1148255190"},[a("span",{class:"LocalVar"},"Δ'")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{id:"v366252104",class:"aya-hover","aya-hover-text":"Ty Δ'",href:"#v366252104"},[a("span",{class:"LocalVar"},"A")]),s(" ⇒ "),a("a",{id:"Mian-3c3c-∷∘",class:"aya-hover","aya-hover-text":"((σ ∷ t) ∘ δ) = ((σ ∘ δ) ∷ transport (Tm _) SubAss (sub t))",href:"#Mian-3c3c-∷∘"},[a("span",{class:"Constructor"},"∷∘")]),s(" {"),a("a",{id:"v1346343363",class:"aya-hover","aya-hover-text":"Con",href:"#v1346343363"},[a("span",{class:"LocalVar"},"Θ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} {"),a("a",{id:"v324169305",class:"aya-hover","aya-hover-text":"Θ << Δ'",href:"#v324169305"},[a("span",{class:"LocalVar"},"σ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1346343363"},[a("span",{class:"LocalVar"},"Θ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1148255190"},[a("span",{class:"LocalVar"},"Δ'")]),s("} {"),a("a",{id:"v573958827",class:"aya-hover","aya-hover-text":"_ << Θ",href:"#v573958827"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1346343363"},[a("span",{class:"LocalVar"},"Θ")]),s("} {"),a("a",{id:"v997033037",class:"aya-hover","aya-hover-text":"Tm Θ (Subst A σ)",href:"#v997033037"},[a("span",{class:"LocalVar"},"t")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1346343363"},[a("span",{class:"LocalVar"},"Θ")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty Θ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ'",href:"#v366252104"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Θ << Δ'",href:"#v324169305"},[a("span",{class:"LocalVar"},"σ")]),s(`)} + : (`),a("a",{class:"aya-hover","aya-hover-text":"Θ << Δ'",href:"#v324169305"},[a("span",{class:"LocalVar"},"σ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?_ Δ' A _ Θ σ δ t << (?Δ' Δ' A _ Θ σ δ t ▷ ?A Δ' A _ Θ σ δ t)",href:"#Mian-3c3c-∷"},[a("span",{class:"Constructor"},"∷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm Θ (Subst A σ)",href:"#v997033037"},[a("span",{class:"LocalVar"},"t")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"?Γ Δ' A _ Θ σ δ t << ?Δ Δ' A _ Θ σ δ t",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << Θ",href:"#v573958827"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Θ << Δ'",href:"#v324169305"},[a("span",{class:"LocalVar"},"σ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?Γ Δ' A _ Θ σ δ t << ?Δ Δ' A _ Θ σ δ t",href:"#Mian-3c3c-∘"},[a("span",{class:"Constructor"},"∘")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << Θ",href:"#v573958827"},[a("span",{class:"LocalVar"},"δ")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"?_ Δ' A _ Θ σ δ t << (?Δ' Δ' A _ Θ σ δ t ▷ ?A Δ' A _ Θ σ δ t)",href:"#Mian-3c3c-∷"},[a("span",{class:"Constructor"},"∷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst A (σ ∘ δ))",href:"#Mian-transport"},[a("span",{class:"Fn"},"transport")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty _ → Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YxODg5MDU3MDMxIj48c3BhbiBjbGFzcz0iTG9jYWxWYXIiPl88L3NwYW4+PC9hPjwvY29kZT4KPC9wcmU+Cg=="},"_"),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Subst (Subst A σ) δ = Subst A (σ ∘ δ)",href:"#Mian-Ty-SubAss"},[a("span",{class:"Constructor"},"SubAss")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst (Subst A σ) δ)",href:"#Mian-Tm-sub"},[a("span",{class:"Constructor"},"sub")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm Θ (Subst A σ)",href:"#v997033037"},[a("span",{class:"LocalVar"},"t")]),s(`) +| _, `),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-•"},[a("span",{class:"Constructor"},"•")]),s(" ⇒ "),a("a",{id:"Mian-3c3c-εη",class:"aya-hover","aya-hover-text":"δ = ε",href:"#Mian-3c3c-εη"},[a("span",{class:"Constructor"},"εη")]),s(" {"),a("a",{id:"v1345900725",class:"aya-hover","aya-hover-text":"_ << •",href:"#v1345900725"},[a("span",{class:"LocalVar"},"δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v1896622931"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-•"},[a("span",{class:"Constructor"},"•")]),s("} : "),a("a",{class:"aya-hover","aya-hover-text":"_ << •",href:"#v1345900725"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << •",href:"#Mian-3c3c-ε"},[a("span",{class:"Constructor"},"ε")])]),s(` +`)],-1),i('

An instance of type Γ << Δ corresponds to the σσ in the substitution typing Γσ:ΔΓ ⊢ σ : Δ.

Terms

',2),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Tm",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(" ("),a("a",{id:"v91912419",class:"aya-hover","aya-hover-text":"Con",href:"#v91912419"},[a("span",{class:"LocalVar"},"Γ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v91912419"},[a("span",{class:"LocalVar"},"Γ")]),s(") : "),a("span",{class:"Keyword"},"Type"),s(` +| _, `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(),a("a",{id:"v1807015220",class:"aya-hover","aya-hover-text":"Ty _",href:"#v1807015220"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{id:"v2107577743",class:"aya-hover","aya-hover-text":"Ty (_ ▷ A)",href:"#v2107577743"},[a("span",{class:"LocalVar"},"B")]),s(" ⇒ "),a("a",{id:"Mian-Tm-λ",class:"aya-hover","aya-hover-text":"Tm _ (Π A B)",href:"#Mian-Tm-λ"},[a("span",{class:"Constructor"},"λ")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v91912419"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty _",href:"#v1807015220"},[a("span",{class:"LocalVar"},"A")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Ty (_ ▷ A)",href:"#v2107577743"},[a("span",{class:"LocalVar"},"B")]),s(`) +| `),a("a",{id:"v102174918",class:"aya-hover","aya-hover-text":"Con",href:"#v102174918"},[a("span",{class:"LocalVar"},"Γ'")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{id:"v52514534",class:"aya-hover","aya-hover-text":"Ty Γ'",href:"#v52514534"},[a("span",{class:"LocalVar"},"A")]),s(", "),a("a",{id:"v943573036",class:"aya-hover","aya-hover-text":"Ty (Γ' ▷ A)",href:"#v943573036"},[a("span",{class:"LocalVar"},"B")]),s(" ⇒ "),a("a",{id:"Mian-Tm-app",class:"aya-hover","aya-hover-text":"Tm (Γ' ▷ A) B",href:"#Mian-Tm-app"},[a("span",{class:"Constructor"},"app")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v102174918"},[a("span",{class:"LocalVar"},"Γ'")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ'",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ'",href:"#v52514534"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty (Γ' ▷ A)",href:"#v943573036"},[a("span",{class:"LocalVar"},"B")]),s(`)) +| _, `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{id:"v1399794302",class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1399794302"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{id:"v1924949331",class:"aya-hover","aya-hover-text":"_ << Δ",href:"#v1924949331"},[a("span",{class:"LocalVar"},"δ")]),s(" ⇒ "),a("a",{id:"Mian-Tm-sub",class:"aya-hover","aya-hover-text":"Tm _ (Subst A δ)",href:"#Mian-Tm-sub"},[a("span",{class:"Constructor"},"sub")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YxMTY3MzQ4NTgiPjxzcGFuIGNsYXNzPSJMb2NhbFZhciI+zpQ8L3NwYW4+PC9hPjwvY29kZT4KPC9wcmU+Cg=="},"_"),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1399794302"},[a("span",{class:"LocalVar"},"A")]),s(`) +| _, `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{id:"v1626343059",class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1626343059"},[a("span",{class:"LocalVar"},"A")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Γ << Δ",href:"#Mian-3c3c-π₁"},[a("span",{class:"Constructor"},"π₁")]),s(),a("a",{id:"v2032169857",class:"aya-hover","aya-hover-text":"_ << (Δ ▷ B)",href:"#v2032169857"},[a("span",{class:"LocalVar"},"δ")]),s(") ⇒ "),a("a",{id:"Mian-Tm-π₂",class:"aya-hover","aya-hover-text":"Tm _ (Subst A (π₁ δ))",href:"#Mian-Tm-π₂"},[a("span",{class:"Constructor"},"π₂")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v91912419"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3Y0NDEwMDE5NDIiPjxzcGFuIGNsYXNzPSJMb2NhbFZhciI+zpQ8L3NwYW4+PC9hPjwvY29kZT4KPC9wcmU+Cg=="},"_"),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v1626343059"},[a("span",{class:"LocalVar"},"A")]),s(`) +| _, `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{id:"v2104973502",class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v2104973502"},[a("span",{class:"LocalVar"},"B")]),s(),a("a",{id:"v735937428",class:"aya-hover","aya-hover-text":"_ << Δ",href:"#v735937428"},[a("span",{class:"LocalVar"},"δ")]),s(),a("span",{class:"Keyword"},"as"),s(),a("a",{id:"v1604247316",class:"aya-hover","aya-hover-text":"Ty _",href:"#v1604247316"},[a("span",{class:"LocalVar"},"A")]),s(" ⇒ "),a("a",{id:"Mian-Tm-π₂β",class:"aya-hover","aya-hover-text":"coe 0 1 (\\ p0 ⇒ Tm _ (Subst B (π₁β t p0))) (π₂ (δ ∷ t)) = t",href:"#Mian-Tm-π₂β"},[a("span",{class:"Constructor"},"π₂β")]),s(" {"),a("a",{id:"v1753714541",class:"aya-hover","aya-hover-text":"Con",href:"#v1753714541"},[a("span",{class:"LocalVar"},"Δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} ("),a("a",{id:"v1095273238",class:"aya-hover","aya-hover-text":"Tm _ (Subst B δ)",href:"#v1095273238"},[a("span",{class:"LocalVar"},"t")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v91912419"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty _",href:"#v1604247316"},[a("span",{class:"LocalVar"},"A")]),s(`) + : `),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst B δ)",href:"#Mian-transport"},[a("span",{class:"Fn"},"transport")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty _ → Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YxNzUyNDYxMDkwIj48c3BhbiBjbGFzcz0iTG9jYWxWYXIiPl88L3NwYW4+PC9hPjwvY29kZT4KPC9wcmU+Cg=="},"_"),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Subst B (π₁ (δ ∷ t)) = Subst B δ",href:"#Mian-pmap"},[a("span",{class:"Fn"},"pmap")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"(_ << Δ) → Ty _",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v2104973502"},[a("span",{class:"LocalVar"},"B")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"I → _ << Δ",href:"#Mian-3c3c-π₁β"},[a("span",{class:"Constructor"},"π₁β")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst B δ)",href:"#v1095273238"},[a("span",{class:"LocalVar"},"t")]),s(")) ("),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst B (π₁ (δ ∷ t)))",href:"#Mian-Tm-π₂"},[a("span",{class:"Constructor"},"π₂")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"_ << Δ",href:"#v735937428"},[a("span",{class:"LocalVar"},"δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"?_ B δ _ Δ Δ t << (?Δ' B δ _ Δ Δ t ▷ ?A B δ _ Δ Δ t)",href:"#Mian-3c3c-∷"},[a("span",{class:"Constructor"},"∷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst B δ)",href:"#v1095273238"},[a("span",{class:"LocalVar"},"t")]),s(")) "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst B δ)",href:"#v1095273238"},[a("span",{class:"LocalVar"},"t")]),s(` +| _ `),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(" _, "),a("a",{id:"v873634936",class:"aya-hover","aya-hover-text":"Ty (_ ▷ _)",href:"#v873634936"},[a("span",{class:"LocalVar"},"A")]),s(" ⇒ "),a("a",{id:"Mian-Tm-Πβ",class:"aya-hover","aya-hover-text":"app (λ f) = f",href:"#Mian-Tm-Πβ"},[a("span",{class:"Constructor"},"Πβ")]),s(" ("),a("a",{id:"v1819940427",class:"aya-hover","aya-hover-text":"Tm (_ ▷ _) A",href:"#v1819940427"},[a("span",{class:"LocalVar"},"f")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v91912419"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty (_ ▷ _)",href:"#v873634936"},[a("span",{class:"LocalVar"},"A")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Tm (_ ▷ _) A",href:"#Mian-Tm-app"},[a("span",{class:"Constructor"},"app")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Π _ A)",href:"#Mian-Tm-λ"},[a("span",{class:"Constructor"},"λ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm (_ ▷ _) A",href:"#v1819940427"},[a("span",{class:"LocalVar"},"f")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm (_ ▷ _) A",href:"#v1819940427"},[a("span",{class:"LocalVar"},"f")]),s(` +| _, `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(" _ _ "),a("span",{class:"Keyword"},"as"),s(),a("a",{id:"v1399701152",class:"aya-hover","aya-hover-text":"Ty _",href:"#v1399701152"},[a("span",{class:"LocalVar"},"A")]),s(" ⇒ "),a("a",{id:"Mian-Tm-Πη",class:"aya-hover","aya-hover-text":"λ (app f) = f",href:"#Mian-Tm-Πη"},[a("span",{class:"Constructor"},"Πη")]),s(" ("),a("a",{id:"v527829831",class:"aya-hover","aya-hover-text":"Tm _ (Π _ _)",href:"#v527829831"},[a("span",{class:"LocalVar"},"f")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v91912419"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty _",href:"#v1399701152"},[a("span",{class:"LocalVar"},"A")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Π _ _)",href:"#Mian-Tm-λ"},[a("span",{class:"Constructor"},"λ")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Tm (_ ▷ _) _",href:"#Mian-Tm-app"},[a("span",{class:"Constructor"},"app")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Π _ _)",href:"#v527829831"},[a("span",{class:"LocalVar"},"f")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Π _ _)",href:"#v527829831"},[a("span",{class:"LocalVar"},"f")]),s(` +| _, `),a("a",{class:"aya-hover","aya-hover-text":"Ty Γ",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(),a("a",{id:"v901205084",class:"aya-hover","aya-hover-text":"Ty _",href:"#v901205084"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{id:"v777457133",class:"aya-hover","aya-hover-text":"Ty (_ ▷ A)",href:"#v777457133"},[a("span",{class:"LocalVar"},"B")]),s(" ⇒ "),a("a",{id:"Mian-Tm-subλ",class:"aya-hover","aya-hover-text":`coe 0 1 (\\ p0 ⇒ Tm _ (fording p0)) (coe 0 1 (\\ p0 ⇒ Tm _ (SubΠ σ p0)) (sub (λ t))) += coe 0 1 (\\ p0 ⇒ Tm _ (fording p0)) (λ (sub t))`,href:"#Mian-Tm-subλ"},[a("span",{class:"Constructor"},"subλ")]),s(" {"),a("a",{id:"v136157810",class:"aya-hover","aya-hover-text":"Con",href:"#v136157810"},[a("span",{class:"LocalVar"},"Δ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Con"},[a("span",{class:"Data"},"Con")]),s("} {"),a("a",{id:"v122155649",class:"aya-hover","aya-hover-text":"_ << Δ",href:"#v122155649"},[a("span",{class:"LocalVar"},"σ")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v91912419"},[a("span",{class:"LocalVar"},"Γ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3c3c"},[a("span",{class:"Data"},"<<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v136157810"},[a("span",{class:"LocalVar"},"Δ")]),s("} {"),a("a",{id:"v292138977",class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v292138977"},[a("span",{class:"LocalVar"},"A'")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v136157810"},[a("span",{class:"LocalVar"},"Δ")]),s("} {"),a("a",{id:"v748842359",class:"aya-hover","aya-hover-text":"Ty (Δ ▷ A')",href:"#v748842359"},[a("span",{class:"LocalVar"},"B'")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Ty"},[a("span",{class:"Data"},"Ty")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v136157810"},[a("span",{class:"LocalVar"},"Δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v292138977"},[a("span",{class:"LocalVar"},"A'")]),s(`)} + (`),a("a",{id:"v2112233878",class:"aya-hover","aya-hover-text":`Π (Subst A' σ) (Subst B' ((σ ∘ π₁ (id refl)) ∷ transport (Tm (_ ▷ Subst A' σ)) SubAss +(π₂ (id refl)))) = Π A B`,href:"#v2112233878"},[a("span",{class:"LocalVar"},"fording")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Ty _",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty _",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v292138977"},[a("span",{class:"LocalVar"},"A'")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << Δ",href:"#v122155649"},[a("span",{class:"LocalVar"},"σ")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Ty (_ ▷ Subst A' σ)",href:"#Mian-Ty-Subst"},[a("span",{class:"Constructor"},"Subst")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty (Δ ▷ A')",href:"#v748842359"},[a("span",{class:"LocalVar"},"B'")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+KDxhIGhyZWY9IiN2MTIyMTU1NjQ5Ij48c3BhbiBjbGFzcz0iTG9jYWxWYXIiPs+DPC9zcGFuPjwvYT4gPGEgaHJlZj0iI01pYW4tM2MzYy3iiJgiPjxzcGFuIGNsYXNzPSJDb25zdHJ1Y3RvciI+4oiYPC9zcGFuPjwvYT4gPHNwYW4gY2xhc3M9IkNhbGwiPjxhIGhyZWY9IiNNaWFuLTNjM2Mtz4DigoEiPjxzcGFuIGNsYXNzPSJDb25zdHJ1Y3RvciI+z4DigoE8L3NwYW4+PC9hPiA8c3BhbiBjbGFzcz0iQ2FsbCI+KDxhIGhyZWY9IiNNaWFuLTNjM2MtaWQiPjxzcGFuIGNsYXNzPSJDb25zdHJ1Y3RvciI+aWQ8L3NwYW4+PC9hPiA8YSBocmVmPSIjTWlhbi1yZWZsIj48c3BhbiBjbGFzcz0iRm4iPnJlZmw8L3NwYW4+PC9hPik8L3NwYW4+PC9zcGFuPikgPGEgaHJlZj0iI01pYW4tM2MzYy3iiLciPjxzcGFuIGNsYXNzPSJDb25zdHJ1Y3RvciI+4oi3PC9zcGFuPjwvYT4gPHNwYW4gY2xhc3M9IkNhbGwiPjxhIGhyZWY9IiNNaWFuLXRyYW5zcG9ydCI+PHNwYW4gY2xhc3M9IkZuIj50cmFuc3BvcnQ8L3NwYW4+PC9hPiA8c3BhbiBjbGFzcz0iQ2FsbCI+KDxhIGhyZWY9IiNNaWFuLVRtIj48c3BhbiBjbGFzcz0iRGF0YSI+VG08L3NwYW4+PC9hPiAoPGEgaHJlZj0iI3YxOTMzODgwNDUiPjxzcGFuIGNsYXNzPSJMb2NhbFZhciI+Xzwvc3Bhbj48L2E+IDxhIGhyZWY9IiNNaWFuLUNvbi3ilrciPjxzcGFuIGNsYXNzPSJDb25zdHJ1Y3RvciI+4pa3PC9zcGFuPjwvYT4gPHNwYW4gY2xhc3M9IkNhbGwiPjxhIGhyZWY9IiNNaWFuLVR5LVN1YnN0Ij48c3BhbiBjbGFzcz0iQ29uc3RydWN0b3IiPlN1YnN0PC9zcGFuPjwvYT4gPGEgaHJlZj0iI3YyOTIxMzg5NzciPjxzcGFuIGNsYXNzPSJMb2NhbFZhciI+QSc8L3NwYW4+PC9hPiA8YSBocmVmPSIjdjEyMjE1NTY0OSI+PHNwYW4gY2xhc3M9IkxvY2FsVmFyIj7Pgzwvc3Bhbj48L2E+PC9zcGFuPikpPC9zcGFuPiA8YSBocmVmPSIjTWlhbi1UeS1TdWJBc3MiPjxzcGFuIGNsYXNzPSJDb25zdHJ1Y3RvciI+U3ViQXNzPC9zcGFuPjwvYT4gPHNwYW4gY2xhc3M9IkNhbGwiPig8YSBocmVmPSIjTWlhbi1UbS3PgOKCgiI+PHNwYW4gY2xhc3M9IkNvbnN0cnVjdG9yIj7PgOKCgjwvc3Bhbj48L2E+IDxzcGFuIGNsYXNzPSJDYWxsIj4oPGEgaHJlZj0iI01pYW4tM2MzYy1pZCI+PHNwYW4gY2xhc3M9IkNvbnN0cnVjdG9yIj5pZDwvc3Bhbj48L2E+IDxhIGhyZWY9IiNNaWFuLXJlZmwiPjxzcGFuIGNsYXNzPSJGbiI+cmVmbDwvc3Bhbj48L2E+KTwvc3Bhbj4pPC9zcGFuPjwvc3Bhbj48L2NvZGU+CjwvcHJlPgo="},"_"),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty _",href:"#Mian-Ty-Π"},[a("span",{class:"Constructor"},"Π")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty _",href:"#v901205084"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty (_ ▷ A)",href:"#v777457133"},[a("span",{class:"LocalVar"},"B")]),s(") {"),a("a",{id:"v372469954",class:"aya-hover","aya-hover-text":"Tm (Δ ▷ A') B'",href:"#v372469954"},[a("span",{class:"LocalVar"},"t")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#v136157810"},[a("span",{class:"LocalVar"},"Δ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Con",href:"#Mian-Con-▷"},[a("span",{class:"Constructor"},"▷")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Ty Δ",href:"#v292138977"},[a("span",{class:"LocalVar"},"A'")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Ty (Δ ▷ A')",href:"#v748842359"},[a("span",{class:"LocalVar"},"B'")]),s(`} + : `),a("span",{class:"Keyword"},"let"),s(),a("a",{id:"v457247584",href:"#v457247584"},[a("span",{class:"LocalVar"},"ford")]),s(" := "),a("a",{class:"aya-hover","aya-hover-text":`Tm _ (Π (Subst A' σ) (Subst B' ((σ ∘ π₁ (id refl)) ∷ transport (Tm (_ ▷ Subst A' +σ)) SubAss (π₂ (id refl))))) → Tm _ (Π A B)`,href:"#Mian-transport"},[a("span",{class:"Fn"},"transport")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty _ → Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YxOTMzODgwNDUiPjxzcGFuIGNsYXNzPSJMb2NhbFZhciI+Xzwvc3Bhbj48L2E+PC9jb2RlPgo8L3ByZT4K"},"_"),s(") "),a("a",{class:"aya-hover","aya-hover-text":`Π (Subst A' σ) (Subst B' ((σ ∘ π₁ (id refl)) ∷ transport (Tm (_ ▷ Subst A' σ)) SubAss +(π₂ (id refl)))) = Π A B`,href:"#v2112233878"},[a("span",{class:"LocalVar"},"fording")]),s(` + `),a("span",{class:"Keyword"},"in"),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Π A B)",href:"#v457247584"},[a("span",{class:"LocalVar"},"ford")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Π (Subst A' σ) (Subst B' (ext σ A')))",href:"#Mian-transport"},[a("span",{class:"Fn"},"transport")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Ty _ → Type 0",href:"#Mian-Tm"},[a("span",{class:"Data"},"Tm")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YxOTMzODgwNDUiPjxzcGFuIGNsYXNzPSJMb2NhbFZhciI+Xzwvc3Bhbj48L2E+PC9jb2RlPgo8L3ByZT4K"},"_"),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"I → Ty _",href:"#Mian-Ty-SubΠ"},[a("span",{class:"Constructor"},"SubΠ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"_ << Δ",href:"#v122155649"},[a("span",{class:"LocalVar"},"σ")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Subst (Π A' B') σ)",href:"#Mian-Tm-sub"},[a("span",{class:"Constructor"},"sub")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Tm Δ (Π A' B')",href:"#Mian-Tm-λ"},[a("span",{class:"Constructor"},"λ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm (Δ ▷ A') B'",href:"#v372469954"},[a("span",{class:"LocalVar"},"t")]),s(`))) + `),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm _ (Π A B)",href:"#v457247584"},[a("span",{class:"LocalVar"},"ford")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":`Tm _ (Π (Subst A' σ) (Subst B' ((σ ∘ π₁ (id refl)) ∷ transport (Tm (_ ▷ Subst A' +σ)) SubAss (π₂ (id refl)))))`,href:"#Mian-Tm-λ"},[a("span",{class:"Constructor"},"λ")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":`Tm (_ ▷ Subst A' σ) (Subst B' ((σ ∘ π₁ (id refl)) ∷ transport (Tm (_ ▷ Subst A' σ)) +SubAss (π₂ (id refl))))`,href:"#Mian-Tm-sub"},[a("span",{class:"Constructor"},"sub")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Tm (Δ ▷ A') B'",href:"#v372469954"},[a("span",{class:"LocalVar"},"t")]),s("))")]),s(` +`)],-1),i('

An instance of type Tm Γ A corresponds to the tt in the judgment Γt:AΓ⊢t:A.

',1)]))}const I=V(w,[["render",S]]);export{P as __pageData,I as default}; diff --git a/assets/chunks/@localSearchIndexroot.BEfJRxcB.js b/assets/chunks/@localSearchIndexroot.BEfJRxcB.js new file mode 100644 index 0000000..ed3f731 --- /dev/null +++ b/assets/chunks/@localSearchIndexroot.BEfJRxcB.js @@ -0,0 +1 @@ +const e=`{"documentCount":61,"nextId":61,"documentIds":{"0":"/blog/binops.html#binary-operators-in-aya","1":"/blog/bye-hott.html#moving-away-from-univalent-type-theory","2":"/blog/class-defeq.html#class-extension-with-definitional-projection","3":"/blog/class-defeq.html#anonymous-extensions","4":"/blog/class-defeq.html#definitional-projection","5":"/blog/class-defeq.html#implementation","6":"/blog/extended-pruning.html#extended-pruning-for-pattern-unification","7":"/blog/extended-pruning.html#case-study","8":"/blog/ind-prop.html#impredicative-props-are-hard","9":"/blog/ind-prop.html#motivation","10":"/blog/ind-prop.html#ad-hoc-termination-rules-of-impredicative-prop","11":"/blog/ind-prop.html#alternative-ways-to-impredicativity","12":"/blog/index-unification.html#index-unification-and-forced-patterns-in-aya","13":"/blog/index-unification.html#the-so-called-meta-patteriables","14":"/blog/#aya-blogs","15":"/blog/lang-exts.html#haskell-or-agda-style-extensions","16":"/blog/lang-exts.html#agda-s-extensions","17":"/blog/lang-exts.html#aya-s-choice","18":"/blog/lang-exts.html#safe-flag","19":"/blog/lang-exts.html#conclusion","20":"/blog/lang-exts.html#library-design","21":"/blog/path-elab.html#elaboration-of-the-extension-type","22":"/blog/path-elab.html#first-attempt","23":"/blog/path-elab.html#second-attempt","24":"/blog/path-elab.html#third-attempt","25":"/blog/path-elab.html#update-2023-03-24","26":"/blog/pathcon-elab.html#elaboration-of-path-constructors","27":"/blog/pathcon-elab.html#syntax","28":"/blog/pathcon-elab.html#flattening","29":"/blog/pathcon-elab.html#example","30":"/blog/tt-in-tt-qiit.html#type-theory-in-type-theory-using-quotient-inductive-types","31":"/blog/tt-in-tt-qiit.html#prelude","32":"/blog/tt-in-tt-qiit.html#context","33":"/blog/tt-in-tt-qiit.html#types","34":"/blog/tt-in-tt-qiit.html#substitution-objects","35":"/blog/tt-in-tt-qiit.html#terms","36":"/guide/fake-literate.html#fake-literate-mode","37":"/guide/haskeller-tutorial.html#so-you-know-some-haskell","38":"/guide/haskeller-tutorial.html#working-with-the-repl","39":"/guide/haskeller-tutorial.html#working-with-projects","40":"/guide/haskeller-tutorial.html#programming-in-aya","41":"/guide/haskeller-tutorial.html#type-level-programming","42":"/guide/haskeller-tutorial.html#type-families","43":"/guide/haskeller-tutorial.html#overlapping-patterns","44":"/guide/#the-aya-prover","45":"/guide/install.html#install-aya","46":"/guide/install.html#download-from-github-release","47":"/guide/install.html#use-aya-in-github-actions","48":"/guide/install.html#if-you-already-have-java-runtime","49":"/guide/install.html#prebuilt-binary","50":"/guide/install.html#build-from-source","51":"/guide/project-tutorial.html#aya-package","52":"/guide/prover-tutorial.html#proof-assistants-user-tutorial","53":"/guide/prover-tutorial.html#function-extensionality","54":"/guide/prover-tutorial.html#cubical","55":"/guide/prover-tutorial.html#overlapping-and-order-independent-pattern-matching","56":"/guide/prover-tutorial.html#heterogeneous-equality","57":"/guide/prover-tutorial.html#quotient-inductive-types","58":"/guide/readings.html#recommended-reading","59":"/guide/vscode-tutorial.html#so-you-are-using-vscode","60":"/pubs/#publications"},"fieldIds":{"title":0,"titles":1,"text":2},"fieldLength":{"0":[4,1,188],"1":[6,1,315],"2":[5,1,51],"3":[2,5,64],"4":[2,5,51],"5":[1,5,125],"6":[5,1,169],"7":[2,5,158],"8":[4,1,30],"9":[1,4,63],"10":[7,4,236],"11":[4,4,87],"12":[7,1,166],"13":[7,7,140],"14":[2,1,29],"15":[5,1,42],"16":[3,5,165],"17":[4,5,125],"18":[3,9,118],"19":[1,9,40],"20":[2,5,71],"21":[6,1,150],"22":[2,6,102],"23":[2,6,73],"24":[2,6,73],"25":[5,6,100],"26":[4,1,27],"27":[1,4,33],"28":[1,4,50],"29":[1,4,106],"30":[7,1,12],"31":[1,7,33],"32":[1,7,50],"33":[1,7,89],"34":[2,7,59],"35":[1,7,52],"36":[3,1,170],"37":[5,1,30],"38":[4,5,124],"39":[3,5,76],"40":[3,5,213],"41":[3,5,117],"42":[2,5,131],"43":[2,5,120],"44":[3,1,111],"45":[2,1,70],"46":[4,2,87],"47":[5,2,39],"48":[7,2,42],"49":[2,9,22],"50":[3,9,98],"51":[2,1,87],"52":[4,1,75],"53":[2,4,115],"54":[1,4,212],"55":[6,4,95],"56":[2,4,175],"57":[3,4,213],"58":[2,1,47],"59":[5,1,143],"60":[1,1,13]},"averageFieldLength":[3.1639344262295084,3.8852459016393444,99.45901639344262],"storedFields":{"0":{"title":"Binary operators in Aya","titles":[]},"1":{"title":"Moving away from univalent type theory","titles":[]},"2":{"title":"Class extension with definitional projection","titles":[]},"3":{"title":"Anonymous extensions","titles":["Class extension with definitional projection"]},"4":{"title":"Definitional projection","titles":["Class extension with definitional projection"]},"5":{"title":"Implementation","titles":["Class extension with definitional projection"]},"6":{"title":"Extended pruning for pattern unification","titles":[]},"7":{"title":"Case Study","titles":["Extended pruning for pattern unification"]},"8":{"title":"Impredicative Props are hard","titles":[]},"9":{"title":"Motivation","titles":["Impredicative Props are hard"]},"10":{"title":"Ad-hoc termination rules of impredicative Prop","titles":["Impredicative Props are hard"]},"11":{"title":"Alternative ways to impredicativity","titles":["Impredicative Props are hard"]},"12":{"title":"Index unification and forced patterns in Aya","titles":[]},"13":{"title":"The so-called "meta patteriables"","titles":["Index unification and forced patterns in Aya"]},"14":{"title":"Aya blogs","titles":[]},"15":{"title":"Haskell or Agda style extensions","titles":[]},"16":{"title":"Agda's extensions","titles":["Haskell or Agda style extensions"]},"17":{"title":"Aya's choice?","titles":["Haskell or Agda style extensions"]},"18":{"title":"Safe flag?","titles":["Haskell or Agda style extensions","Aya's choice?"]},"19":{"title":"Conclusion","titles":["Haskell or Agda style extensions","Aya's choice?"]},"20":{"title":"Library Design","titles":["Haskell or Agda style extensions"]},"21":{"title":"Elaboration of the "extension" type","titles":[]},"22":{"title":"First attempt","titles":["Elaboration of the "extension" type"]},"23":{"title":"Second attempt","titles":["Elaboration of the "extension" type"]},"24":{"title":"Third attempt","titles":["Elaboration of the "extension" type"]},"25":{"title":"Update (2023-03-24)","titles":["Elaboration of the "extension" type"]},"26":{"title":"Elaboration of path constructors","titles":[]},"27":{"title":"Syntax","titles":["Elaboration of path constructors"]},"28":{"title":"Flattening","titles":["Elaboration of path constructors"]},"29":{"title":"Example","titles":["Elaboration of path constructors"]},"30":{"title":"Type Theory in Type Theory using Quotient Inductive Types","titles":[]},"31":{"title":"Prelude","titles":["Type Theory in Type Theory using Quotient Inductive Types"]},"32":{"title":"Context","titles":["Type Theory in Type Theory using Quotient Inductive Types"]},"33":{"title":"Types","titles":["Type Theory in Type Theory using Quotient Inductive Types"]},"34":{"title":"Substitution objects","titles":["Type Theory in Type Theory using Quotient Inductive Types"]},"35":{"title":"Terms","titles":["Type Theory in Type Theory using Quotient Inductive Types"]},"36":{"title":"Fake literate mode","titles":[]},"37":{"title":"So you know some Haskell","titles":[]},"38":{"title":"Working with the REPL","titles":["So you know some Haskell"]},"39":{"title":"Working with projects","titles":["So you know some Haskell"]},"40":{"title":"Programming in Aya","titles":["So you know some Haskell"]},"41":{"title":"Type-level programming","titles":["So you know some Haskell"]},"42":{"title":"Type families","titles":["So you know some Haskell"]},"43":{"title":"Overlapping patterns","titles":["So you know some Haskell"]},"44":{"title":"The Aya Prover","titles":[]},"45":{"title":"Install Aya","titles":[]},"46":{"title":"Download from GitHub Release","titles":["Install Aya"]},"47":{"title":"Use Aya in GitHub Actions","titles":["Install Aya"]},"48":{"title":"If you already have Java runtime...","titles":["Install Aya"]},"49":{"title":"Prebuilt binary","titles":["Install Aya","If you already have Java runtime..."]},"50":{"title":"Build from source","titles":["Install Aya","If you already have Java runtime..."]},"51":{"title":"Aya Package","titles":[]},"52":{"title":"Proof assistants' user tutorial","titles":[]},"53":{"title":"Function extensionality","titles":["Proof assistants' user tutorial"]},"54":{"title":"Cubical","titles":["Proof assistants' user tutorial"]},"55":{"title":"Overlapping and Order-independent Pattern Matching","titles":["Proof assistants' user tutorial"]},"56":{"title":"Heterogeneous equality","titles":["Proof assistants' user tutorial"]},"57":{"title":"Quotient inductive types","titles":["Proof assistants' user tutorial"]},"58":{"title":"Recommended Reading","titles":[]},"59":{"title":"So you are using VSCode","titles":[]},"60":{"title":"Publications","titles":[]}},"dirtCount":0,"index":[["β",{"2":{"54":1}}],["\`ide",{"2":{"50":1}}],["$path",{"2":{"46":1}}],["$user",{"2":{"46":1}}],["$",{"2":{"46":4}}],["$aya",{"2":{"46":2}}],["✨lambdas✨",{"2":{"38":1}}],["≃",{"2":{"36":4}}],["ν",{"2":{"34":3}}],["ξ",{"2":{"34":3}}],["εη",{"2":{"34":1}}],["ε",{"2":{"34":2}}],["↑",{"2":{"33":1,"54":2,"56":1}}],["∘",{"2":{"33":2,"34":9}}],["θ",{"2":{"33":6,"34":10}}],["δγ⊢σ",{"2":{"34":1}}],["δγ",{"2":{"34":1}}],["δ",{"2":{"33":30,"34":35,"35":10}}],["⋅",{"2":{"32":2}}],["▷",{"2":{"32":1,"33":4,"34":5,"35":6}}],["¬j↦p",{"2":{"29":4}}],["¬",{"2":{"29":8}}],["¬i↦b",{"2":{"29":12}}],["¬i¬",{"2":{"27":1}}],["​→π",{"2":{"29":2}}],["​",{"2":{"28":3,"29":4}}],["↦",{"2":{"28":2}}],["↦u",{"2":{"28":4}}],["φ",{"2":{"28":6}}],["φ↦",{"2":{"27":1,"28":2}}],["φ↦u​",{"2":{"27":1,"28":2}}],["φ↦u",{"2":{"27":1,"28":2}}],["⋯",{"2":{"28":2}}],["^",{"2":{"21":2,"51":2}}],["↓",{"2":{"21":2}}],["ℓ",{"2":{"21":2}}],["≡",{"2":{"21":5}}],["👈",{"2":{"14":1}}],["😉",{"2":{"12":1}}],["≅",{"2":{"11":1}}],["⊤",{"2":{"11":1}}],["σσσ",{"2":{"34":1}}],["σ",{"2":{"11":1,"33":4,"34":8,"35":3}}],["⊥",{"2":{"10":2,"11":1}}],["9",{"2":{"7":1}}],["╰──────────────╯",{"2":{"7":3}}],["871094",{"2":{"36":1}}],["8c8c8c",{"2":{"36":1}}],["8",{"2":{"7":1}}],["│",{"2":{"7":7}}],["6",{"2":{"7":1,"40":1}}],["ℕ",{"2":{"7":5}}],["∷∘",{"2":{"34":1}}],["∷",{"2":{"7":9,"33":1,"34":6,"35":1}}],["zro",{"2":{"57":4}}],["zip",{"2":{"46":9}}],["zero",{"2":{"7":1,"12":3,"13":4,"23":2,"36":3,"40":4,"42":1,"52":1}}],["zs",{"2":{"6":6,"7":35,"56":16}}],["λ",{"2":{"7":1,"10":1,"21":12,"22":1,"23":2,"35":5,"38":2,"40":3}}],["∀",{"2":{"7":1,"12":2,"13":1,"54":1,"57":2}}],["q~",{"2":{"29":1}}],["quit",{"2":{"38":1}}],["quite",{"2":{"12":1,"18":1,"59":1}}],["quick",{"2":{"36":1}}],["qualified",{"2":{"39":1,"40":1,"41":1}}],["quad",{"2":{"28":1,"32":2}}],["quantification",{"2":{"9":1}}],["question",{"2":{"9":1,"10":1,"29":1,"53":2}}],["quotients",{"2":{"44":1,"57":1}}],["quotient",{"0":{"30":1,"57":1},"1":{"31":1,"32":1,"33":1,"34":1,"35":1},"2":{"1":1,"57":2}}],["quot",{"0":{"13":2,"21":2},"1":{"22":2,"23":2,"24":2,"25":2},"2":{"1":2,"6":4,"10":4,"11":2,"12":12,"13":8,"15":2,"17":4,"18":10,"21":6,"22":2,"24":2,"40":4,"53":2,"54":4,"59":4}}],["q",{"2":{"6":3,"21":3,"29":7,"38":1,"54":6}}],["­⊢",{"2":{"6":4}}],["γ⊢t",{"2":{"35":1}}],["γ⊢σ",{"2":{"34":1}}],["γ⊢el",{"2":{"33":1}}],["γ⊢",{"2":{"33":2}}],["γ⊢u",{"2":{"33":2}}],["γ⊢a",{"2":{"32":2,"33":6}}],["γ⊢a~",{"2":{"32":1}}],["γ~",{"2":{"32":1}}],["γγγ",{"2":{"32":1}}],["γ",{"2":{"6":13,"32":5,"33":14,"34":15,"35":11}}],["⇒",{"2":{"6":1,"31":8,"33":1,"34":5,"35":8,"40":8,"41":5,"42":8,"52":2,"53":7,"54":12,"55":8,"56":16,"57":15}}],["1cm",{"2":{"36":1}}],["145304",{"2":{"36":1}}],["15cm",{"2":{"36":2}}],["198",{"2":{"13":1}}],["1",{"2":{"6":5,"7":3,"21":6,"22":1,"28":6,"29":2,"31":1,"36":26,"40":6,"54":8,"56":2,"57":4}}],["0cm",{"2":{"36":1}}],["0pt",{"2":{"36":1}}],["0033b3",{"2":{"36":1}}],["00627a",{"2":{"36":5}}],["067d17",{"2":{"36":1}}],["0em",{"2":{"36":2}}],["03",{"0":{"25":1}}],["0",{"2":{"6":5,"7":3,"10":4,"12":2,"13":2,"21":5,"29":2,"31":1,"36":10,"40":2,"41":1,"42":1,"43":7,"51":1,"54":10,"55":6,"56":3,"57":8}}],["→π",{"2":{"29":4}}],["→isprop",{"2":{"29":2}}],["→flatten",{"2":{"28":2}}],["→y",{"2":{"28":2}}],["→y​",{"2":{"28":1}}],["→yflatten",{"2":{"28":1}}],["→",{"2":{"6":2,"7":2,"10":8,"21":16,"22":1,"23":2,"28":3,"29":10,"31":2,"41":2,"52":2,"54":5,"56":1,"57":5}}],["η",{"2":{"5":1,"22":2,"25":1,"54":1}}],["⊢",{"2":{"5":2,"34":1}}],[">>",{"2":{"46":1}}],[">++",{"2":{"42":2}}],[">=",{"2":{"7":6}}],[">",{"2":{"3":2,"10":6,"12":6,"13":3,"29":8,"40":8,"41":1,"42":4}}],["|",{"2":{"3":5,"10":1,"21":18,"24":8,"29":2,"32":2,"33":9,"34":12,"35":8,"40":7,"41":4,"42":10,"43":4,"52":2,"53":4,"55":9,"56":9,"57":19}}],["jon",{"2":{"58":1}}],["json",{"2":{"51":5,"59":1}}],["jpackage",{"2":{"50":2}}],["jlinkaya",{"2":{"50":1}}],["jlink",{"2":{"45":1,"46":3,"50":1,"59":2}}],["jvm",{"2":{"44":1}}],["jit",{"2":{"44":1}}],["jars",{"2":{"48":1,"50":1}}],["jar",{"2":{"36":2,"38":3,"49":3,"50":1,"51":3,"59":2}}],["java",{"0":{"48":1},"1":{"49":1,"50":1},"2":{"1":1,"2":1,"16":2,"36":1,"38":1,"48":1,"49":1,"50":1,"51":1,"59":3}}],["judgmental",{"2":{"54":1,"57":3}}],["judgmentally",{"2":{"43":1}}],["judgment",{"2":{"32":2,"33":2,"35":1}}],["just",{"2":{"1":1,"7":1,"10":1,"13":1,"17":2,"41":2,"42":3,"54":1,"55":1,"57":1,"58":1}}],["j~i",{"2":{"29":1}}],["j↦",{"2":{"29":4}}],["j↦q",{"2":{"29":4}}],["j​​",{"2":{"28":1}}],["j​",{"2":{"28":2}}],["j",{"2":{"21":6,"28":6,"29":8,"54":1,"56":1,"57":4}}],["α",{"2":{"1":1}}],["πβ",{"2":{"35":1}}],["πη",{"2":{"34":1,"35":1}}],["π₂β",{"2":{"35":1}}],["π₂",{"2":{"33":1,"34":1,"35":2}}],["π₁β",{"2":{"34":1,"35":1}}],["π₁",{"2":{"33":1,"34":3,"35":1}}],["π",{"2":{"1":1,"22":1,"25":2,"28":4,"29":7,"33":4,"35":6,"38":1}}],["à",{"2":{"1":1,"25":1}}],["vscode",{"0":{"59":1},"2":{"39":2,"44":2,"49":1,"59":3}}],["vspace",{"2":{"36":2}}],["via",{"2":{"15":1}}],["vcons",{"2":{"12":2,"13":1}}],["vnil",{"2":{"12":3,"13":3}}],["values",{"2":{"41":1,"57":1}}],["valid",{"2":{"10":1,"12":1,"13":1,"22":1,"57":1}}],["vartriangleright",{"2":{"32":1}}],["various",{"2":{"9":1}}],["variables",{"2":{"12":1,"55":1}}],["variable",{"2":{"6":1,"7":1,"12":1,"13":5,"22":1,"31":1,"38":1,"40":1,"41":2,"42":2,"46":1,"52":1,"56":1}}],["vague",{"2":{"20":1}}],["vanilla",{"2":{"6":1}}],["ve",{"2":{"6":1,"16":1}}],["vector",{"2":{"12":1,"42":2,"56":2}}],["vectors",{"2":{"6":1,"54":1,"56":1}}],["vecb",{"2":{"6":4}}],["veca",{"2":{"6":4}}],["vec",{"2":{"6":9,"7":11,"12":5,"13":4,"42":9,"43":2,"56":19}}],["verify",{"2":{"54":1}}],["verbosity",{"2":{"17":1}}],["version>",{"2":{"50":1,"51":1}}],["version",{"2":{"1":2,"12":2,"14":1,"21":2,"24":1,"36":1,"40":1,"45":2,"47":2,"49":1,"51":2,"53":1,"59":1}}],["very",{"2":{"0":1,"4":1,"6":1,"7":1,"10":3,"17":1,"39":1,"41":1,"43":2,"45":1,"48":1,"53":1,"54":1}}],["v0",{"2":{"1":1}}],["gadts",{"2":{"42":1}}],["github",{"0":{"46":1,"47":1},"2":{"37":1,"45":2,"46":1,"47":1,"52":1,"59":1}}],["given",{"2":{"22":1}}],["ghci",{"2":{"37":1,"38":2}}],["guide",{"2":{"44":1}}],["guides",{"2":{"1":1}}],["guess",{"2":{"18":1}}],["guaranteed",{"2":{"18":1}}],["goal",{"2":{"53":4}}],["go",{"2":{"40":1,"45":1,"58":1,"59":1}}],["gonna",{"2":{"20":1}}],["got",{"2":{"10":1}}],["good",{"2":{"7":2,"10":1,"16":2,"21":1,"43":1,"58":1}}],["going",{"2":{"0":1,"17":1,"22":1}}],["generic",{"2":{"38":1}}],["generation",{"2":{"44":1}}],["generating",{"2":{"10":1}}],["generate",{"2":{"10":1,"13":2,"22":3,"24":1,"36":1,"50":1}}],["generates",{"2":{"7":1,"36":1}}],["generated",{"2":{"6":1,"36":2,"40":1}}],["generality",{"2":{"21":1}}],["generalized",{"2":{"1":1,"21":1,"24":1}}],["general",{"2":{"6":1,"7":1,"9":1,"16":1,"45":1}}],["get",{"2":{"6":1,"9":1,"10":1,"11":1,"22":1,"38":1,"42":1,"54":1}}],["gets",{"2":{"5":1,"21":1}}],["gradle",{"2":{"50":2}}],["gradlew",{"2":{"50":7}}],["gratzer",{"2":{"1":1}}],["great",{"2":{"37":1,"52":1}}],["grp",{"2":{"5":9}}],["group>",{"2":{"51":1}}],["group⊢grp",{"2":{"5":2}}],["grouphom",{"2":{"3":2,"4":2}}],["group",{"2":{"3":6,"4":3,"5":7,"51":2}}],["g",{"2":{"1":1,"13":1,"22":1,"36":1,"46":1,"54":7,"57":7}}],["gt",{"2":{"1":3,"13":1,"23":3,"36":2,"38":2,"40":6,"41":5,"42":1,"43":1,"51":2,"53":1,"54":4,"55":1,"56":1}}],["up",{"2":{"52":1}}],["updated",{"2":{"25":1,"45":1}}],["update",{"0":{"25":1}}],["uγ⊢a",{"2":{"33":1}}],["uγ⊢el",{"2":{"33":1}}],["u​",{"2":{"33":1}}],["u",{"2":{"5":6,"27":1,"28":4,"33":11}}],["unless",{"2":{"48":1,"53":1}}],["unlike",{"2":{"40":1}}],["unzip",{"2":{"46":1,"59":1}}],["under",{"2":{"59":1}}],["understand",{"2":{"52":1}}],["underscored",{"2":{"40":1}}],["undergraduate",{"2":{"7":1}}],["unqualify",{"2":{"39":1,"40":1}}],["unrelated",{"2":{"25":1}}],["unsolved",{"2":{"24":1}}],["unsafecoerce",{"2":{"43":1}}],["unsafe",{"2":{"18":3,"19":1,"20":1}}],["unhappy",{"2":{"17":1}}],["unfortunately",{"2":{"17":1}}],["unfold",{"2":{"1":1}}],["unfolding",{"2":{"1":1}}],["unclear",{"2":{"10":1}}],["unchecked",{"2":{"1":1}}],["uninteresting",{"2":{"57":1}}],["unit",{"2":{"42":5,"57":2}}],["unique",{"2":{"7":1,"57":1}}],["unify",{"2":{"23":1}}],["unification",{"0":{"6":1,"12":1},"1":{"7":1,"13":1},"2":{"6":5,"7":2,"12":2,"13":1,"16":1,"17":1}}],["uniform",{"2":{"5":1}}],["uniformly",{"2":{"1":1}}],["universes",{"2":{"1":1,"10":1}}],["universe",{"2":{"1":5,"10":1,"25":1}}],["univalent",{"0":{"1":1},"2":{"1":1}}],["usual",{"2":{"55":1}}],["usually",{"2":{"10":2}}],["usable",{"2":{"50":1}}],["us",{"2":{"17":1,"54":1}}],["user",{"0":{"52":1},"1":{"53":1,"54":1,"55":1,"56":1,"57":1}}],["users",{"2":{"1":1,"38":1,"43":1,"44":2,"51":1,"52":1}}],["useless",{"2":{"43":1}}],["usepackage",{"2":{"36":2}}],["used",{"2":{"6":1,"12":2,"27":2,"28":1,"38":1,"40":1,"51":1}}],["uses",{"2":{"2":1,"10":1,"21":1,"32":1,"33":1,"42":1,"47":1}}],["useful",{"2":{"1":1,"7":1,"17":2,"18":1,"43":1}}],["use",{"0":{"47":1},"2":{"1":4,"7":1,"8":1,"11":1,"12":1,"16":1,"17":2,"18":1,"20":1,"21":3,"36":2,"38":5,"39":3,"40":5,"41":1,"42":1,"43":1,"47":2,"50":1,"52":1,"56":3,"59":3}}],["using",{"0":{"30":1,"59":1},"1":{"31":1,"32":1,"33":1,"34":1,"35":1},"2":{"0":1,"6":1,"10":4,"17":1,"21":1,"38":1,"39":3,"40":1,"41":2,"42":1,"45":1,"48":1,"49":2,"51":1,"54":1,"55":1,"56":1,"57":3}}],["43",{"2":{"7":3}}],["49",{"2":{"7":3}}],["40",{"2":{"7":4}}],["41",{"2":{"7":4}}],["4",{"2":{"0":1}}],["31",{"2":{"51":1}}],["35936",{"2":{"36":1}}],["39",{"2":{"7":10}}],["30",{"2":{"1":1}}],["3",{"2":{"0":1}}],["=π",{"2":{"28":3,"29":6}}],["=aa=",{"2":{"28":1}}],["=a",{"2":{"28":1}}],["==>",{"2":{"5":1}}],["=",{"2":{"0":1,"1":1,"3":6,"5":4,"6":1,"7":46,"10":6,"11":1,"12":4,"13":3,"21":11,"24":1,"28":7,"29":5,"31":5,"33":5,"34":11,"35":6,"38":2,"40":3,"41":1,"43":3,"52":1,"53":3,"54":33,"55":5,"56":9,"57":7}}],["=>",{"2":{"0":4,"6":3,"7":2,"43":4,"54":3,"56":2}}],["~i",{"2":{"29":2}}],["~",{"2":{"0":1,"5":1,"7":6,"21":3,"28":2,"32":1,"33":2,"36":2,"46":3}}],["löf",{"2":{"53":1}}],["lsp",{"2":{"49":1,"50":2,"59":3}}],["l",{"2":{"38":1}}],["lysxia",{"2":{"10":1}}],["lts",{"2":{"48":1}}],["lt",{"2":{"10":2,"33":16,"34":32,"35":4,"36":2,"40":5,"41":3,"42":6,"43":1,"51":2,"56":4}}],["ll",{"2":{"10":2,"15":1,"19":1,"22":1,"54":1}}],["little",{"2":{"52":1}}],["literal",{"2":{"40":1}}],["literals",{"2":{"40":1}}],["literate",{"0":{"36":1},"2":{"36":3,"44":1}}],["linux",{"2":{"46":6}}],["link",{"2":{"30":1,"58":1}}],["linear",{"2":{"40":1}}],["line",{"2":{"15":1,"49":1,"57":9,"59":1}}],["libs",{"2":{"50":1}}],["lib",{"2":{"20":1}}],["library",{"0":{"20":1},"2":{"7":1,"16":2,"17":1,"20":1,"21":1}}],["libraries",{"2":{"1":1,"16":1,"20":2}}],["listed",{"2":{"46":1}}],["lists",{"2":{"20":1}}],["list",{"2":{"14":1,"53":1,"58":2,"60":1}}],["limited",{"2":{"6":1}}],["lightweight",{"2":{"4":1}}],["likely",{"2":{"38":1}}],["like",{"2":{"0":3,"10":3,"16":1,"17":2,"20":4,"22":1,"29":3,"36":1,"38":1,"40":3,"41":1,"42":1,"44":1,"47":1,"50":1,"56":1,"57":2}}],["lame",{"2":{"56":1}}],["lambda",{"2":{"22":2,"54":1}}],["lambdas",{"2":{"21":1,"22":1,"38":1}}],["latter",{"2":{"53":1}}],["latex",{"2":{"36":2}}],["later",{"2":{"16":1,"29":1}}],["latest",{"2":{"14":1,"36":1,"47":2,"48":1,"59":1}}],["layer",{"2":{"11":1}}],["lax",{"2":{"6":1}}],["last",{"2":{"1":1,"18":1,"57":1}}],["la",{"2":{"1":1,"25":1}}],["languages",{"2":{"16":1,"36":1}}],["language",{"2":{"1":1,"3":1,"5":2,"11":2,"15":1,"16":9,"17":4,"18":1,"19":1,"42":3,"44":2,"50":3,"59":1}}],["lemma",{"2":{"55":1,"56":2,"57":2}}],["lemmas",{"2":{"20":1,"54":1,"55":1}}],["lesson",{"2":{"22":1,"23":1}}],["let",{"2":{"12":1,"13":2,"16":1,"35":1,"36":2,"39":1,"40":2,"50":1,"54":1}}],["len",{"2":{"12":8,"13":5}}],["lennon",{"2":{"10":1}}],["leads",{"2":{"21":1,"23":1}}],["lead",{"2":{"18":1,"19":1}}],["least",{"2":{"16":1}}],["lean",{"2":{"10":1,"20":1,"38":1,"57":1}}],["leaf",{"2":{"10":2}}],["level",{"0":{"41":1},"2":{"1":1,"17":3,"40":2,"44":1}}],["levels",{"2":{"0":1,"15":1,"17":1,"38":1}}],["leftskip",{"2":{"36":2}}],["left",{"2":{"0":3,"6":2,"10":5,"40":1,"54":3,"57":8}}],["load",{"2":{"38":1,"59":1}}],["looser",{"2":{"34":1,"40":1}}],["looking",{"2":{"16":1,"57":1}}],["look",{"2":{"6":1,"43":1,"52":1}}],["lookup",{"2":{"0":1}}],["looks",{"2":{"0":1,"10":1,"21":1,"29":1,"40":1,"56":1}}],["lot",{"2":{"16":1,"23":1}}],["logical",{"2":{"18":3}}],["logic",{"2":{"11":1}}],["long",{"2":{"9":1}}],["longer",{"2":{"1":1,"11":1}}],["lossy",{"2":{"7":1}}],["locally",{"2":{"1":1}}],["lower",{"2":{"0":1,"40":1}}],["yaml",{"2":{"47":1}}],["yellow",{"2":{"59":1}}],["yet",{"2":{"24":1,"54":1}}],["yes",{"2":{"1":1,"41":1,"42":1}}],["ys",{"2":{"6":6,"7":35,"42":6,"56":22}}],["yourself",{"2":{"54":1,"56":1}}],["your",{"2":{"6":2,"16":1,"36":2,"38":1,"45":1,"46":2,"47":1,"50":1,"51":1,"53":1,"59":1}}],["you",{"0":{"37":1,"48":1,"59":1},"1":{"38":1,"39":1,"40":1,"41":1,"42":1,"43":1,"49":1,"50":1},"2":{"4":1,"9":1,"10":5,"13":1,"15":2,"18":1,"24":1,"33":1,"36":4,"37":2,"38":6,"39":1,"40":7,"41":2,"42":3,"43":1,"45":1,"46":2,"47":3,"48":1,"50":3,"51":1,"52":4,"53":7,"54":3,"55":4,"56":1,"57":2,"58":1,"59":7}}],["y",{"2":{"0":2,"28":11,"31":2,"39":1}}],["x64",{"2":{"46":5}}],["xcolor",{"2":{"36":1}}],["x3c",{"2":{"36":1,"40":14,"42":2,"43":2,"50":3,"51":5,"56":2}}],["x27",{"2":{"28":4}}],["xs",{"2":{"6":6,"7":31,"10":6,"42":4,"43":4,"56":20}}],["xtt",{"2":{"1":5}}],["x",{"2":{"0":4,"7":12,"10":4,"12":4,"13":2,"27":3,"28":27,"31":2,"38":5,"39":14,"40":3,"41":6,"42":9,"53":7,"56":6,"57":3}}],["+>",{"2":{"40":13,"43":2}}],["++",{"2":{"6":12,"7":15,"43":4,"56":31}}],["+",{"2":{"0":8,"6":14,"7":11,"40":7,"41":3,"42":1,"43":5,"55":15,"56":14}}],["efficient",{"2":{"44":1}}],["efficiency",{"2":{"22":1}}],["effects",{"2":{"20":1}}],["equivalence",{"2":{"54":4,"57":1}}],["equivalent",{"2":{"21":1,"56":1}}],["equates",{"2":{"57":1}}],["equation",{"2":{"7":1,"56":1,"57":1}}],["equations",{"2":{"6":2,"7":1,"17":1}}],["equalities",{"2":{"57":1}}],["equality",{"0":{"56":1},"2":{"1":5,"5":1,"6":4,"53":1,"54":11,"55":1,"56":4,"57":9}}],["equals",{"2":{"54":2,"57":3}}],["equal",{"2":{"4":2,"5":2,"53":1,"56":1,"57":1}}],["evaluate",{"2":{"42":1}}],["evolving",{"2":{"16":1}}],["evidence",{"2":{"16":1}}],["eventually",{"2":{"17":1,"18":1}}],["even",{"2":{"5":2,"15":1,"21":1,"57":1}}],["everything",{"2":{"39":1}}],["everywhere",{"2":{"22":1}}],["every",{"2":{"0":1,"6":1,"22":1,"54":1}}],["emission",{"2":{"12":1}}],["embrace",{"2":{"1":1}}],["each",{"2":{"16":1}}],["easy",{"2":{"12":1,"17":1}}],["easily",{"2":{"0":1}}],["earth",{"2":{"11":1}}],["environments",{"2":{"50":1}}],["enchanted",{"2":{"44":1}}],["encountered",{"2":{"21":1}}],["encouraged",{"2":{"17":1,"54":1,"58":1}}],["encourage",{"2":{"1":1}}],["enforce",{"2":{"40":1}}],["end",{"2":{"19":1,"21":2,"29":3}}],["enabling",{"2":{"18":1}}],["enables",{"2":{"16":1,"19":1}}],["enable",{"2":{"16":3,"17":1,"18":1,"38":1,"49":1,"51":1}}],["enlisted",{"2":{"17":1}}],["enlightening",{"2":{"7":1}}],["ensures",{"2":{"57":1}}],["ensuremath",{"2":{"36":1}}],["ensure",{"2":{"16":1,"18":1}}],["elim",{"2":{"40":2,"55":2,"56":2,"57":8}}],["elimination",{"2":{"54":1,"55":1,"57":4}}],["eliminator",{"2":{"10":2}}],["eliminators",{"2":{"10":2}}],["eliminates",{"2":{"10":1,"23":1}}],["eliminate",{"2":{"8":1}}],["el",{"2":{"25":2,"33":5}}],["element",{"2":{"21":1,"57":1}}],["elements",{"2":{"1":3,"57":1}}],["elaboration",{"0":{"21":1,"26":1},"1":{"22":1,"23":1,"24":1,"25":1,"27":1,"28":1,"29":1},"2":{"6":1,"21":1,"28":1}}],["elaborated",{"2":{"5":1,"23":1,"29":1}}],["elaborate",{"2":{"5":2}}],["etc",{"2":{"3":1,"16":4,"20":2,"36":1,"57":1,"59":3}}],["e",{"2":{"1":2,"7":1,"13":1,"22":1,"36":1,"46":1}}],["especially",{"2":{"38":1}}],["essentially",{"2":{"1":1,"6":1,"25":1}}],["essential",{"2":{"0":1}}],["established",{"2":{"0":1}}],["errors",{"2":{"1":1}}],["error",{"2":{"0":1,"7":1,"19":2,"59":2}}],["either",{"2":{"0":1,"11":1,"17":1,"36":1}}],["exercises",{"2":{"54":1}}],["exercise",{"2":{"54":1}}],["executable",{"2":{"45":1,"50":1,"59":2}}],["exactly",{"2":{"13":1,"42":1}}],["example",{"0":{"29":1},"2":{"10":2,"12":1,"17":1,"21":1,"26":1,"29":1,"40":1,"41":3,"42":2,"47":1,"55":1,"56":2,"57":3}}],["examples",{"2":{"0":1,"1":1,"14":1}}],["expresses",{"2":{"56":1}}],["expression",{"2":{"22":1}}],["expressions",{"2":{"0":1,"21":1,"38":1}}],["export",{"2":{"39":1,"46":1}}],["expanded",{"2":{"22":1}}],["expand",{"2":{"22":2}}],["expansion",{"2":{"5":1,"25":1}}],["explicit",{"2":{"41":1}}],["explicitly",{"2":{"21":1,"41":1}}],["exploiting",{"2":{"18":1}}],["experience",{"2":{"52":1}}],["experimenting",{"2":{"17":1}}],["experimental",{"2":{"17":1}}],["experiment",{"2":{"16":1}}],["expected",{"2":{"12":1,"13":2}}],["expect",{"2":{"10":1,"37":1,"40":1,"52":1}}],["except",{"2":{"1":2,"39":1}}],["exo",{"2":{"1":1}}],["ext",{"2":{"33":3}}],["extremely",{"2":{"17":1}}],["extracting",{"2":{"1":1}}],["extent",{"2":{"16":1}}],["extend",{"2":{"7":1}}],["extending",{"2":{"6":1}}],["extends",{"2":{"2":1}}],["extended",{"0":{"6":1},"1":{"7":1},"2":{"2":1}}],["extension",{"0":{"2":1,"21":1},"1":{"3":1,"4":1,"5":1,"22":1,"23":1,"24":1,"25":1},"2":{"3":1,"5":1,"21":1,"26":1,"27":1,"44":1,"59":3}}],["extensions",{"0":{"3":1,"15":1,"16":1},"1":{"16":1,"17":1,"18":1,"19":1,"20":1},"2":{"1":1,"15":1,"42":1}}],["extensionality",{"0":{"53":1},"2":{"1":1,"53":2,"54":1,"57":1}}],["extensional",{"2":{"1":2}}],["existing",{"2":{"0":1,"12":1}}],["hypothesis",{"2":{"56":1}}],["hypothetically",{"2":{"54":1}}],["hyperlinked",{"2":{"44":1}}],["href=",{"2":{"42":2}}],["https",{"2":{"36":1,"46":1,"50":1}}],["html",{"2":{"36":10}}],["hspace",{"2":{"36":10}}],["helpful",{"2":{"58":1}}],["help",{"2":{"38":1,"45":1,"54":1}}],["hello",{"2":{"36":4}}],["head",{"2":{"12":1,"29":1}}],["heavy",{"2":{"4":1}}],["heterogeneous",{"0":{"56":1},"2":{"6":1,"21":1,"56":3}}],["here",{"2":{"0":1,"5":1,"12":2,"21":2,"30":1,"41":1,"46":1,"47":1,"51":1,"52":1,"54":1,"56":2,"57":1}}],["h",{"2":{"1":1}}],["hit",{"2":{"59":1}}],["hiding",{"2":{"39":1}}],["highlight",{"2":{"59":2}}],["highlights",{"2":{"44":2}}],["highlighting",{"2":{"36":1}}],["higher",{"2":{"0":1,"1":1,"21":1,"26":1,"28":1,"29":1,"44":2}}],["hierarchy",{"2":{"1":1}}],["hovering",{"2":{"59":1}}],["host",{"2":{"51":1}}],["holes",{"2":{"44":1,"53":1}}],["honest",{"2":{"18":1}}],["hott",{"2":{"16":1,"29":1}}],["hoc",{"0":{"10":1}}],["home",{"2":{"59":1}}],["hom",{"2":{"3":7,"4":1,"5":4}}],["however",{"2":{"7":1,"12":2,"16":1,"17":1,"53":1,"54":1,"55":1,"56":1}}],["how",{"2":{"1":1,"7":1,"10":1,"18":1,"21":1,"33":1,"40":1,"42":1,"50":1,"54":1,"57":2,"59":1}}],["hopefully",{"2":{"48":1}}],["hope",{"2":{"0":1,"52":1}}],["happen",{"2":{"16":1}}],["happens",{"2":{"0":1,"2":1}}],["having",{"2":{"10":1,"16":1,"21":1,"43":1,"56":1}}],["have",{"0":{"48":1},"1":{"49":1,"50":1},"2":{"0":3,"1":4,"3":1,"4":2,"5":4,"6":2,"7":1,"8":1,"9":1,"10":5,"11":1,"16":1,"17":1,"18":1,"19":1,"20":1,"21":3,"22":2,"23":1,"24":1,"25":1,"40":3,"41":2,"42":1,"43":2,"50":1,"51":1,"52":1,"53":3,"54":1,"55":1,"56":2,"57":1,"59":3}}],["handed",{"2":{"50":1}}],["hands",{"2":{"46":1}}],["hand",{"2":{"6":2,"54":2}}],["harder",{"2":{"56":1}}],["hard",{"0":{"8":1},"1":{"9":1,"10":1,"11":1},"2":{"5":1,"10":1,"18":1,"56":2}}],["harm",{"2":{"0":1,"19":1,"22":1}}],["has",{"2":{"0":1,"1":4,"6":3,"8":1,"13":1,"21":1,"22":1,"24":1,"25":1,"38":1,"44":2,"53":2,"54":2,"57":3}}],["haskellid",{"2":{"41":1}}],["haskellleft",{"2":{"10":1}}],["haskelldata",{"2":{"10":1,"40":1}}],["haskell",{"0":{"15":1,"37":1},"1":{"16":1,"17":1,"18":1,"19":1,"20":1,"38":1,"39":1,"40":1,"41":1,"42":1,"43":1},"2":{"0":1,"10":1,"15":2,"37":1,"39":1,"40":4,"41":1,"42":4,"44":2}}],["fj",{"2":{"50":1}}],["f",{"2":{"31":4,"35":6,"41":1,"54":20,"56":2,"57":7}}],["ffi",{"2":{"20":1}}],["fewer",{"2":{"21":1}}],["feels",{"2":{"54":1}}],["feel",{"2":{"6":1,"24":1,"42":1}}],["features",{"2":{"1":1,"4":1,"15":1,"16":5,"17":4,"19":1,"44":2,"57":1,"59":1}}],["feature",{"2":{"0":1,"1":1,"2":1,"5":2,"12":1,"16":1,"17":3,"43":1}}],["fat",{"2":{"50":1}}],["fatjar",{"2":{"38":1,"50":2,"51":1,"59":1}}],["fake",{"0":{"36":1},"2":{"36":2,"44":1}}],["face",{"2":{"21":1}}],["faces",{"2":{"21":3}}],["fact",{"2":{"12":1}}],["fancy",{"2":{"17":1}}],["far",{"2":{"16":1,"24":1}}],["familiar",{"2":{"54":1,"57":1}}],["families",{"0":{"42":1},"2":{"42":1,"56":1}}],["family",{"2":{"1":1,"13":1,"42":2}}],["famous",{"2":{"10":1,"12":1,"42":1}}],["false",{"2":{"10":2,"18":1,"53":3}}],["failed",{"2":{"7":1}}],["fail",{"2":{"7":1,"10":1}}],["fails",{"2":{"6":2}}],["fn",{"2":{"6":5,"7":1,"38":2,"53":1,"54":8,"56":4,"57":1}}],["flcl",{"2":{"36":2}}],["flatten",{"2":{"28":10}}],["flattenop",{"2":{"28":8,"29":3}}],["flattening",{"0":{"28":1},"2":{"24":1,"29":1}}],["flags",{"2":{"16":1,"17":1,"19":2}}],["flag",{"0":{"18":1},"2":{"16":2,"17":1,"18":2,"19":1}}],["flexibility",{"2":{"2":1}}],["float",{"2":{"0":1}}],["fibrant",{"2":{"25":1}}],["fibrancy",{"2":{"25":3}}],["fits",{"2":{"18":1,"45":1}}],["files",{"2":{"45":1}}],["file",{"2":{"18":1,"36":2,"38":1,"46":1,"49":1,"51":2,"59":5}}],["find",{"2":{"37":1,"47":1,"52":1,"57":1}}],["finding",{"2":{"6":1}}],["fine",{"2":{"25":1}}],["finalize",{"2":{"13":2}}],["figure",{"2":{"12":1}}],["field",{"2":{"3":3}}],["fields",{"2":{"2":1,"3":1}}],["first",{"0":{"22":1},"2":{"1":2,"12":5,"13":3,"17":1,"21":1,"25":1,"43":2,"46":1,"56":1,"57":1,"59":1}}],["fix",{"2":{"1":1}}],["fixr",{"2":{"0":1,"40":1}}],["fixl",{"2":{"0":2,"40":1}}],["full",{"2":{"17":1,"30":1}}],["funext",{"2":{"44":1,"54":1,"57":1}}],["funny",{"2":{"12":1}}],["functional",{"2":{"44":2}}],["functions",{"2":{"40":1,"41":1,"42":2,"44":1}}],["function",{"0":{"53":1},"2":{"1":5,"10":2,"40":4,"41":2,"42":1,"43":1,"53":2,"54":6,"55":1,"56":2,"57":1}}],["further",{"2":{"4":1,"6":1,"11":1}}],["future",{"2":{"0":1,"1":1,"54":1}}],["fragment",{"2":{"6":1}}],["framework",{"2":{"0":1}}],["freely",{"2":{"21":1}}],["free",{"2":{"1":1,"24":1,"50":1}}],["fromjust",{"2":{"42":5}}],["from",{"0":{"1":1,"46":1,"50":1},"2":{"0":1,"1":8,"5":3,"6":1,"10":2,"13":1,"16":1,"17":2,"18":1,"21":1,"29":1,"31":1,"39":2,"41":1,"48":1,"54":3,"58":1}}],["folder",{"2":{"45":1,"59":1}}],["follow",{"2":{"59":1}}],["followed",{"2":{"38":1,"39":1,"40":1,"50":1}}],["following",{"2":{"1":2,"2":2,"3":1,"6":2,"7":4,"10":4,"21":1,"23":1,"33":1,"36":4,"38":1,"39":1,"40":1,"42":1,"43":1,"44":2,"53":2,"55":1,"56":1,"57":1}}],["four",{"2":{"21":1}}],["found",{"2":{"0":1,"1":1}}],["fortunately",{"2":{"56":1}}],["force",{"2":{"51":1}}],["forced",{"0":{"12":1},"1":{"13":1},"2":{"12":3}}],["ford",{"2":{"35":3}}],["fording",{"2":{"35":2}}],["forks",{"2":{"17":1}}],["forging",{"2":{"11":1}}],["forall",{"2":{"10":2}}],["format",{"2":{"48":1}}],["formalizing",{"2":{"44":1}}],["formalize",{"2":{"1":1,"16":1}}],["form",{"2":{"5":3,"29":1}}],["for",{"0":{"6":1},"1":{"7":1},"2":{"0":1,"1":13,"3":5,"4":1,"6":1,"7":1,"9":1,"10":8,"12":2,"13":5,"14":1,"16":1,"17":2,"18":2,"19":1,"20":2,"21":5,"26":2,"29":2,"36":3,"37":1,"38":1,"39":1,"40":1,"41":3,"43":6,"44":6,"45":1,"46":1,"49":2,"50":1,"51":5,"52":1,"53":1,"54":6,"56":2,"57":1,"59":3}}],["ml",{"2":{"44":1}}],["mltt",{"2":{"4":1,"5":1,"57":1}}],["mkdir",{"2":{"46":1}}],["mk",{"2":{"29":1}}],["multiline",{"2":{"38":1}}],["multiple",{"2":{"2":1}}],["much",{"2":{"22":1,"23":1,"42":1,"48":1,"53":1}}],["mutable",{"2":{"13":3}}],["must",{"2":{"12":1,"13":1,"54":1}}],["mysterious",{"2":{"56":1}}],["my",{"2":{"9":1,"18":1,"29":1}}],["m",{"2":{"6":1,"7":28,"9":1,"29":1,"40":6,"41":2,"42":7,"43":2,"55":6,"56":8}}],["message",{"2":{"59":1}}],["member",{"2":{"53":1}}],["memberwise",{"2":{"53":1}}],["meven",{"2":{"10":1}}],["me",{"2":{"7":1,"18":1,"25":1,"36":1}}],["metadata",{"2":{"51":1}}],["metapatref",{"2":{"13":3}}],["metapat",{"2":{"13":9}}],["metaprogramming",{"2":{"1":1}}],["meta",{"0":{"13":1},"2":{"12":2,"13":2}}],["metas",{"2":{"6":1}}],["metavariables",{"2":{"6":4,"10":1}}],["meaning",{"2":{"39":1,"40":1}}],["meaningful",{"2":{"18":1}}],["mean",{"2":{"0":1,"1":1,"8":1,"21":1}}],["means",{"2":{"0":1,"1":1,"10":1,"12":1,"18":1,"53":1}}],["mian",{"2":{"42":2}}],["minimal",{"2":{"36":1}}],["mind",{"2":{"20":1}}],["minor",{"2":{"17":1}}],["might",{"2":{"1":1,"7":2,"10":1,"57":1}}],["mixfix",{"2":{"0":3}}],["mcbride",{"2":{"1":1,"7":1}}],["money",{"2":{"51":1}}],["moment",{"2":{"29":1}}],["motivation",{"0":{"9":1}}],["motive",{"2":{"7":1}}],["most",{"2":{"6":1,"10":1}}],["modify",{"2":{"16":1,"43":1}}],["modifying",{"2":{"5":1}}],["mode",{"0":{"36":1},"2":{"6":1,"18":1,"36":1,"44":1}}],["modules",{"2":{"20":1,"39":1,"51":1}}],["module",{"2":{"0":1,"1":2,"39":2,"40":1}}],["more",{"2":{"1":1,"2":1,"7":1,"9":1,"13":2,"18":1,"29":1,"42":1,"43":4}}],["moving",{"0":{"1":1},"2":{"1":2}}],["mailing",{"2":{"53":1}}],["main",{"2":{"1":1,"45":1}}],["martin",{"2":{"53":1}}],["macos",{"2":{"46":2}}],["macro",{"2":{"36":1}}],["maps",{"2":{"54":1}}],["map",{"2":{"13":1}}],["match",{"2":{"12":1,"40":1}}],["matching",{"0":{"55":1},"2":{"12":2,"40":1,"41":1,"44":2,"54":1,"55":3}}],["mathrel",{"2":{"36":1}}],["mathlib",{"2":{"20":1}}],["math",{"2":{"11":1,"16":1,"20":1,"44":1}}],["mathematicians",{"2":{"9":1,"16":1,"38":1}}],["mathematics",{"2":{"1":1}}],["mathcal",{"2":{"5":2,"33":3}}],["made",{"2":{"10":1}}],["manually",{"2":{"22":1}}],["many",{"2":{"7":1,"18":1,"36":1}}],["manifest",{"2":{"1":1}}],["major",{"2":{"1":1}}],["make",{"2":{"1":1,"13":1,"16":1,"20":1,"40":1,"43":1,"51":3,"59":1}}],["makes",{"2":{"1":2,"4":1,"10":1,"16":1,"43":1,"44":1,"55":1,"57":1}}],["making",{"2":{"0":1}}],["maybe",{"2":{"16":1,"41":4,"42":4}}],["may",{"2":{"0":1,"3":1,"4":1,"5":2,"10":1,"11":1,"12":1,"13":1,"14":1,"21":1,"36":1,"39":1,"40":1,"41":1,"43":3,"46":1,"54":2,"55":1,"56":2}}],["nightly",{"2":{"45":1,"46":1,"47":1}}],["nil",{"2":{"42":3,"43":2,"56":4}}],["nicely",{"2":{"56":1}}],["nice",{"2":{"12":1}}],["numeric",{"2":{"40":2}}],["numbers",{"2":{"0":1,"6":1,"40":1,"54":1}}],["number",{"2":{"0":1,"40":2,"56":1}}],["null",{"2":{"38":1}}],["nf",{"2":{"38":1}}],["n",{"2":{"7":22,"10":4,"12":7,"13":2,"40":11,"41":4,"42":10,"43":14,"55":14,"56":13,"57":8}}],["neg",{"2":{"57":7}}],["negative",{"2":{"16":1}}],["negatively",{"2":{"16":1}}],["neither",{"2":{"43":1}}],["ne",{"2":{"28":2}}],["necessary",{"2":{"22":1}}],["never",{"2":{"5":1}}],["need",{"2":{"4":1,"10":3,"12":1,"13":3,"15":1,"16":1,"22":1,"25":2,"38":1,"40":3,"42":2,"43":1,"52":1,"53":1,"54":2,"55":1,"56":3,"57":3,"59":1}}],["newunicodechar",{"2":{"36":2}}],["newcommand",{"2":{"28":3,"36":12}}],["new",{"2":{"0":2,"1":1,"2":1,"3":1,"5":1,"13":1,"16":1,"22":1,"23":3,"24":1,"40":1}}],["nor",{"2":{"43":1}}],["normalize",{"2":{"38":2}}],["normalizer",{"2":{"4":2,"5":1}}],["normalization",{"2":{"25":1,"38":1}}],["normal",{"2":{"5":2,"22":1,"29":1,"40":1,"57":1}}],["nose",{"2":{"32":1}}],["non",{"2":{"6":1,"7":2,"57":1}}],["none",{"2":{"6":1}}],["no",{"2":{"1":1,"10":8,"11":1,"16":1,"19":1,"53":1,"54":1}}],["now",{"2":{"1":1,"7":2,"9":1,"10":1,"13":2,"21":1,"22":1,"41":2,"43":1,"48":1,"51":1,"52":1,"53":1,"56":1}}],["nothing",{"2":{"41":1,"42":2,"43":1}}],["notice",{"2":{"10":1}}],["notion",{"2":{"10":1}}],["note",{"2":{"1":1,"6":2,"9":1,"10":3,"13":1,"14":1,"33":1,"38":1,"54":1,"55":1,"57":2}}],["notations",{"2":{"0":1}}],["not",{"2":{"0":3,"1":8,"5":1,"7":2,"8":1,"9":1,"10":3,"12":3,"13":2,"14":1,"16":1,"17":3,"20":1,"21":1,"22":2,"23":1,"24":1,"25":3,"26":1,"38":3,"39":1,"40":4,"41":2,"43":1,"44":2,"51":1,"52":1,"53":8,"54":3,"56":2,"57":4}}],["naming",{"2":{"40":1,"54":1}}],["name>",{"2":{"51":1}}],["names",{"2":{"39":2,"40":5,"50":1,"59":1}}],["named",{"2":{"1":1,"36":1}}],["nameless",{"2":{"1":1}}],["name",{"2":{"0":3,"1":1,"10":1,"12":1,"16":1,"38":1,"40":2,"47":1,"49":1,"50":1,"51":2}}],["natural",{"2":{"1":1,"9":1,"40":2,"54":1,"56":1}}],["nat",{"2":{"0":8,"6":7,"10":1,"12":6,"13":4,"23":1,"40":23,"41":2,"42":3,"43":3,"52":2,"55":7,"56":3,"57":3}}],["oh",{"2":{"40":2}}],["ok",{"2":{"39":1}}],["our",{"2":{"12":1,"16":1,"17":1,"18":1}}],["output",{"2":{"36":2,"40":1}}],["out",{"2":{"7":1,"9":1,"12":1,"24":1,"25":1,"50":1,"54":1}}],["otherwise",{"2":{"43":1}}],["others",{"2":{"41":1}}],["other",{"2":{"10":1,"36":1,"40":1,"43":1,"51":1,"53":1,"55":1,"56":1,"57":1}}],["overlap",{"2":{"43":2,"55":1,"56":2}}],["overlapping",{"0":{"43":1,"55":1},"2":{"44":1}}],["overline",{"2":{"27":2,"28":10}}],["overload",{"2":{"21":1}}],["over",{"2":{"9":1,"38":1}}],["opt",{"2":{"46":1}}],["optional",{"2":{"17":1}}],["options",{"2":{"15":1,"17":1,"40":1}}],["opinion",{"2":{"9":1}}],["operation",{"2":{"54":1,"56":1}}],["operations",{"2":{"20":1,"57":1}}],["operator",{"2":{"0":9,"1":1,"25":1,"33":2,"40":2,"42":1,"57":1}}],["operators",{"0":{"0":1},"2":{"0":2,"41":1}}],["open",{"2":{"0":1,"1":1,"32":1,"33":1,"34":1,"35":1,"37":1,"39":6,"40":4,"41":1,"42":2,"52":2,"53":1,"56":1,"57":2,"59":3}}],["o",{"2":{"6":3,"7":9,"20":1,"36":1,"56":6}}],["observations",{"2":{"41":1}}],["observational",{"2":{"1":1,"53":1}}],["obvious",{"2":{"12":2,"39":1,"40":1,"41":1}}],["obviously",{"2":{"7":1,"12":1}}],["objects",{"0":{"34":1}}],["object",{"2":{"7":1}}],["ob",{"2":{"3":11,"4":1,"5":9}}],["old",{"2":{"1":1,"45":1}}],["ones",{"2":{"40":1}}],["one",{"2":{"9":1,"16":1,"17":3,"20":1,"25":1,"40":3,"43":1,"53":1,"55":1,"56":2,"57":2}}],["once",{"2":{"1":1,"13":1}}],["only",{"2":{"1":1,"10":2,"11":1,"17":2,"18":1,"22":2,"24":1,"25":1,"39":1,"40":1,"43":1,"50":1,"57":1}}],["on",{"2":{"1":1,"5":1,"6":1,"7":9,"9":1,"10":4,"11":1,"16":1,"17":2,"18":1,"20":1,"26":1,"29":2,"32":1,"36":1,"37":1,"40":2,"43":1,"46":2,"48":1,"50":2,"52":1,"53":1,"54":1,"55":1,"56":1,"57":1,"59":2}}],["of",{"0":{"10":1,"21":1,"26":1},"1":{"22":1,"23":1,"24":1,"25":1,"27":1,"28":1,"29":1},"2":{"0":1,"1":10,"3":4,"4":1,"5":4,"6":9,"7":2,"8":1,"9":2,"10":10,"11":6,"12":9,"13":1,"14":2,"16":6,"18":6,"19":4,"20":1,"21":4,"22":6,"23":2,"24":3,"25":4,"29":1,"32":1,"33":2,"34":1,"35":1,"36":2,"38":3,"39":1,"40":5,"41":2,"42":2,"43":3,"44":3,"45":4,"47":1,"48":1,"49":1,"51":6,"53":2,"54":8,"55":2,"56":9,"57":6,"58":4,"59":4,"60":1}}],["org",{"2":{"50":1}}],["original",{"2":{"11":1,"53":1}}],["ordered",{"2":{"3":1,"58":1}}],["order",{"0":{"55":1},"2":{"1":1,"17":1,"21":1,"40":1,"44":2,"56":1}}],["ordering",{"2":{"0":2}}],["or",{"0":{"15":1},"1":{"16":1,"17":1,"18":1,"19":1,"20":1},"2":{"0":1,"6":1,"11":1,"16":4,"17":3,"18":1,"20":2,"21":1,"36":1,"38":3,"43":1,"44":2,"46":2,"48":1,"52":1,"53":1,"54":1,"58":1,"59":3}}],["omitted",{"2":{"0":1,"40":1,"41":2,"56":1}}],["p0",{"2":{"53":2,"56":2}}],["please",{"2":{"59":1}}],["pleasant",{"2":{"56":1}}],["plenty",{"2":{"40":1,"45":1}}],["platform",{"2":{"45":1,"48":1,"50":1}}],["play",{"2":{"42":1}}],["plain",{"2":{"4":1}}],["plan",{"2":{"0":1,"1":1,"51":1}}],["pmap",{"2":{"31":1,"35":1,"54":2,"55":1,"56":4,"57":3}}],["p~",{"2":{"29":1}}],["p~q",{"2":{"29":2}}],["pinv",{"2":{"54":1}}],["pi",{"2":{"38":1}}],["piece",{"2":{"10":1}}],["piπ",{"2":{"1":1}}],["people",{"2":{"7":1,"16":1,"53":1}}],["per",{"2":{"45":1}}],["pervasive",{"2":{"10":1}}],["perspective",{"2":{"7":1,"18":1}}],["perform",{"2":{"5":1,"12":1}}],["publications",{"0":{"60":1},"2":{"60":1}}],["public",{"2":{"39":1,"40":1}}],["purity",{"2":{"13":1}}],["purpose",{"2":{"6":1,"16":1}}],["put",{"2":{"0":1,"36":1,"59":2}}],["p",{"2":{"6":3,"10":15,"21":8,"22":5,"23":1,"24":1,"29":7,"31":4,"46":1,"54":14,"57":9}}],["pseudocode",{"2":{"3":1}}],["phases",{"2":{"1":1,"16":1}}],["page",{"2":{"58":2,"59":1}}],["package",{"0":{"51":1},"2":{"40":1,"51":1}}],["pair",{"2":{"38":1}}],["painlessly",{"2":{"42":1}}],["painless",{"2":{"40":1}}],["pain",{"2":{"22":1}}],["pase",{"2":{"9":1,"10":1}}],["patteriables",{"0":{"13":1},"2":{"12":1}}],["patterns",{"0":{"12":1,"43":1},"1":{"13":1},"2":{"12":10}}],["pattern",{"0":{"6":1,"55":1},"1":{"7":1},"2":{"6":8,"7":3,"10":2,"12":13,"13":9,"17":1,"40":2,"41":1,"44":2,"54":1,"55":3}}],["patching",{"2":{"10":1}}],["patch",{"2":{"10":2}}],["path=",{"2":{"46":1}}],["pathp",{"2":{"6":1,"7":1,"21":11,"27":1}}],["paths",{"2":{"1":1}}],["path",{"0":{"26":1},"1":{"27":1,"28":1,"29":1},"2":{"1":1,"6":7,"7":1,"20":1,"21":6,"22":10,"23":3,"24":2,"25":3,"31":2,"36":1,"47":1,"52":2,"54":1,"56":4,"57":1,"59":5}}],["paper",{"2":{"1":3,"12":1,"30":1,"33":1}}],["parent",{"2":{"51":2}}],["parentheses",{"2":{"40":1,"41":1}}],["parenthesis",{"2":{"0":1}}],["parindent",{"2":{"36":1}}],["paraphrase",{"2":{"10":1}}],["parameters",{"2":{"16":1,"17":1,"19":1,"21":1,"40":3,"41":4,"57":1}}],["parameter",{"2":{"1":1,"17":1,"40":1,"41":1,"43":2}}],["parts",{"2":{"20":1}}],["particularly",{"2":{"16":2}}],["partially",{"2":{"1":1,"5":1,"10":1,"25":1}}],["partial",{"2":{"0":2,"1":3,"21":1,"29":1,"40":1}}],["part",{"2":{"10":1,"11":1,"17":1,"20":3}}],["party",{"2":{"1":1}}],["practical",{"2":{"44":1}}],["practice",{"2":{"7":1,"39":1}}],["pragma",{"2":{"15":1,"16":2,"18":1}}],["pr",{"2":{"13":1}}],["prune",{"2":{"7":1}}],["pruning",{"0":{"6":1},"1":{"7":1},"2":{"6":1}}],["proxy",{"2":{"50":1}}],["probably",{"2":{"18":1,"21":1,"23":1}}],["problems",{"2":{"6":1,"7":2,"21":1,"23":1,"24":1,"25":1,"50":1}}],["problem",{"2":{"0":1,"7":1,"10":1,"12":1,"22":2,"23":2,"29":2}}],["proving",{"2":{"52":1,"54":1}}],["provides",{"2":{"36":1,"56":1}}],["provide",{"2":{"18":1}}],["prove",{"2":{"53":1,"54":5,"55":1,"56":3}}],["prover",{"0":{"44":1},"2":{"44":1,"46":4,"47":2,"52":1,"59":1}}],["proves",{"2":{"10":1}}],["provably",{"2":{"1":1}}],["proofs",{"2":{"54":1,"57":1}}],["proof",{"0":{"52":1},"1":{"53":1,"54":1,"55":1,"56":1,"57":1},"2":{"10":1,"16":1,"18":1,"43":1,"44":1,"54":3,"55":1,"56":3,"57":2}}],["pro",{"2":{"9":1}}],["project>",{"2":{"50":2}}],["project",{"2":{"39":2,"51":6,"59":2}}],["projects",{"0":{"39":1},"2":{"51":1}}],["projected",{"2":{"5":1}}],["projection",{"0":{"2":1,"4":1},"1":{"3":1,"4":1,"5":1},"2":{"4":1,"5":2}}],["programmers",{"2":{"37":1,"44":1,"59":1}}],["programming",{"0":{"40":1,"41":1},"2":{"1":1,"16":2,"18":1,"20":1,"44":3}}],["program",{"2":{"12":1}}],["progress",{"2":{"1":1}}],["property",{"2":{"8":1}}],["proposition",{"2":{"9":1}}],["propositions",{"2":{"8":1,"11":1}}],["propositionally",{"2":{"56":1}}],["propositional",{"2":{"1":1,"11":1,"53":1,"54":2,"56":1}}],["props",{"0":{"8":1},"1":{"9":1,"10":1,"11":1},"2":{"1":3}}],["prop",{"0":{"10":1},"2":{"1":2,"8":1,"9":3,"10":12,"11":4}}],["printing",{"2":{"36":1,"38":1}}],["print",{"2":{"36":1}}],["principles",{"2":{"55":1}}],["principle",{"2":{"22":1}}],["primitive",{"2":{"10":1}}],["primitives",{"2":{"0":1}}],["prim",{"2":{"6":2,"31":3,"52":3}}],["private",{"2":{"1":1,"57":1}}],["priority",{"2":{"0":1}}],["prebuilt",{"0":{"49":1},"2":{"48":1}}],["pre",{"2":{"44":1,"56":1}}],["pretty",{"2":{"38":1,"53":1}}],["prelude",{"0":{"31":1},"2":{"40":1,"52":1}}],["preserved",{"2":{"57":1}}],["preserve",{"2":{"22":1,"54":1,"57":1}}],["preview",{"2":{"38":1,"49":1,"51":1}}],["previously",{"2":{"40":1}}],["previous",{"2":{"1":1}}],["prevents",{"2":{"16":1,"17":1}}],["preferred",{"2":{"24":1,"46":1}}],["prefer",{"2":{"12":1,"13":1}}],["prefix",{"2":{"0":1,"46":7}}],["predicative",{"2":{"10":5}}],["precat⊢a",{"2":{"5":2}}],["precategories",{"2":{"3":1}}],["precat",{"2":{"3":11,"4":2,"5":7}}],["precedence",{"2":{"0":5,"40":3}}],["precedences",{"2":{"0":3}}],["potential",{"2":{"43":1,"54":1}}],["pos",{"2":{"57":8}}],["possibilities",{"2":{"43":1}}],["possible",{"2":{"2":1}}],["position",{"2":{"10":1}}],["positivity",{"2":{"1":1,"16":1}}],["posted",{"2":{"29":1}}],["posts",{"2":{"14":2}}],["post",{"2":{"2":1,"5":1,"8":1,"10":1,"26":1,"53":1}}],["postfix",{"2":{"0":1}}],["ported",{"2":{"1":1}}],["pointwise",{"2":{"1":1}}],["point",{"2":{"0":1,"6":1,"9":1,"10":1,"54":1,"59":1}}],["popular",{"2":{"0":1}}],["create",{"2":{"59":1}}],["creating",{"2":{"3":1,"54":1}}],["ctrl+l",{"2":{"59":2}}],["ctx​γ⊳a",{"2":{"32":1}}],["ctxγ⊢a",{"2":{"32":2}}],["ctxγ",{"2":{"32":2}}],["ctxγ~",{"2":{"32":1}}],["ctx",{"2":{"32":6}}],["cd",{"2":{"46":2}}],["cdots",{"2":{"28":1}}],["cfrac",{"2":{"28":3,"32":2,"33":2}}],["certain",{"2":{"16":3}}],["citizens",{"2":{"1":1}}],["clone",{"2":{"50":1}}],["closed",{"2":{"1":2,"54":1}}],["clickable",{"2":{"59":1}}],["click",{"2":{"59":1}}],["cli",{"2":{"38":1,"49":1,"51":1}}],["clash",{"2":{"40":1,"54":1}}],["classical",{"2":{"11":2,"17":1}}],["classify",{"2":{"1":1}}],["classes",{"2":{"1":1,"2":1}}],["class",{"0":{"2":1},"1":{"3":1,"4":1,"5":1},"2":{"1":2,"2":1,"3":8,"4":1,"5":1,"57":1}}],["claim",{"2":{"13":1}}],["clauses",{"2":{"57":1}}],["clause",{"2":{"10":2,"12":6,"13":4,"43":1}}],["cycles",{"2":{"1":1}}],["cheating",{"2":{"57":1}}],["cheat",{"2":{"53":1}}],["checkout",{"2":{"43":1}}],["checks",{"2":{"16":3,"18":2,"19":2,"23":1,"51":1}}],["check",{"2":{"6":1,"12":3,"13":1,"16":1,"18":2,"22":1,"23":1,"50":1,"57":2}}],["checker",{"2":{"1":6,"10":7,"12":1,"17":1,"41":1}}],["checking",{"2":{"1":2,"7":1,"12":2,"13":3,"17":1,"21":1,"22":1,"23":2,"24":2,"25":1,"43":1,"44":1,"45":1,"54":1,"55":1}}],["china",{"2":{"50":1}}],["chronological",{"2":{"21":1}}],["chown",{"2":{"46":1}}],["chose",{"2":{"45":1,"53":1}}],["choice",{"0":{"17":1},"1":{"18":1,"19":1},"2":{"59":1}}],["choosing",{"2":{"16":1}}],["chance",{"2":{"1":1,"5":1}}],["changed",{"2":{"1":1}}],["change",{"2":{"1":2,"12":1,"23":1,"25":1}}],["changes",{"2":{"0":1,"14":1,"43":1,"48":1,"56":1,"58":1}}],["changing",{"2":{"0":1,"16":1,"53":1}}],["curly",{"2":{"41":2}}],["current\`",{"2":{"50":1}}],["currently",{"2":{"1":1,"24":1,"29":1}}],["current",{"2":{"0":1,"13":1,"16":1}}],["cumulativity",{"2":{"16":1}}],["cubical",{"0":{"54":1},"2":{"1":8,"6":1,"16":2,"21":3,"25":1,"26":1,"29":1,"44":1,"53":1,"54":1,"56":2,"58":1}}],["customers",{"2":{"16":1}}],["custom",{"2":{"0":1,"16":1}}],["came",{"2":{"53":1}}],["calculus",{"2":{"53":1}}],["calling",{"2":{"12":1}}],["call",{"2":{"10":2,"16":2}}],["calls",{"2":{"1":2}}],["called",{"0":{"13":1},"2":{"1":2,"3":1,"6":1,"10":1,"12":1,"21":1,"29":1,"40":1}}],["capitalization",{"2":{"40":1}}],["capabilities",{"2":{"2":1}}],["carlo",{"2":{"25":1,"31":1}}],["carefully",{"2":{"10":1}}],["care",{"2":{"6":1}}],["categories",{"2":{"20":1}}],["caused",{"2":{"1":1}}],["castrefl",{"2":{"56":1}}],["cast",{"2":{"54":3,"56":5}}],["casing",{"2":{"1":1}}],["cases",{"2":{"13":1,"43":1}}],["case",{"0":{"7":1},"2":{"0":1,"1":2,"2":1,"5":1,"13":2,"22":1,"59":1}}],["cannot",{"2":{"6":1,"8":1,"18":1,"53":1,"54":1}}],["can",{"2":{"0":3,"1":6,"2":2,"4":1,"6":1,"10":2,"12":5,"13":2,"15":3,"17":5,"18":3,"20":1,"21":1,"24":1,"36":1,"38":4,"40":6,"41":1,"42":1,"43":1,"47":2,"48":1,"50":1,"52":1,"53":1,"54":3,"55":2,"56":2,"57":2}}],["c",{"2":{"0":3,"6":3,"7":2,"21":3,"54":5,"56":3}}],["cook",{"2":{"57":1}}],["cool",{"2":{"48":1}}],["cooltt",{"2":{"5":1,"25":1}}],["coverage",{"2":{"50":2}}],["colors",{"2":{"36":1}}],["collection",{"2":{"16":1}}],["copied",{"2":{"31":1}}],["copy",{"2":{"0":1}}],["coerce",{"2":{"54":2}}],["coercive",{"2":{"25":1}}],["coercions",{"2":{"56":1}}],["coercion",{"2":{"1":1,"2":1,"54":1}}],["coe",{"2":{"31":2,"52":1,"54":1,"56":1}}],["codomain",{"2":{"12":1,"13":1}}],["codes",{"2":{"25":1}}],["code",{"2":{"0":1,"7":1,"10":2,"12":1,"14":1,"22":1,"36":5,"39":1,"42":1,"48":1,"51":1,"53":1}}],["correspond",{"2":{"32":1}}],["corresponds",{"2":{"13":1,"27":1,"32":1,"33":4,"34":1,"35":1}}],["corresponding",{"2":{"12":2,"54":1}}],["correct",{"2":{"10":1,"12":1}}],["core",{"2":{"1":1,"5":2}}],["coq",{"2":{"10":4,"38":1,"57":1}}],["course",{"2":{"18":1}}],["counterexample",{"2":{"10":1}}],["couple",{"2":{"1":1}}],["combinators",{"2":{"57":1}}],["combination",{"2":{"16":1}}],["com",{"2":{"36":1,"46":1}}],["comments",{"2":{"59":1}}],["comm",{"2":{"55":4}}],["commit",{"2":{"45":1}}],["commonly",{"2":{"54":1}}],["common",{"2":{"16":1}}],["command",{"2":{"15":1,"36":1,"49":1}}],["commute",{"2":{"5":1}}],["comes",{"2":{"5":1}}],["compiling",{"2":{"44":1}}],["compiled",{"2":{"44":1,"55":1}}],["compiler",{"2":{"16":2,"17":1,"36":1,"44":1}}],["compile",{"2":{"1":1,"36":1}}],["compute",{"2":{"43":2,"44":1}}],["computes",{"2":{"33":1}}],["computations",{"2":{"43":1}}],["computation",{"2":{"1":1,"55":1}}],["compatibility",{"2":{"51":1}}],["compatible",{"2":{"16":1}}],["comparison",{"2":{"10":1}}],["comparing",{"2":{"10":1}}],["complete",{"2":{"1":1,"47":1}}],["completely",{"2":{"1":1,"11":1,"43":1}}],["complications",{"2":{"1":1}}],["cong",{"2":{"54":1}}],["configure",{"2":{"59":1}}],["configurations",{"2":{"36":1}}],["confluence",{"2":{"57":1}}],["conflicts",{"2":{"2":1}}],["con",{"2":{"32":3,"33":7,"34":5,"35":3}}],["conventional",{"2":{"21":2}}],["convenient",{"2":{"9":1,"44":1}}],["converted",{"2":{"13":1}}],["conversion",{"2":{"12":1,"17":1,"43":1}}],["concat",{"2":{"21":2,"54":1}}],["concatenation",{"2":{"21":1}}],["conclusion",{"0":{"19":1}}],["concludes",{"2":{"4":1}}],["concept",{"2":{"12":1}}],["concerns",{"2":{"11":1}}],["conor",{"2":{"7":1}}],["constant",{"2":{"54":1}}],["construct",{"2":{"54":3}}],["construction",{"2":{"54":1}}],["constructions",{"2":{"53":1}}],["constructors",{"0":{"26":1},"1":{"27":1,"28":1,"29":1},"2":{"32":1,"40":3,"41":1,"42":1,"57":2,"59":1}}],["constructor",{"2":{"12":1,"29":2,"33":2,"36":1,"42":1,"57":2}}],["constraint",{"2":{"6":2}}],["constraints",{"2":{"6":1,"7":1}}],["cons",{"2":{"42":1}}],["console",{"2":{"36":1}}],["consists",{"2":{"51":1}}],["consistent",{"2":{"18":1}}],["consistency",{"2":{"18":3}}],["considered",{"2":{"10":2,"57":1}}],["consider",{"2":{"6":1,"10":1,"12":1,"21":1,"23":1,"40":1,"42":1,"53":1,"56":1}}],["considering",{"2":{"1":1}}],["content",{"2":{"26":1}}],["context",{"0":{"32":1},"2":{"12":1,"13":2}}],["contexts",{"2":{"5":1}}],["contains",{"2":{"45":1}}],["contained",{"2":{"30":1}}],["contain",{"2":{"13":1}}],["contrast",{"2":{"4":1}}],["controlling",{"2":{"1":1}}],["iapplyconfluence",{"2":{"29":1}}],["i↦",{"2":{"29":12}}],["i↦a",{"2":{"29":12}}],["i¬i",{"2":{"27":1}}],["iii",{"2":{"27":1}}],["i=0i=0i=0",{"2":{"27":1}}],["i=0↦",{"2":{"27":1}}],["i=0↦a",{"2":{"27":2}}],["i=1i=1i=1",{"2":{"27":1}}],["i=1↦",{"2":{"27":1}}],["i=1↦b",{"2":{"27":2}}],["irrelevance",{"2":{"9":1,"10":1}}],["i0",{"2":{"7":4,"21":6}}],["i1",{"2":{"7":4,"21":6}}],["idr",{"2":{"34":1}}],["idris",{"2":{"12":1,"44":2}}],["idl",{"2":{"34":1}}],["idp",{"2":{"23":3}}],["id",{"2":{"3":1,"5":2,"33":3,"34":3,"41":3,"53":4}}],["ide",{"2":{"50":1}}],["identity",{"2":{"54":1,"56":1}}],["identical",{"2":{"13":1}}],["identifier",{"2":{"0":1}}],["ideas",{"2":{"20":1,"59":1}}],["idea",{"2":{"1":1,"5":2,"40":1}}],["image",{"2":{"50":2}}],["imagine",{"2":{"42":1}}],["immediate",{"2":{"1":1}}],["improve",{"2":{"59":1}}],["impredicativity",{"0":{"11":1},"2":{"9":3,"10":1,"11":3}}],["impredicative",{"0":{"8":1,"10":1},"1":{"9":1,"10":1,"11":1},"2":{"1":4,"9":1,"10":1}}],["impact",{"2":{"16":1}}],["impacts",{"2":{"16":1}}],["imply",{"2":{"11":1,"53":1}}],["implicit",{"2":{"6":1,"23":2,"41":1,"44":1}}],["implicitness",{"2":{"1":1}}],["implies",{"2":{"1":1,"11":3,"18":1,"57":1}}],["implementers",{"2":{"26":1}}],["implemented",{"2":{"0":1,"3":1,"56":1,"57":1}}],["implements",{"2":{"10":1,"12":1}}],["implementing",{"2":{"1":1,"16":1}}],["implementation",{"0":{"5":1},"2":{"1":1,"5":1,"13":1,"25":1,"44":1,"58":1}}],["implementations",{"2":{"0":1}}],["implement",{"2":{"1":2,"4":1,"5":1,"12":1,"21":1}}],["impossible",{"2":{"0":1}}],["important",{"2":{"9":1,"10":1}}],["imports",{"2":{"0":1,"39":2}}],["importing",{"2":{"0":1}}],["import",{"2":{"0":2,"39":9}}],["i",{"2":{"0":3,"1":1,"3":1,"6":24,"7":22,"8":1,"9":4,"10":3,"12":3,"13":1,"15":1,"16":1,"17":1,"18":1,"20":3,"21":37,"22":2,"23":5,"24":3,"25":1,"27":8,"28":9,"29":28,"31":5,"33":1,"37":1,"38":3,"42":1,"45":1,"46":1,"52":6,"54":20,"56":7,"57":8}}],["if",{"0":{"48":1},"1":{"49":1,"50":1},"2":{"0":1,"7":1,"10":3,"11":1,"12":2,"17":2,"18":2,"20":1,"24":1,"36":1,"37":1,"38":1,"40":2,"45":1,"46":1,"47":1,"50":1,"52":1,"54":2,"56":1,"57":2,"59":1}}],["iset",{"2":{"41":1}}],["isn",{"2":{"12":1}}],["isprop",{"2":{"11":1,"29":4}}],["isset",{"2":{"3":1,"29":8}}],["issues",{"2":{"1":1,"59":1}}],["issue",{"2":{"0":1,"18":1,"24":1,"37":1,"40":1,"45":1,"52":1}}],["is",{"2":{"0":4,"1":9,"2":2,"3":9,"4":2,"5":4,"6":8,"7":7,"9":4,"10":16,"11":4,"12":9,"13":12,"15":1,"16":8,"17":4,"18":3,"21":4,"22":5,"23":1,"24":2,"25":5,"26":1,"27":2,"29":5,"32":1,"33":1,"36":2,"37":1,"38":1,"39":4,"41":2,"42":4,"43":5,"44":1,"45":2,"46":1,"50":1,"51":1,"52":1,"53":4,"54":7,"55":5,"56":13,"57":13,"58":2,"59":2,"60":1}}],["items",{"2":{"1":1}}],["itself",{"2":{"10":1,"12":1,"45":1}}],["its",{"2":{"0":1,"6":1,"17":2,"24":1,"50":3,"57":3}}],["it",{"2":{"0":4,"1":4,"2":2,"4":2,"5":3,"6":2,"7":4,"8":1,"9":2,"10":5,"11":1,"12":5,"13":2,"15":1,"16":6,"17":7,"18":9,"20":2,"21":3,"22":1,"25":2,"32":1,"33":1,"36":4,"38":2,"39":2,"40":2,"42":3,"43":1,"45":1,"46":1,"49":1,"53":1,"54":4,"55":2,"56":3,"57":5,"59":2}}],["input",{"2":{"36":1}}],["injective",{"2":{"25":1}}],["invocations",{"2":{"41":1}}],["invoked",{"2":{"25":1}}],["invoke",{"2":{"23":1,"50":2}}],["involves",{"2":{"43":1}}],["invol",{"2":{"0":1}}],["incremental",{"2":{"51":1}}],["includes",{"2":{"57":1}}],["includeflcl",{"2":{"36":2}}],["include",{"2":{"36":2,"40":1}}],["including",{"2":{"22":1,"38":1}}],["incorrect",{"2":{"23":1}}],["incompatible",{"2":{"23":1,"55":1}}],["inconsistency",{"2":{"18":1}}],["inconsistent",{"2":{"16":1}}],["inaccessible",{"2":{"12":1}}],["inline",{"2":{"7":1}}],["insertion",{"2":{"40":1}}],["inserting",{"2":{"23":1}}],["insert",{"2":{"25":1,"41":1}}],["inserts",{"2":{"6":1,"41":1}}],["inside",{"2":{"20":1,"22":1}}],["inspired",{"2":{"5":1}}],["instructions",{"2":{"45":1}}],["installer",{"2":{"50":1}}],["installation",{"2":{"36":1,"44":1,"45":1}}],["install",{"0":{"45":1},"1":{"46":1,"47":1,"48":1,"49":1,"50":1},"2":{"36":1,"46":2,"47":1,"59":1}}],["instances",{"2":{"3":3,"54":1,"57":1}}],["instance",{"2":{"3":1,"10":1,"24":1,"32":1,"33":2,"34":1,"35":1,"43":2}}],["instead",{"2":{"1":3,"10":2,"16":1,"21":1,"22":1,"23":1,"36":1,"38":2,"53":1,"56":1}}],["inheritance",{"2":{"2":1}}],["independent",{"0":{"55":1},"2":{"44":1,"48":1}}],["indeed",{"2":{"16":1}}],["indexed",{"2":{"13":1,"56":1}}],["index",{"0":{"12":1},"1":{"13":1},"2":{"12":1}}],["individually",{"2":{"16":1}}],["indicate",{"2":{"1":1}}],["ind",{"2":{"10":1}}],["induct",{"2":{"7":1}}],["induction",{"2":{"7":2,"10":2,"56":2}}],["inductively",{"2":{"54":1,"57":1}}],["inductive",{"0":{"30":1,"57":1},"1":{"31":1,"32":1,"33":1,"34":1,"35":1},"2":{"1":3,"10":1,"13":1,"26":1,"28":1,"29":2,"32":1,"33":1,"34":1,"35":1,"40":2,"41":1,"42":3,"52":1,"53":1,"56":1,"57":2}}],["intuitive",{"2":{"52":1}}],["int",{"2":{"36":9,"38":1,"57":5}}],["introduce",{"2":{"6":1,"17":1}}],["introduced",{"2":{"0":1,"12":1}}],["introduction",{"2":{"5":1}}],["into",{"2":{"5":3,"12":1,"13":4,"20":1,"22":1,"25":2,"40":1,"43":1,"57":2}}],["integer",{"2":{"57":1}}],["intensional",{"2":{"57":1}}],["intentionally",{"2":{"40":1}}],["intend",{"2":{"1":2}}],["interactive",{"2":{"44":2,"45":1,"52":2}}],["interoperability",{"2":{"16":1}}],["interesting",{"2":{"57":3}}],["interest",{"2":{"7":1}}],["internally",{"2":{"22":1,"40":1}}],["internal",{"2":{"1":1}}],["interval",{"2":{"6":1,"21":1,"57":12}}],["intervals",{"2":{"1":1}}],["intervalmax",{"2":{"0":1}}],["intervalmin",{"2":{"0":1}}],["info",{"2":{"7":1}}],["information",{"2":{"0":1,"1":1,"5":1,"10":1,"24":1,"25":1,"43":1,"58":1}}],["infers",{"2":{"39":1}}],["infer",{"2":{"6":1}}],["inferred",{"2":{"1":1,"41":1}}],["infixr",{"2":{"34":1,"40":1,"42":3,"56":2}}],["infix",{"2":{"0":4,"31":1,"32":1,"34":2,"40":2,"42":1,"52":1,"55":2}}],["infixl",{"2":{"0":2,"40":5,"41":1,"43":1}}],["in",{"0":{"0":1,"12":1,"30":1,"40":1,"47":1},"1":{"13":1,"31":1,"32":1,"33":1,"34":1,"35":1},"2":{"0":7,"1":8,"2":3,"3":3,"4":2,"5":4,"6":3,"7":5,"9":2,"10":7,"11":3,"12":14,"13":5,"15":2,"16":4,"17":3,"18":2,"20":1,"21":2,"22":1,"24":2,"25":3,"27":1,"28":1,"32":1,"33":2,"34":1,"35":2,"36":2,"38":2,"39":1,"40":4,"41":4,"42":7,"43":2,"45":1,"47":1,"50":3,"53":3,"54":2,"55":2,"56":3,"57":8,"59":5}}],["7",{"2":{"0":1,"7":1,"40":4}}],["5em",{"2":{"36":8}}],["530",{"2":{"24":1}}],["57",{"2":{"7":2}}],["5",{"2":{"0":1,"40":2}}],["2b2b",{"2":{"42":2}}],["24",{"0":{"25":1}}],["2023",{"0":{"25":1}}],["2ltt",{"2":{"1":1}}],["2",{"2":{"0":1,"40":3}}],["r",{"2":{"52":2}}],["rc",{"2":{"46":1}}],["rf",{"2":{"46":1}}],["rm",{"2":{"46":2}}],["runtime",{"0":{"48":1},"1":{"49":1,"50":1},"2":{"43":1}}],["running",{"2":{"38":1}}],["run",{"2":{"12":1,"13":1,"36":1,"45":1,"49":1,"50":3,"51":2,"59":1}}],["russell",{"2":{"11":1}}],["rule",{"2":{"10":1,"16":1,"33":1,"39":1,"54":2,"55":1,"57":1}}],["rules",{"0":{"10":1},"2":{"6":1,"16":1}}],["rings",{"2":{"20":1}}],["richest",{"2":{"16":1}}],["rid",{"2":{"9":1,"10":1}}],["right",{"2":{"0":1,"5":1,"6":2,"7":1,"11":1,"42":1,"54":1,"57":8}}],["randomly",{"2":{"58":1}}],["raggedright",{"2":{"36":1}}],["raise",{"2":{"7":1}}],["rather",{"2":{"1":1,"48":1}}],["racket",{"2":{"0":1}}],["regular",{"2":{"59":1}}],["regarding",{"2":{"9":1,"10":1}}],["rebuilding",{"2":{"51":1}}],["rerun",{"2":{"50":1}}],["red",{"2":{"59":1}}],["redtt",{"2":{"44":1}}],["reduces",{"2":{"57":1}}],["reduce",{"2":{"22":1,"43":1,"54":2}}],["reduction",{"2":{"22":2}}],["renamed",{"2":{"39":1,"54":1}}],["renaming",{"2":{"0":1}}],["record",{"2":{"53":1,"56":1}}],["records",{"2":{"53":1}}],["recommend",{"2":{"45":1}}],["recommended",{"0":{"58":1},"2":{"39":1,"42":1,"59":1}}],["recursion",{"2":{"10":3,"16":1}}],["recursively",{"2":{"10":1}}],["recursive",{"2":{"1":1,"10":2,"29":1}}],["return",{"2":{"29":1,"40":1}}],["returns",{"2":{"25":1,"57":1}}],["required",{"2":{"18":1,"25":1}}],["requires",{"2":{"5":1,"50":1}}],["rewriting",{"2":{"16":1}}],["rewrites",{"2":{"20":1}}],["rewrite",{"2":{"1":2}}],["respects",{"2":{"25":1}}],["results",{"2":{"13":1}}],["restricted",{"2":{"39":1}}],["rest",{"2":{"12":1,"59":1}}],["restatement",{"2":{"11":1}}],["resizing",{"2":{"1":1,"11":2}}],["re",{"2":{"6":1,"10":1,"20":1,"38":1,"39":1,"46":1,"53":1,"57":1}}],["releases",{"2":{"46":1,"50":1,"59":1}}],["release",{"0":{"46":1},"2":{"44":1,"45":2,"48":1}}],["relevant",{"2":{"5":1}}],["relate",{"2":{"18":1}}],["related",{"2":{"1":2,"10":1,"13":1,"18":1,"24":1,"58":1,"60":1}}],["rely",{"2":{"6":1}}],["reject",{"2":{"2":1}}],["reason",{"2":{"38":1}}],["reasons",{"2":{"9":2,"54":1}}],["reach",{"2":{"24":1}}],["reading",{"0":{"58":1},"2":{"13":1}}],["read",{"2":{"10":1,"39":1}}],["readability",{"2":{"0":1}}],["realized",{"2":{"53":1}}],["really",{"2":{"2":1,"5":2,"10":1,"54":1,"57":1}}],["real",{"2":{"1":1,"18":1}}],["remake",{"2":{"51":1}}],["remains",{"2":{"25":1,"59":1}}],["remain",{"2":{"1":1}}],["remember",{"2":{"40":1,"42":1,"55":1}}],["removing",{"2":{"17":1}}],["remove",{"2":{"1":1,"17":1}}],["removed",{"2":{"1":1}}],["revisit",{"2":{"1":1}}],["repl",{"0":{"38":1},"2":{"38":2,"40":1,"42":1,"44":1,"45":1}}],["replaced",{"2":{"13":1,"40":1}}],["replace",{"2":{"7":1,"11":1,"36":1,"46":2,"51":1}}],["reputation",{"2":{"16":1}}],["repo",{"2":{"1":1}}],["repository",{"2":{"1":1,"50":1,"51":1}}],["reports",{"2":{"50":1,"59":1}}],["reporting",{"2":{"1":1}}],["report",{"2":{"0":1,"50":2}}],["represent",{"2":{"1":1,"21":1}}],["representation",{"2":{"1":1}}],["reuse",{"2":{"1":1}}],["reflexivity",{"2":{"54":1}}],["reflection",{"2":{"1":1}}],["refl",{"2":{"7":1,"31":1,"33":3,"34":2,"54":2,"55":1,"56":3,"57":1}}],["references",{"2":{"13":1,"22":1}}],["reference",{"2":{"1":1,"12":1,"13":2,"26":1}}],["rhombus",{"2":{"0":1}}],["kotlin",{"2":{"16":1}}],["knowledge",{"2":{"26":1}}],["known",{"2":{"16":2,"24":1,"54":1}}],["know",{"0":{"37":1},"1":{"38":1,"39":1,"40":1,"41":1,"42":1,"43":1},"2":{"1":1,"5":1,"10":1,"33":1,"36":1,"37":1}}],["key",{"2":{"56":1,"59":1}}],["keywords",{"2":{"42":1,"59":1}}],["keyword",{"2":{"0":1,"36":1,"40":2,"41":1,"55":1}}],["keep",{"2":{"1":1,"16":1,"17":1}}],["k",{"2":{"0":1,"7":10}}],["skim",{"2":{"54":1}}],["smart",{"2":{"53":1}}],["smaller",{"2":{"10":1,"48":1}}],["src",{"2":{"51":1}}],["snippets",{"2":{"36":1}}],["squares",{"2":{"24":1}}],["squarep",{"2":{"21":2}}],["square",{"2":{"21":3}}],["scroll",{"2":{"59":1}}],["script",{"2":{"46":1}}],["scripts",{"2":{"45":1}}],["scary",{"2":{"42":1}}],["scale",{"2":{"21":1}}],["scala",{"2":{"16":1}}],["scope",{"2":{"6":2,"54":1}}],["split",{"2":{"20":1}}],["speaking",{"2":{"20":1}}],["special",{"2":{"13":2,"16":1,"54":1}}],["specify",{"2":{"38":1}}],["specifying",{"2":{"0":1}}],["specified",{"2":{"0":1,"15":1,"21":1}}],["spines",{"2":{"6":2}}],["signature",{"2":{"21":1,"56":1}}],["significant",{"2":{"16":1}}],["situation",{"2":{"10":1}}],["since",{"2":{"10":1,"11":1,"13":1,"15":1,"25":2,"38":1,"41":1}}],["size",{"2":{"6":6,"10":2,"43":2}}],["sized",{"2":{"6":1,"12":1,"16":1,"42":1,"54":1,"56":2}}],["sidebar",{"2":{"14":1}}],["sides",{"2":{"6":2}}],["side",{"2":{"6":2,"54":2,"56":2}}],["simeq",{"2":{"36":1}}],["simply",{"2":{"58":1}}],["simplified",{"2":{"55":1}}],["simplify",{"2":{"21":1}}],["simplicity",{"2":{"0":1,"13":1}}],["simpler",{"2":{"17":1}}],["simplest",{"2":{"12":1}}],["simple",{"2":{"11":2,"12":1,"20":1,"25":1,"44":1,"54":2}}],["similarly",{"2":{"15":1,"38":1}}],["similar",{"2":{"0":1,"2":1,"5":1,"10":1,"11":1,"38":2,"44":1}}],["sample",{"2":{"51":1}}],["same",{"2":{"0":1,"1":1,"3":1,"10":1,"36":1,"38":2,"39":1,"40":1,"51":1,"53":1,"56":1,"57":1}}],["safe",{"0":{"18":1},"2":{"16":1,"18":5,"54":1}}],["saying",{"2":{"57":1}}],["says",{"2":{"43":1}}],["say",{"2":{"5":1,"16":1,"25":1,"40":1}}],["said",{"2":{"1":2}}],["step",{"2":{"47":1,"56":1}}],["steps",{"2":{"43":1}}],["sterling",{"2":{"1":1,"58":1}}],["store",{"2":{"25":1}}],["story",{"2":{"21":1}}],["stdlib",{"2":{"20":1}}],["stuffs",{"2":{"18":1}}],["study",{"0":{"7":1}}],["stick",{"2":{"15":1}}],["still",{"2":{"1":1,"17":1,"56":2}}],["straightforward",{"2":{"12":1,"57":1}}],["structural",{"2":{"10":2}}],["strict",{"2":{"8":1}}],["stage",{"2":{"45":1}}],["stackexchange",{"2":{"36":1}}],["standalone",{"2":{"20":1}}],["standard",{"2":{"16":1,"55":1}}],["status",{"2":{"16":1}}],["stated",{"2":{"57":1}}],["state",{"2":{"13":1}}],["stateful",{"2":{"12":1}}],["statements",{"2":{"10":1}}],["stay",{"2":{"1":1,"17":1}}],["start",{"2":{"1":1,"10":1,"36":1,"38":2,"45":1}}],["styled",{"2":{"36":1}}],["style",{"0":{"15":1},"1":{"16":1,"17":1,"18":1,"19":1,"20":1},"2":{"1":1,"24":1}}],["shall",{"2":{"57":2}}],["share",{"2":{"0":1,"16":1}}],["shell",{"2":{"46":1}}],["short",{"2":{"39":2,"50":1}}],["shown",{"2":{"53":1}}],["showccr",{"2":{"50":1}}],["show",{"2":{"10":1,"38":1,"50":1,"53":3,"54":1,"56":3}}],["should",{"2":{"1":1,"5":1,"6":1,"10":1,"17":3,"18":3,"23":1,"25":1,"57":1,"59":4}}],["search",{"2":{"59":1}}],["server",{"2":{"44":1,"50":3,"59":2}}],["serialized",{"2":{"1":1}}],["serializable",{"2":{"1":1}}],["self",{"2":{"30":1}}],["section",{"2":{"40":1,"45":1}}],["secures",{"2":{"22":1}}],["second",{"0":{"23":1},"2":{"12":1,"13":1,"43":1}}],["semantics",{"2":{"55":1}}],["semantic",{"2":{"18":1}}],["separated",{"2":{"39":1,"40":1}}],["separate",{"2":{"11":1,"16":1}}],["sense",{"2":{"10":1,"12":1,"25":1}}],["settings",{"2":{"59":2}}],["settrunc",{"2":{"29":6}}],["setup",{"2":{"47":3}}],["setlength",{"2":{"36":3}}],["set",{"2":{"3":1,"5":2,"16":1,"18":1,"19":1,"28":4,"29":8,"41":1,"44":1}}],["sets",{"2":{"1":1}}],["seek",{"2":{"43":1}}],["seen",{"2":{"17":1}}],["seems",{"2":{"5":1,"18":1}}],["seem",{"2":{"4":1,"12":1}}],["see",{"2":{"1":1,"5":2,"13":1,"14":1,"16":1,"29":1,"39":1,"40":1,"54":1,"59":5}}],["several",{"2":{"1":1,"9":1,"21":1}}],["suggest",{"2":{"58":1}}],["sugar",{"2":{"3":1}}],["surprising",{"2":{"57":1}}],["sure",{"2":{"13":1,"20":1,"54":1,"59":1}}],["suffices",{"2":{"54":1}}],["sufficiently",{"2":{"52":1}}],["sudo",{"2":{"46":2}}],["suppresses",{"2":{"19":1}}],["supposed",{"2":{"6":1}}],["suppose",{"2":{"3":2,"4":2,"11":1,"53":1}}],["support",{"2":{"0":2,"1":2,"38":2,"51":1}}],["supported",{"2":{"0":1}}],["supports",{"2":{"0":1,"36":1,"38":1,"39":2,"40":1,"41":1,"50":1}}],["successful",{"2":{"59":1}}],["succ",{"2":{"36":3,"57":4}}],["such",{"2":{"7":1,"10":1,"16":4,"17":1,"19":1,"36":1,"44":2,"54":2,"57":1,"59":1}}],["suc",{"2":{"7":2,"10":2,"12":3,"13":1,"40":12,"41":2,"42":2,"43":3,"52":1,"55":10,"56":3,"57":2}}],["suceeded",{"2":{"1":1}}],["subset",{"2":{"40":1}}],["subst",{"2":{"33":11,"34":3,"35":6}}],["substitute",{"2":{"12":1,"13":1}}],["substituted",{"2":{"6":1}}],["substitution",{"0":{"34":1},"2":{"5":2,"6":1,"34":1,"44":1}}],["subλ",{"2":{"35":1}}],["subπ",{"2":{"33":1,"35":1}}],["sub",{"2":{"33":1,"34":1,"35":3}}],["subel",{"2":{"33":1}}],["subu",{"2":{"33":2}}],["subass",{"2":{"33":2,"34":1}}],["subid",{"2":{"33":1}}],["subtype",{"2":{"25":2}}],["subtypes",{"2":{"1":1}}],["subtyping",{"2":{"2":1,"25":2}}],["symmetric",{"2":{"57":1}}],["symmetry",{"2":{"54":1}}],["symbol",{"2":{"36":1}}],["synthesis",{"2":{"44":1}}],["synthesize",{"2":{"23":1}}],["syntactic",{"2":{"3":1}}],["syntax",{"0":{"27":1},"2":{"1":2,"3":1,"10":1,"12":1,"14":1,"21":1,"29":1,"40":1,"42":1,"44":1,"52":1,"53":1,"57":1}}],["systems",{"2":{"57":1}}],["system",{"2":{"0":1,"2":1,"4":1,"6":1,"44":1}}],["sort",{"2":{"24":1}}],["sorting",{"2":{"20":1}}],["sorry",{"2":{"19":1}}],["sounds",{"2":{"10":1}}],["sources",{"2":{"51":1}}],["source",{"0":{"50":1},"2":{"1":1,"5":1,"16":2,"46":1,"48":1,"51":1,"58":1}}],["so",{"0":{"13":1,"37":1,"59":1},"1":{"38":1,"39":1,"40":1,"41":1,"42":1,"43":1},"2":{"5":2,"6":7,"10":6,"12":4,"13":2,"16":1,"17":2,"18":2,"21":2,"22":1,"24":3,"29":3,"38":1,"40":1,"41":2,"44":2,"50":2,"54":2,"55":1,"56":2,"57":3}}],["solving",{"2":{"6":1,"7":1}}],["solves",{"2":{"17":1}}],["solver",{"2":{"17":3}}],["solved",{"2":{"6":2,"13":5}}],["solve",{"2":{"0":1,"7":3,"13":1,"25":1}}],["solutions",{"2":{"7":1,"13":1}}],["solution",{"2":{"1":1,"6":1,"7":1,"11":1,"22":1,"23":2,"24":1}}],["somewhere",{"2":{"46":1}}],["somehow",{"2":{"22":1}}],["sometimes",{"2":{"18":2,"27":1}}],["something",{"2":{"7":1,"17":2,"23":1,"29":1,"37":1}}],["some",{"0":{"37":1},"1":{"38":1,"39":1,"40":1,"41":1,"42":1,"43":1},"2":{"0":1,"1":5,"10":1,"12":1,"14":2,"16":2,"17":1,"18":1,"19":4,"20":1,"24":1,"25":1,"39":1,"42":2,"43":1,"52":1,"53":1,"54":2,"57":3,"59":1}}],["s",{"0":{"16":1,"17":1},"1":{"18":1,"19":1},"2":{"0":1,"1":1,"5":1,"7":2,"11":1,"12":3,"13":1,"16":5,"17":1,"18":1,"20":1,"21":2,"30":1,"31":1,"33":1,"34":6,"36":1,"38":1,"39":1,"40":2,"45":1,"46":3,"51":1,"52":3,"54":1,"56":2,"57":2,"58":1}}],["swift",{"2":{"0":1}}],["tccr",{"2":{"50":1}}],["ttt",{"2":{"35":1}}],["tmp",{"2":{"46":4}}],["tm",{"2":{"33":4,"34":4,"35":12}}],["tweaks",{"2":{"19":1}}],["tweak",{"2":{"17":1}}],["two",{"2":{"0":1,"1":1,"6":2,"11":1,"13":1,"15":1,"16":1,"43":1,"53":2,"54":2,"55":1,"57":3,"59":1}}],["tasks",{"2":{"50":1}}],["task",{"2":{"50":2}}],["takes",{"2":{"57":1}}],["take",{"2":{"43":1}}],["targets",{"2":{"36":1}}],["tarski",{"2":{"1":1,"25":1}}],["tactics",{"2":{"20":1}}],["talks",{"2":{"18":1}}],["talking",{"2":{"15":1}}],["talk",{"2":{"10":1,"25":1,"54":1}}],["tutorial",{"0":{"52":1},"1":{"53":1,"54":1,"55":1,"56":1,"57":1},"2":{"37":1,"39":2,"43":1,"44":4,"52":3,"54":1,"59":1}}],["turni",{"2":{"43":1}}],["turns",{"2":{"25":1}}],["turn",{"2":{"24":1}}],["turned",{"2":{"9":1,"16":1}}],["tuned",{"2":{"1":1}}],["typing",{"2":{"34":1,"38":2}}],["typeγ⊢a",{"2":{"33":1}}],["typeγ⊢a~",{"2":{"32":1,"33":1}}],["typeγ⊳a",{"2":{"32":1}}],["type​",{"2":{"32":1,"33":1}}],["typefamilies",{"2":{"15":1}}],["typed",{"2":{"12":2,"13":1,"44":2,"53":1,"56":2}}],["types",{"0":{"30":1,"33":1,"57":1},"1":{"31":1,"32":1,"33":1,"34":1,"35":1},"2":{"1":9,"4":1,"5":1,"9":1,"10":1,"11":2,"16":1,"22":3,"23":1,"25":1,"26":1,"27":1,"29":1,"37":1,"40":1,"41":2,"42":1,"44":1,"54":1,"57":2}}],["type",{"0":{"1":1,"21":1,"30":2,"41":1,"42":1},"1":{"22":1,"23":1,"24":1,"25":1,"31":2,"32":2,"33":2,"34":2,"35":2},"2":{"1":18,"3":5,"5":3,"6":9,"7":3,"8":2,"10":2,"11":3,"12":8,"13":6,"16":1,"17":3,"21":16,"22":8,"23":3,"24":5,"25":8,"26":3,"28":1,"29":3,"31":3,"32":5,"33":9,"34":2,"35":2,"38":3,"40":2,"41":14,"42":10,"43":2,"44":3,"52":2,"53":6,"54":5,"55":1,"56":8,"57":8,"59":1}}],["ty",{"2":{"32":1,"33":10,"34":2,"35":3,"56":1}}],["tycking",{"2":{"6":1,"19":1}}],["techniques",{"2":{"54":1}}],["technical",{"2":{"54":1}}],["testcodecoveragereport",{"2":{"50":2}}],["tests",{"2":{"50":1}}],["tex",{"2":{"36":4}}],["textit",{"2":{"36":2}}],["textcolor",{"2":{"36":9}}],["textsf",{"2":{"28":3,"29":5}}],["text",{"2":{"5":9,"32":6,"33":4,"36":1,"59":1}}],["tempting",{"2":{"36":1,"55":1,"56":1}}],["telescope",{"2":{"12":2}}],["telling",{"2":{"53":1}}],["tell",{"2":{"10":1}}],["terminal",{"2":{"38":1}}],["termination",{"0":{"10":1},"2":{"10":8,"16":2}}],["terms",{"0":{"35":1},"2":{"1":2,"22":2,"23":1,"24":1,"38":1,"44":1}}],["term",{"2":{"1":1,"5":1,"8":1,"10":1,"12":1,"22":4,"25":1,"57":1}}],["trunc",{"2":{"29":3}}],["truncation",{"2":{"29":1}}],["true",{"2":{"1":1,"9":1,"53":3,"54":2}}],["trivial",{"2":{"57":1}}],["tries",{"2":{"22":1}}],["trick",{"2":{"5":1}}],["trees",{"2":{"20":1}}],["treatment",{"2":{"5":1}}],["traditional",{"2":{"54":1}}],["traverse",{"2":{"44":1}}],["translated",{"2":{"57":1}}],["transitivity",{"2":{"54":1}}],["transport",{"2":{"31":1,"33":2,"34":1,"35":3}}],["transformed",{"2":{"13":1}}],["transform",{"2":{"13":1}}],["tracker",{"2":{"18":1}}],["try",{"2":{"1":2,"7":2,"23":1,"48":1,"54":1,"56":1}}],["trying",{"2":{"1":1,"23":1}}],["time",{"2":{"0":1,"9":1,"22":1,"46":1,"53":1}}],["tighter",{"2":{"0":6,"34":3,"40":1,"42":1,"55":1,"56":1}}],["those",{"2":{"52":1}}],["thoughts",{"2":{"24":1}}],["though",{"2":{"0":1,"57":1}}],["through",{"2":{"40":1}}],["throughout",{"2":{"8":1}}],["three",{"2":{"20":3,"57":1}}],["threefold",{"2":{"16":1}}],["things",{"2":{"10":1,"54":1}}],["thing",{"2":{"9":1,"10":1,"25":1,"40":1}}],["think",{"2":{"0":1,"7":4,"9":1,"10":2,"11":1,"17":1,"18":1,"24":1,"54":1}}],["third",{"0":{"24":1},"2":{"1":1}}],["this",{"2":{"0":3,"1":8,"2":1,"3":1,"4":2,"5":4,"6":4,"7":3,"8":1,"10":13,"11":1,"12":4,"13":1,"16":2,"17":1,"21":4,"22":2,"23":2,"24":1,"25":2,"26":1,"29":3,"36":1,"37":1,"38":1,"39":2,"40":3,"42":1,"43":4,"45":1,"52":3,"53":3,"54":9,"55":2,"56":4,"57":7,"58":4,"59":2,"60":1}}],["thanks",{"2":{"13":1}}],["than",{"2":{"0":4,"13":1,"21":1,"40":1,"48":1}}],["that",{"2":{"0":2,"1":4,"2":1,"4":1,"5":1,"6":1,"7":2,"8":1,"9":3,"10":5,"11":4,"12":3,"13":5,"14":1,"16":6,"17":2,"18":5,"19":2,"22":1,"25":3,"33":1,"38":2,"40":1,"41":2,"42":1,"43":1,"45":1,"53":1,"54":8,"55":5,"56":5,"57":7,"58":2,"59":1}}],["thesis",{"2":{"31":1}}],["these",{"2":{"6":2,"7":1,"13":1,"15":1,"16":1,"18":1,"20":1,"21":2,"32":1,"40":1,"42":1,"54":1,"57":4}}],["theories",{"2":{"53":1}}],["theorems",{"2":{"57":1}}],["theorem",{"2":{"11":1,"44":1,"52":2,"53":4,"54":1}}],["theory",{"0":{"1":1,"30":2},"1":{"31":2,"32":2,"33":2,"34":2,"35":2},"2":{"1":4,"11":2,"16":1,"26":2,"53":4,"56":1,"57":1}}],["their",{"2":{"6":1,"57":1}}],["then",{"2":{"4":2,"5":1,"6":2,"10":3,"17":1,"18":1,"20":1,"36":2,"40":1,"41":1,"43":2,"50":1,"54":1,"55":1,"56":2,"59":3}}],["they",{"2":{"1":2,"6":1,"10":2,"17":1,"22":1,"42":1,"53":1,"56":2,"57":1}}],["them",{"2":{"1":2,"6":1,"7":1,"13":1,"40":2,"54":2,"55":1}}],["there",{"2":{"0":1,"10":3,"11":1,"13":1,"18":1,"40":1,"41":1,"42":1,"43":1,"45":1,"48":1,"53":1,"54":2,"58":1,"59":3}}],["the",{"0":{"13":1,"21":1,"38":1,"44":1},"1":{"22":1,"23":1,"24":1,"25":1},"2":{"0":11,"1":34,"2":2,"3":13,"4":4,"5":15,"6":20,"7":11,"8":3,"10":26,"11":6,"12":41,"13":19,"14":4,"16":7,"17":10,"18":5,"19":3,"20":4,"21":11,"22":10,"23":7,"24":3,"25":17,"26":1,"29":8,"30":1,"32":5,"33":11,"34":2,"35":2,"36":11,"38":6,"39":4,"40":18,"41":6,"42":6,"43":6,"44":6,"45":8,"46":2,"47":3,"48":3,"49":1,"50":4,"51":3,"53":11,"54":18,"55":7,"56":18,"57":15,"58":2,"59":20,"60":1}}],["tl",{"2":{"0":1}}],["t",{"2":{"0":1,"5":1,"10":1,"12":1,"16":1,"25":1,"34":5,"35":7,"38":2,"40":1,"41":1,"42":1,"54":1,"59":1}}],["top",{"2":{"40":1}}],["toggle",{"2":{"38":1}}],["together",{"2":{"6":1,"57":1}}],["tools",{"2":{"44":1}}],["toolchain",{"2":{"36":1}}],["tool",{"2":{"16":1,"36":1}}],["too",{"2":{"15":1,"22":1,"23":1,"42":1,"43":1}}],["took",{"2":{"1":1}}],["told",{"2":{"7":1,"25":1}}],["touch",{"2":{"5":1}}],["total",{"2":{"1":1}}],["towards",{"2":{"1":1}}],["to",{"0":{"11":1},"2":{"0":9,"1":27,"2":3,"4":6,"5":7,"6":5,"7":5,"8":3,"9":5,"10":9,"11":3,"12":5,"13":9,"15":1,"16":8,"17":4,"18":9,"19":1,"20":1,"21":9,"22":6,"23":3,"24":3,"25":6,"27":3,"29":2,"30":1,"32":2,"33":4,"34":1,"35":1,"36":9,"37":1,"38":10,"39":4,"40":10,"41":2,"42":4,"43":5,"44":2,"45":2,"46":3,"47":2,"50":7,"51":5,"52":2,"53":4,"54":7,"55":4,"56":11,"57":4,"58":4,"59":10,"60":1}}],["date",{"2":{"45":1}}],["datakinds",{"2":{"42":1}}],["data",{"2":{"10":2,"36":4,"37":1,"40":2,"42":1}}],["during",{"2":{"24":1,"55":1}}],["due",{"2":{"1":5}}],["d",{"2":{"13":3,"20":1}}],["docs",{"2":{"59":1}}],["documents",{"2":{"58":1}}],["document",{"2":{"36":1,"44":1}}],["documentation",{"2":{"12":1}}],["downloading",{"2":{"50":1}}],["download",{"0":{"46":1},"2":{"46":1,"49":1,"59":1}}],["down",{"2":{"21":1,"59":1}}],["dot",{"2":{"12":1}}],["dotted",{"2":{"12":1}}],["doing",{"2":{"11":1}}],["don",{"2":{"5":1,"10":1,"16":1,"25":1,"38":1,"40":1,"41":1,"42":1,"54":1,"59":1}}],["do",{"2":{"1":3,"10":1,"12":1,"13":1,"15":1,"22":2,"24":1,"25":1,"40":3,"46":1,"51":1,"52":1,"54":2,"55":1,"57":1}}],["does",{"2":{"0":1,"1":1,"8":1,"12":2,"21":1,"25":1,"38":1,"40":1,"43":1,"44":1,"53":1,"57":1}}],["dir",{"2":{"51":2}}],["directory",{"2":{"51":3,"59":1}}],["directed",{"2":{"22":1,"44":1}}],["directly",{"2":{"5":1,"23":1,"40":1,"43":1,"54":1}}],["direct",{"2":{"1":1}}],["dimensional",{"2":{"44":1}}],["dimensions",{"2":{"21":1}}],["differences",{"2":{"40":1}}],["different",{"2":{"11":1,"16":2,"36":1,"51":1}}],["difficult",{"2":{"16":1}}],["discoverable",{"2":{"59":1}}],["discussion",{"2":{"18":1}}],["discuss",{"2":{"16":1,"40":1,"59":1}}],["discussed",{"2":{"2":1,"24":1}}],["distribution",{"2":{"59":1}}],["distinct",{"2":{"53":1,"57":2}}],["distinguishes",{"2":{"54":1}}],["distinguish",{"2":{"40":1,"51":1}}],["displayed",{"2":{"45":1}}],["disabling",{"2":{"18":1,"19":2}}],["disabledness",{"2":{"18":1}}],["disable",{"2":{"16":3,"17":1,"18":1}}],["did",{"2":{"7":1,"21":1}}],["didn",{"2":{"0":1}}],["desugaring",{"2":{"57":1}}],["describes",{"2":{"55":1}}],["design",{"0":{"20":1},"2":{"20":1,"58":1}}],["designed",{"2":{"0":1,"44":1}}],["dev",{"2":{"46":1}}],["developers",{"2":{"26":1,"60":1}}],["development",{"2":{"1":2,"45":1}}],["demo",{"2":{"44":1}}],["demand",{"2":{"20":1}}],["details",{"2":{"29":1}}],["detect",{"2":{"1":1,"2":1}}],["denotes",{"2":{"41":1}}],["denote",{"2":{"27":2,"40":1,"41":2}}],["delete",{"2":{"21":1}}],["deletion",{"2":{"16":1}}],["debugging",{"2":{"17":1}}],["declares",{"2":{"40":1}}],["decoded",{"2":{"25":1}}],["decided",{"2":{"21":2}}],["decide",{"2":{"17":2,"18":1}}],["decreasing",{"2":{"10":1}}],["dependency>",{"2":{"51":2}}],["dependency",{"2":{"51":1}}],["dependencies",{"2":{"50":1,"51":1}}],["dependent",{"2":{"10":1,"11":1,"38":1,"42":1,"44":2,"50":1}}],["depending",{"2":{"36":1}}],["depth",{"2":{"16":1}}],["deal",{"2":{"1":1,"13":1}}],["default",{"2":{"18":1,"39":1,"50":1}}],["defeated",{"2":{"6":1}}],["definecolor",{"2":{"36":9}}],["define",{"2":{"1":1,"10":1,"11":1,"40":1,"41":2,"42":1,"46":1,"54":2,"55":1,"56":1,"57":1}}],["defined",{"2":{"1":3,"32":1,"33":1,"40":2,"42":2,"54":1,"57":4}}],["defining",{"2":{"1":1}}],["definitions",{"2":{"10":1,"20":1,"38":1,"44":1,"56":1,"59":1}}],["definitionally",{"2":{"3":1,"4":2,"5":1}}],["definitional",{"0":{"2":1,"4":1},"1":{"3":1,"4":1,"5":1},"2":{"4":1,"5":3,"9":1,"55":1}}],["definition",{"2":{"0":1,"1":3,"3":1,"12":1,"30":1,"41":1,"43":1,"54":2,"56":4}}],["def",{"2":{"0":4,"7":1,"21":2,"31":4,"33":1,"40":6,"41":4,"42":3,"43":2,"52":1,"53":5,"54":6,"55":3,"56":7,"57":5}}],["dr",{"2":{"0":1}}],["bunch",{"2":{"54":1}}],["build",{"0":{"50":1},"2":{"46":1,"47":1,"48":1,"50":8,"51":1}}],["bug",{"2":{"37":1,"52":1}}],["but",{"2":{"0":4,"1":2,"6":2,"7":3,"8":1,"10":5,"12":1,"13":2,"16":2,"17":2,"21":2,"25":2,"26":1,"36":1,"38":1,"40":1,"43":3,"44":1,"45":1,"51":1,"54":2,"55":1,"56":1,"57":1}}],["bsol",{"2":{"31":4,"52":1,"54":2}}],["browser",{"2":{"50":1}}],["brouwertree",{"2":{"10":3}}],["braces",{"2":{"41":2}}],["branches",{"2":{"17":1}}],["branch",{"2":{"10":8,"45":1}}],["break",{"2":{"18":1}}],["breaking",{"2":{"14":1,"48":1}}],["blown",{"2":{"17":1}}],["blogs",{"0":{"14":1}}],["blog",{"2":{"8":1,"10":1,"14":1,"26":1}}],["blocked",{"2":{"7":8}}],["bat",{"2":{"59":1}}],["backend",{"2":{"36":1}}],["ban",{"2":{"10":1}}],["bashecho",{"2":{"46":1}}],["bashrc",{"2":{"46":3}}],["bash",{"2":{"46":2,"50":1}}],["bashjava",{"2":{"38":1}}],["bashaya",{"2":{"38":1}}],["base",{"2":{"17":1,"20":2}}],["based",{"2":{"9":1,"10":1}}],["basically",{"2":{"11":1,"57":2}}],["basic",{"2":{"2":1,"4":1,"15":1,"16":1,"20":1,"52":2,"59":1}}],["basis",{"2":{"1":1}}],["bad",{"2":{"7":1,"10":24,"17":1}}],["barely",{"2":{"16":1}}],["bare",{"2":{"5":1}}],["box",{"2":{"59":1}}],["bottom",{"2":{"58":1,"59":1}}],["both",{"2":{"12":1,"41":1,"54":1}}],["bonus",{"2":{"40":1,"43":1}}],["bout",{"2":{"18":1}}],["boundary",{"2":{"23":2,"25":1}}],["boundaries",{"2":{"6":1}}],["bound",{"2":{"0":1}}],["body",{"2":{"12":1,"13":1,"55":1}}],["bodies",{"2":{"1":1,"40":1}}],["bool",{"2":{"10":2,"11":1,"53":5,"57":1}}],["bootstrapping",{"2":{"1":1}}],["bibliography",{"2":{"58":1}}],["bidirectional",{"2":{"23":1,"24":1}}],["big",{"2":{"16":1,"29":6}}],["bishop",{"2":{"1":1}}],["bin",{"2":{"45":1,"46":2,"59":1}}],["binop",{"2":{"41":2}}],["bindings",{"2":{"12":2,"13":2}}],["binding",{"2":{"1":1,"6":1}}],["bind",{"2":{"0":1}}],["binary",{"0":{"0":1,"49":1},"2":{"0":1,"41":1,"44":1}}],["b",{"2":{"0":3,"1":1,"3":2,"6":4,"7":2,"10":3,"13":4,"21":10,"22":2,"27":2,"29":17,"31":14,"33":4,"35":11,"52":3,"54":20,"55":5,"56":10,"57":6}}],["byte",{"2":{"48":1}}],["by",{"2":{"0":1,"1":6,"5":1,"6":2,"12":3,"13":1,"16":3,"18":2,"29":1,"38":3,"39":3,"40":2,"41":1,"44":1,"50":1,"53":1,"54":3,"57":1,"60":1}}],["beware",{"2":{"58":1}}],["beyond",{"2":{"54":1}}],["begin",{"2":{"29":3}}],["been",{"2":{"25":1}}],["below",{"2":{"21":1,"26":1,"32":1,"33":1,"36":1,"45":1,"46":1,"56":1}}],["believe",{"2":{"6":1,"33":1}}],["behave",{"2":{"18":1}}],["before",{"2":{"14":1,"23":1}}],["bertrand",{"2":{"10":1}}],["becomes",{"2":{"6":1,"12":1,"40":1}}],["because",{"2":{"2":1,"5":1,"6":2,"10":1,"12":1,"22":1,"25":1,"38":1,"40":1,"41":1,"54":1,"56":1,"57":2}}],["between",{"2":{"6":1,"53":1,"54":3,"56":1,"57":1}}],["better",{"2":{"0":1,"40":1,"42":1,"44":1}}],["benefit",{"2":{"1":1}}],["being",{"2":{"1":1,"5":1,"7":1,"9":2,"54":1,"57":1}}],["be",{"2":{"0":2,"1":8,"2":2,"5":1,"6":3,"7":2,"8":1,"9":1,"10":1,"12":3,"13":4,"15":2,"17":5,"18":4,"20":1,"24":1,"25":2,"29":1,"40":4,"41":2,"43":1,"45":1,"48":1,"54":1,"55":1,"56":1,"57":3,"58":1,"59":1}}],["wget",{"2":{"46":1}}],["would",{"2":{"12":2,"38":1}}],["worried",{"2":{"25":1}}],["word",{"2":{"18":1}}],["words",{"2":{"10":1}}],["worse",{"2":{"10":1,"21":1}}],["world",{"2":{"1":1,"18":1}}],["workflow",{"2":{"47":1}}],["working",{"0":{"38":1,"39":1},"2":{"29":1,"56":2}}],["worked",{"2":{"24":1}}],["work",{"2":{"1":2,"11":1,"14":1,"38":2,"40":1,"42":1,"56":1,"57":1}}],["works",{"2":{"0":1,"33":1,"38":1,"41":1}}],["w",{"2":{"10":1}}],["wrapping",{"2":{"29":1}}],["wrote",{"2":{"9":1,"46":1}}],["written",{"2":{"3":1,"14":1,"40":1}}],["write",{"2":{"0":1,"3":1,"12":1,"21":1,"22":1,"36":1,"39":1,"41":1,"43":1}}],["wavy",{"2":{"59":1}}],["wait",{"2":{"59":1}}],["was",{"2":{"25":1}}],["warning",{"2":{"7":1}}],["want",{"2":{"1":1,"2":2,"3":1,"4":1,"5":1,"7":1,"9":2,"10":1,"16":1,"18":1,"22":1,"36":1,"40":2,"43":1,"46":1,"47":1,"56":1}}],["ways",{"0":{"11":1},"2":{"59":1}}],["way",{"2":{"0":1,"11":1,"41":1,"53":1,"55":1,"56":1,"57":1}}],["wixtoolset",{"2":{"50":1}}],["windows",{"2":{"46":2,"50":2,"59":1}}],["wish",{"2":{"1":1}}],["will",{"2":{"0":2,"1":14,"2":1,"5":1,"7":4,"8":1,"10":1,"12":3,"13":1,"17":4,"18":2,"19":1,"22":1,"23":1,"29":1,"36":1,"40":1,"41":1,"42":1,"43":1,"45":1,"47":1,"48":1,"52":1,"54":2,"57":1,"58":1}}],["without",{"2":{"5":2,"17":1,"21":1,"40":2,"44":1}}],["with",{"0":{"2":1,"38":1,"39":1},"1":{"3":1,"4":1,"5":1},"2":{"0":6,"1":4,"2":2,"5":1,"6":3,"7":3,"10":3,"11":2,"12":2,"13":2,"14":1,"16":1,"17":1,"19":1,"21":1,"22":2,"23":1,"24":1,"36":4,"38":1,"39":1,"40":4,"42":1,"43":1,"46":2,"47":1,"49":1,"50":2,"51":3,"52":1,"55":1,"56":3,"57":5,"59":1}}],["whnf",{"2":{"38":1}}],["why",{"2":{"11":1,"12":1}}],["where",{"2":{"3":1,"6":3,"10":2,"11":1,"12":1,"13":1,"36":4,"40":1,"42":1,"54":1,"56":1}}],["whenever",{"2":{"5":1}}],["when",{"2":{"0":1,"6":1,"13":4,"17":1,"18":1,"21":1,"22":1,"23":1,"25":1,"40":1,"43":1,"56":1}}],["while",{"2":{"1":2}}],["which",{"2":{"0":3,"1":10,"4":1,"6":1,"8":1,"9":1,"10":2,"11":4,"12":2,"13":2,"19":2,"22":1,"23":1,"29":1,"32":1,"33":1,"52":1,"54":1,"55":2,"56":1,"57":3,"59":1}}],["whose",{"2":{"3":2}}],["who",{"2":{"1":1}}],["what",{"2":{"1":1,"6":1,"7":1,"10":1,"13":1,"36":1,"43":1,"57":1}}],["weak",{"2":{"15":1}}],["weaker",{"2":{"11":1}}],["well",{"2":{"5":1,"12":2,"13":1,"16":1,"18":1,"22":1,"44":1,"55":2,"56":2,"57":1}}],["website",{"2":{"1":1}}],["we",{"2":{"0":8,"1":23,"2":4,"3":2,"4":2,"5":10,"6":2,"7":4,"10":9,"11":6,"12":5,"13":13,"16":1,"17":11,"18":5,"19":1,"20":2,"21":7,"22":7,"23":2,"24":2,"25":3,"38":1,"40":8,"41":3,"42":1,"43":9,"45":1,"48":1,"51":2,"53":2,"54":13,"55":1,"56":8,"57":6}}],["aarch64",{"2":{"46":1}}],["aaa",{"2":{"33":1}}],["apart",{"2":{"41":1,"58":1}}],["appends",{"2":{"56":1}}],["append",{"2":{"42":1,"56":1}}],["appeared",{"2":{"21":1}}],["appear",{"2":{"18":1}}],["app",{"2":{"35":3}}],["apply",{"2":{"17":1,"23":2}}],["applications",{"2":{"22":3,"24":1,"50":1}}],["application",{"2":{"3":1,"22":2,"24":1,"25":1,"57":1}}],["approach",{"2":{"1":1}}],["aγ⊢t",{"2":{"35":2}}],["a~",{"2":{"32":1}}],["a~b",{"2":{"29":4}}],["a~i",{"2":{"27":1}}],["a=π",{"2":{"28":1}}],["a≠π",{"2":{"28":1}}],["a≠",{"2":{"28":1}}],["amp",{"2":{"22":1,"29":6,"58":1}}],["a₋₁",{"2":{"21":6}}],["a₋₀",{"2":{"21":6}}],["a₁₋",{"2":{"21":6}}],["a₁₁",{"2":{"21":6}}],["a₁₀",{"2":{"21":6}}],["a₀₋",{"2":{"21":6}}],["a₀₁",{"2":{"21":6}}],["a₀₀",{"2":{"21":6}}],["across",{"2":{"53":1}}],["activate",{"2":{"59":1}}],["action",{"2":{"54":1}}],["actions",{"0":{"47":1},"2":{"47":1}}],["actually",{"2":{"10":2,"12":2,"21":1,"22":1,"57":1}}],["accepted",{"2":{"10":1}}],["accessible",{"2":{"12":1}}],["access",{"2":{"4":1,"5":1,"40":1}}],["according",{"2":{"6":1,"22":1}}],["avoiding",{"2":{"15":1}}],["avoid",{"2":{"9":1,"40":1,"54":1,"56":1}}],["available",{"2":{"2":1,"17":1,"42":1,"44":1,"46":1}}],["aggressively",{"2":{"16":1}}],["against",{"2":{"22":1,"23":1}}],["again",{"2":{"13":1}}],["ago",{"2":{"9":1}}],["agda",{"0":{"15":1,"16":1},"1":{"16":1,"17":1,"18":1,"19":1,"20":1},"2":{"0":3,"1":1,"6":1,"7":3,"10":3,"12":3,"15":2,"16":6,"18":4,"21":3,"24":1,"27":1,"38":1,"44":1,"57":1}}],["after",{"2":{"6":1,"45":1}}],["attributes",{"2":{"36":1}}],["attach",{"2":{"29":1}}],["attempt",{"0":{"22":1,"23":1,"24":1}}],["at",{"2":{"6":1,"10":1,"16":1,"19":1,"25":1,"29":1,"43":2,"45":1,"54":1,"59":1}}],["axioms",{"2":{"11":4,"44":1}}],["axiom",{"2":{"1":1}}],["artifacts",{"2":{"50":1}}],["arbitrary",{"2":{"40":1}}],["around",{"2":{"29":1}}],["argument",{"2":{"18":1}}],["arguments",{"2":{"1":1,"7":1,"10":2,"15":1,"23":2,"44":1}}],["arend",{"2":{"3":1,"20":1,"44":1}}],["are",{"0":{"8":1,"59":1},"1":{"9":1,"10":1,"11":1},"2":{"0":4,"1":6,"6":2,"7":1,"10":4,"11":2,"12":3,"13":4,"14":1,"17":1,"18":1,"19":1,"38":1,"39":2,"40":4,"41":4,"42":3,"44":1,"48":1,"50":1,"51":1,"52":1,"53":2,"54":5,"55":1,"56":2,"57":6,"58":2,"59":2}}],["abs",{"2":{"57":2}}],["abstraction",{"2":{"54":1,"57":1}}],["abstract",{"2":{"44":1}}],["abandoned",{"2":{"17":1}}],["above",{"2":{"5":2,"21":1,"25":1,"42":1,"47":1,"54":2}}],["about",{"2":{"1":1,"5":1,"6":1,"7":1,"10":1,"12":1,"15":1,"25":2,"37":1,"39":1,"43":1,"54":4,"57":1}}],["able",{"2":{"1":1}}],["abusing",{"2":{"0":1}}],["automagically",{"2":{"39":1,"41":1}}],["automatically",{"2":{"24":1,"38":1,"40":1}}],["automatic",{"2":{"1":1}}],["authors",{"2":{"1":1}}],["along",{"2":{"54":2}}],["alongside",{"2":{"42":1}}],["aliases",{"2":{"41":1}}],["alias",{"2":{"38":1}}],["align",{"2":{"29":6}}],["algebraic",{"2":{"37":1}}],["algorithms",{"2":{"19":1}}],["algorithm",{"2":{"6":1,"7":1,"12":3,"13":1,"17":2,"23":1,"25":1}}],["alternative",{"0":{"11":1},"2":{"53":1}}],["altenkirch",{"2":{"1":1}}],["always",{"2":{"5":2,"6":1,"48":1}}],["also",{"2":{"1":2,"10":2,"15":1,"16":1,"17":2,"25":1,"39":1,"40":1,"41":1,"54":1,"55":1,"56":1,"58":1}}],["alphaα",{"2":{"1":1}}],["allows",{"2":{"12":1,"40":1}}],["allowed",{"2":{"10":1}}],["allowing",{"2":{"10":1}}],["allow",{"2":{"10":1,"17":1,"40":1}}],["all",{"2":{"1":2,"3":3,"6":1,"18":1,"21":1,"55":1}}],["already",{"0":{"48":1},"1":{"49":1,"50":1},"2":{"0":2,"1":1,"3":1,"13":1,"25":1,"33":1,"54":1,"57":1}}],["advanced",{"2":{"54":1,"59":1}}],["advantages",{"2":{"1":1}}],["ad",{"0":{"10":1}}],["adapt",{"2":{"1":3}}],["additional",{"2":{"57":1}}],["addition",{"2":{"40":1,"56":1}}],["adding",{"2":{"10":1,"16":1,"17":1}}],["added",{"2":{"6":1}}],["address",{"2":{"0":1}}],["add",{"2":{"0":1,"1":2,"2":1,"12":1,"13":1,"17":2,"21":1,"36":1,"43":1,"55":1}}],["away",{"0":{"1":1},"2":{"1":2}}],["asking",{"2":{"9":1}}],["ass",{"2":{"34":1}}],["assistants",{"0":{"52":1},"1":{"53":1,"54":1,"55":1,"56":1,"57":1}}],["assistant",{"2":{"16":1,"43":1,"44":1,"57":1}}],["assumes",{"2":{"26":1}}],["assumption",{"2":{"10":6}}],["assuming",{"2":{"1":1}}],["assoc",{"2":{"6":10,"7":14,"56":10}}],["associative",{"2":{"0":2,"40":1,"42":1,"56":1}}],["associativity",{"2":{"0":3,"6":2,"56":1}}],["associativities",{"2":{"0":1}}],["as",{"2":{"0":4,"1":3,"3":3,"5":1,"10":1,"11":1,"16":4,"17":3,"18":2,"19":1,"21":3,"22":1,"35":2,"36":1,"38":3,"39":2,"40":3,"41":3,"42":1,"44":2,"46":1,"50":2,"53":1,"54":5,"55":3,"57":2,"59":1}}],["annotate",{"2":{"22":2}}],["annotations",{"2":{"1":1}}],["anonymous",{"0":{"3":1},"2":{"3":1}}],["another",{"2":{"0":1,"2":1,"10":1,"13":1,"52":1}}],["angiuli",{"2":{"1":1,"25":1,"31":1}}],["an",{"2":{"0":2,"1":2,"3":1,"5":2,"7":1,"9":1,"12":1,"13":1,"16":1,"17":1,"18":3,"19":2,"24":1,"25":1,"32":1,"33":2,"34":1,"35":1,"37":2,"38":1,"39":1,"40":2,"41":1,"44":1,"45":2,"51":1,"52":1,"54":2,"57":4,"59":1}}],["anyway",{"2":{"18":1,"24":1,"57":1}}],["anything",{"2":{"5":1}}],["any",{"2":{"0":1,"1":1,"7":3,"17":2,"24":1,"36":1,"38":1,"59":1}}],["and",{"0":{"12":1,"55":1},"1":{"13":1},"2":{"0":7,"1":12,"2":2,"3":1,"5":2,"6":3,"7":2,"9":1,"10":5,"11":1,"12":7,"13":5,"15":3,"16":4,"17":4,"18":3,"19":3,"21":5,"22":3,"23":1,"25":1,"26":2,"27":1,"29":2,"32":1,"36":2,"37":1,"38":4,"39":1,"40":5,"41":5,"42":2,"43":2,"44":7,"45":2,"46":1,"48":1,"49":2,"50":5,"51":1,"53":4,"54":14,"55":2,"56":4,"57":8,"58":1,"59":3}}],["a",{"2":{"0":15,"1":22,"2":1,"3":8,"4":4,"5":20,"6":14,"7":24,"9":3,"10":7,"11":6,"12":19,"13":33,"16":8,"17":3,"18":6,"19":2,"21":49,"22":11,"23":10,"24":4,"25":4,"26":2,"27":5,"28":6,"29":63,"30":1,"31":20,"33":23,"34":8,"35":22,"36":4,"37":1,"38":3,"39":1,"40":11,"41":17,"42":33,"43":4,"44":3,"45":1,"46":1,"50":3,"51":6,"52":10,"53":4,"54":60,"55":9,"56":46,"57":24,"58":3,"59":8,"60":1}}],["ayaversion",{"2":{"51":1}}],["ayalocalvar",{"2":{"36":1}}],["ayacall",{"2":{"36":1}}],["ayacomment",{"2":{"36":3}}],["ayaconstructor",{"2":{"36":5}}],["ayafield",{"2":{"36":3}}],["ayafn",{"2":{"36":3}}],["ayaprimitive",{"2":{"36":3}}],["ayageneralized",{"2":{"36":3}}],["ayastruct",{"2":{"36":3}}],["ayadata",{"2":{"36":7}}],["ayakeyword",{"2":{"36":5}}],["aya>",{"2":{"36":1}}],["aya",{"0":{"0":1,"12":1,"14":1,"17":1,"40":1,"44":1,"45":1,"47":1,"51":1},"1":{"13":1,"18":1,"19":1,"46":1,"47":1,"48":1,"49":1,"50":1},"2":{"0":2,"1":6,"7":3,"12":2,"14":1,"17":1,"18":1,"21":1,"24":1,"29":1,"36":6,"37":1,"38":5,"39":6,"40":4,"41":4,"42":2,"43":1,"44":3,"45":3,"46":13,"47":7,"48":1,"50":3,"51":7,"52":2,"53":2,"54":3,"55":1,"57":3,"58":1,"59":8,"60":2}}]],"serializationVersion":2}`;export{e as default}; diff --git a/assets/chunks/VPLocalSearchBox.C23CuZ30.js b/assets/chunks/VPLocalSearchBox.C23CuZ30.js new file mode 100644 index 0000000..51f3a99 --- /dev/null +++ b/assets/chunks/VPLocalSearchBox.C23CuZ30.js @@ -0,0 +1,8 @@ +var Ft=Object.defineProperty;var Ot=(a,e,t)=>e in a?Ft(a,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):a[e]=t;var Ae=(a,e,t)=>Ot(a,typeof e!="symbol"?e+"":e,t);import{V as Ct,p as ie,h as me,ah as tt,ai as Rt,aj as At,q as $e,ak as Mt,d as Lt,D as xe,al as st,am as Dt,an as zt,s as Pt,ao as jt,v as Me,P as he,O as _e,ap as Vt,aq as $t,W as Bt,R as Wt,$ as Kt,o as H,b as Jt,j as _,a0 as Ut,k as L,ar as qt,as as Gt,at as Ht,c as Z,n as nt,e as Se,C as it,F as rt,a as fe,t as pe,au as Qt,av as at,aw as Yt,a7 as Zt,ad as Xt,ax as es,_ as ts}from"./framework.CoXjB5sU.js";import{u as ss,c as ns}from"./theme.CNpb5bEr.js";const is={root:()=>Ct(()=>import("./@localSearchIndexroot.BEfJRxcB.js"),[])};/*! +* tabbable 6.2.0 +* @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE +*/var mt=["input:not([inert])","select:not([inert])","textarea:not([inert])","a[href]:not([inert])","button:not([inert])","[tabindex]:not(slot):not([inert])","audio[controls]:not([inert])","video[controls]:not([inert])",'[contenteditable]:not([contenteditable="false"]):not([inert])',"details>summary:first-of-type:not([inert])","details:not([inert])"],Ne=mt.join(","),gt=typeof Element>"u",ae=gt?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,Fe=!gt&&Element.prototype.getRootNode?function(a){var e;return a==null||(e=a.getRootNode)===null||e===void 0?void 0:e.call(a)}:function(a){return a==null?void 0:a.ownerDocument},Oe=function a(e,t){var s;t===void 0&&(t=!0);var n=e==null||(s=e.getAttribute)===null||s===void 0?void 0:s.call(e,"inert"),r=n===""||n==="true",i=r||t&&e&&a(e.parentNode);return i},rs=function(e){var t,s=e==null||(t=e.getAttribute)===null||t===void 0?void 0:t.call(e,"contenteditable");return s===""||s==="true"},bt=function(e,t,s){if(Oe(e))return[];var n=Array.prototype.slice.apply(e.querySelectorAll(Ne));return t&&ae.call(e,Ne)&&n.unshift(e),n=n.filter(s),n},yt=function a(e,t,s){for(var n=[],r=Array.from(e);r.length;){var i=r.shift();if(!Oe(i,!1))if(i.tagName==="SLOT"){var o=i.assignedElements(),l=o.length?o:i.children,c=a(l,!0,s);s.flatten?n.push.apply(n,c):n.push({scopeParent:i,candidates:c})}else{var h=ae.call(i,Ne);h&&s.filter(i)&&(t||!e.includes(i))&&n.push(i);var m=i.shadowRoot||typeof s.getShadowRoot=="function"&&s.getShadowRoot(i),f=!Oe(m,!1)&&(!s.shadowRootFilter||s.shadowRootFilter(i));if(m&&f){var b=a(m===!0?i.children:m.children,!0,s);s.flatten?n.push.apply(n,b):n.push({scopeParent:i,candidates:b})}else r.unshift.apply(r,i.children)}}return n},wt=function(e){return!isNaN(parseInt(e.getAttribute("tabindex"),10))},re=function(e){if(!e)throw new Error("No node provided");return e.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||rs(e))&&!wt(e)?0:e.tabIndex},as=function(e,t){var s=re(e);return s<0&&t&&!wt(e)?0:s},os=function(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex},xt=function(e){return e.tagName==="INPUT"},ls=function(e){return xt(e)&&e.type==="hidden"},cs=function(e){var t=e.tagName==="DETAILS"&&Array.prototype.slice.apply(e.children).some(function(s){return s.tagName==="SUMMARY"});return t},us=function(e,t){for(var s=0;ssummary:first-of-type"),i=r?e.parentElement:e;if(ae.call(i,"details:not([open]) *"))return!0;if(!s||s==="full"||s==="legacy-full"){if(typeof n=="function"){for(var o=e;e;){var l=e.parentElement,c=Fe(e);if(l&&!l.shadowRoot&&n(l)===!0)return ot(e);e.assignedSlot?e=e.assignedSlot:!l&&c!==e.ownerDocument?e=c.host:e=l}e=o}if(ps(e))return!e.getClientRects().length;if(s!=="legacy-full")return!0}else if(s==="non-zero-area")return ot(e);return!1},ms=function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName))for(var t=e.parentElement;t;){if(t.tagName==="FIELDSET"&&t.disabled){for(var s=0;s=0)},bs=function a(e){var t=[],s=[];return e.forEach(function(n,r){var i=!!n.scopeParent,o=i?n.scopeParent:n,l=as(o,i),c=i?a(n.candidates):o;l===0?i?t.push.apply(t,c):t.push(o):s.push({documentOrder:r,tabIndex:l,item:n,isScope:i,content:c})}),s.sort(os).reduce(function(n,r){return r.isScope?n.push.apply(n,r.content):n.push(r.content),n},[]).concat(t)},ys=function(e,t){t=t||{};var s;return t.getShadowRoot?s=yt([e],t.includeContainer,{filter:Be.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:gs}):s=bt(e,t.includeContainer,Be.bind(null,t)),bs(s)},ws=function(e,t){t=t||{};var s;return t.getShadowRoot?s=yt([e],t.includeContainer,{filter:Ce.bind(null,t),flatten:!0,getShadowRoot:t.getShadowRoot}):s=bt(e,t.includeContainer,Ce.bind(null,t)),s},oe=function(e,t){if(t=t||{},!e)throw new Error("No node provided");return ae.call(e,Ne)===!1?!1:Be(t,e)},xs=mt.concat("iframe").join(","),Le=function(e,t){if(t=t||{},!e)throw new Error("No node provided");return ae.call(e,xs)===!1?!1:Ce(t,e)};/*! +* focus-trap 7.6.2 +* @license MIT, https://github.com/focus-trap/focus-trap/blob/master/LICENSE +*/function We(a,e){(e==null||e>a.length)&&(e=a.length);for(var t=0,s=Array(e);t0){var s=e[e.length-1];s!==t&&s.pause()}var n=e.indexOf(t);n===-1||e.splice(n,1),e.push(t)},deactivateTrap:function(e,t){var s=e.indexOf(t);s!==-1&&e.splice(s,1),e.length>0&&e[e.length-1].unpause()}},Os=function(e){return e.tagName&&e.tagName.toLowerCase()==="input"&&typeof e.select=="function"},Cs=function(e){return(e==null?void 0:e.key)==="Escape"||(e==null?void 0:e.key)==="Esc"||(e==null?void 0:e.keyCode)===27},ge=function(e){return(e==null?void 0:e.key)==="Tab"||(e==null?void 0:e.keyCode)===9},Rs=function(e){return ge(e)&&!e.shiftKey},As=function(e){return ge(e)&&e.shiftKey},dt=function(e){return setTimeout(e,0)},ve=function(e){for(var t=arguments.length,s=new Array(t>1?t-1:0),n=1;n1&&arguments[1]!==void 0?arguments[1]:{},g=d.hasFallback,T=g===void 0?!1:g,k=d.params,O=k===void 0?[]:k,S=r[u];if(typeof S=="function"&&(S=S.apply(void 0,Is(O))),S===!0&&(S=void 0),!S){if(S===void 0||S===!1)return S;throw new Error("`".concat(u,"` was specified but was not a node, or did not return a node"))}var C=S;if(typeof S=="string"){try{C=s.querySelector(S)}catch(v){throw new Error("`".concat(u,'` appears to be an invalid selector; error="').concat(v.message,'"'))}if(!C&&!T)throw new Error("`".concat(u,"` as selector refers to no known node"))}return C},m=function(){var u=h("initialFocus",{hasFallback:!0});if(u===!1)return!1;if(u===void 0||u&&!Le(u,r.tabbableOptions))if(c(s.activeElement)>=0)u=s.activeElement;else{var d=i.tabbableGroups[0],g=d&&d.firstTabbableNode;u=g||h("fallbackFocus")}else u===null&&(u=h("fallbackFocus"));if(!u)throw new Error("Your focus-trap needs to have at least one focusable element");return u},f=function(){if(i.containerGroups=i.containers.map(function(u){var d=ys(u,r.tabbableOptions),g=ws(u,r.tabbableOptions),T=d.length>0?d[0]:void 0,k=d.length>0?d[d.length-1]:void 0,O=g.find(function(v){return oe(v)}),S=g.slice().reverse().find(function(v){return oe(v)}),C=!!d.find(function(v){return re(v)>0});return{container:u,tabbableNodes:d,focusableNodes:g,posTabIndexesFound:C,firstTabbableNode:T,lastTabbableNode:k,firstDomTabbableNode:O,lastDomTabbableNode:S,nextTabbableNode:function(p){var E=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,F=d.indexOf(p);return F<0?E?g.slice(g.indexOf(p)+1).find(function(z){return oe(z)}):g.slice(0,g.indexOf(p)).reverse().find(function(z){return oe(z)}):d[F+(E?1:-1)]}}}),i.tabbableGroups=i.containerGroups.filter(function(u){return u.tabbableNodes.length>0}),i.tabbableGroups.length<=0&&!h("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times");if(i.containerGroups.find(function(u){return u.posTabIndexesFound})&&i.containerGroups.length>1)throw new Error("At least one node with a positive tabindex was found in one of your focus-trap's multiple containers. Positive tabindexes are only supported in single-container focus-traps.")},b=function(u){var d=u.activeElement;if(d)return d.shadowRoot&&d.shadowRoot.activeElement!==null?b(d.shadowRoot):d},y=function(u){if(u!==!1&&u!==b(document)){if(!u||!u.focus){y(m());return}u.focus({preventScroll:!!r.preventScroll}),i.mostRecentlyFocusedNode=u,Os(u)&&u.select()}},x=function(u){var d=h("setReturnFocus",{params:[u]});return d||(d===!1?!1:u)},w=function(u){var d=u.target,g=u.event,T=u.isBackward,k=T===void 0?!1:T;d=d||Ee(g),f();var O=null;if(i.tabbableGroups.length>0){var S=c(d,g),C=S>=0?i.containerGroups[S]:void 0;if(S<0)k?O=i.tabbableGroups[i.tabbableGroups.length-1].lastTabbableNode:O=i.tabbableGroups[0].firstTabbableNode;else if(k){var v=i.tabbableGroups.findIndex(function(j){var I=j.firstTabbableNode;return d===I});if(v<0&&(C.container===d||Le(d,r.tabbableOptions)&&!oe(d,r.tabbableOptions)&&!C.nextTabbableNode(d,!1))&&(v=S),v>=0){var p=v===0?i.tabbableGroups.length-1:v-1,E=i.tabbableGroups[p];O=re(d)>=0?E.lastTabbableNode:E.lastDomTabbableNode}else ge(g)||(O=C.nextTabbableNode(d,!1))}else{var F=i.tabbableGroups.findIndex(function(j){var I=j.lastTabbableNode;return d===I});if(F<0&&(C.container===d||Le(d,r.tabbableOptions)&&!oe(d,r.tabbableOptions)&&!C.nextTabbableNode(d))&&(F=S),F>=0){var z=F===i.tabbableGroups.length-1?0:F+1,P=i.tabbableGroups[z];O=re(d)>=0?P.firstTabbableNode:P.firstDomTabbableNode}else ge(g)||(O=C.nextTabbableNode(d))}}else O=h("fallbackFocus");return O},R=function(u){var d=Ee(u);if(!(c(d,u)>=0)){if(ve(r.clickOutsideDeactivates,u)){o.deactivate({returnFocus:r.returnFocusOnDeactivate});return}ve(r.allowOutsideClick,u)||u.preventDefault()}},A=function(u){var d=Ee(u),g=c(d,u)>=0;if(g||d instanceof Document)g&&(i.mostRecentlyFocusedNode=d);else{u.stopImmediatePropagation();var T,k=!0;if(i.mostRecentlyFocusedNode)if(re(i.mostRecentlyFocusedNode)>0){var O=c(i.mostRecentlyFocusedNode),S=i.containerGroups[O].tabbableNodes;if(S.length>0){var C=S.findIndex(function(v){return v===i.mostRecentlyFocusedNode});C>=0&&(r.isKeyForward(i.recentNavEvent)?C+1=0&&(T=S[C-1],k=!1))}}else i.containerGroups.some(function(v){return v.tabbableNodes.some(function(p){return re(p)>0})})||(k=!1);else k=!1;k&&(T=w({target:i.mostRecentlyFocusedNode,isBackward:r.isKeyBackward(i.recentNavEvent)})),y(T||i.mostRecentlyFocusedNode||m())}i.recentNavEvent=void 0},J=function(u){var d=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;i.recentNavEvent=u;var g=w({event:u,isBackward:d});g&&(ge(u)&&u.preventDefault(),y(g))},Q=function(u){(r.isKeyForward(u)||r.isKeyBackward(u))&&J(u,r.isKeyBackward(u))},W=function(u){Cs(u)&&ve(r.escapeDeactivates,u)!==!1&&(u.preventDefault(),o.deactivate())},V=function(u){var d=Ee(u);c(d,u)>=0||ve(r.clickOutsideDeactivates,u)||ve(r.allowOutsideClick,u)||(u.preventDefault(),u.stopImmediatePropagation())},$=function(){if(i.active)return ut.activateTrap(n,o),i.delayInitialFocusTimer=r.delayInitialFocus?dt(function(){y(m())}):y(m()),s.addEventListener("focusin",A,!0),s.addEventListener("mousedown",R,{capture:!0,passive:!1}),s.addEventListener("touchstart",R,{capture:!0,passive:!1}),s.addEventListener("click",V,{capture:!0,passive:!1}),s.addEventListener("keydown",Q,{capture:!0,passive:!1}),s.addEventListener("keydown",W),o},be=function(){if(i.active)return s.removeEventListener("focusin",A,!0),s.removeEventListener("mousedown",R,!0),s.removeEventListener("touchstart",R,!0),s.removeEventListener("click",V,!0),s.removeEventListener("keydown",Q,!0),s.removeEventListener("keydown",W),o},M=function(u){var d=u.some(function(g){var T=Array.from(g.removedNodes);return T.some(function(k){return k===i.mostRecentlyFocusedNode})});d&&y(m())},U=typeof window<"u"&&"MutationObserver"in window?new MutationObserver(M):void 0,q=function(){U&&(U.disconnect(),i.active&&!i.paused&&i.containers.map(function(u){U.observe(u,{subtree:!0,childList:!0})}))};return o={get active(){return i.active},get paused(){return i.paused},activate:function(u){if(i.active)return this;var d=l(u,"onActivate"),g=l(u,"onPostActivate"),T=l(u,"checkCanFocusTrap");T||f(),i.active=!0,i.paused=!1,i.nodeFocusedBeforeActivation=s.activeElement,d==null||d();var k=function(){T&&f(),$(),q(),g==null||g()};return T?(T(i.containers.concat()).then(k,k),this):(k(),this)},deactivate:function(u){if(!i.active)return this;var d=ct({onDeactivate:r.onDeactivate,onPostDeactivate:r.onPostDeactivate,checkCanReturnFocus:r.checkCanReturnFocus},u);clearTimeout(i.delayInitialFocusTimer),i.delayInitialFocusTimer=void 0,be(),i.active=!1,i.paused=!1,q(),ut.deactivateTrap(n,o);var g=l(d,"onDeactivate"),T=l(d,"onPostDeactivate"),k=l(d,"checkCanReturnFocus"),O=l(d,"returnFocus","returnFocusOnDeactivate");g==null||g();var S=function(){dt(function(){O&&y(x(i.nodeFocusedBeforeActivation)),T==null||T()})};return O&&k?(k(x(i.nodeFocusedBeforeActivation)).then(S,S),this):(S(),this)},pause:function(u){if(i.paused||!i.active)return this;var d=l(u,"onPause"),g=l(u,"onPostPause");return i.paused=!0,d==null||d(),be(),q(),g==null||g(),this},unpause:function(u){if(!i.paused||!i.active)return this;var d=l(u,"onUnpause"),g=l(u,"onPostUnpause");return i.paused=!1,d==null||d(),f(),$(),q(),g==null||g(),this},updateContainerElements:function(u){var d=[].concat(u).filter(Boolean);return i.containers=d.map(function(g){return typeof g=="string"?s.querySelector(g):g}),i.active&&f(),q(),this}},o.updateContainerElements(e),o};function Ds(a,e={}){let t;const{immediate:s,...n}=e,r=ie(!1),i=ie(!1),o=f=>t&&t.activate(f),l=f=>t&&t.deactivate(f),c=()=>{t&&(t.pause(),i.value=!0)},h=()=>{t&&(t.unpause(),i.value=!1)},m=me(()=>{const f=tt(a);return(Array.isArray(f)?f:[f]).map(b=>{const y=tt(b);return typeof y=="string"?y:Rt(y)}).filter(At)});return $e(m,f=>{f.length&&(t=Ls(f,{...n,onActivate(){r.value=!0,e.onActivate&&e.onActivate()},onDeactivate(){r.value=!1,e.onDeactivate&&e.onDeactivate()}}),s&&o())},{flush:"post"}),Mt(()=>l()),{hasFocus:r,isPaused:i,activate:o,deactivate:l,pause:c,unpause:h}}class ce{constructor(e,t=!0,s=[],n=5e3){this.ctx=e,this.iframes=t,this.exclude=s,this.iframesTimeout=n}static matches(e,t){const s=typeof t=="string"?[t]:t,n=e.matches||e.matchesSelector||e.msMatchesSelector||e.mozMatchesSelector||e.oMatchesSelector||e.webkitMatchesSelector;if(n){let r=!1;return s.every(i=>n.call(e,i)?(r=!0,!1):!0),r}else return!1}getContexts(){let e,t=[];return typeof this.ctx>"u"||!this.ctx?e=[]:NodeList.prototype.isPrototypeOf(this.ctx)?e=Array.prototype.slice.call(this.ctx):Array.isArray(this.ctx)?e=this.ctx:typeof this.ctx=="string"?e=Array.prototype.slice.call(document.querySelectorAll(this.ctx)):e=[this.ctx],e.forEach(s=>{const n=t.filter(r=>r.contains(s)).length>0;t.indexOf(s)===-1&&!n&&t.push(s)}),t}getIframeContents(e,t,s=()=>{}){let n;try{const r=e.contentWindow;if(n=r.document,!r||!n)throw new Error("iframe inaccessible")}catch{s()}n&&t(n)}isIframeBlank(e){const t="about:blank",s=e.getAttribute("src").trim();return e.contentWindow.location.href===t&&s!==t&&s}observeIframeLoad(e,t,s){let n=!1,r=null;const i=()=>{if(!n){n=!0,clearTimeout(r);try{this.isIframeBlank(e)||(e.removeEventListener("load",i),this.getIframeContents(e,t,s))}catch{s()}}};e.addEventListener("load",i),r=setTimeout(i,this.iframesTimeout)}onIframeReady(e,t,s){try{e.contentWindow.document.readyState==="complete"?this.isIframeBlank(e)?this.observeIframeLoad(e,t,s):this.getIframeContents(e,t,s):this.observeIframeLoad(e,t,s)}catch{s()}}waitForIframes(e,t){let s=0;this.forEachIframe(e,()=>!0,n=>{s++,this.waitForIframes(n.querySelector("html"),()=>{--s||t()})},n=>{n||t()})}forEachIframe(e,t,s,n=()=>{}){let r=e.querySelectorAll("iframe"),i=r.length,o=0;r=Array.prototype.slice.call(r);const l=()=>{--i<=0&&n(o)};i||l(),r.forEach(c=>{ce.matches(c,this.exclude)?l():this.onIframeReady(c,h=>{t(c)&&(o++,s(h)),l()},l)})}createIterator(e,t,s){return document.createNodeIterator(e,t,s,!1)}createInstanceOnIframe(e){return new ce(e.querySelector("html"),this.iframes)}compareNodeIframe(e,t,s){const n=e.compareDocumentPosition(s),r=Node.DOCUMENT_POSITION_PRECEDING;if(n&r)if(t!==null){const i=t.compareDocumentPosition(s),o=Node.DOCUMENT_POSITION_FOLLOWING;if(i&o)return!0}else return!0;return!1}getIteratorNode(e){const t=e.previousNode();let s;return t===null?s=e.nextNode():s=e.nextNode()&&e.nextNode(),{prevNode:t,node:s}}checkIframeFilter(e,t,s,n){let r=!1,i=!1;return n.forEach((o,l)=>{o.val===s&&(r=l,i=o.handled)}),this.compareNodeIframe(e,t,s)?(r===!1&&!i?n.push({val:s,handled:!0}):r!==!1&&!i&&(n[r].handled=!0),!0):(r===!1&&n.push({val:s,handled:!1}),!1)}handleOpenIframes(e,t,s,n){e.forEach(r=>{r.handled||this.getIframeContents(r.val,i=>{this.createInstanceOnIframe(i).forEachNode(t,s,n)})})}iterateThroughNodes(e,t,s,n,r){const i=this.createIterator(t,e,n);let o=[],l=[],c,h,m=()=>({prevNode:h,node:c}=this.getIteratorNode(i),c);for(;m();)this.iframes&&this.forEachIframe(t,f=>this.checkIframeFilter(c,h,f,o),f=>{this.createInstanceOnIframe(f).forEachNode(e,b=>l.push(b),n)}),l.push(c);l.forEach(f=>{s(f)}),this.iframes&&this.handleOpenIframes(o,e,s,n),r()}forEachNode(e,t,s,n=()=>{}){const r=this.getContexts();let i=r.length;i||n(),r.forEach(o=>{const l=()=>{this.iterateThroughNodes(e,o,t,s,()=>{--i<=0&&n()})};this.iframes?this.waitForIframes(o,l):l()})}}let zs=class{constructor(e){this.ctx=e,this.ie=!1;const t=window.navigator.userAgent;(t.indexOf("MSIE")>-1||t.indexOf("Trident")>-1)&&(this.ie=!0)}set opt(e){this._opt=Object.assign({},{element:"",className:"",exclude:[],iframes:!1,iframesTimeout:5e3,separateWordSearch:!0,diacritics:!0,synonyms:{},accuracy:"partially",acrossElements:!1,caseSensitive:!1,ignoreJoiners:!1,ignoreGroups:0,ignorePunctuation:[],wildcards:"disabled",each:()=>{},noMatch:()=>{},filter:()=>!0,done:()=>{},debug:!1,log:window.console},e)}get opt(){return this._opt}get iterator(){return new ce(this.ctx,this.opt.iframes,this.opt.exclude,this.opt.iframesTimeout)}log(e,t="debug"){const s=this.opt.log;this.opt.debug&&typeof s=="object"&&typeof s[t]=="function"&&s[t](`mark.js: ${e}`)}escapeStr(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}createRegExp(e){return this.opt.wildcards!=="disabled"&&(e=this.setupWildcardsRegExp(e)),e=this.escapeStr(e),Object.keys(this.opt.synonyms).length&&(e=this.createSynonymsRegExp(e)),(this.opt.ignoreJoiners||this.opt.ignorePunctuation.length)&&(e=this.setupIgnoreJoinersRegExp(e)),this.opt.diacritics&&(e=this.createDiacriticsRegExp(e)),e=this.createMergedBlanksRegExp(e),(this.opt.ignoreJoiners||this.opt.ignorePunctuation.length)&&(e=this.createJoinersRegExp(e)),this.opt.wildcards!=="disabled"&&(e=this.createWildcardsRegExp(e)),e=this.createAccuracyRegExp(e),e}createSynonymsRegExp(e){const t=this.opt.synonyms,s=this.opt.caseSensitive?"":"i",n=this.opt.ignoreJoiners||this.opt.ignorePunctuation.length?"\0":"";for(let r in t)if(t.hasOwnProperty(r)){const i=t[r],o=this.opt.wildcards!=="disabled"?this.setupWildcardsRegExp(r):this.escapeStr(r),l=this.opt.wildcards!=="disabled"?this.setupWildcardsRegExp(i):this.escapeStr(i);o!==""&&l!==""&&(e=e.replace(new RegExp(`(${this.escapeStr(o)}|${this.escapeStr(l)})`,`gm${s}`),n+`(${this.processSynomyms(o)}|${this.processSynomyms(l)})`+n))}return e}processSynomyms(e){return(this.opt.ignoreJoiners||this.opt.ignorePunctuation.length)&&(e=this.setupIgnoreJoinersRegExp(e)),e}setupWildcardsRegExp(e){return e=e.replace(/(?:\\)*\?/g,t=>t.charAt(0)==="\\"?"?":""),e.replace(/(?:\\)*\*/g,t=>t.charAt(0)==="\\"?"*":"")}createWildcardsRegExp(e){let t=this.opt.wildcards==="withSpaces";return e.replace(/\u0001/g,t?"[\\S\\s]?":"\\S?").replace(/\u0002/g,t?"[\\S\\s]*?":"\\S*")}setupIgnoreJoinersRegExp(e){return e.replace(/[^(|)\\]/g,(t,s,n)=>{let r=n.charAt(s+1);return/[(|)\\]/.test(r)||r===""?t:t+"\0"})}createJoinersRegExp(e){let t=[];const s=this.opt.ignorePunctuation;return Array.isArray(s)&&s.length&&t.push(this.escapeStr(s.join(""))),this.opt.ignoreJoiners&&t.push("\\u00ad\\u200b\\u200c\\u200d"),t.length?e.split(/\u0000+/).join(`[${t.join("")}]*`):e}createDiacriticsRegExp(e){const t=this.opt.caseSensitive?"":"i",s=this.opt.caseSensitive?["aàáảãạăằắẳẵặâầấẩẫậäåāą","AÀÁẢÃẠĂẰẮẲẴẶÂẦẤẨẪẬÄÅĀĄ","cçćč","CÇĆČ","dđď","DĐĎ","eèéẻẽẹêềếểễệëěēę","EÈÉẺẼẸÊỀẾỂỄỆËĚĒĘ","iìíỉĩịîïī","IÌÍỈĨỊÎÏĪ","lł","LŁ","nñňń","NÑŇŃ","oòóỏõọôồốổỗộơởỡớờợöøō","OÒÓỎÕỌÔỒỐỔỖỘƠỞỠỚỜỢÖØŌ","rř","RŘ","sšśșş","SŠŚȘŞ","tťțţ","TŤȚŢ","uùúủũụưừứửữựûüůū","UÙÚỦŨỤƯỪỨỬỮỰÛÜŮŪ","yýỳỷỹỵÿ","YÝỲỶỸỴŸ","zžżź","ZŽŻŹ"]:["aàáảãạăằắẳẵặâầấẩẫậäåāąAÀÁẢÃẠĂẰẮẲẴẶÂẦẤẨẪẬÄÅĀĄ","cçćčCÇĆČ","dđďDĐĎ","eèéẻẽẹêềếểễệëěēęEÈÉẺẼẸÊỀẾỂỄỆËĚĒĘ","iìíỉĩịîïīIÌÍỈĨỊÎÏĪ","lłLŁ","nñňńNÑŇŃ","oòóỏõọôồốổỗộơởỡớờợöøōOÒÓỎÕỌÔỒỐỔỖỘƠỞỠỚỜỢÖØŌ","rřRŘ","sšśșşSŠŚȘŞ","tťțţTŤȚŢ","uùúủũụưừứửữựûüůūUÙÚỦŨỤƯỪỨỬỮỰÛÜŮŪ","yýỳỷỹỵÿYÝỲỶỸỴŸ","zžżźZŽŻŹ"];let n=[];return e.split("").forEach(r=>{s.every(i=>{if(i.indexOf(r)!==-1){if(n.indexOf(i)>-1)return!1;e=e.replace(new RegExp(`[${i}]`,`gm${t}`),`[${i}]`),n.push(i)}return!0})}),e}createMergedBlanksRegExp(e){return e.replace(/[\s]+/gmi,"[\\s]+")}createAccuracyRegExp(e){const t="!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~¡¿";let s=this.opt.accuracy,n=typeof s=="string"?s:s.value,r=typeof s=="string"?[]:s.limiters,i="";switch(r.forEach(o=>{i+=`|${this.escapeStr(o)}`}),n){case"partially":default:return`()(${e})`;case"complementary":return i="\\s"+(i||this.escapeStr(t)),`()([^${i}]*${e}[^${i}]*)`;case"exactly":return`(^|\\s${i})(${e})(?=$|\\s${i})`}}getSeparatedKeywords(e){let t=[];return e.forEach(s=>{this.opt.separateWordSearch?s.split(" ").forEach(n=>{n.trim()&&t.indexOf(n)===-1&&t.push(n)}):s.trim()&&t.indexOf(s)===-1&&t.push(s)}),{keywords:t.sort((s,n)=>n.length-s.length),length:t.length}}isNumeric(e){return Number(parseFloat(e))==e}checkRanges(e){if(!Array.isArray(e)||Object.prototype.toString.call(e[0])!=="[object Object]")return this.log("markRanges() will only accept an array of objects"),this.opt.noMatch(e),[];const t=[];let s=0;return e.sort((n,r)=>n.start-r.start).forEach(n=>{let{start:r,end:i,valid:o}=this.callNoMatchOnInvalidRanges(n,s);o&&(n.start=r,n.length=i-r,t.push(n),s=i)}),t}callNoMatchOnInvalidRanges(e,t){let s,n,r=!1;return e&&typeof e.start<"u"?(s=parseInt(e.start,10),n=s+parseInt(e.length,10),this.isNumeric(e.start)&&this.isNumeric(e.length)&&n-t>0&&n-s>0?r=!0:(this.log(`Ignoring invalid or overlapping range: ${JSON.stringify(e)}`),this.opt.noMatch(e))):(this.log(`Ignoring invalid range: ${JSON.stringify(e)}`),this.opt.noMatch(e)),{start:s,end:n,valid:r}}checkWhitespaceRanges(e,t,s){let n,r=!0,i=s.length,o=t-i,l=parseInt(e.start,10)-o;return l=l>i?i:l,n=l+parseInt(e.length,10),n>i&&(n=i,this.log(`End range automatically set to the max value of ${i}`)),l<0||n-l<0||l>i||n>i?(r=!1,this.log(`Invalid range: ${JSON.stringify(e)}`),this.opt.noMatch(e)):s.substring(l,n).replace(/\s+/g,"")===""&&(r=!1,this.log("Skipping whitespace only range: "+JSON.stringify(e)),this.opt.noMatch(e)),{start:l,end:n,valid:r}}getTextNodes(e){let t="",s=[];this.iterator.forEachNode(NodeFilter.SHOW_TEXT,n=>{s.push({start:t.length,end:(t+=n.textContent).length,node:n})},n=>this.matchesExclude(n.parentNode)?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT,()=>{e({value:t,nodes:s})})}matchesExclude(e){return ce.matches(e,this.opt.exclude.concat(["script","style","title","head","html"]))}wrapRangeInTextNode(e,t,s){const n=this.opt.element?this.opt.element:"mark",r=e.splitText(t),i=r.splitText(s-t);let o=document.createElement(n);return o.setAttribute("data-markjs","true"),this.opt.className&&o.setAttribute("class",this.opt.className),o.textContent=r.textContent,r.parentNode.replaceChild(o,r),i}wrapRangeInMappedTextNode(e,t,s,n,r){e.nodes.every((i,o)=>{const l=e.nodes[o+1];if(typeof l>"u"||l.start>t){if(!n(i.node))return!1;const c=t-i.start,h=(s>i.end?i.end:s)-i.start,m=e.value.substr(0,i.start),f=e.value.substr(h+i.start);if(i.node=this.wrapRangeInTextNode(i.node,c,h),e.value=m+f,e.nodes.forEach((b,y)=>{y>=o&&(e.nodes[y].start>0&&y!==o&&(e.nodes[y].start-=h),e.nodes[y].end-=h)}),s-=h,r(i.node.previousSibling,i.start),s>i.end)t=i.end;else return!1}return!0})}wrapMatches(e,t,s,n,r){const i=t===0?0:t+1;this.getTextNodes(o=>{o.nodes.forEach(l=>{l=l.node;let c;for(;(c=e.exec(l.textContent))!==null&&c[i]!=="";){if(!s(c[i],l))continue;let h=c.index;if(i!==0)for(let m=1;m{let l;for(;(l=e.exec(o.value))!==null&&l[i]!=="";){let c=l.index;if(i!==0)for(let m=1;ms(l[i],m),(m,f)=>{e.lastIndex=f,n(m)})}r()})}wrapRangeFromIndex(e,t,s,n){this.getTextNodes(r=>{const i=r.value.length;e.forEach((o,l)=>{let{start:c,end:h,valid:m}=this.checkWhitespaceRanges(o,i,r.value);m&&this.wrapRangeInMappedTextNode(r,c,h,f=>t(f,o,r.value.substring(c,h),l),f=>{s(f,o)})}),n()})}unwrapMatches(e){const t=e.parentNode;let s=document.createDocumentFragment();for(;e.firstChild;)s.appendChild(e.removeChild(e.firstChild));t.replaceChild(s,e),this.ie?this.normalizeTextNode(t):t.normalize()}normalizeTextNode(e){if(e){if(e.nodeType===3)for(;e.nextSibling&&e.nextSibling.nodeType===3;)e.nodeValue+=e.nextSibling.nodeValue,e.parentNode.removeChild(e.nextSibling);else this.normalizeTextNode(e.firstChild);this.normalizeTextNode(e.nextSibling)}}markRegExp(e,t){this.opt=t,this.log(`Searching with expression "${e}"`);let s=0,n="wrapMatches";const r=i=>{s++,this.opt.each(i)};this.opt.acrossElements&&(n="wrapMatchesAcrossElements"),this[n](e,this.opt.ignoreGroups,(i,o)=>this.opt.filter(o,i,s),r,()=>{s===0&&this.opt.noMatch(e),this.opt.done(s)})}mark(e,t){this.opt=t;let s=0,n="wrapMatches";const{keywords:r,length:i}=this.getSeparatedKeywords(typeof e=="string"?[e]:e),o=this.opt.caseSensitive?"":"i",l=c=>{let h=new RegExp(this.createRegExp(c),`gm${o}`),m=0;this.log(`Searching with expression "${h}"`),this[n](h,1,(f,b)=>this.opt.filter(b,c,s,m),f=>{m++,s++,this.opt.each(f)},()=>{m===0&&this.opt.noMatch(c),r[i-1]===c?this.opt.done(s):l(r[r.indexOf(c)+1])})};this.opt.acrossElements&&(n="wrapMatchesAcrossElements"),i===0?this.opt.done(s):l(r[0])}markRanges(e,t){this.opt=t;let s=0,n=this.checkRanges(e);n&&n.length?(this.log("Starting to mark with the following ranges: "+JSON.stringify(n)),this.wrapRangeFromIndex(n,(r,i,o,l)=>this.opt.filter(r,i,o,l),(r,i)=>{s++,this.opt.each(r,i)},()=>{this.opt.done(s)})):this.opt.done(s)}unmark(e){this.opt=e;let t=this.opt.element?this.opt.element:"*";t+="[data-markjs]",this.opt.className&&(t+=`.${this.opt.className}`),this.log(`Removal selector "${t}"`),this.iterator.forEachNode(NodeFilter.SHOW_ELEMENT,s=>{this.unwrapMatches(s)},s=>{const n=ce.matches(s,t),r=this.matchesExclude(s);return!n||r?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT},this.opt.done)}};function Ps(a){const e=new zs(a);return this.mark=(t,s)=>(e.mark(t,s),this),this.markRegExp=(t,s)=>(e.markRegExp(t,s),this),this.markRanges=(t,s)=>(e.markRanges(t,s),this),this.unmark=t=>(e.unmark(t),this),this}function ke(a,e,t,s){function n(r){return r instanceof t?r:new t(function(i){i(r)})}return new(t||(t=Promise))(function(r,i){function o(h){try{c(s.next(h))}catch(m){i(m)}}function l(h){try{c(s.throw(h))}catch(m){i(m)}}function c(h){h.done?r(h.value):n(h.value).then(o,l)}c((s=s.apply(a,[])).next())})}const js="ENTRIES",_t="KEYS",St="VALUES",D="";class De{constructor(e,t){const s=e._tree,n=Array.from(s.keys());this.set=e,this._type=t,this._path=n.length>0?[{node:s,keys:n}]:[]}next(){const e=this.dive();return this.backtrack(),e}dive(){if(this._path.length===0)return{done:!0,value:void 0};const{node:e,keys:t}=le(this._path);if(le(t)===D)return{done:!1,value:this.result()};const s=e.get(le(t));return this._path.push({node:s,keys:Array.from(s.keys())}),this.dive()}backtrack(){if(this._path.length===0)return;const e=le(this._path).keys;e.pop(),!(e.length>0)&&(this._path.pop(),this.backtrack())}key(){return this.set._prefix+this._path.map(({keys:e})=>le(e)).filter(e=>e!==D).join("")}value(){return le(this._path).node.get(D)}result(){switch(this._type){case St:return this.value();case _t:return this.key();default:return[this.key(),this.value()]}}[Symbol.iterator](){return this}}const le=a=>a[a.length-1],Vs=(a,e,t)=>{const s=new Map;if(e===void 0)return s;const n=e.length+1,r=n+t,i=new Uint8Array(r*n).fill(t+1);for(let o=0;o{const l=r*i;e:for(const c of a.keys())if(c===D){const h=n[l-1];h<=t&&s.set(o,[a.get(c),h])}else{let h=r;for(let m=0;mt)continue e}Et(a.get(c),e,t,s,n,h,i,o+c)}};class X{constructor(e=new Map,t=""){this._size=void 0,this._tree=e,this._prefix=t}atPrefix(e){if(!e.startsWith(this._prefix))throw new Error("Mismatched prefix");const[t,s]=Re(this._tree,e.slice(this._prefix.length));if(t===void 0){const[n,r]=qe(s);for(const i of n.keys())if(i!==D&&i.startsWith(r)){const o=new Map;return o.set(i.slice(r.length),n.get(i)),new X(o,e)}}return new X(t,e)}clear(){this._size=void 0,this._tree.clear()}delete(e){return this._size=void 0,$s(this._tree,e)}entries(){return new De(this,js)}forEach(e){for(const[t,s]of this)e(t,s,this)}fuzzyGet(e,t){return Vs(this._tree,e,t)}get(e){const t=Ke(this._tree,e);return t!==void 0?t.get(D):void 0}has(e){const t=Ke(this._tree,e);return t!==void 0&&t.has(D)}keys(){return new De(this,_t)}set(e,t){if(typeof e!="string")throw new Error("key must be a string");return this._size=void 0,ze(this._tree,e).set(D,t),this}get size(){if(this._size)return this._size;this._size=0;const e=this.entries();for(;!e.next().done;)this._size+=1;return this._size}update(e,t){if(typeof e!="string")throw new Error("key must be a string");this._size=void 0;const s=ze(this._tree,e);return s.set(D,t(s.get(D))),this}fetch(e,t){if(typeof e!="string")throw new Error("key must be a string");this._size=void 0;const s=ze(this._tree,e);let n=s.get(D);return n===void 0&&s.set(D,n=t()),n}values(){return new De(this,St)}[Symbol.iterator](){return this.entries()}static from(e){const t=new X;for(const[s,n]of e)t.set(s,n);return t}static fromObject(e){return X.from(Object.entries(e))}}const Re=(a,e,t=[])=>{if(e.length===0||a==null)return[a,t];for(const s of a.keys())if(s!==D&&e.startsWith(s))return t.push([a,s]),Re(a.get(s),e.slice(s.length),t);return t.push([a,e]),Re(void 0,"",t)},Ke=(a,e)=>{if(e.length===0||a==null)return a;for(const t of a.keys())if(t!==D&&e.startsWith(t))return Ke(a.get(t),e.slice(t.length))},ze=(a,e)=>{const t=e.length;e:for(let s=0;a&&s{const[t,s]=Re(a,e);if(t!==void 0){if(t.delete(D),t.size===0)Tt(s);else if(t.size===1){const[n,r]=t.entries().next().value;It(s,n,r)}}},Tt=a=>{if(a.length===0)return;const[e,t]=qe(a);if(e.delete(t),e.size===0)Tt(a.slice(0,-1));else if(e.size===1){const[s,n]=e.entries().next().value;s!==D&&It(a.slice(0,-1),s,n)}},It=(a,e,t)=>{if(a.length===0)return;const[s,n]=qe(a);s.set(n+e,t),s.delete(n)},qe=a=>a[a.length-1],Ge="or",kt="and",Bs="and_not";class ue{constructor(e){if((e==null?void 0:e.fields)==null)throw new Error('MiniSearch: option "fields" must be provided');const t=e.autoVacuum==null||e.autoVacuum===!0?Ve:e.autoVacuum;this._options=Object.assign(Object.assign(Object.assign({},je),e),{autoVacuum:t,searchOptions:Object.assign(Object.assign({},ht),e.searchOptions||{}),autoSuggestOptions:Object.assign(Object.assign({},qs),e.autoSuggestOptions||{})}),this._index=new X,this._documentCount=0,this._documentIds=new Map,this._idToShortId=new Map,this._fieldIds={},this._fieldLength=new Map,this._avgFieldLength=[],this._nextId=0,this._storedFields=new Map,this._dirtCount=0,this._currentVacuum=null,this._enqueuedVacuum=null,this._enqueuedVacuumConditions=Ue,this.addFields(this._options.fields)}add(e){const{extractField:t,tokenize:s,processTerm:n,fields:r,idField:i}=this._options,o=t(e,i);if(o==null)throw new Error(`MiniSearch: document does not have ID field "${i}"`);if(this._idToShortId.has(o))throw new Error(`MiniSearch: duplicate ID ${o}`);const l=this.addDocumentId(o);this.saveStoredFields(l,e);for(const c of r){const h=t(e,c);if(h==null)continue;const m=s(h.toString(),c),f=this._fieldIds[c],b=new Set(m).size;this.addFieldLength(l,f,this._documentCount-1,b);for(const y of m){const x=n(y,c);if(Array.isArray(x))for(const w of x)this.addTerm(f,l,w);else x&&this.addTerm(f,l,x)}}}addAll(e){for(const t of e)this.add(t)}addAllAsync(e,t={}){const{chunkSize:s=10}=t,n={chunk:[],promise:Promise.resolve()},{chunk:r,promise:i}=e.reduce(({chunk:o,promise:l},c,h)=>(o.push(c),(h+1)%s===0?{chunk:[],promise:l.then(()=>new Promise(m=>setTimeout(m,0))).then(()=>this.addAll(o))}:{chunk:o,promise:l}),n);return i.then(()=>this.addAll(r))}remove(e){const{tokenize:t,processTerm:s,extractField:n,fields:r,idField:i}=this._options,o=n(e,i);if(o==null)throw new Error(`MiniSearch: document does not have ID field "${i}"`);const l=this._idToShortId.get(o);if(l==null)throw new Error(`MiniSearch: cannot remove document with ID ${o}: it is not in the index`);for(const c of r){const h=n(e,c);if(h==null)continue;const m=t(h.toString(),c),f=this._fieldIds[c],b=new Set(m).size;this.removeFieldLength(l,f,this._documentCount,b);for(const y of m){const x=s(y,c);if(Array.isArray(x))for(const w of x)this.removeTerm(f,l,w);else x&&this.removeTerm(f,l,x)}}this._storedFields.delete(l),this._documentIds.delete(l),this._idToShortId.delete(o),this._fieldLength.delete(l),this._documentCount-=1}removeAll(e){if(e)for(const t of e)this.remove(t);else{if(arguments.length>0)throw new Error("Expected documents to be present. Omit the argument to remove all documents.");this._index=new X,this._documentCount=0,this._documentIds=new Map,this._idToShortId=new Map,this._fieldLength=new Map,this._avgFieldLength=[],this._storedFields=new Map,this._nextId=0}}discard(e){const t=this._idToShortId.get(e);if(t==null)throw new Error(`MiniSearch: cannot discard document with ID ${e}: it is not in the index`);this._idToShortId.delete(e),this._documentIds.delete(t),this._storedFields.delete(t),(this._fieldLength.get(t)||[]).forEach((s,n)=>{this.removeFieldLength(t,n,this._documentCount,s)}),this._fieldLength.delete(t),this._documentCount-=1,this._dirtCount+=1,this.maybeAutoVacuum()}maybeAutoVacuum(){if(this._options.autoVacuum===!1)return;const{minDirtFactor:e,minDirtCount:t,batchSize:s,batchWait:n}=this._options.autoVacuum;this.conditionalVacuum({batchSize:s,batchWait:n},{minDirtCount:t,minDirtFactor:e})}discardAll(e){const t=this._options.autoVacuum;try{this._options.autoVacuum=!1;for(const s of e)this.discard(s)}finally{this._options.autoVacuum=t}this.maybeAutoVacuum()}replace(e){const{idField:t,extractField:s}=this._options,n=s(e,t);this.discard(n),this.add(e)}vacuum(e={}){return this.conditionalVacuum(e)}conditionalVacuum(e,t){return this._currentVacuum?(this._enqueuedVacuumConditions=this._enqueuedVacuumConditions&&t,this._enqueuedVacuum!=null?this._enqueuedVacuum:(this._enqueuedVacuum=this._currentVacuum.then(()=>{const s=this._enqueuedVacuumConditions;return this._enqueuedVacuumConditions=Ue,this.performVacuuming(e,s)}),this._enqueuedVacuum)):this.vacuumConditionsMet(t)===!1?Promise.resolve():(this._currentVacuum=this.performVacuuming(e),this._currentVacuum)}performVacuuming(e,t){return ke(this,void 0,void 0,function*(){const s=this._dirtCount;if(this.vacuumConditionsMet(t)){const n=e.batchSize||Je.batchSize,r=e.batchWait||Je.batchWait;let i=1;for(const[o,l]of this._index){for(const[c,h]of l)for(const[m]of h)this._documentIds.has(m)||(h.size<=1?l.delete(c):h.delete(m));this._index.get(o).size===0&&this._index.delete(o),i%n===0&&(yield new Promise(c=>setTimeout(c,r))),i+=1}this._dirtCount-=s}yield null,this._currentVacuum=this._enqueuedVacuum,this._enqueuedVacuum=null})}vacuumConditionsMet(e){if(e==null)return!0;let{minDirtCount:t,minDirtFactor:s}=e;return t=t||Ve.minDirtCount,s=s||Ve.minDirtFactor,this.dirtCount>=t&&this.dirtFactor>=s}get isVacuuming(){return this._currentVacuum!=null}get dirtCount(){return this._dirtCount}get dirtFactor(){return this._dirtCount/(1+this._documentCount+this._dirtCount)}has(e){return this._idToShortId.has(e)}getStoredFields(e){const t=this._idToShortId.get(e);if(t!=null)return this._storedFields.get(t)}search(e,t={}){const{searchOptions:s}=this._options,n=Object.assign(Object.assign({},s),t),r=this.executeQuery(e,t),i=[];for(const[o,{score:l,terms:c,match:h}]of r){const m=c.length||1,f={id:this._documentIds.get(o),score:l*m,terms:Object.keys(h),queryTerms:c,match:h};Object.assign(f,this._storedFields.get(o)),(n.filter==null||n.filter(f))&&i.push(f)}return e===ue.wildcard&&n.boostDocument==null||i.sort(pt),i}autoSuggest(e,t={}){t=Object.assign(Object.assign({},this._options.autoSuggestOptions),t);const s=new Map;for(const{score:r,terms:i}of this.search(e,t)){const o=i.join(" "),l=s.get(o);l!=null?(l.score+=r,l.count+=1):s.set(o,{score:r,terms:i,count:1})}const n=[];for(const[r,{score:i,terms:o,count:l}]of s)n.push({suggestion:r,terms:o,score:i/l});return n.sort(pt),n}get documentCount(){return this._documentCount}get termCount(){return this._index.size}static loadJSON(e,t){if(t==null)throw new Error("MiniSearch: loadJSON should be given the same options used when serializing the index");return this.loadJS(JSON.parse(e),t)}static loadJSONAsync(e,t){return ke(this,void 0,void 0,function*(){if(t==null)throw new Error("MiniSearch: loadJSON should be given the same options used when serializing the index");return this.loadJSAsync(JSON.parse(e),t)})}static getDefault(e){if(je.hasOwnProperty(e))return Pe(je,e);throw new Error(`MiniSearch: unknown option "${e}"`)}static loadJS(e,t){const{index:s,documentIds:n,fieldLength:r,storedFields:i,serializationVersion:o}=e,l=this.instantiateMiniSearch(e,t);l._documentIds=Te(n),l._fieldLength=Te(r),l._storedFields=Te(i);for(const[c,h]of l._documentIds)l._idToShortId.set(h,c);for(const[c,h]of s){const m=new Map;for(const f of Object.keys(h)){let b=h[f];o===1&&(b=b.ds),m.set(parseInt(f,10),Te(b))}l._index.set(c,m)}return l}static loadJSAsync(e,t){return ke(this,void 0,void 0,function*(){const{index:s,documentIds:n,fieldLength:r,storedFields:i,serializationVersion:o}=e,l=this.instantiateMiniSearch(e,t);l._documentIds=yield Ie(n),l._fieldLength=yield Ie(r),l._storedFields=yield Ie(i);for(const[h,m]of l._documentIds)l._idToShortId.set(m,h);let c=0;for(const[h,m]of s){const f=new Map;for(const b of Object.keys(m)){let y=m[b];o===1&&(y=y.ds),f.set(parseInt(b,10),yield Ie(y))}++c%1e3===0&&(yield Nt(0)),l._index.set(h,f)}return l})}static instantiateMiniSearch(e,t){const{documentCount:s,nextId:n,fieldIds:r,averageFieldLength:i,dirtCount:o,serializationVersion:l}=e;if(l!==1&&l!==2)throw new Error("MiniSearch: cannot deserialize an index created with an incompatible version");const c=new ue(t);return c._documentCount=s,c._nextId=n,c._idToShortId=new Map,c._fieldIds=r,c._avgFieldLength=i,c._dirtCount=o||0,c._index=new X,c}executeQuery(e,t={}){if(e===ue.wildcard)return this.executeWildcardQuery(t);if(typeof e!="string"){const f=Object.assign(Object.assign(Object.assign({},t),e),{queries:void 0}),b=e.queries.map(y=>this.executeQuery(y,f));return this.combineResults(b,f.combineWith)}const{tokenize:s,processTerm:n,searchOptions:r}=this._options,i=Object.assign(Object.assign({tokenize:s,processTerm:n},r),t),{tokenize:o,processTerm:l}=i,m=o(e).flatMap(f=>l(f)).filter(f=>!!f).map(Us(i)).map(f=>this.executeQuerySpec(f,i));return this.combineResults(m,i.combineWith)}executeQuerySpec(e,t){const s=Object.assign(Object.assign({},this._options.searchOptions),t),n=(s.fields||this._options.fields).reduce((x,w)=>Object.assign(Object.assign({},x),{[w]:Pe(s.boost,w)||1}),{}),{boostDocument:r,weights:i,maxFuzzy:o,bm25:l}=s,{fuzzy:c,prefix:h}=Object.assign(Object.assign({},ht.weights),i),m=this._index.get(e.term),f=this.termResults(e.term,e.term,1,e.termBoost,m,n,r,l);let b,y;if(e.prefix&&(b=this._index.atPrefix(e.term)),e.fuzzy){const x=e.fuzzy===!0?.2:e.fuzzy,w=x<1?Math.min(o,Math.round(e.term.length*x)):x;w&&(y=this._index.fuzzyGet(e.term,w))}if(b)for(const[x,w]of b){const R=x.length-e.term.length;if(!R)continue;y==null||y.delete(x);const A=h*x.length/(x.length+.3*R);this.termResults(e.term,x,A,e.termBoost,w,n,r,l,f)}if(y)for(const x of y.keys()){const[w,R]=y.get(x);if(!R)continue;const A=c*x.length/(x.length+R);this.termResults(e.term,x,A,e.termBoost,w,n,r,l,f)}return f}executeWildcardQuery(e){const t=new Map,s=Object.assign(Object.assign({},this._options.searchOptions),e);for(const[n,r]of this._documentIds){const i=s.boostDocument?s.boostDocument(r,"",this._storedFields.get(n)):1;t.set(n,{score:i,terms:[],match:{}})}return t}combineResults(e,t=Ge){if(e.length===0)return new Map;const s=t.toLowerCase(),n=Ws[s];if(!n)throw new Error(`Invalid combination operator: ${t}`);return e.reduce(n)||new Map}toJSON(){const e=[];for(const[t,s]of this._index){const n={};for(const[r,i]of s)n[r]=Object.fromEntries(i);e.push([t,n])}return{documentCount:this._documentCount,nextId:this._nextId,documentIds:Object.fromEntries(this._documentIds),fieldIds:this._fieldIds,fieldLength:Object.fromEntries(this._fieldLength),averageFieldLength:this._avgFieldLength,storedFields:Object.fromEntries(this._storedFields),dirtCount:this._dirtCount,index:e,serializationVersion:2}}termResults(e,t,s,n,r,i,o,l,c=new Map){if(r==null)return c;for(const h of Object.keys(i)){const m=i[h],f=this._fieldIds[h],b=r.get(f);if(b==null)continue;let y=b.size;const x=this._avgFieldLength[f];for(const w of b.keys()){if(!this._documentIds.has(w)){this.removeTerm(f,w,t),y-=1;continue}const R=o?o(this._documentIds.get(w),t,this._storedFields.get(w)):1;if(!R)continue;const A=b.get(w),J=this._fieldLength.get(w)[f],Q=Js(A,y,this._documentCount,J,x,l),W=s*n*m*R*Q,V=c.get(w);if(V){V.score+=W,Gs(V.terms,e);const $=Pe(V.match,t);$?$.push(h):V.match[t]=[h]}else c.set(w,{score:W,terms:[e],match:{[t]:[h]}})}}return c}addTerm(e,t,s){const n=this._index.fetch(s,vt);let r=n.get(e);if(r==null)r=new Map,r.set(t,1),n.set(e,r);else{const i=r.get(t);r.set(t,(i||0)+1)}}removeTerm(e,t,s){if(!this._index.has(s)){this.warnDocumentChanged(t,e,s);return}const n=this._index.fetch(s,vt),r=n.get(e);r==null||r.get(t)==null?this.warnDocumentChanged(t,e,s):r.get(t)<=1?r.size<=1?n.delete(e):r.delete(t):r.set(t,r.get(t)-1),this._index.get(s).size===0&&this._index.delete(s)}warnDocumentChanged(e,t,s){for(const n of Object.keys(this._fieldIds))if(this._fieldIds[n]===t){this._options.logger("warn",`MiniSearch: document with ID ${this._documentIds.get(e)} has changed before removal: term "${s}" was not present in field "${n}". Removing a document after it has changed can corrupt the index!`,"version_conflict");return}}addDocumentId(e){const t=this._nextId;return this._idToShortId.set(e,t),this._documentIds.set(t,e),this._documentCount+=1,this._nextId+=1,t}addFields(e){for(let t=0;tObject.prototype.hasOwnProperty.call(a,e)?a[e]:void 0,Ws={[Ge]:(a,e)=>{for(const t of e.keys()){const s=a.get(t);if(s==null)a.set(t,e.get(t));else{const{score:n,terms:r,match:i}=e.get(t);s.score=s.score+n,s.match=Object.assign(s.match,i),ft(s.terms,r)}}return a},[kt]:(a,e)=>{const t=new Map;for(const s of e.keys()){const n=a.get(s);if(n==null)continue;const{score:r,terms:i,match:o}=e.get(s);ft(n.terms,i),t.set(s,{score:n.score+r,terms:n.terms,match:Object.assign(n.match,o)})}return t},[Bs]:(a,e)=>{for(const t of e.keys())a.delete(t);return a}},Ks={k:1.2,b:.7,d:.5},Js=(a,e,t,s,n,r)=>{const{k:i,b:o,d:l}=r;return Math.log(1+(t-e+.5)/(e+.5))*(l+a*(i+1)/(a+i*(1-o+o*s/n)))},Us=a=>(e,t,s)=>{const n=typeof a.fuzzy=="function"?a.fuzzy(e,t,s):a.fuzzy||!1,r=typeof a.prefix=="function"?a.prefix(e,t,s):a.prefix===!0,i=typeof a.boostTerm=="function"?a.boostTerm(e,t,s):1;return{term:e,fuzzy:n,prefix:r,termBoost:i}},je={idField:"id",extractField:(a,e)=>a[e],tokenize:a=>a.split(Hs),processTerm:a=>a.toLowerCase(),fields:void 0,searchOptions:void 0,storeFields:[],logger:(a,e)=>{typeof(console==null?void 0:console[a])=="function"&&console[a](e)},autoVacuum:!0},ht={combineWith:Ge,prefix:!1,fuzzy:!1,maxFuzzy:6,boost:{},weights:{fuzzy:.45,prefix:.375},bm25:Ks},qs={combineWith:kt,prefix:(a,e,t)=>e===t.length-1},Je={batchSize:1e3,batchWait:10},Ue={minDirtFactor:.1,minDirtCount:20},Ve=Object.assign(Object.assign({},Je),Ue),Gs=(a,e)=>{a.includes(e)||a.push(e)},ft=(a,e)=>{for(const t of e)a.includes(t)||a.push(t)},pt=({score:a},{score:e})=>e-a,vt=()=>new Map,Te=a=>{const e=new Map;for(const t of Object.keys(a))e.set(parseInt(t,10),a[t]);return e},Ie=a=>ke(void 0,void 0,void 0,function*(){const e=new Map;let t=0;for(const s of Object.keys(a))e.set(parseInt(s,10),a[s]),++t%1e3===0&&(yield Nt(0));return e}),Nt=a=>new Promise(e=>setTimeout(e,a)),Hs=/[\n\r\p{Z}\p{P}]+/u;class Qs{constructor(e=10){Ae(this,"max");Ae(this,"cache");this.max=e,this.cache=new Map}get(e){let t=this.cache.get(e);return t!==void 0&&(this.cache.delete(e),this.cache.set(e,t)),t}set(e,t){this.cache.has(e)?this.cache.delete(e):this.cache.size===this.max&&this.cache.delete(this.first()),this.cache.set(e,t)}first(){return this.cache.keys().next().value}clear(){this.cache.clear()}}const Ys=["aria-owns"],Zs={class:"shell"},Xs=["title"],en={class:"search-actions before"},tn=["title"],sn=["aria-activedescendant","aria-controls","placeholder"],nn={class:"search-actions"},rn=["title"],an=["disabled","title"],on=["id","role","aria-labelledby"],ln=["id","aria-selected"],cn=["href","aria-label","onMouseenter","onFocusin","data-index"],un={class:"titles"},dn=["innerHTML"],hn={class:"title main"},fn=["innerHTML"],pn={key:0,class:"excerpt-wrapper"},vn={key:0,class:"excerpt",inert:""},mn=["innerHTML"],gn={key:0,class:"no-results"},bn={class:"search-keyboard-shortcuts"},yn=["aria-label"],wn=["aria-label"],xn=["aria-label"],_n=["aria-label"],Sn=Lt({__name:"VPLocalSearchBox",emits:["close"],setup(a,{emit:e}){var S,C;const t=e,s=xe(),n=xe(),r=xe(is),i=ss(),{activate:o}=Ds(s,{immediate:!0,allowOutsideClick:!0,clickOutsideDeactivates:!0,escapeDeactivates:!0}),{localeIndex:l,theme:c}=i,h=st(async()=>{var v,p,E,F,z,P,j,I,K;return at(ue.loadJSON((E=await((p=(v=r.value)[l.value])==null?void 0:p.call(v)))==null?void 0:E.default,{fields:["title","titles","text"],storeFields:["title","titles"],searchOptions:{fuzzy:.2,prefix:!0,boost:{title:4,text:2,titles:1},...((F=c.value.search)==null?void 0:F.provider)==="local"&&((P=(z=c.value.search.options)==null?void 0:z.miniSearch)==null?void 0:P.searchOptions)},...((j=c.value.search)==null?void 0:j.provider)==="local"&&((K=(I=c.value.search.options)==null?void 0:I.miniSearch)==null?void 0:K.options)}))}),f=me(()=>{var v,p;return((v=c.value.search)==null?void 0:v.provider)==="local"&&((p=c.value.search.options)==null?void 0:p.disableQueryPersistence)===!0}).value?ie(""):Dt("vitepress:local-search-filter",""),b=zt("vitepress:local-search-detailed-list",((S=c.value.search)==null?void 0:S.provider)==="local"&&((C=c.value.search.options)==null?void 0:C.detailedView)===!0),y=me(()=>{var v,p,E;return((v=c.value.search)==null?void 0:v.provider)==="local"&&(((p=c.value.search.options)==null?void 0:p.disableDetailedView)===!0||((E=c.value.search.options)==null?void 0:E.detailedView)===!1)}),x=me(()=>{var p,E,F,z,P,j,I;const v=((p=c.value.search)==null?void 0:p.options)??c.value.algolia;return((P=(z=(F=(E=v==null?void 0:v.locales)==null?void 0:E[l.value])==null?void 0:F.translations)==null?void 0:z.button)==null?void 0:P.buttonText)||((I=(j=v==null?void 0:v.translations)==null?void 0:j.button)==null?void 0:I.buttonText)||"Search"});Pt(()=>{y.value&&(b.value=!1)});const w=xe([]),R=ie(!1);$e(f,()=>{R.value=!1});const A=st(async()=>{if(n.value)return at(new Ps(n.value))},null),J=new Qs(16);jt(()=>[h.value,f.value,b.value],async([v,p,E],F,z)=>{var ee,ye,He,Qe;(F==null?void 0:F[0])!==v&&J.clear();let P=!1;if(z(()=>{P=!0}),!v)return;w.value=v.search(p).slice(0,16),R.value=!0;const j=E?await Promise.all(w.value.map(B=>Q(B.id))):[];if(P)return;for(const{id:B,mod:te}of j){const se=B.slice(0,B.indexOf("#"));let Y=J.get(se);if(Y)continue;Y=new Map,J.set(se,Y);const G=te.default??te;if(G!=null&&G.render||G!=null&&G.setup){const ne=Yt(G);ne.config.warnHandler=()=>{},ne.provide(Zt,i),Object.defineProperties(ne.config.globalProperties,{$frontmatter:{get(){return i.frontmatter.value}},$params:{get(){return i.page.value.params}}});const Ye=document.createElement("div");ne.mount(Ye),Ye.querySelectorAll("h1, h2, h3, h4, h5, h6").forEach(de=>{var et;const we=(et=de.querySelector("a"))==null?void 0:et.getAttribute("href"),Ze=(we==null?void 0:we.startsWith("#"))&&we.slice(1);if(!Ze)return;let Xe="";for(;(de=de.nextElementSibling)&&!/^h[1-6]$/i.test(de.tagName);)Xe+=de.outerHTML;Y.set(Ze,Xe)}),ne.unmount()}if(P)return}const I=new Set;if(w.value=w.value.map(B=>{const[te,se]=B.id.split("#"),Y=J.get(te),G=(Y==null?void 0:Y.get(se))??"";for(const ne in B.match)I.add(ne);return{...B,text:G}}),await he(),P)return;await new Promise(B=>{var te;(te=A.value)==null||te.unmark({done:()=>{var se;(se=A.value)==null||se.markRegExp(k(I),{done:B})}})});const K=((ee=s.value)==null?void 0:ee.querySelectorAll(".result .excerpt"))??[];for(const B of K)(ye=B.querySelector('mark[data-markjs="true"]'))==null||ye.scrollIntoView({block:"center"});(Qe=(He=n.value)==null?void 0:He.firstElementChild)==null||Qe.scrollIntoView({block:"start"})},{debounce:200,immediate:!0});async function Q(v){const p=Xt(v.slice(0,v.indexOf("#")));try{if(!p)throw new Error(`Cannot find file for id: ${v}`);return{id:v,mod:await import(p)}}catch(E){return console.error(E),{id:v,mod:{}}}}const W=ie(),V=me(()=>{var v;return((v=f.value)==null?void 0:v.length)<=0});function $(v=!0){var p,E;(p=W.value)==null||p.focus(),v&&((E=W.value)==null||E.select())}Me(()=>{$()});function be(v){v.pointerType==="mouse"&&$()}const M=ie(-1),U=ie(!0);$e(w,v=>{M.value=v.length?0:-1,q()});function q(){he(()=>{const v=document.querySelector(".result.selected");v==null||v.scrollIntoView({block:"nearest"})})}_e("ArrowUp",v=>{v.preventDefault(),M.value--,M.value<0&&(M.value=w.value.length-1),U.value=!0,q()}),_e("ArrowDown",v=>{v.preventDefault(),M.value++,M.value>=w.value.length&&(M.value=0),U.value=!0,q()});const N=Vt();_e("Enter",v=>{if(v.isComposing||v.target instanceof HTMLButtonElement&&v.target.type!=="submit")return;const p=w.value[M.value];if(v.target instanceof HTMLInputElement&&!p){v.preventDefault();return}p&&(N.go(p.id),t("close"))}),_e("Escape",()=>{t("close")});const d=ns({modal:{displayDetails:"Display detailed list",resetButtonTitle:"Reset search",backButtonTitle:"Close search",noResultsText:"No results for",footer:{selectText:"to select",selectKeyAriaLabel:"enter",navigateText:"to navigate",navigateUpKeyAriaLabel:"up arrow",navigateDownKeyAriaLabel:"down arrow",closeText:"to close",closeKeyAriaLabel:"escape"}}});Me(()=>{window.history.pushState(null,"",null)}),$t("popstate",v=>{v.preventDefault(),t("close")});const g=Bt(Wt?document.body:null);Me(()=>{he(()=>{g.value=!0,he().then(()=>o())})}),Kt(()=>{g.value=!1});function T(){f.value="",he().then(()=>$(!1))}function k(v){return new RegExp([...v].sort((p,E)=>E.length-p.length).map(p=>`(${es(p)})`).join("|"),"gi")}function O(v){var F;if(!U.value)return;const p=(F=v.target)==null?void 0:F.closest(".result"),E=Number.parseInt(p==null?void 0:p.dataset.index);E>=0&&E!==M.value&&(M.value=E),U.value=!1}return(v,p)=>{var E,F,z,P,j;return H(),Jt(Qt,{to:"body"},[_("div",{ref_key:"el",ref:s,role:"button","aria-owns":(E=w.value)!=null&&E.length?"localsearch-list":void 0,"aria-expanded":"true","aria-haspopup":"listbox","aria-labelledby":"localsearch-label",class:"VPLocalSearchBox"},[_("div",{class:"backdrop",onClick:p[0]||(p[0]=I=>v.$emit("close"))}),_("div",Zs,[_("form",{class:"search-bar",onPointerup:p[4]||(p[4]=I=>be(I)),onSubmit:p[5]||(p[5]=Ut(()=>{},["prevent"]))},[_("label",{title:x.value,id:"localsearch-label",for:"localsearch-input"},p[7]||(p[7]=[_("span",{"aria-hidden":"true",class:"vpi-search search-icon local-search-icon"},null,-1)]),8,Xs),_("div",en,[_("button",{class:"back-button",title:L(d)("modal.backButtonTitle"),onClick:p[1]||(p[1]=I=>v.$emit("close"))},p[8]||(p[8]=[_("span",{class:"vpi-arrow-left local-search-icon"},null,-1)]),8,tn)]),qt(_("input",{ref_key:"searchInput",ref:W,"onUpdate:modelValue":p[2]||(p[2]=I=>Ht(f)?f.value=I:null),"aria-activedescendant":M.value>-1?"localsearch-item-"+M.value:void 0,"aria-autocomplete":"both","aria-controls":(F=w.value)!=null&&F.length?"localsearch-list":void 0,"aria-labelledby":"localsearch-label",autocapitalize:"off",autocomplete:"off",autocorrect:"off",class:"search-input",id:"localsearch-input",enterkeyhint:"go",maxlength:"64",placeholder:x.value,spellcheck:"false",type:"search"},null,8,sn),[[Gt,L(f)]]),_("div",nn,[y.value?Se("",!0):(H(),Z("button",{key:0,class:nt(["toggle-layout-button",{"detailed-list":L(b)}]),type:"button",title:L(d)("modal.displayDetails"),onClick:p[3]||(p[3]=I=>M.value>-1&&(b.value=!L(b)))},p[9]||(p[9]=[_("span",{class:"vpi-layout-list local-search-icon"},null,-1)]),10,rn)),_("button",{class:"clear-button",type:"reset",disabled:V.value,title:L(d)("modal.resetButtonTitle"),onClick:T},p[10]||(p[10]=[_("span",{class:"vpi-delete local-search-icon"},null,-1)]),8,an)])],32),_("ul",{ref_key:"resultsEl",ref:n,id:(z=w.value)!=null&&z.length?"localsearch-list":void 0,role:(P=w.value)!=null&&P.length?"listbox":void 0,"aria-labelledby":(j=w.value)!=null&&j.length?"localsearch-label":void 0,class:"results",onMousemove:O},[(H(!0),Z(rt,null,it(w.value,(I,K)=>(H(),Z("li",{key:I.id,id:"localsearch-item-"+K,"aria-selected":M.value===K?"true":"false",role:"option"},[_("a",{href:I.id,class:nt(["result",{selected:M.value===K}]),"aria-label":[...I.titles,I.title].join(" > "),onMouseenter:ee=>!U.value&&(M.value=K),onFocusin:ee=>M.value=K,onClick:p[6]||(p[6]=ee=>v.$emit("close")),"data-index":K},[_("div",null,[_("div",un,[p[12]||(p[12]=_("span",{class:"title-icon"},"#",-1)),(H(!0),Z(rt,null,it(I.titles,(ee,ye)=>(H(),Z("span",{key:ye,class:"title"},[_("span",{class:"text",innerHTML:ee},null,8,dn),p[11]||(p[11]=_("span",{class:"vpi-chevron-right local-search-icon"},null,-1))]))),128)),_("span",hn,[_("span",{class:"text",innerHTML:I.title},null,8,fn)])]),L(b)?(H(),Z("div",pn,[I.text?(H(),Z("div",vn,[_("div",{class:"vp-doc",innerHTML:I.text},null,8,mn)])):Se("",!0),p[13]||(p[13]=_("div",{class:"excerpt-gradient-bottom"},null,-1)),p[14]||(p[14]=_("div",{class:"excerpt-gradient-top"},null,-1))])):Se("",!0)])],42,cn)],8,ln))),128)),L(f)&&!w.value.length&&R.value?(H(),Z("li",gn,[fe(pe(L(d)("modal.noResultsText"))+' "',1),_("strong",null,pe(L(f)),1),p[15]||(p[15]=fe('" '))])):Se("",!0)],40,on),_("div",bn,[_("span",null,[_("kbd",{"aria-label":L(d)("modal.footer.navigateUpKeyAriaLabel")},p[16]||(p[16]=[_("span",{class:"vpi-arrow-up navigate-icon"},null,-1)]),8,yn),_("kbd",{"aria-label":L(d)("modal.footer.navigateDownKeyAriaLabel")},p[17]||(p[17]=[_("span",{class:"vpi-arrow-down navigate-icon"},null,-1)]),8,wn),fe(" "+pe(L(d)("modal.footer.navigateText")),1)]),_("span",null,[_("kbd",{"aria-label":L(d)("modal.footer.selectKeyAriaLabel")},p[18]||(p[18]=[_("span",{class:"vpi-corner-down-left navigate-icon"},null,-1)]),8,xn),fe(" "+pe(L(d)("modal.footer.selectText")),1)]),_("span",null,[_("kbd",{"aria-label":L(d)("modal.footer.closeKeyAriaLabel")},"esc",8,_n),fe(" "+pe(L(d)("modal.footer.closeText")),1)])])])],8,Ys)])}}}),Fn=ts(Sn,[["__scopeId","data-v-2eb8502c"]]);export{Fn as default}; diff --git a/assets/chunks/framework.CoXjB5sU.js b/assets/chunks/framework.CoXjB5sU.js new file mode 100644 index 0000000..19beab3 --- /dev/null +++ b/assets/chunks/framework.CoXjB5sU.js @@ -0,0 +1,18 @@ +/** +* @vue/shared v3.5.13 +* (c) 2018-present Yuxi (Evan) You and Vue contributors +* @license MIT +**//*! #__NO_SIDE_EFFECTS__ */function Ns(e){const t=Object.create(null);for(const n of e.split(","))t[n]=1;return n=>n in t}const Z={},Et=[],ke=()=>{},Ko=()=>!1,en=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),Fs=e=>e.startsWith("onUpdate:"),ae=Object.assign,Hs=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},qo=Object.prototype.hasOwnProperty,z=(e,t)=>qo.call(e,t),W=Array.isArray,Tt=e=>In(e)==="[object Map]",ii=e=>In(e)==="[object Set]",q=e=>typeof e=="function",re=e=>typeof e=="string",Xe=e=>typeof e=="symbol",ne=e=>e!==null&&typeof e=="object",oi=e=>(ne(e)||q(e))&&q(e.then)&&q(e.catch),li=Object.prototype.toString,In=e=>li.call(e),Go=e=>In(e).slice(8,-1),ci=e=>In(e)==="[object Object]",$s=e=>re(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,Ct=Ns(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),Nn=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},Yo=/-(\w)/g,Le=Nn(e=>e.replace(Yo,(t,n)=>n?n.toUpperCase():"")),Xo=/\B([A-Z])/g,st=Nn(e=>e.replace(Xo,"-$1").toLowerCase()),Fn=Nn(e=>e.charAt(0).toUpperCase()+e.slice(1)),_n=Nn(e=>e?`on${Fn(e)}`:""),tt=(e,t)=>!Object.is(e,t),bn=(e,...t)=>{for(let n=0;n{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:s,value:n})},vs=e=>{const t=parseFloat(e);return isNaN(t)?e:t},Jo=e=>{const t=re(e)?Number(e):NaN;return isNaN(t)?e:t};let ar;const Hn=()=>ar||(ar=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Ds(e){if(W(e)){const t={};for(let n=0;n{if(n){const s=n.split(Qo);s.length>1&&(t[s[0].trim()]=s[1].trim())}}),t}function js(e){let t="";if(re(e))t=e;else if(W(e))for(let n=0;n!!(e&&e.__v_isRef===!0),sl=e=>re(e)?e:e==null?"":W(e)||ne(e)&&(e.toString===li||!q(e.toString))?ui(e)?sl(e.value):JSON.stringify(e,di,2):String(e),di=(e,t)=>ui(t)?di(e,t.value):Tt(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[s,r],i)=>(n[zn(s,i)+" =>"]=r,n),{})}:ii(t)?{[`Set(${t.size})`]:[...t.values()].map(n=>zn(n))}:Xe(t)?zn(t):ne(t)&&!W(t)&&!ci(t)?String(t):t,zn=(e,t="")=>{var n;return Xe(e)?`Symbol(${(n=e.description)!=null?n:t})`:e};/** +* @vue/reactivity v3.5.13 +* (c) 2018-present Yuxi (Evan) You and Vue contributors +* @license MIT +**/let we;class rl{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=we,!t&&we&&(this.index=(we.scopes||(we.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,n;if(this.scopes)for(t=0,n=this.scopes.length;t0)return;if(jt){let t=jt;for(jt=void 0;t;){const n=t.next;t.next=void 0,t.flags&=-9,t=n}}let e;for(;Dt;){let t=Dt;for(Dt=void 0;t;){const n=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(s){e||(e=s)}t=n}}if(e)throw e}function yi(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function vi(e){let t,n=e.depsTail,s=n;for(;s;){const r=s.prevDep;s.version===-1?(s===n&&(n=r),ks(s),ol(s)):t=s,s.dep.activeLink=s.prevActiveLink,s.prevActiveLink=void 0,s=r}e.deps=t,e.depsTail=n}function _s(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(_i(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function _i(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Kt))return;e.globalVersion=Kt;const t=e.dep;if(e.flags|=2,t.version>0&&!e.isSSR&&e.deps&&!_s(e)){e.flags&=-3;return}const n=te,s=Ne;te=e,Ne=!0;try{yi(e);const r=e.fn(e._value);(t.version===0||tt(r,e._value))&&(e._value=r,t.version++)}catch(r){throw t.version++,r}finally{te=n,Ne=s,vi(e),e.flags&=-3}}function ks(e,t=!1){const{dep:n,prevSub:s,nextSub:r}=e;if(s&&(s.nextSub=r,e.prevSub=void 0),r&&(r.prevSub=s,e.nextSub=void 0),n.subs===e&&(n.subs=s,!s&&n.computed)){n.computed.flags&=-5;for(let i=n.computed.deps;i;i=i.nextDep)ks(i,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function ol(e){const{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}let Ne=!0;const bi=[];function rt(){bi.push(Ne),Ne=!1}function it(){const e=bi.pop();Ne=e===void 0?!0:e}function fr(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const n=te;te=void 0;try{t()}finally{te=n}}}let Kt=0;class ll{constructor(t,n){this.sub=t,this.dep=n,this.version=n.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class $n{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0}track(t){if(!te||!Ne||te===this.computed)return;let n=this.activeLink;if(n===void 0||n.sub!==te)n=this.activeLink=new ll(te,this),te.deps?(n.prevDep=te.depsTail,te.depsTail.nextDep=n,te.depsTail=n):te.deps=te.depsTail=n,wi(n);else if(n.version===-1&&(n.version=this.version,n.nextDep)){const s=n.nextDep;s.prevDep=n.prevDep,n.prevDep&&(n.prevDep.nextDep=s),n.prevDep=te.depsTail,n.nextDep=void 0,te.depsTail.nextDep=n,te.depsTail=n,te.deps===n&&(te.deps=s)}return n}trigger(t){this.version++,Kt++,this.notify(t)}notify(t){Vs();try{for(let n=this.subs;n;n=n.prevSub)n.sub.notify()&&n.sub.dep.notify()}finally{Us()}}}function wi(e){if(e.dep.sc++,e.sub.flags&4){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let s=t.deps;s;s=s.nextDep)wi(s)}const n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}const Cn=new WeakMap,dt=Symbol(""),bs=Symbol(""),qt=Symbol("");function me(e,t,n){if(Ne&&te){let s=Cn.get(e);s||Cn.set(e,s=new Map);let r=s.get(n);r||(s.set(n,r=new $n),r.map=s,r.key=n),r.track()}}function Ge(e,t,n,s,r,i){const o=Cn.get(e);if(!o){Kt++;return}const l=c=>{c&&c.trigger()};if(Vs(),t==="clear")o.forEach(l);else{const c=W(e),f=c&&$s(n);if(c&&n==="length"){const a=Number(s);o.forEach((h,y)=>{(y==="length"||y===qt||!Xe(y)&&y>=a)&&l(h)})}else switch((n!==void 0||o.has(void 0))&&l(o.get(n)),f&&l(o.get(qt)),t){case"add":c?f&&l(o.get("length")):(l(o.get(dt)),Tt(e)&&l(o.get(bs)));break;case"delete":c||(l(o.get(dt)),Tt(e)&&l(o.get(bs)));break;case"set":Tt(e)&&l(o.get(dt));break}}Us()}function cl(e,t){const n=Cn.get(e);return n&&n.get(t)}function _t(e){const t=J(e);return t===e?t:(me(t,"iterate",qt),Pe(e)?t:t.map(ye))}function Dn(e){return me(e=J(e),"iterate",qt),e}const al={__proto__:null,[Symbol.iterator](){return Zn(this,Symbol.iterator,ye)},concat(...e){return _t(this).concat(...e.map(t=>W(t)?_t(t):t))},entries(){return Zn(this,"entries",e=>(e[1]=ye(e[1]),e))},every(e,t){return We(this,"every",e,t,void 0,arguments)},filter(e,t){return We(this,"filter",e,t,n=>n.map(ye),arguments)},find(e,t){return We(this,"find",e,t,ye,arguments)},findIndex(e,t){return We(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return We(this,"findLast",e,t,ye,arguments)},findLastIndex(e,t){return We(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return We(this,"forEach",e,t,void 0,arguments)},includes(...e){return es(this,"includes",e)},indexOf(...e){return es(this,"indexOf",e)},join(e){return _t(this).join(e)},lastIndexOf(...e){return es(this,"lastIndexOf",e)},map(e,t){return We(this,"map",e,t,void 0,arguments)},pop(){return Ft(this,"pop")},push(...e){return Ft(this,"push",e)},reduce(e,...t){return ur(this,"reduce",e,t)},reduceRight(e,...t){return ur(this,"reduceRight",e,t)},shift(){return Ft(this,"shift")},some(e,t){return We(this,"some",e,t,void 0,arguments)},splice(...e){return Ft(this,"splice",e)},toReversed(){return _t(this).toReversed()},toSorted(e){return _t(this).toSorted(e)},toSpliced(...e){return _t(this).toSpliced(...e)},unshift(...e){return Ft(this,"unshift",e)},values(){return Zn(this,"values",ye)}};function Zn(e,t,n){const s=Dn(e),r=s[t]();return s!==e&&!Pe(e)&&(r._next=r.next,r.next=()=>{const i=r._next();return i.value&&(i.value=n(i.value)),i}),r}const fl=Array.prototype;function We(e,t,n,s,r,i){const o=Dn(e),l=o!==e&&!Pe(e),c=o[t];if(c!==fl[t]){const h=c.apply(e,i);return l?ye(h):h}let f=n;o!==e&&(l?f=function(h,y){return n.call(this,ye(h),y,e)}:n.length>2&&(f=function(h,y){return n.call(this,h,y,e)}));const a=c.call(o,f,s);return l&&r?r(a):a}function ur(e,t,n,s){const r=Dn(e);let i=n;return r!==e&&(Pe(e)?n.length>3&&(i=function(o,l,c){return n.call(this,o,l,c,e)}):i=function(o,l,c){return n.call(this,o,ye(l),c,e)}),r[t](i,...s)}function es(e,t,n){const s=J(e);me(s,"iterate",qt);const r=s[t](...n);return(r===-1||r===!1)&&Ks(n[0])?(n[0]=J(n[0]),s[t](...n)):r}function Ft(e,t,n=[]){rt(),Vs();const s=J(e)[t].apply(e,n);return Us(),it(),s}const ul=Ns("__proto__,__v_isRef,__isVue"),Si=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Xe));function dl(e){Xe(e)||(e=String(e));const t=J(this);return me(t,"has",e),t.hasOwnProperty(e)}class xi{constructor(t=!1,n=!1){this._isReadonly=t,this._isShallow=n}get(t,n,s){if(n==="__v_skip")return t.__v_skip;const r=this._isReadonly,i=this._isShallow;if(n==="__v_isReactive")return!r;if(n==="__v_isReadonly")return r;if(n==="__v_isShallow")return i;if(n==="__v_raw")return s===(r?i?Sl:Ai:i?Ci:Ti).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(s)?t:void 0;const o=W(t);if(!r){let c;if(o&&(c=al[n]))return c;if(n==="hasOwnProperty")return dl}const l=Reflect.get(t,n,fe(t)?t:s);return(Xe(n)?Si.has(n):ul(n))||(r||me(t,"get",n),i)?l:fe(l)?o&&$s(n)?l:l.value:ne(l)?r?Vn(l):jn(l):l}}class Ei extends xi{constructor(t=!1){super(!1,t)}set(t,n,s,r){let i=t[n];if(!this._isShallow){const c=yt(i);if(!Pe(s)&&!yt(s)&&(i=J(i),s=J(s)),!W(t)&&fe(i)&&!fe(s))return c?!1:(i.value=s,!0)}const o=W(t)&&$s(n)?Number(n)e,cn=e=>Reflect.getPrototypeOf(e);function yl(e,t,n){return function(...s){const r=this.__v_raw,i=J(r),o=Tt(i),l=e==="entries"||e===Symbol.iterator&&o,c=e==="keys"&&o,f=r[e](...s),a=n?ws:t?Ss:ye;return!t&&me(i,"iterate",c?bs:dt),{next(){const{value:h,done:y}=f.next();return y?{value:h,done:y}:{value:l?[a(h[0]),a(h[1])]:a(h),done:y}},[Symbol.iterator](){return this}}}}function an(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function vl(e,t){const n={get(r){const i=this.__v_raw,o=J(i),l=J(r);e||(tt(r,l)&&me(o,"get",r),me(o,"get",l));const{has:c}=cn(o),f=t?ws:e?Ss:ye;if(c.call(o,r))return f(i.get(r));if(c.call(o,l))return f(i.get(l));i!==o&&i.get(r)},get size(){const r=this.__v_raw;return!e&&me(J(r),"iterate",dt),Reflect.get(r,"size",r)},has(r){const i=this.__v_raw,o=J(i),l=J(r);return e||(tt(r,l)&&me(o,"has",r),me(o,"has",l)),r===l?i.has(r):i.has(r)||i.has(l)},forEach(r,i){const o=this,l=o.__v_raw,c=J(l),f=t?ws:e?Ss:ye;return!e&&me(c,"iterate",dt),l.forEach((a,h)=>r.call(i,f(a),f(h),o))}};return ae(n,e?{add:an("add"),set:an("set"),delete:an("delete"),clear:an("clear")}:{add(r){!t&&!Pe(r)&&!yt(r)&&(r=J(r));const i=J(this);return cn(i).has.call(i,r)||(i.add(r),Ge(i,"add",r,r)),this},set(r,i){!t&&!Pe(i)&&!yt(i)&&(i=J(i));const o=J(this),{has:l,get:c}=cn(o);let f=l.call(o,r);f||(r=J(r),f=l.call(o,r));const a=c.call(o,r);return o.set(r,i),f?tt(i,a)&&Ge(o,"set",r,i):Ge(o,"add",r,i),this},delete(r){const i=J(this),{has:o,get:l}=cn(i);let c=o.call(i,r);c||(r=J(r),c=o.call(i,r)),l&&l.call(i,r);const f=i.delete(r);return c&&Ge(i,"delete",r,void 0),f},clear(){const r=J(this),i=r.size!==0,o=r.clear();return i&&Ge(r,"clear",void 0,void 0),o}}),["keys","values","entries",Symbol.iterator].forEach(r=>{n[r]=yl(r,e,t)}),n}function Bs(e,t){const n=vl(e,t);return(s,r,i)=>r==="__v_isReactive"?!e:r==="__v_isReadonly"?e:r==="__v_raw"?s:Reflect.get(z(n,r)&&r in s?n:s,r,i)}const _l={get:Bs(!1,!1)},bl={get:Bs(!1,!0)},wl={get:Bs(!0,!1)};const Ti=new WeakMap,Ci=new WeakMap,Ai=new WeakMap,Sl=new WeakMap;function xl(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function El(e){return e.__v_skip||!Object.isExtensible(e)?0:xl(Go(e))}function jn(e){return yt(e)?e:Ws(e,!1,pl,_l,Ti)}function Tl(e){return Ws(e,!1,ml,bl,Ci)}function Vn(e){return Ws(e,!0,gl,wl,Ai)}function Ws(e,t,n,s,r){if(!ne(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const i=r.get(e);if(i)return i;const o=El(e);if(o===0)return e;const l=new Proxy(e,o===2?s:n);return r.set(e,l),l}function ht(e){return yt(e)?ht(e.__v_raw):!!(e&&e.__v_isReactive)}function yt(e){return!!(e&&e.__v_isReadonly)}function Pe(e){return!!(e&&e.__v_isShallow)}function Ks(e){return e?!!e.__v_raw:!1}function J(e){const t=e&&e.__v_raw;return t?J(t):e}function wn(e){return!z(e,"__v_skip")&&Object.isExtensible(e)&&ai(e,"__v_skip",!0),e}const ye=e=>ne(e)?jn(e):e,Ss=e=>ne(e)?Vn(e):e;function fe(e){return e?e.__v_isRef===!0:!1}function oe(e){return Ri(e,!1)}function qs(e){return Ri(e,!0)}function Ri(e,t){return fe(e)?e:new Cl(e,t)}class Cl{constructor(t,n){this.dep=new $n,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=n?t:J(t),this._value=n?t:ye(t),this.__v_isShallow=n}get value(){return this.dep.track(),this._value}set value(t){const n=this._rawValue,s=this.__v_isShallow||Pe(t)||yt(t);t=s?t:J(t),tt(t,n)&&(this._rawValue=t,this._value=s?t:ye(t),this.dep.trigger())}}function Oi(e){return fe(e)?e.value:e}const Al={get:(e,t,n)=>t==="__v_raw"?e:Oi(Reflect.get(e,t,n)),set:(e,t,n,s)=>{const r=e[t];return fe(r)&&!fe(n)?(r.value=n,!0):Reflect.set(e,t,n,s)}};function Mi(e){return ht(e)?e:new Proxy(e,Al)}class Rl{constructor(t){this.__v_isRef=!0,this._value=void 0;const n=this.dep=new $n,{get:s,set:r}=t(n.track.bind(n),n.trigger.bind(n));this._get=s,this._set=r}get value(){return this._value=this._get()}set value(t){this._set(t)}}function Ol(e){return new Rl(e)}class Ml{constructor(t,n,s){this._object=t,this._key=n,this._defaultValue=s,this.__v_isRef=!0,this._value=void 0}get value(){const t=this._object[this._key];return this._value=t===void 0?this._defaultValue:t}set value(t){this._object[this._key]=t}get dep(){return cl(J(this._object),this._key)}}class Pl{constructor(t){this._getter=t,this.__v_isRef=!0,this.__v_isReadonly=!0,this._value=void 0}get value(){return this._value=this._getter()}}function Ll(e,t,n){return fe(e)?e:q(e)?new Pl(e):ne(e)&&arguments.length>1?Il(e,t,n):oe(e)}function Il(e,t,n){const s=e[t];return fe(s)?s:new Ml(e,t,n)}class Nl{constructor(t,n,s){this.fn=t,this.setter=n,this._value=void 0,this.dep=new $n(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=Kt-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!n,this.isSSR=s}notify(){if(this.flags|=16,!(this.flags&8)&&te!==this)return mi(this,!0),!0}get value(){const t=this.dep.track();return _i(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function Fl(e,t,n=!1){let s,r;return q(e)?s=e:(s=e.get,r=e.set),new Nl(s,r,n)}const fn={},An=new WeakMap;let ft;function Hl(e,t=!1,n=ft){if(n){let s=An.get(n);s||An.set(n,s=[]),s.push(e)}}function $l(e,t,n=Z){const{immediate:s,deep:r,once:i,scheduler:o,augmentJob:l,call:c}=n,f=g=>r?g:Pe(g)||r===!1||r===0?Ye(g,1):Ye(g);let a,h,y,v,S=!1,_=!1;if(fe(e)?(h=()=>e.value,S=Pe(e)):ht(e)?(h=()=>f(e),S=!0):W(e)?(_=!0,S=e.some(g=>ht(g)||Pe(g)),h=()=>e.map(g=>{if(fe(g))return g.value;if(ht(g))return f(g);if(q(g))return c?c(g,2):g()})):q(e)?t?h=c?()=>c(e,2):e:h=()=>{if(y){rt();try{y()}finally{it()}}const g=ft;ft=a;try{return c?c(e,3,[v]):e(v)}finally{ft=g}}:h=ke,t&&r){const g=h,O=r===!0?1/0:r;h=()=>Ye(g(),O)}const K=hi(),N=()=>{a.stop(),K&&K.active&&Hs(K.effects,a)};if(i&&t){const g=t;t=(...O)=>{g(...O),N()}}let j=_?new Array(e.length).fill(fn):fn;const p=g=>{if(!(!(a.flags&1)||!a.dirty&&!g))if(t){const O=a.run();if(r||S||(_?O.some((F,$)=>tt(F,j[$])):tt(O,j))){y&&y();const F=ft;ft=a;try{const $=[O,j===fn?void 0:_&&j[0]===fn?[]:j,v];c?c(t,3,$):t(...$),j=O}finally{ft=F}}}else a.run()};return l&&l(p),a=new pi(h),a.scheduler=o?()=>o(p,!1):p,v=g=>Hl(g,!1,a),y=a.onStop=()=>{const g=An.get(a);if(g){if(c)c(g,4);else for(const O of g)O();An.delete(a)}},t?s?p(!0):j=a.run():o?o(p.bind(null,!0),!0):a.run(),N.pause=a.pause.bind(a),N.resume=a.resume.bind(a),N.stop=N,N}function Ye(e,t=1/0,n){if(t<=0||!ne(e)||e.__v_skip||(n=n||new Set,n.has(e)))return e;if(n.add(e),t--,fe(e))Ye(e.value,t,n);else if(W(e))for(let s=0;s{Ye(s,t,n)});else if(ci(e)){for(const s in e)Ye(e[s],t,n);for(const s of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,s)&&Ye(e[s],t,n)}return e}/** +* @vue/runtime-core v3.5.13 +* (c) 2018-present Yuxi (Evan) You and Vue contributors +* @license MIT +**/function tn(e,t,n,s){try{return s?e(...s):e()}catch(r){nn(r,t,n)}}function He(e,t,n,s){if(q(e)){const r=tn(e,t,n,s);return r&&oi(r)&&r.catch(i=>{nn(i,t,n)}),r}if(W(e)){const r=[];for(let i=0;i>>1,r=Se[s],i=Gt(r);i=Gt(n)?Se.push(e):Se.splice(jl(t),0,e),e.flags|=1,Li()}}function Li(){Rn||(Rn=Pi.then(Ii))}function Vl(e){W(e)?At.push(...e):Qe&&e.id===-1?Qe.splice(wt+1,0,e):e.flags&1||(At.push(e),e.flags|=1),Li()}function dr(e,t,n=Ve+1){for(;nGt(n)-Gt(s));if(At.length=0,Qe){Qe.push(...t);return}for(Qe=t,wt=0;wte.id==null?e.flags&2?-1:1/0:e.id;function Ii(e){try{for(Ve=0;Ve{s._d&&Ar(-1);const i=Mn(t);let o;try{o=e(...r)}finally{Mn(i),s._d&&Ar(1)}return o};return s._n=!0,s._c=!0,s._d=!0,s}function _f(e,t){if(de===null)return e;const n=Gn(de),s=e.dirs||(e.dirs=[]);for(let r=0;re.__isTeleport,Vt=e=>e&&(e.disabled||e.disabled===""),hr=e=>e&&(e.defer||e.defer===""),pr=e=>typeof SVGElement<"u"&&e instanceof SVGElement,gr=e=>typeof MathMLElement=="function"&&e instanceof MathMLElement,xs=(e,t)=>{const n=e&&e.to;return re(n)?t?t(n):null:n},$i={name:"Teleport",__isTeleport:!0,process(e,t,n,s,r,i,o,l,c,f){const{mc:a,pc:h,pbc:y,o:{insert:v,querySelector:S,createText:_,createComment:K}}=f,N=Vt(t.props);let{shapeFlag:j,children:p,dynamicChildren:g}=t;if(e==null){const O=t.el=_(""),F=t.anchor=_("");v(O,n,s),v(F,n,s);const $=(R,b)=>{j&16&&(r&&r.isCE&&(r.ce._teleportTarget=R),a(p,R,b,r,i,o,l,c))},V=()=>{const R=t.target=xs(t.props,S),b=Di(R,t,_,v);R&&(o!=="svg"&&pr(R)?o="svg":o!=="mathml"&&gr(R)&&(o="mathml"),N||($(R,b),Sn(t,!1)))};N&&($(n,F),Sn(t,!0)),hr(t.props)?be(()=>{V(),t.el.__isMounted=!0},i):V()}else{if(hr(t.props)&&!e.el.__isMounted){be(()=>{$i.process(e,t,n,s,r,i,o,l,c,f),delete e.el.__isMounted},i);return}t.el=e.el,t.targetStart=e.targetStart;const O=t.anchor=e.anchor,F=t.target=e.target,$=t.targetAnchor=e.targetAnchor,V=Vt(e.props),R=V?n:F,b=V?O:$;if(o==="svg"||pr(F)?o="svg":(o==="mathml"||gr(F))&&(o="mathml"),g?(y(e.dynamicChildren,g,R,r,i,o,l),Qs(e,t,!0)):c||h(e,t,R,b,r,i,o,l,!1),N)V?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):un(t,n,O,f,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const I=t.target=xs(t.props,S);I&&un(t,I,null,f,0)}else V&&un(t,F,$,f,1);Sn(t,N)}},remove(e,t,n,{um:s,o:{remove:r}},i){const{shapeFlag:o,children:l,anchor:c,targetStart:f,targetAnchor:a,target:h,props:y}=e;if(h&&(r(f),r(a)),i&&r(c),o&16){const v=i||!Vt(y);for(let S=0;S{e.isMounted=!0}),Ki(()=>{e.isUnmounting=!0}),e}const Re=[Function,Array],ji={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:Re,onEnter:Re,onAfterEnter:Re,onEnterCancelled:Re,onBeforeLeave:Re,onLeave:Re,onAfterLeave:Re,onLeaveCancelled:Re,onBeforeAppear:Re,onAppear:Re,onAfterAppear:Re,onAppearCancelled:Re},Vi=e=>{const t=e.subTree;return t.component?Vi(t.component):t},Wl={name:"BaseTransition",props:ji,setup(e,{slots:t}){const n=qn(),s=Bl();return()=>{const r=t.default&&Bi(t.default(),!0);if(!r||!r.length)return;const i=Ui(r),o=J(e),{mode:l}=o;if(s.isLeaving)return ts(i);const c=mr(i);if(!c)return ts(i);let f=Es(c,o,s,n,h=>f=h);c.type!==ve&&Yt(c,f);let a=n.subTree&&mr(n.subTree);if(a&&a.type!==ve&&!ut(c,a)&&Vi(n).type!==ve){let h=Es(a,o,s,n);if(Yt(a,h),l==="out-in"&&c.type!==ve)return s.isLeaving=!0,h.afterLeave=()=>{s.isLeaving=!1,n.job.flags&8||n.update(),delete h.afterLeave,a=void 0},ts(i);l==="in-out"&&c.type!==ve?h.delayLeave=(y,v,S)=>{const _=ki(s,a);_[String(a.key)]=a,y[Ze]=()=>{v(),y[Ze]=void 0,delete f.delayedLeave,a=void 0},f.delayedLeave=()=>{S(),delete f.delayedLeave,a=void 0}}:a=void 0}else a&&(a=void 0);return i}}};function Ui(e){let t=e[0];if(e.length>1){for(const n of e)if(n.type!==ve){t=n;break}}return t}const Kl=Wl;function ki(e,t){const{leavingVNodes:n}=e;let s=n.get(t.type);return s||(s=Object.create(null),n.set(t.type,s)),s}function Es(e,t,n,s,r){const{appear:i,mode:o,persisted:l=!1,onBeforeEnter:c,onEnter:f,onAfterEnter:a,onEnterCancelled:h,onBeforeLeave:y,onLeave:v,onAfterLeave:S,onLeaveCancelled:_,onBeforeAppear:K,onAppear:N,onAfterAppear:j,onAppearCancelled:p}=t,g=String(e.key),O=ki(n,e),F=(R,b)=>{R&&He(R,s,9,b)},$=(R,b)=>{const I=b[1];F(R,b),W(R)?R.every(x=>x.length<=1)&&I():R.length<=1&&I()},V={mode:o,persisted:l,beforeEnter(R){let b=c;if(!n.isMounted)if(i)b=K||c;else return;R[Ze]&&R[Ze](!0);const I=O[g];I&&ut(e,I)&&I.el[Ze]&&I.el[Ze](),F(b,[R])},enter(R){let b=f,I=a,x=h;if(!n.isMounted)if(i)b=N||f,I=j||a,x=p||h;else return;let B=!1;const se=R[dn]=le=>{B||(B=!0,le?F(x,[R]):F(I,[R]),V.delayedLeave&&V.delayedLeave(),R[dn]=void 0)};b?$(b,[R,se]):se()},leave(R,b){const I=String(e.key);if(R[dn]&&R[dn](!0),n.isUnmounting)return b();F(y,[R]);let x=!1;const B=R[Ze]=se=>{x||(x=!0,b(),se?F(_,[R]):F(S,[R]),R[Ze]=void 0,O[I]===e&&delete O[I])};O[I]=e,v?$(v,[R,B]):B()},clone(R){const b=Es(R,t,n,s,r);return r&&r(b),b}};return V}function ts(e){if(sn(e))return e=nt(e),e.children=null,e}function mr(e){if(!sn(e))return Hi(e.type)&&e.children?Ui(e.children):e;const{shapeFlag:t,children:n}=e;if(n){if(t&16)return n[0];if(t&32&&q(n.default))return n.default()}}function Yt(e,t){e.shapeFlag&6&&e.component?(e.transition=t,Yt(e.component.subTree,t)):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function Bi(e,t=!1,n){let s=[],r=0;for(let i=0;i1)for(let i=0;iXt(S,t&&(W(t)?t[_]:t),n,s,r));return}if(pt(s)&&!r){s.shapeFlag&512&&s.type.__asyncResolved&&s.component.subTree.component&&Xt(e,t,n,s.component.subTree);return}const i=s.shapeFlag&4?Gn(s.component):s.el,o=r?null:i,{i:l,r:c}=e,f=t&&t.r,a=l.refs===Z?l.refs={}:l.refs,h=l.setupState,y=J(h),v=h===Z?()=>!1:S=>z(y,S);if(f!=null&&f!==c&&(re(f)?(a[f]=null,v(f)&&(h[f]=null)):fe(f)&&(f.value=null)),q(c))tn(c,l,12,[o,a]);else{const S=re(c),_=fe(c);if(S||_){const K=()=>{if(e.f){const N=S?v(c)?h[c]:a[c]:c.value;r?W(N)&&Hs(N,i):W(N)?N.includes(i)||N.push(i):S?(a[c]=[i],v(c)&&(h[c]=a[c])):(c.value=[i],e.k&&(a[e.k]=c.value))}else S?(a[c]=o,v(c)&&(h[c]=o)):_&&(c.value=o,e.k&&(a[e.k]=o))};o?(K.id=-1,be(K,n)):K()}}}let yr=!1;const bt=()=>{yr||(console.error("Hydration completed but contains mismatches."),yr=!0)},ql=e=>e.namespaceURI.includes("svg")&&e.tagName!=="foreignObject",Gl=e=>e.namespaceURI.includes("MathML"),hn=e=>{if(e.nodeType===1){if(ql(e))return"svg";if(Gl(e))return"mathml"}},xt=e=>e.nodeType===8;function Yl(e){const{mt:t,p:n,o:{patchProp:s,createText:r,nextSibling:i,parentNode:o,remove:l,insert:c,createComment:f}}=e,a=(p,g)=>{if(!g.hasChildNodes()){n(null,p,g),On(),g._vnode=p;return}h(g.firstChild,p,null,null,null),On(),g._vnode=p},h=(p,g,O,F,$,V=!1)=>{V=V||!!g.dynamicChildren;const R=xt(p)&&p.data==="[",b=()=>_(p,g,O,F,$,R),{type:I,ref:x,shapeFlag:B,patchFlag:se}=g;let le=p.nodeType;g.el=p,se===-2&&(V=!1,g.dynamicChildren=null);let U=null;switch(I){case gt:le!==3?g.children===""?(c(g.el=r(""),o(p),p),U=p):U=b():(p.data!==g.children&&(bt(),p.data=g.children),U=i(p));break;case ve:j(p)?(U=i(p),N(g.el=p.content.firstChild,p,O)):le!==8||R?U=b():U=i(p);break;case kt:if(R&&(p=i(p),le=p.nodeType),le===1||le===3){U=p;const Y=!g.children.length;for(let D=0;D{V=V||!!g.dynamicChildren;const{type:R,props:b,patchFlag:I,shapeFlag:x,dirs:B,transition:se}=g,le=R==="input"||R==="option";if(le||I!==-1){B&&Ue(g,null,O,"created");let U=!1;if(j(p)){U=co(null,se)&&O&&O.vnode.props&&O.vnode.props.appear;const D=p.content.firstChild;U&&se.beforeEnter(D),N(D,p,O),g.el=p=D}if(x&16&&!(b&&(b.innerHTML||b.textContent))){let D=v(p.firstChild,g,p,O,F,$,V);for(;D;){pn(p,1)||bt();const he=D;D=D.nextSibling,l(he)}}else if(x&8){let D=g.children;D[0]===` +`&&(p.tagName==="PRE"||p.tagName==="TEXTAREA")&&(D=D.slice(1)),p.textContent!==D&&(pn(p,0)||bt(),p.textContent=g.children)}if(b){if(le||!V||I&48){const D=p.tagName.includes("-");for(const he in b)(le&&(he.endsWith("value")||he==="indeterminate")||en(he)&&!Ct(he)||he[0]==="."||D)&&s(p,he,null,b[he],void 0,O)}else if(b.onClick)s(p,"onClick",null,b.onClick,void 0,O);else if(I&4&&ht(b.style))for(const D in b.style)b.style[D]}let Y;(Y=b&&b.onVnodeBeforeMount)&&Oe(Y,O,g),B&&Ue(g,null,O,"beforeMount"),((Y=b&&b.onVnodeMounted)||B||U)&&go(()=>{Y&&Oe(Y,O,g),U&&se.enter(p),B&&Ue(g,null,O,"mounted")},F)}return p.nextSibling},v=(p,g,O,F,$,V,R)=>{R=R||!!g.dynamicChildren;const b=g.children,I=b.length;for(let x=0;x{const{slotScopeIds:R}=g;R&&($=$?$.concat(R):R);const b=o(p),I=v(i(p),g,b,O,F,$,V);return I&&xt(I)&&I.data==="]"?i(g.anchor=I):(bt(),c(g.anchor=f("]"),b,I),I)},_=(p,g,O,F,$,V)=>{if(pn(p.parentElement,1)||bt(),g.el=null,V){const I=K(p);for(;;){const x=i(p);if(x&&x!==I)l(x);else break}}const R=i(p),b=o(p);return l(p),n(null,g,b,R,O,F,hn(b),$),O&&(O.vnode.el=g.el,ho(O,g.el)),R},K=(p,g="[",O="]")=>{let F=0;for(;p;)if(p=i(p),p&&xt(p)&&(p.data===g&&F++,p.data===O)){if(F===0)return i(p);F--}return p},N=(p,g,O)=>{const F=g.parentNode;F&&F.replaceChild(p,g);let $=O;for(;$;)$.vnode.el===g&&($.vnode.el=$.subTree.el=p),$=$.parent},j=p=>p.nodeType===1&&p.tagName==="TEMPLATE";return[a,h]}const vr="data-allow-mismatch",Xl={0:"text",1:"children",2:"class",3:"style",4:"attribute"};function pn(e,t){if(t===0||t===1)for(;e&&!e.hasAttribute(vr);)e=e.parentElement;const n=e&&e.getAttribute(vr);if(n==null)return!1;if(n==="")return!0;{const s=n.split(",");return t===0&&s.includes("children")?!0:n.split(",").includes(Xl[t])}}Hn().requestIdleCallback;Hn().cancelIdleCallback;function Jl(e,t){if(xt(e)&&e.data==="["){let n=1,s=e.nextSibling;for(;s;){if(s.nodeType===1){if(t(s)===!1)break}else if(xt(s))if(s.data==="]"){if(--n===0)break}else s.data==="["&&n++;s=s.nextSibling}}else t(e)}const pt=e=>!!e.type.__asyncLoader;/*! #__NO_SIDE_EFFECTS__ */function wf(e){q(e)&&(e={loader:e});const{loader:t,loadingComponent:n,errorComponent:s,delay:r=200,hydrate:i,timeout:o,suspensible:l=!0,onError:c}=e;let f=null,a,h=0;const y=()=>(h++,f=null,v()),v=()=>{let S;return f||(S=f=t().catch(_=>{if(_=_ instanceof Error?_:new Error(String(_)),c)return new Promise((K,N)=>{c(_,()=>K(y()),()=>N(_),h+1)});throw _}).then(_=>S!==f&&f?f:(_&&(_.__esModule||_[Symbol.toStringTag]==="Module")&&(_=_.default),a=_,_)))};return Ys({name:"AsyncComponentWrapper",__asyncLoader:v,__asyncHydrate(S,_,K){const N=i?()=>{const j=i(K,p=>Jl(S,p));j&&(_.bum||(_.bum=[])).push(j)}:K;a?N():v().then(()=>!_.isUnmounted&&N())},get __asyncResolved(){return a},setup(){const S=ue;if(Xs(S),a)return()=>ns(a,S);const _=p=>{f=null,nn(p,S,13,!s)};if(l&&S.suspense||Mt)return v().then(p=>()=>ns(p,S)).catch(p=>(_(p),()=>s?ce(s,{error:p}):null));const K=oe(!1),N=oe(),j=oe(!!r);return r&&setTimeout(()=>{j.value=!1},r),o!=null&&setTimeout(()=>{if(!K.value&&!N.value){const p=new Error(`Async component timed out after ${o}ms.`);_(p),N.value=p}},o),v().then(()=>{K.value=!0,S.parent&&sn(S.parent.vnode)&&S.parent.update()}).catch(p=>{_(p),N.value=p}),()=>{if(K.value&&a)return ns(a,S);if(N.value&&s)return ce(s,{error:N.value});if(n&&!j.value)return ce(n)}}})}function ns(e,t){const{ref:n,props:s,children:r,ce:i}=t.vnode,o=ce(e,s,r);return o.ref=n,o.ce=i,delete t.vnode.ce,o}const sn=e=>e.type.__isKeepAlive;function zl(e,t){Wi(e,"a",t)}function Ql(e,t){Wi(e,"da",t)}function Wi(e,t,n=ue){const s=e.__wdc||(e.__wdc=()=>{let r=n;for(;r;){if(r.isDeactivated)return;r=r.parent}return e()});if(kn(t,s,n),n){let r=n.parent;for(;r&&r.parent;)sn(r.parent.vnode)&&Zl(s,t,n,r),r=r.parent}}function Zl(e,t,n,s){const r=kn(t,e,s,!0);Bn(()=>{Hs(s[t],r)},n)}function kn(e,t,n=ue,s=!1){if(n){const r=n[e]||(n[e]=[]),i=t.__weh||(t.__weh=(...o)=>{rt();const l=rn(n),c=He(t,n,e,o);return l(),it(),c});return s?r.unshift(i):r.push(i),i}}const Je=e=>(t,n=ue)=>{(!Mt||e==="sp")&&kn(e,(...s)=>t(...s),n)},ec=Je("bm"),Lt=Je("m"),tc=Je("bu"),nc=Je("u"),Ki=Je("bum"),Bn=Je("um"),sc=Je("sp"),rc=Je("rtg"),ic=Je("rtc");function oc(e,t=ue){kn("ec",e,t)}const qi="components";function Sf(e,t){return Yi(qi,e,!0,t)||e}const Gi=Symbol.for("v-ndc");function xf(e){return re(e)?Yi(qi,e,!1)||e:e||Gi}function Yi(e,t,n=!0,s=!1){const r=de||ue;if(r){const i=r.type;{const l=Wc(i,!1);if(l&&(l===t||l===Le(t)||l===Fn(Le(t))))return i}const o=_r(r[e]||i[e],t)||_r(r.appContext[e],t);return!o&&s?i:o}}function _r(e,t){return e&&(e[t]||e[Le(t)]||e[Fn(Le(t))])}function Ef(e,t,n,s){let r;const i=n,o=W(e);if(o||re(e)){const l=o&&ht(e);let c=!1;l&&(c=!Pe(e),e=Dn(e)),r=new Array(e.length);for(let f=0,a=e.length;ft(l,c,void 0,i));else{const l=Object.keys(e);r=new Array(l.length);for(let c=0,f=l.length;czt(t)?!(t.type===ve||t.type===xe&&!Xi(t.children)):!0)?e:null}function Cf(e,t){const n={};for(const s in e)n[/[A-Z]/.test(s)?`on:${s}`:_n(s)]=e[s];return n}const Ts=e=>e?bo(e)?Gn(e):Ts(e.parent):null,Ut=ae(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>Ts(e.parent),$root:e=>Ts(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>Js(e),$forceUpdate:e=>e.f||(e.f=()=>{Gs(e.update)}),$nextTick:e=>e.n||(e.n=Un.bind(e.proxy)),$watch:e=>Rc.bind(e)}),ss=(e,t)=>e!==Z&&!e.__isScriptSetup&&z(e,t),lc={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:n,setupState:s,data:r,props:i,accessCache:o,type:l,appContext:c}=e;let f;if(t[0]!=="$"){const v=o[t];if(v!==void 0)switch(v){case 1:return s[t];case 2:return r[t];case 4:return n[t];case 3:return i[t]}else{if(ss(s,t))return o[t]=1,s[t];if(r!==Z&&z(r,t))return o[t]=2,r[t];if((f=e.propsOptions[0])&&z(f,t))return o[t]=3,i[t];if(n!==Z&&z(n,t))return o[t]=4,n[t];Cs&&(o[t]=0)}}const a=Ut[t];let h,y;if(a)return t==="$attrs"&&me(e.attrs,"get",""),a(e);if((h=l.__cssModules)&&(h=h[t]))return h;if(n!==Z&&z(n,t))return o[t]=4,n[t];if(y=c.config.globalProperties,z(y,t))return y[t]},set({_:e},t,n){const{data:s,setupState:r,ctx:i}=e;return ss(r,t)?(r[t]=n,!0):s!==Z&&z(s,t)?(s[t]=n,!0):z(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(i[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:s,appContext:r,propsOptions:i}},o){let l;return!!n[o]||e!==Z&&z(e,o)||ss(t,o)||(l=i[0])&&z(l,o)||z(s,o)||z(Ut,o)||z(r.config.globalProperties,o)},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:z(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function Af(){return cc().slots}function cc(){const e=qn();return e.setupContext||(e.setupContext=So(e))}function br(e){return W(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}let Cs=!0;function ac(e){const t=Js(e),n=e.proxy,s=e.ctx;Cs=!1,t.beforeCreate&&wr(t.beforeCreate,e,"bc");const{data:r,computed:i,methods:o,watch:l,provide:c,inject:f,created:a,beforeMount:h,mounted:y,beforeUpdate:v,updated:S,activated:_,deactivated:K,beforeDestroy:N,beforeUnmount:j,destroyed:p,unmounted:g,render:O,renderTracked:F,renderTriggered:$,errorCaptured:V,serverPrefetch:R,expose:b,inheritAttrs:I,components:x,directives:B,filters:se}=t;if(f&&fc(f,s,null),o)for(const Y in o){const D=o[Y];q(D)&&(s[Y]=D.bind(n))}if(r){const Y=r.call(n,n);ne(Y)&&(e.data=jn(Y))}if(Cs=!0,i)for(const Y in i){const D=i[Y],he=q(D)?D.bind(n,n):q(D.get)?D.get.bind(n,n):ke,on=!q(D)&&q(D.set)?D.set.bind(n):ke,ot=ie({get:he,set:on});Object.defineProperty(s,Y,{enumerable:!0,configurable:!0,get:()=>ot.value,set:De=>ot.value=De})}if(l)for(const Y in l)Ji(l[Y],s,n,Y);if(c){const Y=q(c)?c.call(n):c;Reflect.ownKeys(Y).forEach(D=>{mc(D,Y[D])})}a&&wr(a,e,"c");function U(Y,D){W(D)?D.forEach(he=>Y(he.bind(n))):D&&Y(D.bind(n))}if(U(ec,h),U(Lt,y),U(tc,v),U(nc,S),U(zl,_),U(Ql,K),U(oc,V),U(ic,F),U(rc,$),U(Ki,j),U(Bn,g),U(sc,R),W(b))if(b.length){const Y=e.exposed||(e.exposed={});b.forEach(D=>{Object.defineProperty(Y,D,{get:()=>n[D],set:he=>n[D]=he})})}else e.exposed||(e.exposed={});O&&e.render===ke&&(e.render=O),I!=null&&(e.inheritAttrs=I),x&&(e.components=x),B&&(e.directives=B),R&&Xs(e)}function fc(e,t,n=ke){W(e)&&(e=As(e));for(const s in e){const r=e[s];let i;ne(r)?"default"in r?i=Ot(r.from||s,r.default,!0):i=Ot(r.from||s):i=Ot(r),fe(i)?Object.defineProperty(t,s,{enumerable:!0,configurable:!0,get:()=>i.value,set:o=>i.value=o}):t[s]=i}}function wr(e,t,n){He(W(e)?e.map(s=>s.bind(t.proxy)):e.bind(t.proxy),t,n)}function Ji(e,t,n,s){let r=s.includes(".")?fo(n,s):()=>n[s];if(re(e)){const i=t[e];q(i)&&Fe(r,i)}else if(q(e))Fe(r,e.bind(n));else if(ne(e))if(W(e))e.forEach(i=>Ji(i,t,n,s));else{const i=q(e.handler)?e.handler.bind(n):t[e.handler];q(i)&&Fe(r,i,e)}}function Js(e){const t=e.type,{mixins:n,extends:s}=t,{mixins:r,optionsCache:i,config:{optionMergeStrategies:o}}=e.appContext,l=i.get(t);let c;return l?c=l:!r.length&&!n&&!s?c=t:(c={},r.length&&r.forEach(f=>Pn(c,f,o,!0)),Pn(c,t,o)),ne(t)&&i.set(t,c),c}function Pn(e,t,n,s=!1){const{mixins:r,extends:i}=t;i&&Pn(e,i,n,!0),r&&r.forEach(o=>Pn(e,o,n,!0));for(const o in t)if(!(s&&o==="expose")){const l=uc[o]||n&&n[o];e[o]=l?l(e[o],t[o]):t[o]}return e}const uc={data:Sr,props:xr,emits:xr,methods:$t,computed:$t,beforeCreate:_e,created:_e,beforeMount:_e,mounted:_e,beforeUpdate:_e,updated:_e,beforeDestroy:_e,beforeUnmount:_e,destroyed:_e,unmounted:_e,activated:_e,deactivated:_e,errorCaptured:_e,serverPrefetch:_e,components:$t,directives:$t,watch:hc,provide:Sr,inject:dc};function Sr(e,t){return t?e?function(){return ae(q(e)?e.call(this,this):e,q(t)?t.call(this,this):t)}:t:e}function dc(e,t){return $t(As(e),As(t))}function As(e){if(W(e)){const t={};for(let n=0;n1)return n&&q(t)?t.call(s&&s.proxy):t}}const Qi={},Zi=()=>Object.create(Qi),eo=e=>Object.getPrototypeOf(e)===Qi;function yc(e,t,n,s=!1){const r={},i=Zi();e.propsDefaults=Object.create(null),to(e,t,r,i);for(const o in e.propsOptions[0])o in r||(r[o]=void 0);n?e.props=s?r:Tl(r):e.type.props?e.props=r:e.props=i,e.attrs=i}function vc(e,t,n,s){const{props:r,attrs:i,vnode:{patchFlag:o}}=e,l=J(r),[c]=e.propsOptions;let f=!1;if((s||o>0)&&!(o&16)){if(o&8){const a=e.vnode.dynamicProps;for(let h=0;h{c=!0;const[y,v]=no(h,t,!0);ae(o,y),v&&l.push(...v)};!n&&t.mixins.length&&t.mixins.forEach(a),e.extends&&a(e.extends),e.mixins&&e.mixins.forEach(a)}if(!i&&!c)return ne(e)&&s.set(e,Et),Et;if(W(i))for(let a=0;ae[0]==="_"||e==="$stable",zs=e=>W(e)?e.map(Me):[Me(e)],bc=(e,t,n)=>{if(t._n)return t;const s=Ul((...r)=>zs(t(...r)),n);return s._c=!1,s},ro=(e,t,n)=>{const s=e._ctx;for(const r in e){if(so(r))continue;const i=e[r];if(q(i))t[r]=bc(r,i,s);else if(i!=null){const o=zs(i);t[r]=()=>o}}},io=(e,t)=>{const n=zs(t);e.slots.default=()=>n},oo=(e,t,n)=>{for(const s in t)(n||s!=="_")&&(e[s]=t[s])},wc=(e,t,n)=>{const s=e.slots=Zi();if(e.vnode.shapeFlag&32){const r=t._;r?(oo(s,t,n),n&&ai(s,"_",r,!0)):ro(t,s)}else t&&io(e,t)},Sc=(e,t,n)=>{const{vnode:s,slots:r}=e;let i=!0,o=Z;if(s.shapeFlag&32){const l=t._;l?n&&l===1?i=!1:oo(r,t,n):(i=!t.$stable,ro(t,r)),o=t}else t&&(io(e,t),o={default:1});if(i)for(const l in r)!so(l)&&o[l]==null&&delete r[l]},be=go;function xc(e){return lo(e)}function Ec(e){return lo(e,Yl)}function lo(e,t){const n=Hn();n.__VUE__=!0;const{insert:s,remove:r,patchProp:i,createElement:o,createText:l,createComment:c,setText:f,setElementText:a,parentNode:h,nextSibling:y,setScopeId:v=ke,insertStaticContent:S}=e,_=(u,d,m,T=null,w=null,E=null,P=void 0,M=null,A=!!d.dynamicChildren)=>{if(u===d)return;u&&!ut(u,d)&&(T=ln(u),De(u,w,E,!0),u=null),d.patchFlag===-2&&(A=!1,d.dynamicChildren=null);const{type:C,ref:k,shapeFlag:L}=d;switch(C){case gt:K(u,d,m,T);break;case ve:N(u,d,m,T);break;case kt:u==null&&j(d,m,T,P);break;case xe:x(u,d,m,T,w,E,P,M,A);break;default:L&1?O(u,d,m,T,w,E,P,M,A):L&6?B(u,d,m,T,w,E,P,M,A):(L&64||L&128)&&C.process(u,d,m,T,w,E,P,M,A,vt)}k!=null&&w&&Xt(k,u&&u.ref,E,d||u,!d)},K=(u,d,m,T)=>{if(u==null)s(d.el=l(d.children),m,T);else{const w=d.el=u.el;d.children!==u.children&&f(w,d.children)}},N=(u,d,m,T)=>{u==null?s(d.el=c(d.children||""),m,T):d.el=u.el},j=(u,d,m,T)=>{[u.el,u.anchor]=S(u.children,d,m,T,u.el,u.anchor)},p=({el:u,anchor:d},m,T)=>{let w;for(;u&&u!==d;)w=y(u),s(u,m,T),u=w;s(d,m,T)},g=({el:u,anchor:d})=>{let m;for(;u&&u!==d;)m=y(u),r(u),u=m;r(d)},O=(u,d,m,T,w,E,P,M,A)=>{d.type==="svg"?P="svg":d.type==="math"&&(P="mathml"),u==null?F(d,m,T,w,E,P,M,A):R(u,d,w,E,P,M,A)},F=(u,d,m,T,w,E,P,M)=>{let A,C;const{props:k,shapeFlag:L,transition:H,dirs:G}=u;if(A=u.el=o(u.type,E,k&&k.is,k),L&8?a(A,u.children):L&16&&V(u.children,A,null,T,w,rs(u,E),P,M),G&&Ue(u,null,T,"created"),$(A,u,u.scopeId,P,T),k){for(const ee in k)ee!=="value"&&!Ct(ee)&&i(A,ee,null,k[ee],E,T);"value"in k&&i(A,"value",null,k.value,E),(C=k.onVnodeBeforeMount)&&Oe(C,T,u)}G&&Ue(u,null,T,"beforeMount");const X=co(w,H);X&&H.beforeEnter(A),s(A,d,m),((C=k&&k.onVnodeMounted)||X||G)&&be(()=>{C&&Oe(C,T,u),X&&H.enter(A),G&&Ue(u,null,T,"mounted")},w)},$=(u,d,m,T,w)=>{if(m&&v(u,m),T)for(let E=0;E{for(let C=A;C{const M=d.el=u.el;let{patchFlag:A,dynamicChildren:C,dirs:k}=d;A|=u.patchFlag&16;const L=u.props||Z,H=d.props||Z;let G;if(m&<(m,!1),(G=H.onVnodeBeforeUpdate)&&Oe(G,m,d,u),k&&Ue(d,u,m,"beforeUpdate"),m&<(m,!0),(L.innerHTML&&H.innerHTML==null||L.textContent&&H.textContent==null)&&a(M,""),C?b(u.dynamicChildren,C,M,m,T,rs(d,w),E):P||D(u,d,M,null,m,T,rs(d,w),E,!1),A>0){if(A&16)I(M,L,H,m,w);else if(A&2&&L.class!==H.class&&i(M,"class",null,H.class,w),A&4&&i(M,"style",L.style,H.style,w),A&8){const X=d.dynamicProps;for(let ee=0;ee{G&&Oe(G,m,d,u),k&&Ue(d,u,m,"updated")},T)},b=(u,d,m,T,w,E,P)=>{for(let M=0;M{if(d!==m){if(d!==Z)for(const E in d)!Ct(E)&&!(E in m)&&i(u,E,d[E],null,w,T);for(const E in m){if(Ct(E))continue;const P=m[E],M=d[E];P!==M&&E!=="value"&&i(u,E,M,P,w,T)}"value"in m&&i(u,"value",d.value,m.value,w)}},x=(u,d,m,T,w,E,P,M,A)=>{const C=d.el=u?u.el:l(""),k=d.anchor=u?u.anchor:l("");let{patchFlag:L,dynamicChildren:H,slotScopeIds:G}=d;G&&(M=M?M.concat(G):G),u==null?(s(C,m,T),s(k,m,T),V(d.children||[],m,k,w,E,P,M,A)):L>0&&L&64&&H&&u.dynamicChildren?(b(u.dynamicChildren,H,m,w,E,P,M),(d.key!=null||w&&d===w.subTree)&&Qs(u,d,!0)):D(u,d,m,k,w,E,P,M,A)},B=(u,d,m,T,w,E,P,M,A)=>{d.slotScopeIds=M,u==null?d.shapeFlag&512?w.ctx.activate(d,m,T,P,A):se(d,m,T,w,E,P,A):le(u,d,A)},se=(u,d,m,T,w,E,P)=>{const M=u.component=Vc(u,T,w);if(sn(u)&&(M.ctx.renderer=vt),Uc(M,!1,P),M.asyncDep){if(w&&w.registerDep(M,U,P),!u.el){const A=M.subTree=ce(ve);N(null,A,d,m)}}else U(M,u,d,m,w,E,P)},le=(u,d,m)=>{const T=d.component=u.component;if(Ic(u,d,m))if(T.asyncDep&&!T.asyncResolved){Y(T,d,m);return}else T.next=d,T.update();else d.el=u.el,T.vnode=d},U=(u,d,m,T,w,E,P)=>{const M=()=>{if(u.isMounted){let{next:L,bu:H,u:G,parent:X,vnode:ee}=u;{const Te=ao(u);if(Te){L&&(L.el=ee.el,Y(u,L,P)),Te.asyncDep.then(()=>{u.isUnmounted||M()});return}}let Q=L,Ee;lt(u,!1),L?(L.el=ee.el,Y(u,L,P)):L=ee,H&&bn(H),(Ee=L.props&&L.props.onVnodeBeforeUpdate)&&Oe(Ee,X,L,ee),lt(u,!0);const pe=is(u),Ie=u.subTree;u.subTree=pe,_(Ie,pe,h(Ie.el),ln(Ie),u,w,E),L.el=pe.el,Q===null&&ho(u,pe.el),G&&be(G,w),(Ee=L.props&&L.props.onVnodeUpdated)&&be(()=>Oe(Ee,X,L,ee),w)}else{let L;const{el:H,props:G}=d,{bm:X,m:ee,parent:Q,root:Ee,type:pe}=u,Ie=pt(d);if(lt(u,!1),X&&bn(X),!Ie&&(L=G&&G.onVnodeBeforeMount)&&Oe(L,Q,d),lt(u,!0),H&&Jn){const Te=()=>{u.subTree=is(u),Jn(H,u.subTree,u,w,null)};Ie&&pe.__asyncHydrate?pe.__asyncHydrate(H,u,Te):Te()}else{Ee.ce&&Ee.ce._injectChildStyle(pe);const Te=u.subTree=is(u);_(null,Te,m,T,u,w,E),d.el=Te.el}if(ee&&be(ee,w),!Ie&&(L=G&&G.onVnodeMounted)){const Te=d;be(()=>Oe(L,Q,Te),w)}(d.shapeFlag&256||Q&&pt(Q.vnode)&&Q.vnode.shapeFlag&256)&&u.a&&be(u.a,w),u.isMounted=!0,d=m=T=null}};u.scope.on();const A=u.effect=new pi(M);u.scope.off();const C=u.update=A.run.bind(A),k=u.job=A.runIfDirty.bind(A);k.i=u,k.id=u.uid,A.scheduler=()=>Gs(k),lt(u,!0),C()},Y=(u,d,m)=>{d.component=u;const T=u.vnode.props;u.vnode=d,u.next=null,vc(u,d.props,T,m),Sc(u,d.children,m),rt(),dr(u),it()},D=(u,d,m,T,w,E,P,M,A=!1)=>{const C=u&&u.children,k=u?u.shapeFlag:0,L=d.children,{patchFlag:H,shapeFlag:G}=d;if(H>0){if(H&128){on(C,L,m,T,w,E,P,M,A);return}else if(H&256){he(C,L,m,T,w,E,P,M,A);return}}G&8?(k&16&&It(C,w,E),L!==C&&a(m,L)):k&16?G&16?on(C,L,m,T,w,E,P,M,A):It(C,w,E,!0):(k&8&&a(m,""),G&16&&V(L,m,T,w,E,P,M,A))},he=(u,d,m,T,w,E,P,M,A)=>{u=u||Et,d=d||Et;const C=u.length,k=d.length,L=Math.min(C,k);let H;for(H=0;Hk?It(u,w,E,!0,!1,L):V(d,m,T,w,E,P,M,A,L)},on=(u,d,m,T,w,E,P,M,A)=>{let C=0;const k=d.length;let L=u.length-1,H=k-1;for(;C<=L&&C<=H;){const G=u[C],X=d[C]=A?et(d[C]):Me(d[C]);if(ut(G,X))_(G,X,m,null,w,E,P,M,A);else break;C++}for(;C<=L&&C<=H;){const G=u[L],X=d[H]=A?et(d[H]):Me(d[H]);if(ut(G,X))_(G,X,m,null,w,E,P,M,A);else break;L--,H--}if(C>L){if(C<=H){const G=H+1,X=GH)for(;C<=L;)De(u[C],w,E,!0),C++;else{const G=C,X=C,ee=new Map;for(C=X;C<=H;C++){const Ce=d[C]=A?et(d[C]):Me(d[C]);Ce.key!=null&&ee.set(Ce.key,C)}let Q,Ee=0;const pe=H-X+1;let Ie=!1,Te=0;const Nt=new Array(pe);for(C=0;C=pe){De(Ce,w,E,!0);continue}let je;if(Ce.key!=null)je=ee.get(Ce.key);else for(Q=X;Q<=H;Q++)if(Nt[Q-X]===0&&ut(Ce,d[Q])){je=Q;break}je===void 0?De(Ce,w,E,!0):(Nt[je-X]=C+1,je>=Te?Te=je:Ie=!0,_(Ce,d[je],m,null,w,E,P,M,A),Ee++)}const lr=Ie?Tc(Nt):Et;for(Q=lr.length-1,C=pe-1;C>=0;C--){const Ce=X+C,je=d[Ce],cr=Ce+1{const{el:E,type:P,transition:M,children:A,shapeFlag:C}=u;if(C&6){ot(u.component.subTree,d,m,T);return}if(C&128){u.suspense.move(d,m,T);return}if(C&64){P.move(u,d,m,vt);return}if(P===xe){s(E,d,m);for(let L=0;LM.enter(E),w);else{const{leave:L,delayLeave:H,afterLeave:G}=M,X=()=>s(E,d,m),ee=()=>{L(E,()=>{X(),G&&G()})};H?H(E,X,ee):ee()}else s(E,d,m)},De=(u,d,m,T=!1,w=!1)=>{const{type:E,props:P,ref:M,children:A,dynamicChildren:C,shapeFlag:k,patchFlag:L,dirs:H,cacheIndex:G}=u;if(L===-2&&(w=!1),M!=null&&Xt(M,null,m,u,!0),G!=null&&(d.renderCache[G]=void 0),k&256){d.ctx.deactivate(u);return}const X=k&1&&H,ee=!pt(u);let Q;if(ee&&(Q=P&&P.onVnodeBeforeUnmount)&&Oe(Q,d,u),k&6)Wo(u.component,m,T);else{if(k&128){u.suspense.unmount(m,T);return}X&&Ue(u,null,d,"beforeUnmount"),k&64?u.type.remove(u,d,m,vt,T):C&&!C.hasOnce&&(E!==xe||L>0&&L&64)?It(C,d,m,!1,!0):(E===xe&&L&384||!w&&k&16)&&It(A,d,m),T&&ir(u)}(ee&&(Q=P&&P.onVnodeUnmounted)||X)&&be(()=>{Q&&Oe(Q,d,u),X&&Ue(u,null,d,"unmounted")},m)},ir=u=>{const{type:d,el:m,anchor:T,transition:w}=u;if(d===xe){Bo(m,T);return}if(d===kt){g(u);return}const E=()=>{r(m),w&&!w.persisted&&w.afterLeave&&w.afterLeave()};if(u.shapeFlag&1&&w&&!w.persisted){const{leave:P,delayLeave:M}=w,A=()=>P(m,E);M?M(u.el,E,A):A()}else E()},Bo=(u,d)=>{let m;for(;u!==d;)m=y(u),r(u),u=m;r(d)},Wo=(u,d,m)=>{const{bum:T,scope:w,job:E,subTree:P,um:M,m:A,a:C}=u;Tr(A),Tr(C),T&&bn(T),w.stop(),E&&(E.flags|=8,De(P,u,d,m)),M&&be(M,d),be(()=>{u.isUnmounted=!0},d),d&&d.pendingBranch&&!d.isUnmounted&&u.asyncDep&&!u.asyncResolved&&u.suspenseId===d.pendingId&&(d.deps--,d.deps===0&&d.resolve())},It=(u,d,m,T=!1,w=!1,E=0)=>{for(let P=E;P{if(u.shapeFlag&6)return ln(u.component.subTree);if(u.shapeFlag&128)return u.suspense.next();const d=y(u.anchor||u.el),m=d&&d[Fi];return m?y(m):d};let Yn=!1;const or=(u,d,m)=>{u==null?d._vnode&&De(d._vnode,null,null,!0):_(d._vnode||null,u,d,null,null,null,m),d._vnode=u,Yn||(Yn=!0,dr(),On(),Yn=!1)},vt={p:_,um:De,m:ot,r:ir,mt:se,mc:V,pc:D,pbc:b,n:ln,o:e};let Xn,Jn;return t&&([Xn,Jn]=t(vt)),{render:or,hydrate:Xn,createApp:gc(or,Xn)}}function rs({type:e,props:t},n){return n==="svg"&&e==="foreignObject"||n==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:n}function lt({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function co(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Qs(e,t,n=!1){const s=e.children,r=t.children;if(W(s)&&W(r))for(let i=0;i>1,e[n[l]]0&&(t[s]=n[i-1]),n[i]=s)}}for(i=n.length,o=n[i-1];i-- >0;)n[i]=o,o=t[o];return n}function ao(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:ao(t)}function Tr(e){if(e)for(let t=0;tOt(Cc);function Zs(e,t){return Wn(e,null,t)}function Rf(e,t){return Wn(e,null,{flush:"post"})}function Fe(e,t,n){return Wn(e,t,n)}function Wn(e,t,n=Z){const{immediate:s,deep:r,flush:i,once:o}=n,l=ae({},n),c=t&&s||!t&&i!=="post";let f;if(Mt){if(i==="sync"){const v=Ac();f=v.__watcherHandles||(v.__watcherHandles=[])}else if(!c){const v=()=>{};return v.stop=ke,v.resume=ke,v.pause=ke,v}}const a=ue;l.call=(v,S,_)=>He(v,a,S,_);let h=!1;i==="post"?l.scheduler=v=>{be(v,a&&a.suspense)}:i!=="sync"&&(h=!0,l.scheduler=(v,S)=>{S?v():Gs(v)}),l.augmentJob=v=>{t&&(v.flags|=4),h&&(v.flags|=2,a&&(v.id=a.uid,v.i=a))};const y=$l(e,t,l);return Mt&&(f?f.push(y):c&&y()),y}function Rc(e,t,n){const s=this.proxy,r=re(e)?e.includes(".")?fo(s,e):()=>s[e]:e.bind(s,s);let i;q(t)?i=t:(i=t.handler,n=t);const o=rn(this),l=Wn(r,i.bind(s),n);return o(),l}function fo(e,t){const n=t.split(".");return()=>{let s=e;for(let r=0;rt==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${Le(t)}Modifiers`]||e[`${st(t)}Modifiers`];function Mc(e,t,...n){if(e.isUnmounted)return;const s=e.vnode.props||Z;let r=n;const i=t.startsWith("update:"),o=i&&Oc(s,t.slice(7));o&&(o.trim&&(r=n.map(a=>re(a)?a.trim():a)),o.number&&(r=n.map(vs)));let l,c=s[l=_n(t)]||s[l=_n(Le(t))];!c&&i&&(c=s[l=_n(st(t))]),c&&He(c,e,6,r);const f=s[l+"Once"];if(f){if(!e.emitted)e.emitted={};else if(e.emitted[l])return;e.emitted[l]=!0,He(f,e,6,r)}}function uo(e,t,n=!1){const s=t.emitsCache,r=s.get(e);if(r!==void 0)return r;const i=e.emits;let o={},l=!1;if(!q(e)){const c=f=>{const a=uo(f,t,!0);a&&(l=!0,ae(o,a))};!n&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}return!i&&!l?(ne(e)&&s.set(e,null),null):(W(i)?i.forEach(c=>o[c]=null):ae(o,i),ne(e)&&s.set(e,o),o)}function Kn(e,t){return!e||!en(t)?!1:(t=t.slice(2).replace(/Once$/,""),z(e,t[0].toLowerCase()+t.slice(1))||z(e,st(t))||z(e,t))}function is(e){const{type:t,vnode:n,proxy:s,withProxy:r,propsOptions:[i],slots:o,attrs:l,emit:c,render:f,renderCache:a,props:h,data:y,setupState:v,ctx:S,inheritAttrs:_}=e,K=Mn(e);let N,j;try{if(n.shapeFlag&4){const g=r||s,O=g;N=Me(f.call(O,g,a,h,v,y,S)),j=l}else{const g=t;N=Me(g.length>1?g(h,{attrs:l,slots:o,emit:c}):g(h,null)),j=t.props?l:Pc(l)}}catch(g){Bt.length=0,nn(g,e,1),N=ce(ve)}let p=N;if(j&&_!==!1){const g=Object.keys(j),{shapeFlag:O}=p;g.length&&O&7&&(i&&g.some(Fs)&&(j=Lc(j,i)),p=nt(p,j,!1,!0))}return n.dirs&&(p=nt(p,null,!1,!0),p.dirs=p.dirs?p.dirs.concat(n.dirs):n.dirs),n.transition&&Yt(p,n.transition),N=p,Mn(K),N}const Pc=e=>{let t;for(const n in e)(n==="class"||n==="style"||en(n))&&((t||(t={}))[n]=e[n]);return t},Lc=(e,t)=>{const n={};for(const s in e)(!Fs(s)||!(s.slice(9)in t))&&(n[s]=e[s]);return n};function Ic(e,t,n){const{props:s,children:r,component:i}=e,{props:o,children:l,patchFlag:c}=t,f=i.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&c>=0){if(c&1024)return!0;if(c&16)return s?Cr(s,o,f):!!o;if(c&8){const a=t.dynamicProps;for(let h=0;he.__isSuspense;function go(e,t){t&&t.pendingBranch?W(e)?t.effects.push(...e):t.effects.push(e):Vl(e)}const xe=Symbol.for("v-fgt"),gt=Symbol.for("v-txt"),ve=Symbol.for("v-cmt"),kt=Symbol.for("v-stc"),Bt=[];let Ae=null;function Os(e=!1){Bt.push(Ae=e?null:[])}function Nc(){Bt.pop(),Ae=Bt[Bt.length-1]||null}let Jt=1;function Ar(e,t=!1){Jt+=e,e<0&&Ae&&t&&(Ae.hasOnce=!0)}function mo(e){return e.dynamicChildren=Jt>0?Ae||Et:null,Nc(),Jt>0&&Ae&&Ae.push(e),e}function Of(e,t,n,s,r,i){return mo(vo(e,t,n,s,r,i,!0))}function Ms(e,t,n,s,r){return mo(ce(e,t,n,s,r,!0))}function zt(e){return e?e.__v_isVNode===!0:!1}function ut(e,t){return e.type===t.type&&e.key===t.key}const yo=({key:e})=>e??null,xn=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?re(e)||fe(e)||q(e)?{i:de,r:e,k:t,f:!!n}:e:null);function vo(e,t=null,n=null,s=0,r=null,i=e===xe?0:1,o=!1,l=!1){const c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&yo(t),ref:t&&xn(t),scopeId:Ni,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:i,patchFlag:s,dynamicProps:r,dynamicChildren:null,appContext:null,ctx:de};return l?(er(c,n),i&128&&e.normalize(c)):n&&(c.shapeFlag|=re(n)?8:16),Jt>0&&!o&&Ae&&(c.patchFlag>0||i&6)&&c.patchFlag!==32&&Ae.push(c),c}const ce=Fc;function Fc(e,t=null,n=null,s=0,r=null,i=!1){if((!e||e===Gi)&&(e=ve),zt(e)){const l=nt(e,t,!0);return n&&er(l,n),Jt>0&&!i&&Ae&&(l.shapeFlag&6?Ae[Ae.indexOf(e)]=l:Ae.push(l)),l.patchFlag=-2,l}if(Kc(e)&&(e=e.__vccOpts),t){t=Hc(t);let{class:l,style:c}=t;l&&!re(l)&&(t.class=js(l)),ne(c)&&(Ks(c)&&!W(c)&&(c=ae({},c)),t.style=Ds(c))}const o=re(e)?1:po(e)?128:Hi(e)?64:ne(e)?4:q(e)?2:0;return vo(e,t,n,s,r,o,i,!0)}function Hc(e){return e?Ks(e)||eo(e)?ae({},e):e:null}function nt(e,t,n=!1,s=!1){const{props:r,ref:i,patchFlag:o,children:l,transition:c}=e,f=t?$c(r||{},t):r,a={__v_isVNode:!0,__v_skip:!0,type:e.type,props:f,key:f&&yo(f),ref:t&&t.ref?n&&i?W(i)?i.concat(xn(t)):[i,xn(t)]:xn(t):i,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:l,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==xe?o===-1?16:o|16:o,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:c,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&nt(e.ssContent),ssFallback:e.ssFallback&&nt(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return c&&s&&Yt(a,c.clone(a)),a}function _o(e=" ",t=0){return ce(gt,null,e,t)}function Mf(e,t){const n=ce(kt,null,e);return n.staticCount=t,n}function Pf(e="",t=!1){return t?(Os(),Ms(ve,null,e)):ce(ve,null,e)}function Me(e){return e==null||typeof e=="boolean"?ce(ve):W(e)?ce(xe,null,e.slice()):zt(e)?et(e):ce(gt,null,String(e))}function et(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:nt(e)}function er(e,t){let n=0;const{shapeFlag:s}=e;if(t==null)t=null;else if(W(t))n=16;else if(typeof t=="object")if(s&65){const r=t.default;r&&(r._c&&(r._d=!1),er(e,r()),r._c&&(r._d=!0));return}else{n=32;const r=t._;!r&&!eo(t)?t._ctx=de:r===3&&de&&(de.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else q(t)?(t={default:t,_ctx:de},n=32):(t=String(t),s&64?(n=16,t=[_o(t)]):n=8);e.children=t,e.shapeFlag|=n}function $c(...e){const t={};for(let n=0;nue||de;let Ln,Ps;{const e=Hn(),t=(n,s)=>{let r;return(r=e[n])||(r=e[n]=[]),r.push(s),i=>{r.length>1?r.forEach(o=>o(i)):r[0](i)}};Ln=t("__VUE_INSTANCE_SETTERS__",n=>ue=n),Ps=t("__VUE_SSR_SETTERS__",n=>Mt=n)}const rn=e=>{const t=ue;return Ln(e),e.scope.on(),()=>{e.scope.off(),Ln(t)}},Rr=()=>{ue&&ue.scope.off(),Ln(null)};function bo(e){return e.vnode.shapeFlag&4}let Mt=!1;function Uc(e,t=!1,n=!1){t&&Ps(t);const{props:s,children:r}=e.vnode,i=bo(e);yc(e,s,i,t),wc(e,r,n);const o=i?kc(e,t):void 0;return t&&Ps(!1),o}function kc(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,lc);const{setup:s}=n;if(s){rt();const r=e.setupContext=s.length>1?So(e):null,i=rn(e),o=tn(s,e,0,[e.props,r]),l=oi(o);if(it(),i(),(l||e.sp)&&!pt(e)&&Xs(e),l){if(o.then(Rr,Rr),t)return o.then(c=>{Or(e,c,t)}).catch(c=>{nn(c,e,0)});e.asyncDep=o}else Or(e,o,t)}else wo(e,t)}function Or(e,t,n){q(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:ne(t)&&(e.setupState=Mi(t)),wo(e,n)}let Mr;function wo(e,t,n){const s=e.type;if(!e.render){if(!t&&Mr&&!s.render){const r=s.template||Js(e).template;if(r){const{isCustomElement:i,compilerOptions:o}=e.appContext.config,{delimiters:l,compilerOptions:c}=s,f=ae(ae({isCustomElement:i,delimiters:l},o),c);s.render=Mr(r,f)}}e.render=s.render||ke}{const r=rn(e);rt();try{ac(e)}finally{it(),r()}}}const Bc={get(e,t){return me(e,"get",""),e[t]}};function So(e){const t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,Bc),slots:e.slots,emit:e.emit,expose:t}}function Gn(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(Mi(wn(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Ut)return Ut[n](e)},has(t,n){return n in t||n in Ut}})):e.proxy}function Wc(e,t=!0){return q(e)?e.displayName||e.name:e.name||t&&e.__name}function Kc(e){return q(e)&&"__vccOpts"in e}const ie=(e,t)=>Fl(e,t,Mt);function Ls(e,t,n){const s=arguments.length;return s===2?ne(t)&&!W(t)?zt(t)?ce(e,null,[t]):ce(e,t):ce(e,null,t):(s>3?n=Array.prototype.slice.call(arguments,2):s===3&&zt(n)&&(n=[n]),ce(e,t,n))}const qc="3.5.13";/** +* @vue/runtime-dom v3.5.13 +* (c) 2018-present Yuxi (Evan) You and Vue contributors +* @license MIT +**/let Is;const Pr=typeof window<"u"&&window.trustedTypes;if(Pr)try{Is=Pr.createPolicy("vue",{createHTML:e=>e})}catch{}const xo=Is?e=>Is.createHTML(e):e=>e,Gc="http://www.w3.org/2000/svg",Yc="http://www.w3.org/1998/Math/MathML",qe=typeof document<"u"?document:null,Lr=qe&&qe.createElement("template"),Xc={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,s)=>{const r=t==="svg"?qe.createElementNS(Gc,e):t==="mathml"?qe.createElementNS(Yc,e):n?qe.createElement(e,{is:n}):qe.createElement(e);return e==="select"&&s&&s.multiple!=null&&r.setAttribute("multiple",s.multiple),r},createText:e=>qe.createTextNode(e),createComment:e=>qe.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>qe.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,s,r,i){const o=n?n.previousSibling:t.lastChild;if(r&&(r===i||r.nextSibling))for(;t.insertBefore(r.cloneNode(!0),n),!(r===i||!(r=r.nextSibling)););else{Lr.innerHTML=xo(s==="svg"?`${e}`:s==="mathml"?`${e}`:e);const l=Lr.content;if(s==="svg"||s==="mathml"){const c=l.firstChild;for(;c.firstChild;)l.appendChild(c.firstChild);l.removeChild(c)}t.insertBefore(l,n)}return[o?o.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},ze="transition",Ht="animation",Qt=Symbol("_vtc"),Eo={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},Jc=ae({},ji,Eo),zc=e=>(e.displayName="Transition",e.props=Jc,e),Lf=zc((e,{slots:t})=>Ls(Kl,Qc(e),t)),ct=(e,t=[])=>{W(e)?e.forEach(n=>n(...t)):e&&e(...t)},Ir=e=>e?W(e)?e.some(t=>t.length>1):e.length>1:!1;function Qc(e){const t={};for(const x in e)x in Eo||(t[x]=e[x]);if(e.css===!1)return t;const{name:n="v",type:s,duration:r,enterFromClass:i=`${n}-enter-from`,enterActiveClass:o=`${n}-enter-active`,enterToClass:l=`${n}-enter-to`,appearFromClass:c=i,appearActiveClass:f=o,appearToClass:a=l,leaveFromClass:h=`${n}-leave-from`,leaveActiveClass:y=`${n}-leave-active`,leaveToClass:v=`${n}-leave-to`}=e,S=Zc(r),_=S&&S[0],K=S&&S[1],{onBeforeEnter:N,onEnter:j,onEnterCancelled:p,onLeave:g,onLeaveCancelled:O,onBeforeAppear:F=N,onAppear:$=j,onAppearCancelled:V=p}=t,R=(x,B,se,le)=>{x._enterCancelled=le,at(x,B?a:l),at(x,B?f:o),se&&se()},b=(x,B)=>{x._isLeaving=!1,at(x,h),at(x,v),at(x,y),B&&B()},I=x=>(B,se)=>{const le=x?$:j,U=()=>R(B,x,se);ct(le,[B,U]),Nr(()=>{at(B,x?c:i),Ke(B,x?a:l),Ir(le)||Fr(B,s,_,U)})};return ae(t,{onBeforeEnter(x){ct(N,[x]),Ke(x,i),Ke(x,o)},onBeforeAppear(x){ct(F,[x]),Ke(x,c),Ke(x,f)},onEnter:I(!1),onAppear:I(!0),onLeave(x,B){x._isLeaving=!0;const se=()=>b(x,B);Ke(x,h),x._enterCancelled?(Ke(x,y),Dr()):(Dr(),Ke(x,y)),Nr(()=>{x._isLeaving&&(at(x,h),Ke(x,v),Ir(g)||Fr(x,s,K,se))}),ct(g,[x,se])},onEnterCancelled(x){R(x,!1,void 0,!0),ct(p,[x])},onAppearCancelled(x){R(x,!0,void 0,!0),ct(V,[x])},onLeaveCancelled(x){b(x),ct(O,[x])}})}function Zc(e){if(e==null)return null;if(ne(e))return[os(e.enter),os(e.leave)];{const t=os(e);return[t,t]}}function os(e){return Jo(e)}function Ke(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e[Qt]||(e[Qt]=new Set)).add(t)}function at(e,t){t.split(/\s+/).forEach(s=>s&&e.classList.remove(s));const n=e[Qt];n&&(n.delete(t),n.size||(e[Qt]=void 0))}function Nr(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let ea=0;function Fr(e,t,n,s){const r=e._endId=++ea,i=()=>{r===e._endId&&s()};if(n!=null)return setTimeout(i,n);const{type:o,timeout:l,propCount:c}=ta(e,t);if(!o)return s();const f=o+"end";let a=0;const h=()=>{e.removeEventListener(f,y),i()},y=v=>{v.target===e&&++a>=c&&h()};setTimeout(()=>{a(n[S]||"").split(", "),r=s(`${ze}Delay`),i=s(`${ze}Duration`),o=Hr(r,i),l=s(`${Ht}Delay`),c=s(`${Ht}Duration`),f=Hr(l,c);let a=null,h=0,y=0;t===ze?o>0&&(a=ze,h=o,y=i.length):t===Ht?f>0&&(a=Ht,h=f,y=c.length):(h=Math.max(o,f),a=h>0?o>f?ze:Ht:null,y=a?a===ze?i.length:c.length:0);const v=a===ze&&/\b(transform|all)(,|$)/.test(s(`${ze}Property`).toString());return{type:a,timeout:h,propCount:y,hasTransform:v}}function Hr(e,t){for(;e.length$r(n)+$r(e[s])))}function $r(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function Dr(){return document.body.offsetHeight}function na(e,t,n){const s=e[Qt];s&&(t=(t?[t,...s]:[...s]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const jr=Symbol("_vod"),sa=Symbol("_vsh"),ra=Symbol(""),ia=/(^|;)\s*display\s*:/;function oa(e,t,n){const s=e.style,r=re(n);let i=!1;if(n&&!r){if(t)if(re(t))for(const o of t.split(";")){const l=o.slice(0,o.indexOf(":")).trim();n[l]==null&&En(s,l,"")}else for(const o in t)n[o]==null&&En(s,o,"");for(const o in n)o==="display"&&(i=!0),En(s,o,n[o])}else if(r){if(t!==n){const o=s[ra];o&&(n+=";"+o),s.cssText=n,i=ia.test(n)}}else t&&e.removeAttribute("style");jr in e&&(e[jr]=i?s.display:"",e[sa]&&(s.display="none"))}const Vr=/\s*!important$/;function En(e,t,n){if(W(n))n.forEach(s=>En(e,t,s));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const s=la(e,t);Vr.test(n)?e.setProperty(st(s),n.replace(Vr,""),"important"):e[s]=n}}const Ur=["Webkit","Moz","ms"],ls={};function la(e,t){const n=ls[t];if(n)return n;let s=Le(t);if(s!=="filter"&&s in e)return ls[t]=s;s=Fn(s);for(let r=0;rcs||(ua.then(()=>cs=0),cs=Date.now());function ha(e,t){const n=s=>{if(!s._vts)s._vts=Date.now();else if(s._vts<=n.attached)return;He(pa(s,n.value),t,5,[s])};return n.value=e,n.attached=da(),n}function pa(e,t){if(W(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(s=>r=>!r._stopped&&s&&s(r))}else return t}const Gr=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,ga=(e,t,n,s,r,i)=>{const o=r==="svg";t==="class"?na(e,s,o):t==="style"?oa(e,n,s):en(t)?Fs(t)||aa(e,t,n,s,i):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):ma(e,t,s,o))?(Wr(e,t,s),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&Br(e,t,s,o,i,t!=="value")):e._isVueCE&&(/[A-Z]/.test(t)||!re(s))?Wr(e,Le(t),s,i,t):(t==="true-value"?e._trueValue=s:t==="false-value"&&(e._falseValue=s),Br(e,t,s,o))};function ma(e,t,n,s){if(s)return!!(t==="innerHTML"||t==="textContent"||t in e&&Gr(t)&&q(n));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){const r=e.tagName;if(r==="IMG"||r==="VIDEO"||r==="CANVAS"||r==="SOURCE")return!1}return Gr(t)&&re(n)?!1:t in e}const Yr=e=>{const t=e.props["onUpdate:modelValue"]||!1;return W(t)?n=>bn(t,n):t};function ya(e){e.target.composing=!0}function Xr(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const as=Symbol("_assign"),If={created(e,{modifiers:{lazy:t,trim:n,number:s}},r){e[as]=Yr(r);const i=s||r.props&&r.props.type==="number";St(e,t?"change":"input",o=>{if(o.target.composing)return;let l=e.value;n&&(l=l.trim()),i&&(l=vs(l)),e[as](l)}),n&&St(e,"change",()=>{e.value=e.value.trim()}),t||(St(e,"compositionstart",ya),St(e,"compositionend",Xr),St(e,"change",Xr))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:s,trim:r,number:i}},o){if(e[as]=Yr(o),e.composing)return;const l=(i||e.type==="number")&&!/^0\d/.test(e.value)?vs(e.value):e.value,c=t??"";l!==c&&(document.activeElement===e&&e.type!=="range"&&(s&&t===n||r&&e.value.trim()===c)||(e.value=c))}},va=["ctrl","shift","alt","meta"],_a={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&e.button!==0,middle:e=>"button"in e&&e.button!==1,right:e=>"button"in e&&e.button!==2,exact:(e,t)=>va.some(n=>e[`${n}Key`]&&!t.includes(n))},Nf=(e,t)=>{const n=e._withMods||(e._withMods={}),s=t.join(".");return n[s]||(n[s]=(r,...i)=>{for(let o=0;o{const n=e._withKeys||(e._withKeys={}),s=t.join(".");return n[s]||(n[s]=r=>{if(!("key"in r))return;const i=st(r.key);if(t.some(o=>o===i||ba[o]===i))return e(r)})},To=ae({patchProp:ga},Xc);let Wt,Jr=!1;function wa(){return Wt||(Wt=xc(To))}function Sa(){return Wt=Jr?Wt:Ec(To),Jr=!0,Wt}const Hf=(...e)=>{const t=wa().createApp(...e),{mount:n}=t;return t.mount=s=>{const r=Ao(s);if(!r)return;const i=t._component;!q(i)&&!i.render&&!i.template&&(i.template=r.innerHTML),r.nodeType===1&&(r.textContent="");const o=n(r,!1,Co(r));return r instanceof Element&&(r.removeAttribute("v-cloak"),r.setAttribute("data-v-app","")),o},t},$f=(...e)=>{const t=Sa().createApp(...e),{mount:n}=t;return t.mount=s=>{const r=Ao(s);if(r)return n(r,!0,Co(r))},t};function Co(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function Ao(e){return re(e)?document.querySelector(e):e}const Df=(e,t)=>{const n=e.__vccOpts||e;for(const[s,r]of t)n[s]=r;return n},xa=window.__VP_SITE_DATA__;function tr(e){return hi()?(il(e),!0):!1}function Be(e){return typeof e=="function"?e():Oi(e)}const Ro=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const jf=e=>e!=null,Ea=Object.prototype.toString,Ta=e=>Ea.call(e)==="[object Object]",Zt=()=>{},zr=Ca();function Ca(){var e,t;return Ro&&((e=window==null?void 0:window.navigator)==null?void 0:e.userAgent)&&(/iP(?:ad|hone|od)/.test(window.navigator.userAgent)||((t=window==null?void 0:window.navigator)==null?void 0:t.maxTouchPoints)>2&&/iPad|Macintosh/.test(window==null?void 0:window.navigator.userAgent))}function Aa(e,t){function n(...s){return new Promise((r,i)=>{Promise.resolve(e(()=>t.apply(this,s),{fn:t,thisArg:this,args:s})).then(r).catch(i)})}return n}const Oo=e=>e();function Ra(e,t={}){let n,s,r=Zt;const i=l=>{clearTimeout(l),r(),r=Zt};return l=>{const c=Be(e),f=Be(t.maxWait);return n&&i(n),c<=0||f!==void 0&&f<=0?(s&&(i(s),s=null),Promise.resolve(l())):new Promise((a,h)=>{r=t.rejectOnCancel?h:a,f&&!s&&(s=setTimeout(()=>{n&&i(n),s=null,a(l())},f)),n=setTimeout(()=>{s&&i(s),s=null,a(l())},c)})}}function Oa(e=Oo){const t=oe(!0);function n(){t.value=!1}function s(){t.value=!0}const r=(...i)=>{t.value&&e(...i)};return{isActive:Vn(t),pause:n,resume:s,eventFilter:r}}function Ma(e){return qn()}function Mo(...e){if(e.length!==1)return Ll(...e);const t=e[0];return typeof t=="function"?Vn(Ol(()=>({get:t,set:Zt}))):oe(t)}function Po(e,t,n={}){const{eventFilter:s=Oo,...r}=n;return Fe(e,Aa(s,t),r)}function Pa(e,t,n={}){const{eventFilter:s,...r}=n,{eventFilter:i,pause:o,resume:l,isActive:c}=Oa(s);return{stop:Po(e,t,{...r,eventFilter:i}),pause:o,resume:l,isActive:c}}function nr(e,t=!0,n){Ma()?Lt(e,n):t?e():Un(e)}function Vf(e,t,n={}){const{debounce:s=0,maxWait:r=void 0,...i}=n;return Po(e,t,{...i,eventFilter:Ra(s,{maxWait:r})})}function Uf(e,t,n){let s;fe(n)?s={evaluating:n}:s={};const{lazy:r=!1,evaluating:i=void 0,shallow:o=!0,onError:l=Zt}=s,c=oe(!r),f=o?qs(t):oe(t);let a=0;return Zs(async h=>{if(!c.value)return;a++;const y=a;let v=!1;i&&Promise.resolve().then(()=>{i.value=!0});try{const S=await e(_=>{h(()=>{i&&(i.value=!1),v||_()})});y===a&&(f.value=S)}catch(S){l(S)}finally{i&&y===a&&(i.value=!1),v=!0}}),r?ie(()=>(c.value=!0,f.value)):f}const $e=Ro?window:void 0;function Lo(e){var t;const n=Be(e);return(t=n==null?void 0:n.$el)!=null?t:n}function Pt(...e){let t,n,s,r;if(typeof e[0]=="string"||Array.isArray(e[0])?([n,s,r]=e,t=$e):[t,n,s,r]=e,!t)return Zt;Array.isArray(n)||(n=[n]),Array.isArray(s)||(s=[s]);const i=[],o=()=>{i.forEach(a=>a()),i.length=0},l=(a,h,y,v)=>(a.addEventListener(h,y,v),()=>a.removeEventListener(h,y,v)),c=Fe(()=>[Lo(t),Be(r)],([a,h])=>{if(o(),!a)return;const y=Ta(h)?{...h}:h;i.push(...n.flatMap(v=>s.map(S=>l(a,v,S,y))))},{immediate:!0,flush:"post"}),f=()=>{c(),o()};return tr(f),f}function La(e){return typeof e=="function"?e:typeof e=="string"?t=>t.key===e:Array.isArray(e)?t=>e.includes(t.key):()=>!0}function kf(...e){let t,n,s={};e.length===3?(t=e[0],n=e[1],s=e[2]):e.length===2?typeof e[1]=="object"?(t=!0,n=e[0],s=e[1]):(t=e[0],n=e[1]):(t=!0,n=e[0]);const{target:r=$e,eventName:i="keydown",passive:o=!1,dedupe:l=!1}=s,c=La(t);return Pt(r,i,a=>{a.repeat&&Be(l)||c(a)&&n(a)},o)}function Ia(){const e=oe(!1),t=qn();return t&&Lt(()=>{e.value=!0},t),e}function Na(e){const t=Ia();return ie(()=>(t.value,!!e()))}function Io(e,t={}){const{window:n=$e}=t,s=Na(()=>n&&"matchMedia"in n&&typeof n.matchMedia=="function");let r;const i=oe(!1),o=f=>{i.value=f.matches},l=()=>{r&&("removeEventListener"in r?r.removeEventListener("change",o):r.removeListener(o))},c=Zs(()=>{s.value&&(l(),r=n.matchMedia(Be(e)),"addEventListener"in r?r.addEventListener("change",o):r.addListener(o),i.value=r.matches)});return tr(()=>{c(),l(),r=void 0}),i}const gn=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},mn="__vueuse_ssr_handlers__",Fa=Ha();function Ha(){return mn in gn||(gn[mn]=gn[mn]||{}),gn[mn]}function No(e,t){return Fa[e]||t}function sr(e){return Io("(prefers-color-scheme: dark)",e)}function $a(e){return e==null?"any":e instanceof Set?"set":e instanceof Map?"map":e instanceof Date?"date":typeof e=="boolean"?"boolean":typeof e=="string"?"string":typeof e=="object"?"object":Number.isNaN(e)?"any":"number"}const Da={boolean:{read:e=>e==="true",write:e=>String(e)},object:{read:e=>JSON.parse(e),write:e=>JSON.stringify(e)},number:{read:e=>Number.parseFloat(e),write:e=>String(e)},any:{read:e=>e,write:e=>String(e)},string:{read:e=>e,write:e=>String(e)},map:{read:e=>new Map(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e.entries()))},set:{read:e=>new Set(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e))},date:{read:e=>new Date(e),write:e=>e.toISOString()}},Qr="vueuse-storage";function rr(e,t,n,s={}){var r;const{flush:i="pre",deep:o=!0,listenToStorageChanges:l=!0,writeDefaults:c=!0,mergeDefaults:f=!1,shallow:a,window:h=$e,eventFilter:y,onError:v=b=>{console.error(b)},initOnMounted:S}=s,_=(a?qs:oe)(typeof t=="function"?t():t);if(!n)try{n=No("getDefaultStorage",()=>{var b;return(b=$e)==null?void 0:b.localStorage})()}catch(b){v(b)}if(!n)return _;const K=Be(t),N=$a(K),j=(r=s.serializer)!=null?r:Da[N],{pause:p,resume:g}=Pa(_,()=>F(_.value),{flush:i,deep:o,eventFilter:y});h&&l&&nr(()=>{n instanceof Storage?Pt(h,"storage",V):Pt(h,Qr,R),S&&V()}),S||V();function O(b,I){if(h){const x={key:e,oldValue:b,newValue:I,storageArea:n};h.dispatchEvent(n instanceof Storage?new StorageEvent("storage",x):new CustomEvent(Qr,{detail:x}))}}function F(b){try{const I=n.getItem(e);if(b==null)O(I,null),n.removeItem(e);else{const x=j.write(b);I!==x&&(n.setItem(e,x),O(I,x))}}catch(I){v(I)}}function $(b){const I=b?b.newValue:n.getItem(e);if(I==null)return c&&K!=null&&n.setItem(e,j.write(K)),K;if(!b&&f){const x=j.read(I);return typeof f=="function"?f(x,K):N==="object"&&!Array.isArray(x)?{...K,...x}:x}else return typeof I!="string"?I:j.read(I)}function V(b){if(!(b&&b.storageArea!==n)){if(b&&b.key==null){_.value=K;return}if(!(b&&b.key!==e)){p();try{(b==null?void 0:b.newValue)!==j.write(_.value)&&(_.value=$(b))}catch(I){v(I)}finally{b?Un(g):g()}}}}function R(b){V(b.detail)}return _}const ja="*,*::before,*::after{-webkit-transition:none!important;-moz-transition:none!important;-o-transition:none!important;-ms-transition:none!important;transition:none!important}";function Va(e={}){const{selector:t="html",attribute:n="class",initialValue:s="auto",window:r=$e,storage:i,storageKey:o="vueuse-color-scheme",listenToStorageChanges:l=!0,storageRef:c,emitAuto:f,disableTransition:a=!0}=e,h={auto:"",light:"light",dark:"dark",...e.modes||{}},y=sr({window:r}),v=ie(()=>y.value?"dark":"light"),S=c||(o==null?Mo(s):rr(o,s,i,{window:r,listenToStorageChanges:l})),_=ie(()=>S.value==="auto"?v.value:S.value),K=No("updateHTMLAttrs",(g,O,F)=>{const $=typeof g=="string"?r==null?void 0:r.document.querySelector(g):Lo(g);if(!$)return;const V=new Set,R=new Set;let b=null;if(O==="class"){const x=F.split(/\s/g);Object.values(h).flatMap(B=>(B||"").split(/\s/g)).filter(Boolean).forEach(B=>{x.includes(B)?V.add(B):R.add(B)})}else b={key:O,value:F};if(V.size===0&&R.size===0&&b===null)return;let I;a&&(I=r.document.createElement("style"),I.appendChild(document.createTextNode(ja)),r.document.head.appendChild(I));for(const x of V)$.classList.add(x);for(const x of R)$.classList.remove(x);b&&$.setAttribute(b.key,b.value),a&&(r.getComputedStyle(I).opacity,document.head.removeChild(I))});function N(g){var O;K(t,n,(O=h[g])!=null?O:g)}function j(g){e.onChanged?e.onChanged(g,N):N(g)}Fe(_,j,{flush:"post",immediate:!0}),nr(()=>j(_.value));const p=ie({get(){return f?S.value:_.value},set(g){S.value=g}});try{return Object.assign(p,{store:S,system:v,state:_})}catch{return p}}function Ua(e={}){const{valueDark:t="dark",valueLight:n="",window:s=$e}=e,r=Va({...e,onChanged:(l,c)=>{var f;e.onChanged?(f=e.onChanged)==null||f.call(e,l==="dark",c,l):c(l)},modes:{dark:t,light:n}}),i=ie(()=>r.system?r.system.value:sr({window:s}).value?"dark":"light");return ie({get(){return r.value==="dark"},set(l){const c=l?"dark":"light";i.value===c?r.value="auto":r.value=c}})}function fs(e){return typeof Window<"u"&&e instanceof Window?e.document.documentElement:typeof Document<"u"&&e instanceof Document?e.documentElement:e}function Bf(e,t,n={}){const{window:s=$e}=n;return rr(e,t,s==null?void 0:s.localStorage,n)}function Fo(e){const t=window.getComputedStyle(e);if(t.overflowX==="scroll"||t.overflowY==="scroll"||t.overflowX==="auto"&&e.clientWidth1?!0:(t.preventDefault&&t.preventDefault(),!1)}const us=new WeakMap;function Wf(e,t=!1){const n=oe(t);let s=null,r="";Fe(Mo(e),l=>{const c=fs(Be(l));if(c){const f=c;if(us.get(f)||us.set(f,f.style.overflow),f.style.overflow!=="hidden"&&(r=f.style.overflow),f.style.overflow==="hidden")return n.value=!0;if(n.value)return f.style.overflow="hidden"}},{immediate:!0});const i=()=>{const l=fs(Be(e));!l||n.value||(zr&&(s=Pt(l,"touchmove",c=>{ka(c)},{passive:!1})),l.style.overflow="hidden",n.value=!0)},o=()=>{const l=fs(Be(e));!l||!n.value||(zr&&(s==null||s()),l.style.overflow=r,us.delete(l),n.value=!1)};return tr(o),ie({get(){return n.value},set(l){l?i():o()}})}function Kf(e,t,n={}){const{window:s=$e}=n;return rr(e,t,s==null?void 0:s.sessionStorage,n)}function qf(e={}){const{window:t=$e,behavior:n="auto"}=e;if(!t)return{x:oe(0),y:oe(0)};const s=oe(t.scrollX),r=oe(t.scrollY),i=ie({get(){return s.value},set(l){scrollTo({left:l,behavior:n})}}),o=ie({get(){return r.value},set(l){scrollTo({top:l,behavior:n})}});return Pt(t,"scroll",()=>{s.value=t.scrollX,r.value=t.scrollY},{capture:!1,passive:!0}),{x:i,y:o}}function Gf(e={}){const{window:t=$e,initialWidth:n=Number.POSITIVE_INFINITY,initialHeight:s=Number.POSITIVE_INFINITY,listenOrientation:r=!0,includeScrollbar:i=!0,type:o="inner"}=e,l=oe(n),c=oe(s),f=()=>{t&&(o==="outer"?(l.value=t.outerWidth,c.value=t.outerHeight):i?(l.value=t.innerWidth,c.value=t.innerHeight):(l.value=t.document.documentElement.clientWidth,c.value=t.document.documentElement.clientHeight))};if(f(),nr(f),Pt("resize",f,{passive:!0}),r){const a=Io("(orientation: portrait)");Fe(a,()=>f())}return{width:l,height:c}}const ds={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1};var hs={};const Ho=/^(?:[a-z]+:|\/\/)/i,Ba="vitepress-theme-appearance",Wa=/#.*$/,Ka=/[?#].*$/,qa=/(?:(^|\/)index)?\.(?:md|html)$/,ge=typeof document<"u",$o={relativePath:"404.md",filePath:"",title:"404",description:"Not Found",headers:[],frontmatter:{sidebar:!1,layout:"page"},lastUpdated:0,isNotFound:!0};function Ga(e,t,n=!1){if(t===void 0)return!1;if(e=Zr(`/${e}`),n)return new RegExp(t).test(e);if(Zr(t)!==e)return!1;const s=t.match(Wa);return s?(ge?location.hash:"")===s[0]:!0}function Zr(e){return decodeURI(e).replace(Ka,"").replace(qa,"$1")}function Ya(e){return Ho.test(e)}function Xa(e,t){return Object.keys((e==null?void 0:e.locales)||{}).find(n=>n!=="root"&&!Ya(n)&&Ga(t,`/${n}/`,!0))||"root"}function Ja(e,t){var s,r,i,o,l,c,f;const n=Xa(e,t);return Object.assign({},e,{localeIndex:n,lang:((s=e.locales[n])==null?void 0:s.lang)??e.lang,dir:((r=e.locales[n])==null?void 0:r.dir)??e.dir,title:((i=e.locales[n])==null?void 0:i.title)??e.title,titleTemplate:((o=e.locales[n])==null?void 0:o.titleTemplate)??e.titleTemplate,description:((l=e.locales[n])==null?void 0:l.description)??e.description,head:jo(e.head,((c=e.locales[n])==null?void 0:c.head)??[]),themeConfig:{...e.themeConfig,...(f=e.locales[n])==null?void 0:f.themeConfig}})}function Do(e,t){const n=t.title||e.title,s=t.titleTemplate??e.titleTemplate;if(typeof s=="string"&&s.includes(":title"))return s.replace(/:title/g,n);const r=za(e.title,s);return n===r.slice(3)?n:`${n}${r}`}function za(e,t){return t===!1?"":t===!0||t===void 0?` | ${e}`:e===t?"":` | ${t}`}function Qa(e,t){const[n,s]=t;if(n!=="meta")return!1;const r=Object.entries(s)[0];return r==null?!1:e.some(([i,o])=>i===n&&o[r[0]]===r[1])}function jo(e,t){return[...e.filter(n=>!Qa(t,n)),...t]}const Za=/[\u0000-\u001F"#$&*+,:;<=>?[\]^`{|}\u007F]/g,ef=/^[a-z]:/i;function ei(e){const t=ef.exec(e),n=t?t[0]:"";return n+e.slice(n.length).replace(Za,"_").replace(/(^|\/)_+(?=[^/]*$)/,"$1")}const ps=new Set;function tf(e){if(ps.size===0){const n=typeof process=="object"&&(hs==null?void 0:hs.VITE_EXTRA_EXTENSIONS)||(ds==null?void 0:ds.VITE_EXTRA_EXTENSIONS)||"";("3g2,3gp,aac,ai,apng,au,avif,bin,bmp,cer,class,conf,crl,css,csv,dll,doc,eps,epub,exe,gif,gz,ics,ief,jar,jpe,jpeg,jpg,js,json,jsonld,m4a,man,mid,midi,mjs,mov,mp2,mp3,mp4,mpe,mpeg,mpg,mpp,oga,ogg,ogv,ogx,opus,otf,p10,p7c,p7m,p7s,pdf,png,ps,qt,roff,rtf,rtx,ser,svg,t,tif,tiff,tr,ts,tsv,ttf,txt,vtt,wav,weba,webm,webp,woff,woff2,xhtml,xml,yaml,yml,zip"+(n&&typeof n=="string"?","+n:"")).split(",").forEach(s=>ps.add(s))}const t=e.split(".").pop();return t==null||!ps.has(t.toLowerCase())}function Yf(e){return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}const nf=Symbol(),mt=qs(xa);function Xf(e){const t=ie(()=>Ja(mt.value,e.data.relativePath)),n=t.value.appearance,s=n==="force-dark"?oe(!0):n==="force-auto"?sr():n?Ua({storageKey:Ba,initialValue:()=>n==="dark"?"dark":"auto",...typeof n=="object"?n:{}}):oe(!1),r=oe(ge?location.hash:"");return ge&&window.addEventListener("hashchange",()=>{r.value=location.hash}),Fe(()=>e.data,()=>{r.value=ge?location.hash:""}),{site:t,theme:ie(()=>t.value.themeConfig),page:ie(()=>e.data),frontmatter:ie(()=>e.data.frontmatter),params:ie(()=>e.data.params),lang:ie(()=>t.value.lang),dir:ie(()=>e.data.frontmatter.dir||t.value.dir),localeIndex:ie(()=>t.value.localeIndex||"root"),title:ie(()=>Do(t.value,e.data)),description:ie(()=>e.data.description||t.value.description),isDark:s,hash:ie(()=>r.value)}}function sf(){const e=Ot(nf);if(!e)throw new Error("vitepress data not properly injected in app");return e}function rf(e,t){return`${e}${t}`.replace(/\/+/g,"/")}function ti(e){return Ho.test(e)||!e.startsWith("/")?e:rf(mt.value.base,e)}function of(e){let t=e.replace(/\.html$/,"");if(t=decodeURIComponent(t),t=t.replace(/\/$/,"/index"),ge){const n="/";t=ei(t.slice(n.length).replace(/\//g,"_")||"index")+".md";let s=__VP_HASH_MAP__[t.toLowerCase()];if(s||(t=t.endsWith("_index.md")?t.slice(0,-9)+".md":t.slice(0,-3)+"_index.md",s=__VP_HASH_MAP__[t.toLowerCase()]),!s)return null;t=`${n}assets/${t}.${s}.js`}else t=`./${ei(t.slice(1).replace(/\//g,"_"))}.md.js`;return t}let Tn=[];function Jf(e){Tn.push(e),Bn(()=>{Tn=Tn.filter(t=>t!==e)})}function lf(){let e=mt.value.scrollOffset,t=0,n=24;if(typeof e=="object"&&"padding"in e&&(n=e.padding,e=e.selector),typeof e=="number")t=e;else if(typeof e=="string")t=ni(e,n);else if(Array.isArray(e))for(const s of e){const r=ni(s,n);if(r){t=r;break}}return t}function ni(e,t){const n=document.querySelector(e);if(!n)return 0;const s=n.getBoundingClientRect().bottom;return s<0?0:s+t}const cf=Symbol(),Vo="http://a.com",af=()=>({path:"/",component:null,data:$o});function zf(e,t){const n=jn(af()),s={route:n,go:r};async function r(l=ge?location.href:"/"){var c,f;l=gs(l),await((c=s.onBeforeRouteChange)==null?void 0:c.call(s,l))!==!1&&(ge&&l!==gs(location.href)&&(history.replaceState({scrollPosition:window.scrollY},""),history.pushState({},"",l)),await o(l),await((f=s.onAfterRouteChanged)==null?void 0:f.call(s,l)))}let i=null;async function o(l,c=0,f=!1){var y,v;if(await((y=s.onBeforePageLoad)==null?void 0:y.call(s,l))===!1)return;const a=new URL(l,Vo),h=i=a.pathname;try{let S=await e(h);if(!S)throw new Error(`Page not found: ${h}`);if(i===h){i=null;const{default:_,__pageData:K}=S;if(!_)throw new Error(`Invalid route component: ${_}`);await((v=s.onAfterPageLoad)==null?void 0:v.call(s,l)),n.path=ge?h:ti(h),n.component=wn(_),n.data=wn(K),ge&&Un(()=>{let N=mt.value.base+K.relativePath.replace(/(?:(^|\/)index)?\.md$/,"$1");if(!mt.value.cleanUrls&&!N.endsWith("/")&&(N+=".html"),N!==a.pathname&&(a.pathname=N,l=N+a.search+a.hash,history.replaceState({},"",l)),a.hash&&!c){let j=null;try{j=document.getElementById(decodeURIComponent(a.hash).slice(1))}catch(p){console.warn(p)}if(j){si(j,a.hash);return}}window.scrollTo(0,c)})}}catch(S){if(!/fetch|Page not found/.test(S.message)&&!/^\/404(\.html|\/)?$/.test(l)&&console.error(S),!f)try{const _=await fetch(mt.value.base+"hashmap.json");window.__VP_HASH_MAP__=await _.json(),await o(l,c,!0);return}catch{}if(i===h){i=null,n.path=ge?h:ti(h),n.component=t?wn(t):null;const _=ge?h.replace(/(^|\/)$/,"$1index").replace(/(\.html)?$/,".md").replace(/^\//,""):"404.md";n.data={...$o,relativePath:_}}}}return ge&&(history.state===null&&history.replaceState({},""),window.addEventListener("click",l=>{if(l.defaultPrevented||!(l.target instanceof Element)||l.target.closest("button")||l.button!==0||l.ctrlKey||l.shiftKey||l.altKey||l.metaKey)return;const c=l.target.closest("a");if(!c||c.closest(".vp-raw")||c.hasAttribute("download")||c.hasAttribute("target"))return;const f=c.getAttribute("href")??(c instanceof SVGAElement?c.getAttribute("xlink:href"):null);if(f==null)return;const{href:a,origin:h,pathname:y,hash:v,search:S}=new URL(f,c.baseURI),_=new URL(location.href);h===_.origin&&tf(y)&&(l.preventDefault(),y===_.pathname&&S===_.search?(v!==_.hash&&(history.pushState({},"",a),window.dispatchEvent(new HashChangeEvent("hashchange",{oldURL:_.href,newURL:a}))),v?si(c,v,c.classList.contains("header-anchor")):window.scrollTo(0,0)):r(a))},{capture:!0}),window.addEventListener("popstate",async l=>{var c;l.state!==null&&(await o(gs(location.href),l.state&&l.state.scrollPosition||0),(c=s.onAfterRouteChanged)==null||c.call(s,location.href))}),window.addEventListener("hashchange",l=>{l.preventDefault()})),s}function ff(){const e=Ot(cf);if(!e)throw new Error("useRouter() is called without provider.");return e}function Uo(){return ff().route}function si(e,t,n=!1){let s=null;try{s=e.classList.contains("header-anchor")?e:document.getElementById(decodeURIComponent(t).slice(1))}catch(r){console.warn(r)}if(s){let r=function(){!n||Math.abs(o-window.scrollY)>window.innerHeight?window.scrollTo(0,o):window.scrollTo({left:0,top:o,behavior:"smooth"})};const i=parseInt(window.getComputedStyle(s).paddingTop,10),o=window.scrollY+s.getBoundingClientRect().top-lf()+i;requestAnimationFrame(r)}}function gs(e){const t=new URL(e,Vo);return t.pathname=t.pathname.replace(/(^|\/)index(\.html)?$/,"$1"),mt.value.cleanUrls?t.pathname=t.pathname.replace(/\.html$/,""):!t.pathname.endsWith("/")&&!t.pathname.endsWith(".html")&&(t.pathname+=".html"),t.pathname+t.search+t.hash}const yn=()=>Tn.forEach(e=>e()),Qf=Ys({name:"VitePressContent",props:{as:{type:[Object,String],default:"div"}},setup(e){const t=Uo(),{frontmatter:n,site:s}=sf();return Fe(n,yn,{deep:!0,flush:"post"}),()=>Ls(e.as,s.value.contentProps??{style:{position:"relative"}},[t.component?Ls(t.component,{onVnodeMounted:yn,onVnodeUpdated:yn,onVnodeUnmounted:yn}):"404 Page Not Found"])}}),uf="modulepreload",df=function(e){return"/"+e},ri={},Zf=function(t,n,s){let r=Promise.resolve();if(n&&n.length>0){document.getElementsByTagName("link");const o=document.querySelector("meta[property=csp-nonce]"),l=(o==null?void 0:o.nonce)||(o==null?void 0:o.getAttribute("nonce"));r=Promise.allSettled(n.map(c=>{if(c=df(c),c in ri)return;ri[c]=!0;const f=c.endsWith(".css"),a=f?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${c}"]${a}`))return;const h=document.createElement("link");if(h.rel=f?"stylesheet":uf,f||(h.as="script"),h.crossOrigin="",h.href=c,l&&h.setAttribute("nonce",l),document.head.appendChild(h),f)return new Promise((y,v)=>{h.addEventListener("load",y),h.addEventListener("error",()=>v(new Error(`Unable to preload CSS for ${c}`)))})}))}function i(o){const l=new Event("vite:preloadError",{cancelable:!0});if(l.payload=o,window.dispatchEvent(l),!l.defaultPrevented)throw o}return r.then(o=>{for(const l of o||[])l.status==="rejected"&&i(l.reason);return t().catch(i)})},eu=Ys({setup(e,{slots:t}){const n=oe(!1);return Lt(()=>{n.value=!0}),()=>n.value&&t.default?t.default():null}});function tu(){ge&&window.addEventListener("click",e=>{var n;const t=e.target;if(t.matches(".vp-code-group input")){const s=(n=t.parentElement)==null?void 0:n.parentElement;if(!s)return;const r=Array.from(s.querySelectorAll("input")).indexOf(t);if(r<0)return;const i=s.querySelector(".blocks");if(!i)return;const o=Array.from(i.children).find(f=>f.classList.contains("active"));if(!o)return;const l=i.children[r];if(!l||o===l)return;o.classList.remove("active"),l.classList.add("active");const c=s==null?void 0:s.querySelector(`label[for="${t.id}"]`);c==null||c.scrollIntoView({block:"nearest"})}})}function nu(){if(ge){const e=new WeakMap;window.addEventListener("click",t=>{var s;const n=t.target;if(n.matches('div[class*="language-"] > button.copy')){const r=n.parentElement,i=(s=n.nextElementSibling)==null?void 0:s.nextElementSibling;if(!r||!i)return;const o=/language-(shellscript|shell|bash|sh|zsh)/.test(r.className),l=[".vp-copy-ignore",".diff.remove"],c=i.cloneNode(!0);c.querySelectorAll(l.join(",")).forEach(a=>a.remove());let f=c.textContent||"";o&&(f=f.replace(/^ *(\$|>) /gm,"").trim()),hf(f).then(()=>{n.classList.add("copied"),clearTimeout(e.get(n));const a=setTimeout(()=>{n.classList.remove("copied"),n.blur(),e.delete(n)},2e3);e.set(n,a)})}})}}async function hf(e){try{return navigator.clipboard.writeText(e)}catch{const t=document.createElement("textarea"),n=document.activeElement;t.value=e,t.setAttribute("readonly",""),t.style.contain="strict",t.style.position="absolute",t.style.left="-9999px",t.style.fontSize="12pt";const s=document.getSelection(),r=s?s.rangeCount>0&&s.getRangeAt(0):null;document.body.appendChild(t),t.select(),t.selectionStart=0,t.selectionEnd=e.length,document.execCommand("copy"),document.body.removeChild(t),r&&(s.removeAllRanges(),s.addRange(r)),n&&n.focus()}}function su(e,t){let n=!0,s=[];const r=i=>{if(n){n=!1,i.forEach(l=>{const c=ms(l);for(const f of document.head.children)if(f.isEqualNode(c)){s.push(f);return}});return}const o=i.map(ms);s.forEach((l,c)=>{const f=o.findIndex(a=>a==null?void 0:a.isEqualNode(l??null));f!==-1?delete o[f]:(l==null||l.remove(),delete s[c])}),o.forEach(l=>l&&document.head.appendChild(l)),s=[...s,...o].filter(Boolean)};Zs(()=>{const i=e.data,o=t.value,l=i&&i.description,c=i&&i.frontmatter.head||[],f=Do(o,i);f!==document.title&&(document.title=f);const a=l||o.description;let h=document.querySelector("meta[name=description]");h?h.getAttribute("content")!==a&&h.setAttribute("content",a):ms(["meta",{name:"description",content:a}]),r(jo(o.head,gf(c)))})}function ms([e,t,n]){const s=document.createElement(e);for(const r in t)s.setAttribute(r,t[r]);return n&&(s.innerHTML=n),e==="script"&&t.async==null&&(s.async=!1),s}function pf(e){return e[0]==="meta"&&e[1]&&e[1].name==="description"}function gf(e){return e.filter(t=>!pf(t))}const ys=new Set,ko=()=>document.createElement("link"),mf=e=>{const t=ko();t.rel="prefetch",t.href=e,document.head.appendChild(t)},yf=e=>{const t=new XMLHttpRequest;t.open("GET",e,t.withCredentials=!0),t.send()};let vn;const vf=ge&&(vn=ko())&&vn.relList&&vn.relList.supports&&vn.relList.supports("prefetch")?mf:yf;function ru(){if(!ge||!window.IntersectionObserver)return;let e;if((e=navigator.connection)&&(e.saveData||/2g/.test(e.effectiveType)))return;const t=window.requestIdleCallback||setTimeout;let n=null;const s=()=>{n&&n.disconnect(),n=new IntersectionObserver(i=>{i.forEach(o=>{if(o.isIntersecting){const l=o.target;n.unobserve(l);const{pathname:c}=l;if(!ys.has(c)){ys.add(c);const f=of(c);f&&vf(f)}}})}),t(()=>{document.querySelectorAll("#app a").forEach(i=>{const{hostname:o,pathname:l}=new URL(i.href instanceof SVGAnimatedString?i.href.animVal:i.href,i.baseURI),c=l.match(/\.\w+$/);c&&c[0]!==".html"||i.target!=="_blank"&&o===location.hostname&&(l!==location.pathname?n.observe(i):ys.add(l))})})};Lt(s);const r=Uo();Fe(()=>r.path,s),Bn(()=>{n&&n.disconnect()})}export{Ki as $,lf as A,Sf as B,Ef as C,qs as D,Jf as E,xe as F,ce as G,xf as H,Ho as I,Uo as J,$c as K,Ot as L,Gf as M,Ds as N,kf as O,Un as P,qf as Q,ge as R,Vn as S,Lf as T,wf as U,Zf as V,Wf as W,mc as X,Ff as Y,Cf as Z,Df as _,_o as a,Nf as a0,Af as a1,Mf as a2,Ls as a3,su as a4,cf as a5,Xf as a6,nf as a7,Qf as a8,eu as a9,mt as aa,$f as ab,zf as ac,of as ad,ru as ae,nu as af,tu as ag,Be as ah,Lo as ai,jf as aj,tr as ak,Uf as al,Kf as am,Bf as an,Vf as ao,ff as ap,Pt as aq,_f as ar,If as as,fe as at,bf as au,wn as av,Hf as aw,Yf as ax,Ms as b,Of as c,Ys as d,Pf as e,tf as f,ti as g,ie as h,Ya as i,vo as j,Oi as k,Ga as l,Io as m,js as n,Os as o,oe as p,Fe as q,Tf as r,Zs as s,sl as t,sf as u,Lt as v,Ul as w,Bn as x,Rf as y,nc as z}; diff --git a/assets/chunks/theme.CNpb5bEr.js b/assets/chunks/theme.CNpb5bEr.js new file mode 100644 index 0000000..69c79df --- /dev/null +++ b/assets/chunks/theme.CNpb5bEr.js @@ -0,0 +1,2 @@ +const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/chunks/VPLocalSearchBox.C23CuZ30.js","assets/chunks/framework.CoXjB5sU.js"])))=>i.map(i=>d[i]); +import{d as _,o as a,c as u,r as c,n as w,a as E,t as M,b as k,w as p,e as m,T as ue,_ as g,u as De,i as Oe,f as Ge,g as de,h as y,j as d,k as r,l as q,m as ae,p as T,q as O,s as X,v as z,x as ve,y as pe,z as Ue,A as je,B as K,F as I,C,D as Ve,E as Q,G as h,H as F,I as Se,J as Z,K as j,L as x,M as ze,N as Te,O as re,P as Ne,Q as we,R as ee,S as qe,U as Ke,V as We,W as Me,X as Ie,Y as Re,Z as Je,$ as Ye,a0 as Xe,a1 as Qe,a2 as Ze,a3 as ge}from"./framework.CoXjB5sU.js";const xe=_({__name:"VPBadge",props:{text:{},type:{default:"tip"}},setup(o){return(e,t)=>(a(),u("span",{class:w(["VPBadge",e.type])},[c(e.$slots,"default",{},()=>[E(M(e.text),1)])],2))}}),et={key:0,class:"VPBackdrop"},tt=_({__name:"VPBackdrop",props:{show:{type:Boolean}},setup(o){return(e,t)=>(a(),k(ue,{name:"fade"},{default:p(()=>[e.show?(a(),u("div",et)):m("",!0)]),_:1}))}}),nt=g(tt,[["__scopeId","data-v-2bf0c4a0"]]),L=De;function st(o,e){let t,s=!1;return()=>{t&&clearTimeout(t),s?t=setTimeout(o,e):(o(),(s=!0)&&setTimeout(()=>s=!1,e))}}function ie(o){return/^\//.test(o)?o:`/${o}`}function fe(o){const{pathname:e,search:t,hash:s,protocol:n}=new URL(o,"http://a.com");if(Oe(o)||o.startsWith("#")||!n.startsWith("http")||!Ge(e))return o;const{site:i}=L(),l=e.endsWith("/")||e.endsWith(".html")?o:o.replace(/(?:(^\.+)\/)?.*$/,`$1${e.replace(/(\.md)?$/,i.value.cleanUrls?"":".html")}${t}${s}`);return de(l)}function R({correspondingLink:o=!1}={}){const{site:e,localeIndex:t,page:s,theme:n,hash:i}=L(),l=y(()=>{var v,$;return{label:(v=e.value.locales[t.value])==null?void 0:v.label,link:(($=e.value.locales[t.value])==null?void 0:$.link)||(t.value==="root"?"/":`/${t.value}/`)}});return{localeLinks:y(()=>Object.entries(e.value.locales).flatMap(([v,$])=>l.value.label===$.label?[]:{text:$.label,link:ot($.link||(v==="root"?"/":`/${v}/`),n.value.i18nRouting!==!1&&o,s.value.relativePath.slice(l.value.link.length-1),!e.value.cleanUrls)+i.value})),currentLang:l}}function ot(o,e,t,s){return e?o.replace(/\/$/,"")+ie(t.replace(/(^|\/)index\.md$/,"$1").replace(/\.md$/,s?".html":"")):o}const at={class:"NotFound"},rt={class:"code"},it={class:"title"},lt={class:"quote"},ct={class:"action"},ut=["href","aria-label"],dt=_({__name:"NotFound",setup(o){const{theme:e}=L(),{currentLang:t}=R();return(s,n)=>{var i,l,f,v,$;return a(),u("div",at,[d("p",rt,M(((i=r(e).notFound)==null?void 0:i.code)??"404"),1),d("h1",it,M(((l=r(e).notFound)==null?void 0:l.title)??"PAGE NOT FOUND"),1),n[0]||(n[0]=d("div",{class:"divider"},null,-1)),d("blockquote",lt,M(((f=r(e).notFound)==null?void 0:f.quote)??"But if you don't change your direction, and if you keep looking, you may end up where you are heading."),1),d("div",ct,[d("a",{class:"link",href:r(de)(r(t).link),"aria-label":((v=r(e).notFound)==null?void 0:v.linkLabel)??"go to home"},M((($=r(e).notFound)==null?void 0:$.linkText)??"Take me home"),9,ut)])])}}}),vt=g(dt,[["__scopeId","data-v-a5285cbb"]]);function Ae(o,e){if(Array.isArray(o))return J(o);if(o==null)return[];e=ie(e);const t=Object.keys(o).sort((n,i)=>i.split("/").length-n.split("/").length).find(n=>e.startsWith(ie(n))),s=t?o[t]:[];return Array.isArray(s)?J(s):J(s.items,s.base)}function pt(o){const e=[];let t=0;for(const s in o){const n=o[s];if(n.items){t=e.push(n);continue}e[t]||e.push({items:[]}),e[t].items.push(n)}return e}function ft(o){const e=[];function t(s){for(const n of s)n.text&&n.link&&e.push({text:n.text,link:n.link,docFooterText:n.docFooterText}),n.items&&t(n.items)}return t(o),e}function le(o,e){return Array.isArray(e)?e.some(t=>le(o,t)):q(o,e.link)?!0:e.items?le(o,e.items):!1}function J(o,e){return[...o].map(t=>{const s={...t},n=s.base||e;return n&&s.link&&(s.link=n+s.link),s.items&&(s.items=J(s.items,n)),s})}function G(){const{frontmatter:o,page:e,theme:t}=L(),s=ae("(min-width: 960px)"),n=T(!1),i=y(()=>{const H=t.value.sidebar,S=e.value.relativePath;return H?Ae(H,S):[]}),l=T(i.value);O(i,(H,S)=>{JSON.stringify(H)!==JSON.stringify(S)&&(l.value=i.value)});const f=y(()=>o.value.sidebar!==!1&&l.value.length>0&&o.value.layout!=="home"),v=y(()=>$?o.value.aside==null?t.value.aside==="left":o.value.aside==="left":!1),$=y(()=>o.value.layout==="home"?!1:o.value.aside!=null?!!o.value.aside:t.value.aside!==!1),V=y(()=>f.value&&s.value),b=y(()=>f.value?pt(l.value):[]);function P(){n.value=!0}function N(){n.value=!1}function A(){n.value?N():P()}return{isOpen:n,sidebar:l,sidebarGroups:b,hasSidebar:f,hasAside:$,leftAside:v,isSidebarEnabled:V,open:P,close:N,toggle:A}}function ht(o,e){let t;X(()=>{t=o.value?document.activeElement:void 0}),z(()=>{window.addEventListener("keyup",s)}),ve(()=>{window.removeEventListener("keyup",s)});function s(n){n.key==="Escape"&&o.value&&(e(),t==null||t.focus())}}function mt(o){const{page:e,hash:t}=L(),s=T(!1),n=y(()=>o.value.collapsed!=null),i=y(()=>!!o.value.link),l=T(!1),f=()=>{l.value=q(e.value.relativePath,o.value.link)};O([e,o,t],f),z(f);const v=y(()=>l.value?!0:o.value.items?le(e.value.relativePath,o.value.items):!1),$=y(()=>!!(o.value.items&&o.value.items.length));X(()=>{s.value=!!(n.value&&o.value.collapsed)}),pe(()=>{(l.value||v.value)&&(s.value=!1)});function V(){n.value&&(s.value=!s.value)}return{collapsed:s,collapsible:n,isLink:i,isActiveLink:l,hasActiveLink:v,hasChildren:$,toggle:V}}function _t(){const{hasSidebar:o}=G(),e=ae("(min-width: 960px)"),t=ae("(min-width: 1280px)");return{isAsideEnabled:y(()=>!t.value&&!e.value?!1:o.value?t.value:e.value)}}const ce=[];function He(o){return typeof o.outline=="object"&&!Array.isArray(o.outline)&&o.outline.label||o.outlineTitle||"On this page"}function he(o){const e=[...document.querySelectorAll(".VPDoc :where(h1,h2,h3,h4,h5,h6)")].filter(t=>t.id&&t.hasChildNodes()).map(t=>{const s=Number(t.tagName[1]);return{element:t,title:kt(t),link:"#"+t.id,level:s}});return bt(e,o)}function kt(o){let e="";for(const t of o.childNodes)if(t.nodeType===1){if(t.classList.contains("VPBadge")||t.classList.contains("header-anchor")||t.classList.contains("ignore-header"))continue;e+=t.textContent}else t.nodeType===3&&(e+=t.textContent);return e.trim()}function bt(o,e){if(e===!1)return[];const t=(typeof e=="object"&&!Array.isArray(e)?e.level:e)||2,[s,n]=typeof t=="number"?[t,t]:t==="deep"?[2,6]:t;return yt(o,s,n)}function gt(o,e){const{isAsideEnabled:t}=_t(),s=st(i,100);let n=null;z(()=>{requestAnimationFrame(i),window.addEventListener("scroll",s)}),Ue(()=>{l(location.hash)}),ve(()=>{window.removeEventListener("scroll",s)});function i(){if(!t.value)return;const f=window.scrollY,v=window.innerHeight,$=document.body.offsetHeight,V=Math.abs(f+v-$)<1,b=ce.map(({element:N,link:A})=>({link:A,top:$t(N)})).filter(({top:N})=>!Number.isNaN(N)).sort((N,A)=>N.top-A.top);if(!b.length){l(null);return}if(f<1){l(null);return}if(V){l(b[b.length-1].link);return}let P=null;for(const{link:N,top:A}of b){if(A>f+je()+4)break;P=N}l(P)}function l(f){n&&n.classList.remove("active"),f==null?n=null:n=o.value.querySelector(`a[href="${decodeURIComponent(f)}"]`);const v=n;v?(v.classList.add("active"),e.value.style.top=v.offsetTop+39+"px",e.value.style.opacity="1"):(e.value.style.top="33px",e.value.style.opacity="0")}}function $t(o){let e=0;for(;o!==document.body;){if(o===null)return NaN;e+=o.offsetTop,o=o.offsetParent}return e}function yt(o,e,t){ce.length=0;const s=[],n=[];return o.forEach(i=>{const l={...i,children:[]};let f=n[n.length-1];for(;f&&f.level>=l.level;)n.pop(),f=n[n.length-1];if(l.element.classList.contains("ignore-header")||f&&"shouldIgnore"in f){n.push({level:l.level,shouldIgnore:!0});return}l.level>t||l.level{const n=K("VPDocOutlineItem",!0);return a(),u("ul",{class:w(["VPDocOutlineItem",t.root?"root":"nested"])},[(a(!0),u(I,null,C(t.headers,({children:i,link:l,title:f})=>(a(),u("li",null,[d("a",{class:"outline-link",href:l,onClick:e,title:f},M(f),9,Pt),i!=null&&i.length?(a(),k(n,{key:0,headers:i},null,8,["headers"])):m("",!0)]))),256))],2)}}}),Ce=g(Lt,[["__scopeId","data-v-6fc04da0"]]),Vt={class:"content"},St={"aria-level":"2",class:"outline-title",id:"doc-outline-aria-label",role:"heading"},Tt=_({__name:"VPDocAsideOutline",setup(o){const{frontmatter:e,theme:t}=L(),s=Ve([]);Q(()=>{s.value=he(e.value.outline??t.value.outline)});const n=T(),i=T();return gt(n,i),(l,f)=>(a(),u("nav",{"aria-labelledby":"doc-outline-aria-label",class:w(["VPDocAsideOutline",{"has-outline":s.value.length>0}]),ref_key:"container",ref:n},[d("div",Vt,[d("div",{class:"outline-marker",ref_key:"marker",ref:i},null,512),d("div",St,M(r(He)(r(t))),1),h(Ce,{headers:s.value,root:!0},null,8,["headers"])])],2))}}),Nt=g(Tt,[["__scopeId","data-v-0c0cedaf"]]),wt={class:"VPDocAsideCarbonAds"},Mt=_({__name:"VPDocAsideCarbonAds",props:{carbonAds:{}},setup(o){const e=()=>null;return(t,s)=>(a(),u("div",wt,[h(r(e),{"carbon-ads":t.carbonAds},null,8,["carbon-ads"])]))}}),It={class:"VPDocAside"},At=_({__name:"VPDocAside",setup(o){const{theme:e}=L();return(t,s)=>(a(),u("div",It,[c(t.$slots,"aside-top",{},void 0,!0),c(t.$slots,"aside-outline-before",{},void 0,!0),h(Nt),c(t.$slots,"aside-outline-after",{},void 0,!0),s[0]||(s[0]=d("div",{class:"spacer"},null,-1)),c(t.$slots,"aside-ads-before",{},void 0,!0),r(e).carbonAds?(a(),k(Mt,{key:0,"carbon-ads":r(e).carbonAds},null,8,["carbon-ads"])):m("",!0),c(t.$slots,"aside-ads-after",{},void 0,!0),c(t.$slots,"aside-bottom",{},void 0,!0)]))}}),Ht=g(At,[["__scopeId","data-v-1a813d93"]]);function Ct(){const{theme:o,page:e}=L();return y(()=>{const{text:t="Edit this page",pattern:s=""}=o.value.editLink||{};let n;return typeof s=="function"?n=s(e.value):n=s.replace(/:path/g,e.value.filePath),{url:n,text:t}})}function Bt(){const{page:o,theme:e,frontmatter:t}=L();return y(()=>{var $,V,b,P,N,A,H,S;const s=Ae(e.value.sidebar,o.value.relativePath),n=ft(s),i=Et(n,B=>B.link.replace(/[?#].*$/,"")),l=i.findIndex(B=>q(o.value.relativePath,B.link)),f=(($=e.value.docFooter)==null?void 0:$.prev)===!1&&!t.value.prev||t.value.prev===!1,v=((V=e.value.docFooter)==null?void 0:V.next)===!1&&!t.value.next||t.value.next===!1;return{prev:f?void 0:{text:(typeof t.value.prev=="string"?t.value.prev:typeof t.value.prev=="object"?t.value.prev.text:void 0)??((b=i[l-1])==null?void 0:b.docFooterText)??((P=i[l-1])==null?void 0:P.text),link:(typeof t.value.prev=="object"?t.value.prev.link:void 0)??((N=i[l-1])==null?void 0:N.link)},next:v?void 0:{text:(typeof t.value.next=="string"?t.value.next:typeof t.value.next=="object"?t.value.next.text:void 0)??((A=i[l+1])==null?void 0:A.docFooterText)??((H=i[l+1])==null?void 0:H.text),link:(typeof t.value.next=="object"?t.value.next.link:void 0)??((S=i[l+1])==null?void 0:S.link)}}})}function Et(o,e){const t=new Set;return o.filter(s=>{const n=e(s);return t.has(n)?!1:t.add(n)})}const D=_({__name:"VPLink",props:{tag:{},href:{},noIcon:{type:Boolean},target:{},rel:{}},setup(o){const e=o,t=y(()=>e.tag??(e.href?"a":"span")),s=y(()=>e.href&&Se.test(e.href)||e.target==="_blank");return(n,i)=>(a(),k(F(t.value),{class:w(["VPLink",{link:n.href,"vp-external-link-icon":s.value,"no-icon":n.noIcon}]),href:n.href?r(fe)(n.href):void 0,target:n.target??(s.value?"_blank":void 0),rel:n.rel??(s.value?"noreferrer":void 0)},{default:p(()=>[c(n.$slots,"default")]),_:3},8,["class","href","target","rel"]))}}),Ft={class:"VPLastUpdated"},Dt=["datetime"],Ot=_({__name:"VPDocFooterLastUpdated",setup(o){const{theme:e,page:t,lang:s}=L(),n=y(()=>new Date(t.value.lastUpdated)),i=y(()=>n.value.toISOString()),l=T("");return z(()=>{X(()=>{var f,v,$;l.value=new Intl.DateTimeFormat((v=(f=e.value.lastUpdated)==null?void 0:f.formatOptions)!=null&&v.forceLocale?s.value:void 0,(($=e.value.lastUpdated)==null?void 0:$.formatOptions)??{dateStyle:"short",timeStyle:"short"}).format(n.value)})}),(f,v)=>{var $;return a(),u("p",Ft,[E(M((($=r(e).lastUpdated)==null?void 0:$.text)||r(e).lastUpdatedText||"Last updated")+": ",1),d("time",{datetime:i.value},M(l.value),9,Dt)])}}}),Gt=g(Ot,[["__scopeId","data-v-6cdca359"]]),Ut={key:0,class:"VPDocFooter"},jt={key:0,class:"edit-info"},zt={key:0,class:"edit-link"},qt={key:1,class:"last-updated"},Kt={key:1,class:"prev-next","aria-labelledby":"doc-footer-aria-label"},Wt={class:"pager"},Rt=["innerHTML"],Jt=["innerHTML"],Yt={class:"pager"},Xt=["innerHTML"],Qt=["innerHTML"],Zt=_({__name:"VPDocFooter",setup(o){const{theme:e,page:t,frontmatter:s}=L(),n=Ct(),i=Bt(),l=y(()=>e.value.editLink&&s.value.editLink!==!1),f=y(()=>t.value.lastUpdated),v=y(()=>l.value||f.value||i.value.prev||i.value.next);return($,V)=>{var b,P,N,A;return v.value?(a(),u("footer",Ut,[c($.$slots,"doc-footer-before",{},void 0,!0),l.value||f.value?(a(),u("div",jt,[l.value?(a(),u("div",zt,[h(D,{class:"edit-link-button",href:r(n).url,"no-icon":!0},{default:p(()=>[V[0]||(V[0]=d("span",{class:"vpi-square-pen edit-link-icon"},null,-1)),E(" "+M(r(n).text),1)]),_:1},8,["href"])])):m("",!0),f.value?(a(),u("div",qt,[h(Gt)])):m("",!0)])):m("",!0),(b=r(i).prev)!=null&&b.link||(P=r(i).next)!=null&&P.link?(a(),u("nav",Kt,[V[1]||(V[1]=d("span",{class:"visually-hidden",id:"doc-footer-aria-label"},"Pager",-1)),d("div",Wt,[(N=r(i).prev)!=null&&N.link?(a(),k(D,{key:0,class:"pager-link prev",href:r(i).prev.link},{default:p(()=>{var H;return[d("span",{class:"desc",innerHTML:((H=r(e).docFooter)==null?void 0:H.prev)||"Previous page"},null,8,Rt),d("span",{class:"title",innerHTML:r(i).prev.text},null,8,Jt)]}),_:1},8,["href"])):m("",!0)]),d("div",Yt,[(A=r(i).next)!=null&&A.link?(a(),k(D,{key:0,class:"pager-link next",href:r(i).next.link},{default:p(()=>{var H;return[d("span",{class:"desc",innerHTML:((H=r(e).docFooter)==null?void 0:H.next)||"Next page"},null,8,Xt),d("span",{class:"title",innerHTML:r(i).next.text},null,8,Qt)]}),_:1},8,["href"])):m("",!0)])])):m("",!0)])):m("",!0)}}}),xt=g(Zt,[["__scopeId","data-v-623a8dfe"]]),en={class:"container"},tn={class:"aside-container"},nn={class:"aside-content"},sn={class:"content"},on={class:"content-container"},an={class:"main"},rn=_({__name:"VPDoc",setup(o){const{theme:e}=L(),t=Z(),{hasSidebar:s,hasAside:n,leftAside:i}=G(),l=y(()=>t.path.replace(/[./]+/g,"_").replace(/_html$/,""));return(f,v)=>{const $=K("Content");return a(),u("div",{class:w(["VPDoc",{"has-sidebar":r(s),"has-aside":r(n)}])},[c(f.$slots,"doc-top",{},void 0,!0),d("div",en,[r(n)?(a(),u("div",{key:0,class:w(["aside",{"left-aside":r(i)}])},[v[0]||(v[0]=d("div",{class:"aside-curtain"},null,-1)),d("div",tn,[d("div",nn,[h(Ht,null,{"aside-top":p(()=>[c(f.$slots,"aside-top",{},void 0,!0)]),"aside-bottom":p(()=>[c(f.$slots,"aside-bottom",{},void 0,!0)]),"aside-outline-before":p(()=>[c(f.$slots,"aside-outline-before",{},void 0,!0)]),"aside-outline-after":p(()=>[c(f.$slots,"aside-outline-after",{},void 0,!0)]),"aside-ads-before":p(()=>[c(f.$slots,"aside-ads-before",{},void 0,!0)]),"aside-ads-after":p(()=>[c(f.$slots,"aside-ads-after",{},void 0,!0)]),_:3})])])],2)):m("",!0),d("div",sn,[d("div",on,[c(f.$slots,"doc-before",{},void 0,!0),d("main",an,[h($,{class:w(["vp-doc",[l.value,r(e).externalLinkIcon&&"external-link-icon-enabled"]])},null,8,["class"])]),h(xt,null,{"doc-footer-before":p(()=>[c(f.$slots,"doc-footer-before",{},void 0,!0)]),_:3}),c(f.$slots,"doc-after",{},void 0,!0)])])]),c(f.$slots,"doc-bottom",{},void 0,!0)],2)}}}),ln=g(rn,[["__scopeId","data-v-dd7190e0"]]),cn=_({__name:"VPButton",props:{tag:{},size:{default:"medium"},theme:{default:"brand"},text:{},href:{},target:{},rel:{}},setup(o){const e=o,t=y(()=>e.href&&Se.test(e.href)),s=y(()=>e.tag||(e.href?"a":"button"));return(n,i)=>(a(),k(F(s.value),{class:w(["VPButton",[n.size,n.theme]]),href:n.href?r(fe)(n.href):void 0,target:e.target??(t.value?"_blank":void 0),rel:e.rel??(t.value?"noreferrer":void 0)},{default:p(()=>[E(M(n.text),1)]),_:1},8,["class","href","target","rel"]))}}),un=g(cn,[["__scopeId","data-v-48d0230e"]]),dn=["src","alt"],vn=_({inheritAttrs:!1,__name:"VPImage",props:{image:{},alt:{}},setup(o){return(e,t)=>{const s=K("VPImage",!0);return e.image?(a(),u(I,{key:0},[typeof e.image=="string"||"src"in e.image?(a(),u("img",j({key:0,class:"VPImage"},typeof e.image=="string"?e.$attrs:{...e.image,...e.$attrs},{src:r(de)(typeof e.image=="string"?e.image:e.image.src),alt:e.alt??(typeof e.image=="string"?"":e.image.alt||"")}),null,16,dn)):(a(),u(I,{key:1},[h(s,j({class:"dark",image:e.image.dark,alt:e.image.alt},e.$attrs),null,16,["image","alt"]),h(s,j({class:"light",image:e.image.light,alt:e.image.alt},e.$attrs),null,16,["image","alt"])],64))],64)):m("",!0)}}}),Y=g(vn,[["__scopeId","data-v-d440722e"]]),pn={class:"container"},fn={class:"main"},hn={key:0,class:"name"},mn=["innerHTML"],_n=["innerHTML"],kn=["innerHTML"],bn={key:0,class:"actions"},gn={key:0,class:"image"},$n={class:"image-container"},yn=_({__name:"VPHero",props:{name:{},text:{},tagline:{},image:{},actions:{}},setup(o){const e=x("hero-image-slot-exists");return(t,s)=>(a(),u("div",{class:w(["VPHero",{"has-image":t.image||r(e)}])},[d("div",pn,[d("div",fn,[c(t.$slots,"home-hero-info-before",{},void 0,!0),c(t.$slots,"home-hero-info",{},()=>[t.name?(a(),u("h1",hn,[d("span",{innerHTML:t.name,class:"clip"},null,8,mn)])):m("",!0),t.text?(a(),u("p",{key:1,innerHTML:t.text,class:"text"},null,8,_n)):m("",!0),t.tagline?(a(),u("p",{key:2,innerHTML:t.tagline,class:"tagline"},null,8,kn)):m("",!0)],!0),c(t.$slots,"home-hero-info-after",{},void 0,!0),t.actions?(a(),u("div",bn,[(a(!0),u(I,null,C(t.actions,n=>(a(),u("div",{key:n.link,class:"action"},[h(un,{tag:"a",size:"medium",theme:n.theme,text:n.text,href:n.link,target:n.target,rel:n.rel},null,8,["theme","text","href","target","rel"])]))),128))])):m("",!0),c(t.$slots,"home-hero-actions-after",{},void 0,!0)]),t.image||r(e)?(a(),u("div",gn,[d("div",$n,[s[0]||(s[0]=d("div",{class:"image-bg"},null,-1)),c(t.$slots,"home-hero-image",{},()=>[t.image?(a(),k(Y,{key:0,class:"image-src",image:t.image},null,8,["image"])):m("",!0)],!0)])])):m("",!0)])],2))}}),Pn=g(yn,[["__scopeId","data-v-1990d40c"]]),Ln=_({__name:"VPHomeHero",setup(o){const{frontmatter:e}=L();return(t,s)=>r(e).hero?(a(),k(Pn,{key:0,class:"VPHomeHero",name:r(e).hero.name,text:r(e).hero.text,tagline:r(e).hero.tagline,image:r(e).hero.image,actions:r(e).hero.actions},{"home-hero-info-before":p(()=>[c(t.$slots,"home-hero-info-before")]),"home-hero-info":p(()=>[c(t.$slots,"home-hero-info")]),"home-hero-info-after":p(()=>[c(t.$slots,"home-hero-info-after")]),"home-hero-actions-after":p(()=>[c(t.$slots,"home-hero-actions-after")]),"home-hero-image":p(()=>[c(t.$slots,"home-hero-image")]),_:3},8,["name","text","tagline","image","actions"])):m("",!0)}}),Vn={class:"box"},Sn={key:0,class:"icon"},Tn=["innerHTML"],Nn=["innerHTML"],wn=["innerHTML"],Mn={key:4,class:"link-text"},In={class:"link-text-value"},An=_({__name:"VPFeature",props:{icon:{},title:{},details:{},link:{},linkText:{},rel:{},target:{}},setup(o){return(e,t)=>(a(),k(D,{class:"VPFeature",href:e.link,rel:e.rel,target:e.target,"no-icon":!0,tag:e.link?"a":"div"},{default:p(()=>[d("article",Vn,[typeof e.icon=="object"&&e.icon.wrap?(a(),u("div",Sn,[h(Y,{image:e.icon,alt:e.icon.alt,height:e.icon.height||48,width:e.icon.width||48},null,8,["image","alt","height","width"])])):typeof e.icon=="object"?(a(),k(Y,{key:1,image:e.icon,alt:e.icon.alt,height:e.icon.height||48,width:e.icon.width||48},null,8,["image","alt","height","width"])):e.icon?(a(),u("div",{key:2,class:"icon",innerHTML:e.icon},null,8,Tn)):m("",!0),d("h2",{class:"title",innerHTML:e.title},null,8,Nn),e.details?(a(),u("p",{key:3,class:"details",innerHTML:e.details},null,8,wn)):m("",!0),e.linkText?(a(),u("div",Mn,[d("p",In,[E(M(e.linkText)+" ",1),t[0]||(t[0]=d("span",{class:"vpi-arrow-right link-text-icon"},null,-1))])])):m("",!0)])]),_:1},8,["href","rel","target","tag"]))}}),Hn=g(An,[["__scopeId","data-v-a96f5862"]]),Cn={key:0,class:"VPFeatures"},Bn={class:"container"},En={class:"items"},Fn=_({__name:"VPFeatures",props:{features:{}},setup(o){const e=o,t=y(()=>{const s=e.features.length;if(s){if(s===2)return"grid-2";if(s===3)return"grid-3";if(s%3===0)return"grid-6";if(s>3)return"grid-4"}else return});return(s,n)=>s.features?(a(),u("div",Cn,[d("div",Bn,[d("div",En,[(a(!0),u(I,null,C(s.features,i=>(a(),u("div",{key:i.title,class:w(["item",[t.value]])},[h(Hn,{icon:i.icon,title:i.title,details:i.details,link:i.link,"link-text":i.linkText,rel:i.rel,target:i.target},null,8,["icon","title","details","link","link-text","rel","target"])],2))),128))])])])):m("",!0)}}),Dn=g(Fn,[["__scopeId","data-v-64091ee1"]]),On=_({__name:"VPHomeFeatures",setup(o){const{frontmatter:e}=L();return(t,s)=>r(e).features?(a(),k(Dn,{key:0,class:"VPHomeFeatures",features:r(e).features},null,8,["features"])):m("",!0)}}),Gn=_({__name:"VPHomeContent",setup(o){const{width:e}=ze({initialWidth:0,includeScrollbar:!1});return(t,s)=>(a(),u("div",{class:"vp-doc container",style:Te(r(e)?{"--vp-offset":`calc(50% - ${r(e)/2}px)`}:{})},[c(t.$slots,"default",{},void 0,!0)],4))}}),Un=g(Gn,[["__scopeId","data-v-7350a991"]]),jn={class:"VPHome"},zn=_({__name:"VPHome",setup(o){const{frontmatter:e}=L();return(t,s)=>{const n=K("Content");return a(),u("div",jn,[c(t.$slots,"home-hero-before",{},void 0,!0),h(Ln,null,{"home-hero-info-before":p(()=>[c(t.$slots,"home-hero-info-before",{},void 0,!0)]),"home-hero-info":p(()=>[c(t.$slots,"home-hero-info",{},void 0,!0)]),"home-hero-info-after":p(()=>[c(t.$slots,"home-hero-info-after",{},void 0,!0)]),"home-hero-actions-after":p(()=>[c(t.$slots,"home-hero-actions-after",{},void 0,!0)]),"home-hero-image":p(()=>[c(t.$slots,"home-hero-image",{},void 0,!0)]),_:3}),c(t.$slots,"home-hero-after",{},void 0,!0),c(t.$slots,"home-features-before",{},void 0,!0),h(On),c(t.$slots,"home-features-after",{},void 0,!0),r(e).markdownStyles!==!1?(a(),k(Un,{key:0},{default:p(()=>[h(n)]),_:1})):(a(),k(n,{key:1}))])}}}),qn=g(zn,[["__scopeId","data-v-5664ecf3"]]),Kn={},Wn={class:"VPPage"};function Rn(o,e){const t=K("Content");return a(),u("div",Wn,[c(o.$slots,"page-top"),h(t),c(o.$slots,"page-bottom")])}const Jn=g(Kn,[["render",Rn]]),Yn=_({__name:"VPContent",setup(o){const{page:e,frontmatter:t}=L(),{hasSidebar:s}=G();return(n,i)=>(a(),u("div",{class:w(["VPContent",{"has-sidebar":r(s),"is-home":r(t).layout==="home"}]),id:"VPContent"},[r(e).isNotFound?c(n.$slots,"not-found",{key:0},()=>[h(vt)],!0):r(t).layout==="page"?(a(),k(Jn,{key:1},{"page-top":p(()=>[c(n.$slots,"page-top",{},void 0,!0)]),"page-bottom":p(()=>[c(n.$slots,"page-bottom",{},void 0,!0)]),_:3})):r(t).layout==="home"?(a(),k(qn,{key:2},{"home-hero-before":p(()=>[c(n.$slots,"home-hero-before",{},void 0,!0)]),"home-hero-info-before":p(()=>[c(n.$slots,"home-hero-info-before",{},void 0,!0)]),"home-hero-info":p(()=>[c(n.$slots,"home-hero-info",{},void 0,!0)]),"home-hero-info-after":p(()=>[c(n.$slots,"home-hero-info-after",{},void 0,!0)]),"home-hero-actions-after":p(()=>[c(n.$slots,"home-hero-actions-after",{},void 0,!0)]),"home-hero-image":p(()=>[c(n.$slots,"home-hero-image",{},void 0,!0)]),"home-hero-after":p(()=>[c(n.$slots,"home-hero-after",{},void 0,!0)]),"home-features-before":p(()=>[c(n.$slots,"home-features-before",{},void 0,!0)]),"home-features-after":p(()=>[c(n.$slots,"home-features-after",{},void 0,!0)]),_:3})):r(t).layout&&r(t).layout!=="doc"?(a(),k(F(r(t).layout),{key:3})):(a(),k(ln,{key:4},{"doc-top":p(()=>[c(n.$slots,"doc-top",{},void 0,!0)]),"doc-bottom":p(()=>[c(n.$slots,"doc-bottom",{},void 0,!0)]),"doc-footer-before":p(()=>[c(n.$slots,"doc-footer-before",{},void 0,!0)]),"doc-before":p(()=>[c(n.$slots,"doc-before",{},void 0,!0)]),"doc-after":p(()=>[c(n.$slots,"doc-after",{},void 0,!0)]),"aside-top":p(()=>[c(n.$slots,"aside-top",{},void 0,!0)]),"aside-outline-before":p(()=>[c(n.$slots,"aside-outline-before",{},void 0,!0)]),"aside-outline-after":p(()=>[c(n.$slots,"aside-outline-after",{},void 0,!0)]),"aside-ads-before":p(()=>[c(n.$slots,"aside-ads-before",{},void 0,!0)]),"aside-ads-after":p(()=>[c(n.$slots,"aside-ads-after",{},void 0,!0)]),"aside-bottom":p(()=>[c(n.$slots,"aside-bottom",{},void 0,!0)]),_:3}))],2))}}),Xn=g(Yn,[["__scopeId","data-v-9b48e573"]]),Qn={class:"container"},Zn=["innerHTML"],xn=["innerHTML"],es=_({__name:"VPFooter",setup(o){const{theme:e,frontmatter:t}=L(),{hasSidebar:s}=G();return(n,i)=>r(e).footer&&r(t).footer!==!1?(a(),u("footer",{key:0,class:w(["VPFooter",{"has-sidebar":r(s)}])},[d("div",Qn,[r(e).footer.message?(a(),u("p",{key:0,class:"message",innerHTML:r(e).footer.message},null,8,Zn)):m("",!0),r(e).footer.copyright?(a(),u("p",{key:1,class:"copyright",innerHTML:r(e).footer.copyright},null,8,xn)):m("",!0)])],2)):m("",!0)}}),ts=g(es,[["__scopeId","data-v-3e99d79d"]]);function ns(){const{theme:o,frontmatter:e}=L(),t=Ve([]),s=y(()=>t.value.length>0);return Q(()=>{t.value=he(e.value.outline??o.value.outline)}),{headers:t,hasLocalNav:s}}const ss={class:"menu-text"},os={class:"header"},as={class:"outline"},rs=_({__name:"VPLocalNavOutlineDropdown",props:{headers:{},navHeight:{}},setup(o){const e=o,{theme:t}=L(),s=T(!1),n=T(0),i=T(),l=T();function f(b){var P;(P=i.value)!=null&&P.contains(b.target)||(s.value=!1)}O(s,b=>{if(b){document.addEventListener("click",f);return}document.removeEventListener("click",f)}),re("Escape",()=>{s.value=!1}),Q(()=>{s.value=!1});function v(){s.value=!s.value,n.value=window.innerHeight+Math.min(window.scrollY-e.navHeight,0)}function $(b){b.target.classList.contains("outline-link")&&(l.value&&(l.value.style.transition="none"),Ne(()=>{s.value=!1}))}function V(){s.value=!1,window.scrollTo({top:0,left:0,behavior:"smooth"})}return(b,P)=>(a(),u("div",{class:"VPLocalNavOutlineDropdown",style:Te({"--vp-vh":n.value+"px"}),ref_key:"main",ref:i},[b.headers.length>0?(a(),u("button",{key:0,onClick:v,class:w({open:s.value})},[d("span",ss,M(r(He)(r(t))),1),P[0]||(P[0]=d("span",{class:"vpi-chevron-right icon"},null,-1))],2)):(a(),u("button",{key:1,onClick:V},M(r(t).returnToTopLabel||"Return to top"),1)),h(ue,{name:"flyout"},{default:p(()=>[s.value?(a(),u("div",{key:0,ref_key:"items",ref:l,class:"items",onClick:$},[d("div",os,[d("a",{class:"top-link",href:"#",onClick:V},M(r(t).returnToTopLabel||"Return to top"),1)]),d("div",as,[h(Ce,{headers:b.headers},null,8,["headers"])])],512)):m("",!0)]),_:1})],4))}}),is=g(rs,[["__scopeId","data-v-90060d6b"]]),ls={class:"container"},cs=["aria-expanded"],us={class:"menu-text"},ds=_({__name:"VPLocalNav",props:{open:{type:Boolean}},emits:["open-menu"],setup(o){const{theme:e,frontmatter:t}=L(),{hasSidebar:s}=G(),{headers:n}=ns(),{y:i}=we(),l=T(0);z(()=>{l.value=parseInt(getComputedStyle(document.documentElement).getPropertyValue("--vp-nav-height"))}),Q(()=>{n.value=he(t.value.outline??e.value.outline)});const f=y(()=>n.value.length===0),v=y(()=>f.value&&!s.value),$=y(()=>({VPLocalNav:!0,"has-sidebar":s.value,empty:f.value,fixed:v.value}));return(V,b)=>r(t).layout!=="home"&&(!v.value||r(i)>=l.value)?(a(),u("div",{key:0,class:w($.value)},[d("div",ls,[r(s)?(a(),u("button",{key:0,class:"menu","aria-expanded":V.open,"aria-controls":"VPSidebarNav",onClick:b[0]||(b[0]=P=>V.$emit("open-menu"))},[b[1]||(b[1]=d("span",{class:"vpi-align-left menu-icon"},null,-1)),d("span",us,M(r(e).sidebarMenuLabel||"Menu"),1)],8,cs)):m("",!0),h(is,{headers:r(n),navHeight:l.value},null,8,["headers","navHeight"])])],2)):m("",!0)}}),vs=g(ds,[["__scopeId","data-v-d66dc387"]]);function ps(){const o=T(!1);function e(){o.value=!0,window.addEventListener("resize",n)}function t(){o.value=!1,window.removeEventListener("resize",n)}function s(){o.value?t():e()}function n(){window.outerWidth>=768&&t()}const i=Z();return O(()=>i.path,t),{isScreenOpen:o,openScreen:e,closeScreen:t,toggleScreen:s}}const fs={},hs={class:"VPSwitch",type:"button",role:"switch"},ms={class:"check"},_s={key:0,class:"icon"};function ks(o,e){return a(),u("button",hs,[d("span",ms,[o.$slots.default?(a(),u("span",_s,[c(o.$slots,"default",{},void 0,!0)])):m("",!0)])])}const bs=g(fs,[["render",ks],["__scopeId","data-v-813ef981"]]),gs=_({__name:"VPSwitchAppearance",setup(o){const{isDark:e,theme:t}=L(),s=x("toggle-appearance",()=>{e.value=!e.value}),n=T("");return pe(()=>{n.value=e.value?t.value.lightModeSwitchTitle||"Switch to light theme":t.value.darkModeSwitchTitle||"Switch to dark theme"}),(i,l)=>(a(),k(bs,{title:n.value,class:"VPSwitchAppearance","aria-checked":r(e),onClick:r(s)},{default:p(()=>l[0]||(l[0]=[d("span",{class:"vpi-sun sun"},null,-1),d("span",{class:"vpi-moon moon"},null,-1)])),_:1},8,["title","aria-checked","onClick"]))}}),me=g(gs,[["__scopeId","data-v-da7ec100"]]),$s={key:0,class:"VPNavBarAppearance"},ys=_({__name:"VPNavBarAppearance",setup(o){const{site:e}=L();return(t,s)=>r(e).appearance&&r(e).appearance!=="force-dark"&&r(e).appearance!=="force-auto"?(a(),u("div",$s,[h(me)])):m("",!0)}}),Ps=g(ys,[["__scopeId","data-v-1b2826e7"]]),_e=T();let Be=!1,oe=0;function Ls(o){const e=T(!1);if(ee){!Be&&Vs(),oe++;const t=O(_e,s=>{var n,i,l;s===o.el.value||(n=o.el.value)!=null&&n.contains(s)?(e.value=!0,(i=o.onFocus)==null||i.call(o)):(e.value=!1,(l=o.onBlur)==null||l.call(o))});ve(()=>{t(),oe--,oe||Ss()})}return qe(e)}function Vs(){document.addEventListener("focusin",Ee),Be=!0,_e.value=document.activeElement}function Ss(){document.removeEventListener("focusin",Ee)}function Ee(){_e.value=document.activeElement}const Ts={class:"VPMenuLink"},Ns=["innerHTML"],ws=_({__name:"VPMenuLink",props:{item:{}},setup(o){const{page:e}=L();return(t,s)=>(a(),u("div",Ts,[h(D,{class:w({active:r(q)(r(e).relativePath,t.item.activeMatch||t.item.link,!!t.item.activeMatch)}),href:t.item.link,target:t.item.target,rel:t.item.rel,"no-icon":t.item.noIcon},{default:p(()=>[d("span",{innerHTML:t.item.text},null,8,Ns)]),_:1},8,["class","href","target","rel","no-icon"])]))}}),te=g(ws,[["__scopeId","data-v-89a5c348"]]),Ms={class:"VPMenuGroup"},Is={key:0,class:"title"},As=_({__name:"VPMenuGroup",props:{text:{},items:{}},setup(o){return(e,t)=>(a(),u("div",Ms,[e.text?(a(),u("p",Is,M(e.text),1)):m("",!0),(a(!0),u(I,null,C(e.items,s=>(a(),u(I,null,["link"in s?(a(),k(te,{key:0,item:s},null,8,["item"])):m("",!0)],64))),256))]))}}),Hs=g(As,[["__scopeId","data-v-56396be0"]]),Cs={class:"VPMenu"},Bs={key:0,class:"items"},Es=_({__name:"VPMenu",props:{items:{}},setup(o){return(e,t)=>(a(),u("div",Cs,[e.items?(a(),u("div",Bs,[(a(!0),u(I,null,C(e.items,s=>(a(),u(I,{key:JSON.stringify(s)},["link"in s?(a(),k(te,{key:0,item:s},null,8,["item"])):"component"in s?(a(),k(F(s.component),j({key:1,ref_for:!0},s.props),null,16)):(a(),k(Hs,{key:2,text:s.text,items:s.items},null,8,["text","items"]))],64))),128))])):m("",!0),c(e.$slots,"default",{},void 0,!0)]))}}),Fs=g(Es,[["__scopeId","data-v-e6ae5541"]]),Ds=["aria-expanded","aria-label"],Os={key:0,class:"text"},Gs=["innerHTML"],Us={key:1,class:"vpi-more-horizontal icon"},js={class:"menu"},zs=_({__name:"VPFlyout",props:{icon:{},button:{},label:{},items:{}},setup(o){const e=T(!1),t=T();Ls({el:t,onBlur:s});function s(){e.value=!1}return(n,i)=>(a(),u("div",{class:"VPFlyout",ref_key:"el",ref:t,onMouseenter:i[1]||(i[1]=l=>e.value=!0),onMouseleave:i[2]||(i[2]=l=>e.value=!1)},[d("button",{type:"button",class:"button","aria-haspopup":"true","aria-expanded":e.value,"aria-label":n.label,onClick:i[0]||(i[0]=l=>e.value=!e.value)},[n.button||n.icon?(a(),u("span",Os,[n.icon?(a(),u("span",{key:0,class:w([n.icon,"option-icon"])},null,2)):m("",!0),n.button?(a(),u("span",{key:1,innerHTML:n.button},null,8,Gs)):m("",!0),i[3]||(i[3]=d("span",{class:"vpi-chevron-down text-icon"},null,-1))])):(a(),u("span",Us))],8,Ds),d("div",js,[h(Fs,{items:n.items},{default:p(()=>[c(n.$slots,"default",{},void 0,!0)]),_:3},8,["items"])])],544))}}),ke=g(zs,[["__scopeId","data-v-c7dcff6d"]]),qs=["href","aria-label","innerHTML"],Ks=_({__name:"VPSocialLink",props:{icon:{},link:{},ariaLabel:{}},setup(o){const e=o,t=T();z(async()=>{var i;await Ne();const n=(i=t.value)==null?void 0:i.children[0];n instanceof HTMLElement&&n.className.startsWith("vpi-social-")&&(getComputedStyle(n).maskImage||getComputedStyle(n).webkitMaskImage)==="none"&&n.style.setProperty("--icon",`url('https://api.iconify.design/simple-icons/${e.icon}.svg')`)});const s=y(()=>typeof e.icon=="object"?e.icon.svg:``);return(n,i)=>(a(),u("a",{ref_key:"el",ref:t,class:"VPSocialLink no-icon",href:n.link,"aria-label":n.ariaLabel??(typeof n.icon=="string"?n.icon:""),target:"_blank",rel:"noopener",innerHTML:s.value},null,8,qs))}}),Ws=g(Ks,[["__scopeId","data-v-a1268182"]]),Rs={class:"VPSocialLinks"},Js=_({__name:"VPSocialLinks",props:{links:{}},setup(o){return(e,t)=>(a(),u("div",Rs,[(a(!0),u(I,null,C(e.links,({link:s,icon:n,ariaLabel:i})=>(a(),k(Ws,{key:s,icon:n,link:s,ariaLabel:i},null,8,["icon","link","ariaLabel"]))),128))]))}}),be=g(Js,[["__scopeId","data-v-d71f35b5"]]),Ys={key:0,class:"group translations"},Xs={class:"trans-title"},Qs={key:1,class:"group"},Zs={class:"item appearance"},xs={class:"label"},eo={class:"appearance-action"},to={key:2,class:"group"},no={class:"item social-links"},so=_({__name:"VPNavBarExtra",setup(o){const{site:e,theme:t}=L(),{localeLinks:s,currentLang:n}=R({correspondingLink:!0}),i=y(()=>s.value.length&&n.value.label||e.value.appearance||t.value.socialLinks);return(l,f)=>i.value?(a(),k(ke,{key:0,class:"VPNavBarExtra",label:"extra navigation"},{default:p(()=>[r(s).length&&r(n).label?(a(),u("div",Ys,[d("p",Xs,M(r(n).label),1),(a(!0),u(I,null,C(r(s),v=>(a(),k(te,{key:v.link,item:v},null,8,["item"]))),128))])):m("",!0),r(e).appearance&&r(e).appearance!=="force-dark"&&r(e).appearance!=="force-auto"?(a(),u("div",Qs,[d("div",Zs,[d("p",xs,M(r(t).darkModeSwitchLabel||"Appearance"),1),d("div",eo,[h(me)])])])):m("",!0),r(t).socialLinks?(a(),u("div",to,[d("div",no,[h(be,{class:"social-links-list",links:r(t).socialLinks},null,8,["links"])])])):m("",!0)]),_:1})):m("",!0)}}),oo=g(so,[["__scopeId","data-v-0c20fffb"]]),ao=["aria-expanded"],ro=_({__name:"VPNavBarHamburger",props:{active:{type:Boolean}},emits:["click"],setup(o){return(e,t)=>(a(),u("button",{type:"button",class:w(["VPNavBarHamburger",{active:e.active}]),"aria-label":"mobile navigation","aria-expanded":e.active,"aria-controls":"VPNavScreen",onClick:t[0]||(t[0]=s=>e.$emit("click"))},t[1]||(t[1]=[d("span",{class:"container"},[d("span",{class:"top"}),d("span",{class:"middle"}),d("span",{class:"bottom"})],-1)]),10,ao))}}),io=g(ro,[["__scopeId","data-v-1006ddd6"]]),lo=["innerHTML"],co=_({__name:"VPNavBarMenuLink",props:{item:{}},setup(o){const{page:e}=L();return(t,s)=>(a(),k(D,{class:w({VPNavBarMenuLink:!0,active:r(q)(r(e).relativePath,t.item.activeMatch||t.item.link,!!t.item.activeMatch)}),href:t.item.link,target:t.item.target,rel:t.item.rel,"no-icon":t.item.noIcon,tabindex:"0"},{default:p(()=>[d("span",{innerHTML:t.item.text},null,8,lo)]),_:1},8,["class","href","target","rel","no-icon"]))}}),uo=g(co,[["__scopeId","data-v-89faf8bb"]]),vo=_({__name:"VPNavBarMenuGroup",props:{item:{}},setup(o){const e=o,{page:t}=L(),s=i=>"component"in i?!1:"link"in i?q(t.value.relativePath,i.link,!!e.item.activeMatch):i.items.some(s),n=y(()=>s(e.item));return(i,l)=>(a(),k(ke,{class:w({VPNavBarMenuGroup:!0,active:r(q)(r(t).relativePath,i.item.activeMatch,!!i.item.activeMatch)||n.value}),button:i.item.text,items:i.item.items},null,8,["class","button","items"]))}}),po={key:0,"aria-labelledby":"main-nav-aria-label",class:"VPNavBarMenu"},fo=_({__name:"VPNavBarMenu",setup(o){const{theme:e}=L();return(t,s)=>r(e).nav?(a(),u("nav",po,[s[0]||(s[0]=d("span",{id:"main-nav-aria-label",class:"visually-hidden"}," Main Navigation ",-1)),(a(!0),u(I,null,C(r(e).nav,n=>(a(),u(I,{key:JSON.stringify(n)},["link"in n?(a(),k(uo,{key:0,item:n},null,8,["item"])):"component"in n?(a(),k(F(n.component),j({key:1,ref_for:!0},n.props),null,16)):(a(),k(vo,{key:2,item:n},null,8,["item"]))],64))),128))])):m("",!0)}}),ho=g(fo,[["__scopeId","data-v-ec1f35aa"]]);function mo(o){const{localeIndex:e,theme:t}=L();function s(n){var A,H,S;const i=n.split("."),l=(A=t.value.search)==null?void 0:A.options,f=l&&typeof l=="object",v=f&&((S=(H=l.locales)==null?void 0:H[e.value])==null?void 0:S.translations)||null,$=f&&l.translations||null;let V=v,b=$,P=o;const N=i.pop();for(const B of i){let U=null;const W=P==null?void 0:P[B];W&&(U=P=W);const ne=b==null?void 0:b[B];ne&&(U=b=ne);const se=V==null?void 0:V[B];se&&(U=V=se),W||(P=U),ne||(b=U),se||(V=U)}return(V==null?void 0:V[N])??(b==null?void 0:b[N])??(P==null?void 0:P[N])??""}return s}const _o=["aria-label"],ko={class:"DocSearch-Button-Container"},bo={class:"DocSearch-Button-Placeholder"},$e=_({__name:"VPNavBarSearchButton",setup(o){const t=mo({button:{buttonText:"Search",buttonAriaLabel:"Search"}});return(s,n)=>(a(),u("button",{type:"button",class:"DocSearch DocSearch-Button","aria-label":r(t)("button.buttonAriaLabel")},[d("span",ko,[n[0]||(n[0]=d("span",{class:"vp-icon DocSearch-Search-Icon"},null,-1)),d("span",bo,M(r(t)("button.buttonText")),1)]),n[1]||(n[1]=d("span",{class:"DocSearch-Button-Keys"},[d("kbd",{class:"DocSearch-Button-Key"}),d("kbd",{class:"DocSearch-Button-Key"},"K")],-1))],8,_o))}}),go={class:"VPNavBarSearch"},$o={id:"local-search"},yo={key:1,id:"docsearch"},Po=_({__name:"VPNavBarSearch",setup(o){const e=Ke(()=>We(()=>import("./VPLocalSearchBox.C23CuZ30.js"),__vite__mapDeps([0,1]))),t=()=>null,{theme:s}=L(),n=T(!1),i=T(!1);z(()=>{});function l(){n.value||(n.value=!0,setTimeout(f,16))}function f(){const b=new Event("keydown");b.key="k",b.metaKey=!0,window.dispatchEvent(b),setTimeout(()=>{document.querySelector(".DocSearch-Modal")||f()},16)}function v(b){const P=b.target,N=P.tagName;return P.isContentEditable||N==="INPUT"||N==="SELECT"||N==="TEXTAREA"}const $=T(!1);re("k",b=>{(b.ctrlKey||b.metaKey)&&(b.preventDefault(),$.value=!0)}),re("/",b=>{v(b)||(b.preventDefault(),$.value=!0)});const V="local";return(b,P)=>{var N;return a(),u("div",go,[r(V)==="local"?(a(),u(I,{key:0},[$.value?(a(),k(r(e),{key:0,onClose:P[0]||(P[0]=A=>$.value=!1)})):m("",!0),d("div",$o,[h($e,{onClick:P[1]||(P[1]=A=>$.value=!0)})])],64)):r(V)==="algolia"?(a(),u(I,{key:1},[n.value?(a(),k(r(t),{key:0,algolia:((N=r(s).search)==null?void 0:N.options)??r(s).algolia,onVnodeBeforeMount:P[2]||(P[2]=A=>i.value=!0)},null,8,["algolia"])):m("",!0),i.value?m("",!0):(a(),u("div",yo,[h($e,{onClick:l})]))],64)):m("",!0)])}}}),Lo=_({__name:"VPNavBarSocialLinks",setup(o){const{theme:e}=L();return(t,s)=>r(e).socialLinks?(a(),k(be,{key:0,class:"VPNavBarSocialLinks",links:r(e).socialLinks},null,8,["links"])):m("",!0)}}),Vo=g(Lo,[["__scopeId","data-v-bc5763b5"]]),So=["href","rel","target"],To=["innerHTML"],No={key:2},wo=_({__name:"VPNavBarTitle",setup(o){const{site:e,theme:t}=L(),{hasSidebar:s}=G(),{currentLang:n}=R(),i=y(()=>{var v;return typeof t.value.logoLink=="string"?t.value.logoLink:(v=t.value.logoLink)==null?void 0:v.link}),l=y(()=>{var v;return typeof t.value.logoLink=="string"||(v=t.value.logoLink)==null?void 0:v.rel}),f=y(()=>{var v;return typeof t.value.logoLink=="string"||(v=t.value.logoLink)==null?void 0:v.target});return(v,$)=>(a(),u("div",{class:w(["VPNavBarTitle",{"has-sidebar":r(s)}])},[d("a",{class:"title",href:i.value??r(fe)(r(n).link),rel:l.value,target:f.value},[c(v.$slots,"nav-bar-title-before",{},void 0,!0),r(t).logo?(a(),k(Y,{key:0,class:"logo",image:r(t).logo},null,8,["image"])):m("",!0),r(t).siteTitle?(a(),u("span",{key:1,innerHTML:r(t).siteTitle},null,8,To)):r(t).siteTitle===void 0?(a(),u("span",No,M(r(e).title),1)):m("",!0),c(v.$slots,"nav-bar-title-after",{},void 0,!0)],8,So)],2))}}),Mo=g(wo,[["__scopeId","data-v-a1a198d5"]]),Io={class:"items"},Ao={class:"title"},Ho=_({__name:"VPNavBarTranslations",setup(o){const{theme:e}=L(),{localeLinks:t,currentLang:s}=R({correspondingLink:!0});return(n,i)=>r(t).length&&r(s).label?(a(),k(ke,{key:0,class:"VPNavBarTranslations",icon:"vpi-languages",label:r(e).langMenuLabel||"Change language"},{default:p(()=>[d("div",Io,[d("p",Ao,M(r(s).label),1),(a(!0),u(I,null,C(r(t),l=>(a(),k(te,{key:l.link,item:l},null,8,["item"]))),128))])]),_:1},8,["label"])):m("",!0)}}),Co=g(Ho,[["__scopeId","data-v-73c6375d"]]),Bo={class:"wrapper"},Eo={class:"container"},Fo={class:"title"},Do={class:"content"},Oo={class:"content-body"},Go=_({__name:"VPNavBar",props:{isScreenOpen:{type:Boolean}},emits:["toggle-screen"],setup(o){const e=o,{y:t}=we(),{hasSidebar:s}=G(),{frontmatter:n}=L(),i=T({});return pe(()=>{i.value={"has-sidebar":s.value,home:n.value.layout==="home",top:t.value===0,"screen-open":e.isScreenOpen}}),(l,f)=>(a(),u("div",{class:w(["VPNavBar",i.value])},[d("div",Bo,[d("div",Eo,[d("div",Fo,[h(Mo,null,{"nav-bar-title-before":p(()=>[c(l.$slots,"nav-bar-title-before",{},void 0,!0)]),"nav-bar-title-after":p(()=>[c(l.$slots,"nav-bar-title-after",{},void 0,!0)]),_:3})]),d("div",Do,[d("div",Oo,[c(l.$slots,"nav-bar-content-before",{},void 0,!0),h(Po,{class:"search"}),h(ho,{class:"menu"}),h(Co,{class:"translations"}),h(Ps,{class:"appearance"}),h(Vo,{class:"social-links"}),h(oo,{class:"extra"}),c(l.$slots,"nav-bar-content-after",{},void 0,!0),h(io,{class:"hamburger",active:l.isScreenOpen,onClick:f[0]||(f[0]=v=>l.$emit("toggle-screen"))},null,8,["active"])])])])]),f[1]||(f[1]=d("div",{class:"divider"},[d("div",{class:"divider-line"})],-1))],2))}}),Uo=g(Go,[["__scopeId","data-v-cb65f61d"]]),jo={key:0,class:"VPNavScreenAppearance"},zo={class:"text"},qo=_({__name:"VPNavScreenAppearance",setup(o){const{site:e,theme:t}=L();return(s,n)=>r(e).appearance&&r(e).appearance!=="force-dark"&&r(e).appearance!=="force-auto"?(a(),u("div",jo,[d("p",zo,M(r(t).darkModeSwitchLabel||"Appearance"),1),h(me)])):m("",!0)}}),Ko=g(qo,[["__scopeId","data-v-70a76bde"]]),Wo=["innerHTML"],Ro=_({__name:"VPNavScreenMenuLink",props:{item:{}},setup(o){const e=x("close-screen");return(t,s)=>(a(),k(D,{class:"VPNavScreenMenuLink",href:t.item.link,target:t.item.target,rel:t.item.rel,"no-icon":t.item.noIcon,onClick:r(e)},{default:p(()=>[d("span",{innerHTML:t.item.text},null,8,Wo)]),_:1},8,["href","target","rel","no-icon","onClick"]))}}),Jo=g(Ro,[["__scopeId","data-v-2cea500d"]]),Yo=["innerHTML"],Xo=_({__name:"VPNavScreenMenuGroupLink",props:{item:{}},setup(o){const e=x("close-screen");return(t,s)=>(a(),k(D,{class:"VPNavScreenMenuGroupLink",href:t.item.link,target:t.item.target,rel:t.item.rel,"no-icon":t.item.noIcon,onClick:r(e)},{default:p(()=>[d("span",{innerHTML:t.item.text},null,8,Yo)]),_:1},8,["href","target","rel","no-icon","onClick"]))}}),Fe=g(Xo,[["__scopeId","data-v-d196ed44"]]),Qo={class:"VPNavScreenMenuGroupSection"},Zo={key:0,class:"title"},xo=_({__name:"VPNavScreenMenuGroupSection",props:{text:{},items:{}},setup(o){return(e,t)=>(a(),u("div",Qo,[e.text?(a(),u("p",Zo,M(e.text),1)):m("",!0),(a(!0),u(I,null,C(e.items,s=>(a(),k(Fe,{key:s.text,item:s},null,8,["item"]))),128))]))}}),ea=g(xo,[["__scopeId","data-v-a62d7f92"]]),ta=["aria-controls","aria-expanded"],na=["innerHTML"],sa=["id"],oa={key:0,class:"item"},aa={key:1,class:"item"},ra={key:2,class:"group"},ia=_({__name:"VPNavScreenMenuGroup",props:{text:{},items:{}},setup(o){const e=o,t=T(!1),s=y(()=>`NavScreenGroup-${e.text.replace(" ","-").toLowerCase()}`);function n(){t.value=!t.value}return(i,l)=>(a(),u("div",{class:w(["VPNavScreenMenuGroup",{open:t.value}])},[d("button",{class:"button","aria-controls":s.value,"aria-expanded":t.value,onClick:n},[d("span",{class:"button-text",innerHTML:i.text},null,8,na),l[0]||(l[0]=d("span",{class:"vpi-plus button-icon"},null,-1))],8,ta),d("div",{id:s.value,class:"items"},[(a(!0),u(I,null,C(i.items,f=>(a(),u(I,{key:JSON.stringify(f)},["link"in f?(a(),u("div",oa,[h(Fe,{item:f},null,8,["item"])])):"component"in f?(a(),u("div",aa,[(a(),k(F(f.component),j({ref_for:!0},f.props,{"screen-menu":""}),null,16))])):(a(),u("div",ra,[h(ea,{text:f.text,items:f.items},null,8,["text","items"])]))],64))),128))],8,sa)],2))}}),la=g(ia,[["__scopeId","data-v-13bc299f"]]),ca={key:0,class:"VPNavScreenMenu"},ua=_({__name:"VPNavScreenMenu",setup(o){const{theme:e}=L();return(t,s)=>r(e).nav?(a(),u("nav",ca,[(a(!0),u(I,null,C(r(e).nav,n=>(a(),u(I,{key:JSON.stringify(n)},["link"in n?(a(),k(Jo,{key:0,item:n},null,8,["item"])):"component"in n?(a(),k(F(n.component),j({key:1,ref_for:!0},n.props,{"screen-menu":""}),null,16)):(a(),k(la,{key:2,text:n.text||"",items:n.items},null,8,["text","items"]))],64))),128))])):m("",!0)}}),da=_({__name:"VPNavScreenSocialLinks",setup(o){const{theme:e}=L();return(t,s)=>r(e).socialLinks?(a(),k(be,{key:0,class:"VPNavScreenSocialLinks",links:r(e).socialLinks},null,8,["links"])):m("",!0)}}),va={class:"list"},pa=_({__name:"VPNavScreenTranslations",setup(o){const{localeLinks:e,currentLang:t}=R({correspondingLink:!0}),s=T(!1);function n(){s.value=!s.value}return(i,l)=>r(e).length&&r(t).label?(a(),u("div",{key:0,class:w(["VPNavScreenTranslations",{open:s.value}])},[d("button",{class:"title",onClick:n},[l[0]||(l[0]=d("span",{class:"vpi-languages icon lang"},null,-1)),E(" "+M(r(t).label)+" ",1),l[1]||(l[1]=d("span",{class:"vpi-chevron-down icon chevron"},null,-1))]),d("ul",va,[(a(!0),u(I,null,C(r(e),f=>(a(),u("li",{key:f.link,class:"item"},[h(D,{class:"link",href:f.link},{default:p(()=>[E(M(f.text),1)]),_:2},1032,["href"])]))),128))])],2)):m("",!0)}}),fa=g(pa,[["__scopeId","data-v-925440ed"]]),ha={class:"container"},ma=_({__name:"VPNavScreen",props:{open:{type:Boolean}},setup(o){const e=T(null),t=Me(ee?document.body:null);return(s,n)=>(a(),k(ue,{name:"fade",onEnter:n[0]||(n[0]=i=>t.value=!0),onAfterLeave:n[1]||(n[1]=i=>t.value=!1)},{default:p(()=>[s.open?(a(),u("div",{key:0,class:"VPNavScreen",ref_key:"screen",ref:e,id:"VPNavScreen"},[d("div",ha,[c(s.$slots,"nav-screen-content-before",{},void 0,!0),h(ua,{class:"menu"}),h(fa,{class:"translations"}),h(Ko,{class:"appearance"}),h(da,{class:"social-links"}),c(s.$slots,"nav-screen-content-after",{},void 0,!0)])],512)):m("",!0)]),_:3}))}}),_a=g(ma,[["__scopeId","data-v-9d48cc3b"]]),ka={key:0,class:"VPNav"},ba=_({__name:"VPNav",setup(o){const{isScreenOpen:e,closeScreen:t,toggleScreen:s}=ps(),{frontmatter:n}=L(),i=y(()=>n.value.navbar!==!1);return Ie("close-screen",t),X(()=>{ee&&document.documentElement.classList.toggle("hide-nav",!i.value)}),(l,f)=>i.value?(a(),u("header",ka,[h(Uo,{"is-screen-open":r(e),onToggleScreen:r(s)},{"nav-bar-title-before":p(()=>[c(l.$slots,"nav-bar-title-before",{},void 0,!0)]),"nav-bar-title-after":p(()=>[c(l.$slots,"nav-bar-title-after",{},void 0,!0)]),"nav-bar-content-before":p(()=>[c(l.$slots,"nav-bar-content-before",{},void 0,!0)]),"nav-bar-content-after":p(()=>[c(l.$slots,"nav-bar-content-after",{},void 0,!0)]),_:3},8,["is-screen-open","onToggleScreen"]),h(_a,{open:r(e)},{"nav-screen-content-before":p(()=>[c(l.$slots,"nav-screen-content-before",{},void 0,!0)]),"nav-screen-content-after":p(()=>[c(l.$slots,"nav-screen-content-after",{},void 0,!0)]),_:3},8,["open"])])):m("",!0)}}),ga=g(ba,[["__scopeId","data-v-21f5ce95"]]),$a=["role","tabindex"],ya={key:1,class:"items"},Pa=_({__name:"VPSidebarItem",props:{item:{},depth:{}},setup(o){const e=o,{collapsed:t,collapsible:s,isLink:n,isActiveLink:i,hasActiveLink:l,hasChildren:f,toggle:v}=mt(y(()=>e.item)),$=y(()=>f.value?"section":"div"),V=y(()=>n.value?"a":"div"),b=y(()=>f.value?e.depth+2===7?"p":`h${e.depth+2}`:"p"),P=y(()=>n.value?void 0:"button"),N=y(()=>[[`level-${e.depth}`],{collapsible:s.value},{collapsed:t.value},{"is-link":n.value},{"is-active":i.value},{"has-active":l.value}]);function A(S){"key"in S&&S.key!=="Enter"||!e.item.link&&v()}function H(){e.item.link&&v()}return(S,B)=>{const U=K("VPSidebarItem",!0);return a(),k(F($.value),{class:w(["VPSidebarItem",N.value])},{default:p(()=>[S.item.text?(a(),u("div",j({key:0,class:"item",role:P.value},Je(S.item.items?{click:A,keydown:A}:{},!0),{tabindex:S.item.items&&0}),[B[1]||(B[1]=d("div",{class:"indicator"},null,-1)),S.item.link?(a(),k(D,{key:0,tag:V.value,class:"link",href:S.item.link,rel:S.item.rel,target:S.item.target},{default:p(()=>[(a(),k(F(b.value),{class:"text",innerHTML:S.item.text},null,8,["innerHTML"]))]),_:1},8,["tag","href","rel","target"])):(a(),k(F(b.value),{key:1,class:"text",innerHTML:S.item.text},null,8,["innerHTML"])),S.item.collapsed!=null&&S.item.items&&S.item.items.length?(a(),u("div",{key:2,class:"caret",role:"button","aria-label":"toggle section",onClick:H,onKeydown:Re(H,["enter"]),tabindex:"0"},B[0]||(B[0]=[d("span",{class:"vpi-chevron-right caret-icon"},null,-1)]),32)):m("",!0)],16,$a)):m("",!0),S.item.items&&S.item.items.length?(a(),u("div",ya,[S.depth<5?(a(!0),u(I,{key:0},C(S.item.items,W=>(a(),k(U,{key:W.text,item:W,depth:S.depth+1},null,8,["item","depth"]))),128)):m("",!0)])):m("",!0)]),_:1},8,["class"])}}}),La=g(Pa,[["__scopeId","data-v-ca8d42a6"]]),Va=_({__name:"VPSidebarGroup",props:{items:{}},setup(o){const e=T(!0);let t=null;return z(()=>{t=setTimeout(()=>{t=null,e.value=!1},300)}),Ye(()=>{t!=null&&(clearTimeout(t),t=null)}),(s,n)=>(a(!0),u(I,null,C(s.items,i=>(a(),u("div",{key:i.text,class:w(["group",{"no-transition":e.value}])},[h(La,{item:i,depth:0},null,8,["item"])],2))),128))}}),Sa=g(Va,[["__scopeId","data-v-4fb3f82c"]]),Ta={class:"nav",id:"VPSidebarNav","aria-labelledby":"sidebar-aria-label",tabindex:"-1"},Na=_({__name:"VPSidebar",props:{open:{type:Boolean}},setup(o){const{sidebarGroups:e,hasSidebar:t}=G(),s=o,n=T(null),i=Me(ee?document.body:null);O([s,n],()=>{var f;s.open?(i.value=!0,(f=n.value)==null||f.focus()):i.value=!1},{immediate:!0,flush:"post"});const l=T(0);return O(e,()=>{l.value+=1},{deep:!0}),(f,v)=>r(t)?(a(),u("aside",{key:0,class:w(["VPSidebar",{open:f.open}]),ref_key:"navEl",ref:n,onClick:v[0]||(v[0]=Xe(()=>{},["stop"]))},[v[2]||(v[2]=d("div",{class:"curtain"},null,-1)),d("nav",Ta,[v[1]||(v[1]=d("span",{class:"visually-hidden",id:"sidebar-aria-label"}," Sidebar Navigation ",-1)),c(f.$slots,"sidebar-nav-before",{},void 0,!0),(a(),k(Sa,{items:r(e),key:l.value},null,8,["items"])),c(f.$slots,"sidebar-nav-after",{},void 0,!0)])],2)):m("",!0)}}),wa=g(Na,[["__scopeId","data-v-7fee7a11"]]),Ma=_({__name:"VPSkipLink",setup(o){const e=Z(),t=T();O(()=>e.path,()=>t.value.focus());function s({target:n}){const i=document.getElementById(decodeURIComponent(n.hash).slice(1));if(i){const l=()=>{i.removeAttribute("tabindex"),i.removeEventListener("blur",l)};i.setAttribute("tabindex","-1"),i.addEventListener("blur",l),i.focus(),window.scrollTo(0,0)}}return(n,i)=>(a(),u(I,null,[d("span",{ref_key:"backToTop",ref:t,tabindex:"-1"},null,512),d("a",{href:"#VPContent",class:"VPSkipLink visually-hidden",onClick:s}," Skip to content ")],64))}}),Ia=g(Ma,[["__scopeId","data-v-f3ab029e"]]),Aa=_({__name:"Layout",setup(o){const{isOpen:e,open:t,close:s}=G(),n=Z();O(()=>n.path,s),ht(e,s);const{frontmatter:i}=L(),l=Qe(),f=y(()=>!!l["home-hero-image"]);return Ie("hero-image-slot-exists",f),(v,$)=>{const V=K("Content");return r(i).layout!==!1?(a(),u("div",{key:0,class:w(["Layout",r(i).pageClass])},[c(v.$slots,"layout-top",{},void 0,!0),h(Ia),h(nt,{class:"backdrop",show:r(e),onClick:r(s)},null,8,["show","onClick"]),h(ga,null,{"nav-bar-title-before":p(()=>[c(v.$slots,"nav-bar-title-before",{},void 0,!0)]),"nav-bar-title-after":p(()=>[c(v.$slots,"nav-bar-title-after",{},void 0,!0)]),"nav-bar-content-before":p(()=>[c(v.$slots,"nav-bar-content-before",{},void 0,!0)]),"nav-bar-content-after":p(()=>[c(v.$slots,"nav-bar-content-after",{},void 0,!0)]),"nav-screen-content-before":p(()=>[c(v.$slots,"nav-screen-content-before",{},void 0,!0)]),"nav-screen-content-after":p(()=>[c(v.$slots,"nav-screen-content-after",{},void 0,!0)]),_:3}),h(vs,{open:r(e),onOpenMenu:r(t)},null,8,["open","onOpenMenu"]),h(wa,{open:r(e)},{"sidebar-nav-before":p(()=>[c(v.$slots,"sidebar-nav-before",{},void 0,!0)]),"sidebar-nav-after":p(()=>[c(v.$slots,"sidebar-nav-after",{},void 0,!0)]),_:3},8,["open"]),h(Xn,null,{"page-top":p(()=>[c(v.$slots,"page-top",{},void 0,!0)]),"page-bottom":p(()=>[c(v.$slots,"page-bottom",{},void 0,!0)]),"not-found":p(()=>[c(v.$slots,"not-found",{},void 0,!0)]),"home-hero-before":p(()=>[c(v.$slots,"home-hero-before",{},void 0,!0)]),"home-hero-info-before":p(()=>[c(v.$slots,"home-hero-info-before",{},void 0,!0)]),"home-hero-info":p(()=>[c(v.$slots,"home-hero-info",{},void 0,!0)]),"home-hero-info-after":p(()=>[c(v.$slots,"home-hero-info-after",{},void 0,!0)]),"home-hero-actions-after":p(()=>[c(v.$slots,"home-hero-actions-after",{},void 0,!0)]),"home-hero-image":p(()=>[c(v.$slots,"home-hero-image",{},void 0,!0)]),"home-hero-after":p(()=>[c(v.$slots,"home-hero-after",{},void 0,!0)]),"home-features-before":p(()=>[c(v.$slots,"home-features-before",{},void 0,!0)]),"home-features-after":p(()=>[c(v.$slots,"home-features-after",{},void 0,!0)]),"doc-footer-before":p(()=>[c(v.$slots,"doc-footer-before",{},void 0,!0)]),"doc-before":p(()=>[c(v.$slots,"doc-before",{},void 0,!0)]),"doc-after":p(()=>[c(v.$slots,"doc-after",{},void 0,!0)]),"doc-top":p(()=>[c(v.$slots,"doc-top",{},void 0,!0)]),"doc-bottom":p(()=>[c(v.$slots,"doc-bottom",{},void 0,!0)]),"aside-top":p(()=>[c(v.$slots,"aside-top",{},void 0,!0)]),"aside-bottom":p(()=>[c(v.$slots,"aside-bottom",{},void 0,!0)]),"aside-outline-before":p(()=>[c(v.$slots,"aside-outline-before",{},void 0,!0)]),"aside-outline-after":p(()=>[c(v.$slots,"aside-outline-after",{},void 0,!0)]),"aside-ads-before":p(()=>[c(v.$slots,"aside-ads-before",{},void 0,!0)]),"aside-ads-after":p(()=>[c(v.$slots,"aside-ads-after",{},void 0,!0)]),_:3}),h(ts),c(v.$slots,"layout-bottom",{},void 0,!0)],2)):(a(),k(V,{key:1}))}}}),Ha=g(Aa,[["__scopeId","data-v-a5ebdd2e"]]),ye={Layout:Ha,enhanceApp:({app:o})=>{o.component("Badge",xe)}},Pe=(o,e)=>o.flatMap(t=>[t,e]).slice(0,-1),Ca=_({name:"Publications",props:{pubs:{type:Array,required:!0}},setup(o){const e={arxiv:{name:"arXiv preprint",link:n=>`https://arxiv.org/abs/${n}`},doi:{name:"doi",link:n=>`https://doi.org/${n}`},hal:{name:"hal",link:n=>`https://inria.hal.science/${n}`},online:{name:"online",link:n=>n},slides:{name:"slides",link:n=>n},github:{name:"github",link:n=>`https://github.com/${n}`}};return{formattedLink:(n,i)=>e[n].link(i),getLinkName:n=>e[n].name}},render(){var o;return h("div",null,[(o=this.pubs)==null?void 0:o.map(e=>h("div",null,[h("h3",null,[e.type]),h("ul",null,[e.items.map(t=>h("li",null,[h("div",null,[h("span",{class:"pubs-title"},[t.title]),h("span",null,[E(", by ")]),Pe(t.authors.map(s=>h("span",{class:"pubs-author"},[s.link?h("a",{href:s.link},[s.name]):s.name])),h("span",null,[E(", ")]))]),t.venue?h("div",{class:"pubs-venue"},[t.venue]):null,h("div",null,[Pe(t.links.map(s=>h("a",{class:"pubs-link",href:this.formattedLink(s[0],s[1])},[E(" "),this.getLinkName(s[0])])),h("span",null,[E(" | ")]))])]))])]))])}}),Ba={};function Ea(o,e){return a(),u("div",null,e[0]||(e[0]=[Ze('
',2)]))}const Le=g(Ba,[["render",Ea],["__scopeId","data-v-26586a7a"]]),Da={...ye,Layout(){return ge(ye.Layout,null,{"home-hero-before":()=>ge(Le)})},enhanceApp({app:o}){o.component("Publications",Ca).component("AyaHeader",Le)}};export{Da as R,mo as c,L as u}; diff --git a/assets/guide_fake-literate.md.wKOOxSKp.js b/assets/guide_fake-literate.md.wKOOxSKp.js new file mode 100644 index 0000000..4ee03fb --- /dev/null +++ b/assets/guide_fake-literate.md.wKOOxSKp.js @@ -0,0 +1,45 @@ +import{_ as a,c as i,a2 as n,o as e}from"./chunks/framework.CoXjB5sU.js";const c=JSON.parse('{"title":"Fake literate mode","description":"","frontmatter":{},"headers":[],"relativePath":"guide/fake-literate.md","filePath":"guide/fake-literate.md","lastUpdated":1717700861000}'),t={name:"guide/fake-literate.md"};function l(p,s,h,k,d,r){return e(),i("div",null,s[0]||(s[0]=[n(`

Fake literate mode

The Aya compiler generates styled (e.g. with colors and text attributes) code snippets for many targets, like HTML, LaTeX, etc., and it's tempting to use the same tool but for different languages. This is what the fake literate mode is for. Let me know if you want other backend supports.

To start, install the latest version of Aya, put the following code in a file named hello.flcl:

keyword: data where;
+symbol: ≃;
+data: Int;
+constructor: zero succ;
+------
+data Int where
+  zero : Int
+  succ : Int ≃ Int

Then, run the following command to generate literate output, where you replace <AYA> with either java -jar <path-to-aya.jar> or aya depending on your installation:

<AYA> --fake-literate hello.flcl

Then it will print the following output:

\\AyaKeyword{data}\\hspace{0.5em}\\AyaData{Int}\\hspace{0.5em}\\AyaKeyword{where}~\\\\
+\\hspace{1.0em}\\AyaConstructor{zero}\\hspace{0.5em}:\\hspace{0.5em}\\AyaData{Int}~\\\\
+\\hspace{1.0em}\\AyaConstructor{succ}\\hspace{0.5em}:\\hspace{0.5em}\\AyaData{Int}\\hspace{0.5em}≃\\hspace{0.5em}\\AyaData{Int}

You may add -o hello.tex to let it write to a file instead of printing to the console. With minimal configurations such as below, you can compile it with any LaTeX toolchain:

tex
\\usepackage{newunicodechar}
+\\newunicodechar{≃}{\\ensuremath{\\mathrel{\\simeq}}}
+
+\\usepackage{xcolor}
+
+% Aya highlighting
+\\definecolor{AyaFn}{HTML}{00627a}
+\\definecolor{AyaConstructor}{HTML}{067d17}
+\\definecolor{AyaStruct}{HTML}{00627a}
+\\definecolor{AyaGeneralized}{HTML}{00627a}
+\\definecolor{AyaData}{HTML}{00627a}
+\\definecolor{AyaPrimitive}{HTML}{00627a}
+\\definecolor{AyaKeyword}{HTML}{0033b3}
+\\definecolor{AyaComment}{HTML}{8c8c8c}
+\\definecolor{AyaField}{HTML}{871094}
+\\newcommand\\AyaFn[1]{\\textcolor{AyaFn}{#1}}
+\\newcommand\\AyaConstructor[1]{\\textcolor{AyaConstructor}{#1}}
+\\newcommand\\AyaCall[1]{#1}
+\\newcommand\\AyaStruct[1]{\\textcolor{AyaStruct}{#1}}
+\\newcommand\\AyaGeneralized[1]{\\textcolor{AyaGeneralized}{#1}}
+\\newcommand\\AyaData[1]{\\textcolor{AyaData}{#1}}
+\\newcommand\\AyaPrimitive[1]{\\textcolor{AyaPrimitive}{#1}}
+\\newcommand\\AyaKeyword[1]{\\textcolor{AyaKeyword}{#1}}
+\\newcommand\\AyaLocalVar[1]{\\textit{#1}}
+\\newcommand\\AyaComment[1]{\\textit{\\textcolor{AyaComment}{#1}}}
+\\newcommand\\AyaField[1]{\\textcolor{AyaField}{#1}}

The following code provides a quick macro to include the generated code:

tex
\\newcommand{\\includeFlcl}[1]{{
+\\vspace{0.15cm}
+\\RaggedRight
+% https://tex.stackexchange.com/a/35936/145304
+\\setlength\\parindent{0pt}
+\\setlength{\\leftskip}{1cm}
+\\input{#1}
+
+\\setlength{\\leftskip}{0cm}
+\\vspace{0.15cm}
+}}

Use \\includeFlcl{hello} to include the generated code in your document.

`,13)]))}const E=a(t,[["render",l]]);export{c as __pageData,E as default}; diff --git a/assets/guide_fake-literate.md.wKOOxSKp.lean.js b/assets/guide_fake-literate.md.wKOOxSKp.lean.js new file mode 100644 index 0000000..4ee03fb --- /dev/null +++ b/assets/guide_fake-literate.md.wKOOxSKp.lean.js @@ -0,0 +1,45 @@ +import{_ as a,c as i,a2 as n,o as e}from"./chunks/framework.CoXjB5sU.js";const c=JSON.parse('{"title":"Fake literate mode","description":"","frontmatter":{},"headers":[],"relativePath":"guide/fake-literate.md","filePath":"guide/fake-literate.md","lastUpdated":1717700861000}'),t={name:"guide/fake-literate.md"};function l(p,s,h,k,d,r){return e(),i("div",null,s[0]||(s[0]=[n(`

Fake literate mode

The Aya compiler generates styled (e.g. with colors and text attributes) code snippets for many targets, like HTML, LaTeX, etc., and it's tempting to use the same tool but for different languages. This is what the fake literate mode is for. Let me know if you want other backend supports.

To start, install the latest version of Aya, put the following code in a file named hello.flcl:

keyword: data where;
+symbol: ≃;
+data: Int;
+constructor: zero succ;
+------
+data Int where
+  zero : Int
+  succ : Int ≃ Int

Then, run the following command to generate literate output, where you replace <AYA> with either java -jar <path-to-aya.jar> or aya depending on your installation:

<AYA> --fake-literate hello.flcl

Then it will print the following output:

\\AyaKeyword{data}\\hspace{0.5em}\\AyaData{Int}\\hspace{0.5em}\\AyaKeyword{where}~\\\\
+\\hspace{1.0em}\\AyaConstructor{zero}\\hspace{0.5em}:\\hspace{0.5em}\\AyaData{Int}~\\\\
+\\hspace{1.0em}\\AyaConstructor{succ}\\hspace{0.5em}:\\hspace{0.5em}\\AyaData{Int}\\hspace{0.5em}≃\\hspace{0.5em}\\AyaData{Int}

You may add -o hello.tex to let it write to a file instead of printing to the console. With minimal configurations such as below, you can compile it with any LaTeX toolchain:

tex
\\usepackage{newunicodechar}
+\\newunicodechar{≃}{\\ensuremath{\\mathrel{\\simeq}}}
+
+\\usepackage{xcolor}
+
+% Aya highlighting
+\\definecolor{AyaFn}{HTML}{00627a}
+\\definecolor{AyaConstructor}{HTML}{067d17}
+\\definecolor{AyaStruct}{HTML}{00627a}
+\\definecolor{AyaGeneralized}{HTML}{00627a}
+\\definecolor{AyaData}{HTML}{00627a}
+\\definecolor{AyaPrimitive}{HTML}{00627a}
+\\definecolor{AyaKeyword}{HTML}{0033b3}
+\\definecolor{AyaComment}{HTML}{8c8c8c}
+\\definecolor{AyaField}{HTML}{871094}
+\\newcommand\\AyaFn[1]{\\textcolor{AyaFn}{#1}}
+\\newcommand\\AyaConstructor[1]{\\textcolor{AyaConstructor}{#1}}
+\\newcommand\\AyaCall[1]{#1}
+\\newcommand\\AyaStruct[1]{\\textcolor{AyaStruct}{#1}}
+\\newcommand\\AyaGeneralized[1]{\\textcolor{AyaGeneralized}{#1}}
+\\newcommand\\AyaData[1]{\\textcolor{AyaData}{#1}}
+\\newcommand\\AyaPrimitive[1]{\\textcolor{AyaPrimitive}{#1}}
+\\newcommand\\AyaKeyword[1]{\\textcolor{AyaKeyword}{#1}}
+\\newcommand\\AyaLocalVar[1]{\\textit{#1}}
+\\newcommand\\AyaComment[1]{\\textit{\\textcolor{AyaComment}{#1}}}
+\\newcommand\\AyaField[1]{\\textcolor{AyaField}{#1}}

The following code provides a quick macro to include the generated code:

tex
\\newcommand{\\includeFlcl}[1]{{
+\\vspace{0.15cm}
+\\RaggedRight
+% https://tex.stackexchange.com/a/35936/145304
+\\setlength\\parindent{0pt}
+\\setlength{\\leftskip}{1cm}
+\\input{#1}
+
+\\setlength{\\leftskip}{0cm}
+\\vspace{0.15cm}
+}}

Use \\includeFlcl{hello} to include the generated code in your document.

`,13)]))}const E=a(t,[["render",l]]);export{c as __pageData,E as default}; diff --git a/assets/guide_haskeller-tutorial.md.CwlnPH1m.js b/assets/guide_haskeller-tutorial.md.CwlnPH1m.js new file mode 100644 index 0000000..b9fdac0 --- /dev/null +++ b/assets/guide_haskeller-tutorial.md.CwlnPH1m.js @@ -0,0 +1,75 @@ +import{_ as F,c as N,a2 as h,j as a,a as s,o as M}from"./chunks/framework.CoXjB5sU.js";const V={mounted(){const d=new Map;function y(r){const e=r.querySelectorAll("a[href]");for(const t of e){const o=t.href,p=d.get(o)??new Set;p.add(t),d.set(o,p)}for(const t of e)t.onmouseover=function(){for(const o of d.get(this.href))o.classList.add("hover-highlight")},t.onmouseout=function(){for(const o of d.get(this.href))o.classList.remove("hover-highlight")}}function u(r){return decodeURIComponent(atob(r).split("").map(function(e){return"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)}).join(""))}const k=(r=>{const e={};return(...t)=>{const o=JSON.stringify(t);return e[o]=e[o]||r(...t)}})(u);class f{constructor(){this.list=[]}dismiss(e){e&&(e.remove(),this.list=this.list.filter(t=>t!==e))}dismissIfNotUsed(e){e&&(e.markedForDismissal=!0,setTimeout(()=>{!e.userIsThinking&&this.allowAutoDismissal(e)&&this.dismiss(e)},1e3))}allowAutoDismissal(e){return e.markedForDismissal&&!e.userClicked}fireAutoDismissalFor(e){let t=this.list.find(o=>o.userCreatedFrom===e);this.dismissIfNotUsed(t)}createHoverFor(e,t,o){let p=this.list.find(i=>i.userCreatedFrom===e);if(p&&p.userClicked)return p;let x=[];const b=this.list.filter(i=>{if(this.allowAutoDismissal(i))return x.push(i),!1;const l=i.userCreatedFrom,v=e;let c=v;for(;c;){if(c===l)return!0;c=c.parentElement}for(c=l;c;){if(c===v)return!0;c=c.parentElement}return!1});x.forEach(i=>this.dismiss(i));let n=document.createElement("div");n.userCreatedFrom=e,n.innerHTML="×"+k(t),n.classList.add("AyaTooltipPopup"),y(n);let A=this;if(n.handleEvent=function(i){if(i.type==="click"){this.userClicked=!0,this.markedForDismissal=!1;let l=this.children[0];if(!l)return;let v=this;l.style.visibility="visible",l.addEventListener("click",c=>A.dismiss(v))}i.type==="mouseover"&&(this.userIsThinking=!0),i.type==="mouseout"&&(this.userIsThinking=!1,A.dismissIfNotUsed(this))},n.addEventListener("click",n),n.addEventListener("mouseover",n),n.addEventListener("mouseout",n),o.appendChild(n),n.style.left=`${e.offsetLeft}px`,b.length===0){const i=e.getBoundingClientRect(),l=n.getBoundingClientRect();i.bottom+l.height+30>window.innerHeight?n.style.top=`calc(${e.offsetTop-l.height+8}px - 3em)`:n.style.top=`${e.offsetTop+e.offsetHeight+8}px`}else{const i=Math.max(...b.map(l=>l.offsetTop+l.offsetHeight));n.style.top=`${i+8}px`}return this.list.push(n),n}}let g=new f;function m(r){return function(){let e=this;const t=e.getAttribute("data-tooltip-text");t&&(r?g.createHoverFor(e,t,document.body):g.fireAutoDismissalFor(e))}}y(document);{let r=document.getElementsByClassName("aya-tooltip");for(let e=0;eSo you know some Haskell

Great. I expect you to know something about GHCi and algebraic data types. This is an Aya tutorial for Haskell programmers. If you find a bug, open an issue on GitHub!

Working with the REPL

Aya has a REPL that works similar to GHCi. You can start it by running aya -i in your terminal, and you can start typing definitions or expressions.

bash
aya -i

If you're using jar with java, use the following instead:

bash
java --enable-preview -jar cli-fatjar.jar -i

In the REPL, you can use :l to load a file, :q to quit, and :? to get help. Use :t to show the type. Since it's dependent type, you can toggle normalization levels by :normalize followed by NF, WHNF, or NULL (don't normalize).

To work multiline, use the pair :{ and :} -- same as GHCi.

Aya supports pretty-printing of any terms, including ✨lambdas✨. Note that Aya does not automatically support generic lambdas, so typing \\x => x would not work. You need to specify the type of x, like \\(x : Int) => x.

Aya support fn as an alias to \\ instead of λ, similar to Coq and Lean (but not Agda). This is because users (especially mathematicians) are likely to use λ as a variable name. Similarly, we used Fn over Pi or Π for the same reason.

Working with projects

Read project-tutorial, it is very short. It is recommended to practice the following with an Aya project in VSCode, see vscode-tutorial.

About modules:

  • Aya module names are separated by ::, not ..
  • Aya infers the module names automagically, using the same rule as of Haskell.
  • Aya imports (import X) are qualified by default, use open import X to unqualify. This is short for import X followed by open X.
  • Aya supports restricted import open import X using (x) (this only imports x from X) you may also use open import X hiding (x) to import everything except x from X.
  • Aya supports renamed import open import X using (x as y) and the meaning is obvious.
  • To re-export, use a public open.

Ok, let's write some code!

Programming in Aya

Natural numbers. In Haskell:

haskell
data Nat = Zero | Suc Nat

In Aya (we replaced the keyword data with inductive because we want to use it as a package name):

',20),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Nat",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(" | "),a("a",{id:"Mian-Nat-zero",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-zero"},[a("span",{class:"Constructor"},"zero")]),s(" | "),a("a",{id:"Mian-Nat-suc",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")])]),s(` +`)],-1),h(`

We don't enforce capitalization of constructors. The constructors need to be qualified (like Nat::zero) to access. As you may expect, Nat automatically becomes a module, so we can use open and public open to unqualify the constructors.

Bonus: if you define a data type that looks like Nat, then you can use numeric literals.

Functions are defined with def, followed by pattern matching. Consider this natural number addition in Haskell (intentionally not called + to avoid name clash with Prelude):

haskell
(<+>) :: Nat -> Nat -> Nat
+Zero <+> n = n
+Suc m <+> n = Suc (m <+> n)
+
+infixl 6 <+>

In Aya (remember the numeric literal thing?):

`,5),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("a",{href:"#Nat"},"Nat"),s(` +`),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"Keyword"},"infixl"),s(),a("a",{id:"Mian-3c2b3e",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3c2b3e"},[a("span",{class:"Fn"},"<+>")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(` +| 0, `),a("a",{id:"v572145572",class:"aya-hover","aya-hover-text":"Nat",href:"#v572145572"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v572145572"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{id:"v711540569",class:"aya-hover","aya-hover-text":"Nat",href:"#v711540569"},[a("span",{class:"LocalVar"},"m")]),s(", "),a("a",{id:"v1396431506",class:"aya-hover","aya-hover-text":"Nat",href:"#v1396431506"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v711540569"},[a("span",{class:"LocalVar"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3c2b3e"},[a("span",{class:"Fn"},"<+>")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1396431506"},[a("span",{class:"LocalVar"},"n")]),s(")")]),s(` +`)],-1),h(`

There are plenty of differences. Let's go through them one by one.

The infixl declares <+> to be a left-associative infix operator. Other options include infix, infixr, fixl, and fixr. Without it, the function will work the same as normal function. Unlike Haskell, we do not distinguish "operator" names and "function" names.

We do not use a number to denote precedence, but a partial order. This allows arbitrary insertion of new precedence level into previously defined ones. Say you want <+> to have a lower precedence than <*>, you can do:

def infixl <+> Nat Nat : Nat
+/// .... omitted
+looser <*>

You also have tighter, with the obvious meaning.

The parameters and the return type are separated using :. The parameter types can be written directly, without ->. Aya allow naming the parameters like this:

def oh (x : Nat) : Nat

These names can be used for one-linear function bodies:

`,8),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-oh",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-oh"},[a("span",{class:"Fn"},"oh")]),s(" ("),a("a",{id:"v1041109062",class:"aya-hover","aya-hover-text":"Nat",href:"#v1041109062"},[a("span",{class:"LocalVar"},"x")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1041109062"},[a("span",{class:"LocalVar"},"x")])]),s(` +`)],-1),h(`

Aya supports a painless version of the section syntax, where the top-level does not need parentheses. See the following REPL output (the underscored names are internally generated variable names. If you have an idea on how to make them better, open an issue and let's discuss!).

> 1 <+>
+suc
+
+> <+> 1
+λ _7 ⇒ _7 <+> 1
+
+> 1 <+> 1
+suc 1
+
+> 2 <+>
+λ _5 ⇒ suc (suc _5)
+
+> <+> 2
+λ _7 ⇒ _7 <+> 2

When we only need to pattern match on a subset of the parameters, we can use the elim keyword:

`,3),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"example"),s(),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"Keyword"},"infixl"),s(),a("a",{id:"Mian-3aNoExport-5b2b5d",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3aNoExport-5b2b5d"},[a("span",{class:"Fn"},"[+]")]),s(" ("),a("a",{id:"v1351478315",class:"aya-hover","aya-hover-text":"Nat",href:"#v1351478315"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v508512860",class:"aya-hover","aya-hover-text":"Nat",href:"#v508512860"},[a("span",{class:"LocalVar"},"n")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(),a("span",{class:"Keyword"},"elim"),s(),a("a",{href:"#v1351478315"},[a("span",{class:"LocalVar"},"a")]),s(` +| 0 ⇒ `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v508512860"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{id:"v1569754439",class:"aya-hover","aya-hover-text":"Nat",href:"#v1569754439"},[a("span",{class:"LocalVar"},"m")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1569754439"},[a("span",{class:"LocalVar"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3aNoExport-5b2b5d"},[a("span",{class:"Fn"},"[+]")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v508512860"},[a("span",{class:"LocalVar"},"n")]),s(")")]),s(` +`)],-1),h(`

Type-level programming

In Haskell:

haskell
id :: a -> a
+id x = x

In Aya:

`,4),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-id",class:"aya-hover","aya-hover-text":"A",href:"#Mian-id"},[a("span",{class:"Fn"},"id")]),s(" {"),a("a",{id:"v530539368",class:"aya-hover","aya-hover-text":"Type 0",href:"#v530539368"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("span",{class:"Keyword"},"Type"),s("} ("),a("a",{id:"v479920916",class:"aya-hover","aya-hover-text":"A",href:"#v479920916"},[a("span",{class:"LocalVar"},"x")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v530539368"},[a("span",{class:"LocalVar"},"A")]),s(") ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v479920916"},[a("span",{class:"LocalVar"},"x")])]),s(` +`)],-1),h("

Observations:

  • Type parameters have to be explicitly qualified using curly braces.
  • Curly braces denote parameters that are omitted (and will be inferred by type checker) in the pattern matching and invocations. So, parentheses denote parameters that are not omitted.
  • Apart from Type, we also have Set, and ISet. For now, don't use the others.

Type constructors are like {F : Type -> Type} (and yes, the -> denotes function types, works for both values and types), very obvious. Definition of Maybe in Aya:

",3),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Maybe",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Maybe"},[a("span",{class:"Data"},"Maybe")]),s(" ("),a("a",{id:"v1096485705",class:"aya-hover","aya-hover-text":"Type 0",href:"#v1096485705"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("span",{class:"Keyword"},"Type"),s(`) +| `),a("a",{id:"Mian-Maybe-nothing",class:"aya-hover","aya-hover-text":"Maybe A",href:"#Mian-Maybe-nothing"},[a("span",{class:"Constructor"},"nothing")]),s(` +| `),a("a",{id:"Mian-Maybe-just",class:"aya-hover","aya-hover-text":"Maybe A",href:"#Mian-Maybe-just"},[a("span",{class:"Constructor"},"just")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1096485705"},[a("span",{class:"LocalVar"},"A")])]),s(` +`)],-1),a("p",null,[s("Here, "),a("code",null,"(A : Type)"),s(" is an explicit parameter, because you write "),a("code",null,"Maybe Nat"),s(", not just "),a("code",null,"Maybe"),s(".")],-1),a("p",null,[s("There is a way to automagically insert the implicit parameters -- the "),a("code",null,"variable"),s(" keyword.")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"variable"),s(),a("a",{id:"v1912960603",href:"#v1912960603"},[a("span",{class:"Generalized"},"A")]),s(" : "),a("span",{class:"Keyword"},"Type"),s(` + +`),a("span",{class:"Comment"},"// Now, since you are using A, so Aya inserts {A : Type}"),s(` +`),a("span",{class:"Keyword"},"example"),s(),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+V2FybmluZzogVGhlIG5hbWUgPGNvZGUgY2xhc3M9IkF5YSI+aWQ8L2NvZGU+IHNoYWRvd3MgYSBwcmV2aW91cyBsb2NhbCBkZWZpbml0aW9uIGZyb20gb3V0ZXIgc2NvcGU8L2NvZGU+CjwvcHJlPgo="},[a("span",{class:"Warning"},[a("a",{id:"Mian-3aNoExport-id",class:"aya-hover","aya-hover-text":"A",href:"#Mian-3aNoExport-id"},[a("span",{class:"Fn"},"id")])])]),s(" ("),a("a",{id:"v2017797638",class:"aya-hover","aya-hover-text":"A",href:"#v2017797638"},[a("span",{class:"LocalVar"},"x")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1912960603"},[a("span",{class:"Generalized"},"A")]),s(") ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v2017797638"},[a("span",{class:"LocalVar"},"x")])]),s(` +`)],-1),a("p",null,"Aya supports type aliases as functions. For example, we may define the type of binary operators as a function:",-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-BinOp",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-BinOp"},[a("span",{class:"Fn"},"BinOp")]),s(" ("),a("a",{id:"v1150058854",class:"aya-hover","aya-hover-text":"Type 0",href:"#v1150058854"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("span",{class:"Keyword"},"Type"),s(") ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1150058854"},[a("span",{class:"LocalVar"},"A")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1150058854"},[a("span",{class:"LocalVar"},"A")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1150058854"},[a("span",{class:"LocalVar"},"A")])]),s(` +`)],-1),a("p",null,[s("Then, we can define "),a("code",null,"<+>"),s(" as:")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"example"),s(),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"Keyword"},"infixl"),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+V2FybmluZzogVGhlIG5hbWUgPGNvZGUgY2xhc3M9IkF5YSI+Jmx0OysmZ3Q7PC9jb2RlPiBzaGFkb3dzIGEgcHJldmlvdXMgbG9jYWwgZGVmaW5pdGlvbiBmcm9tIG91dGVyIHNjb3BlPC9jb2RlPgo8L3ByZT4K"},[a("span",{class:"Warning"},[a("a",{id:"Mian-3aNoExport-3c2b3e",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3aNoExport-3c2b3e"},[a("span",{class:"Fn"},"<+>")])])]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-BinOp"},[a("span",{class:"Fn"},"BinOp")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(` +| 0, `),a("a",{id:"v1624972302",class:"aya-hover","aya-hover-text":"Nat",href:"#v1624972302"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1624972302"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{id:"v1048098469",class:"aya-hover","aya-hover-text":"Nat",href:"#v1048098469"},[a("span",{class:"LocalVar"},"m")]),s(", "),a("a",{id:"v1989811701",class:"aya-hover","aya-hover-text":"Nat",href:"#v1989811701"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1048098469"},[a("span",{class:"LocalVar"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3aNoExport-3c2b3e"},[a("span",{class:"Fn"},"<+>")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1989811701"},[a("span",{class:"LocalVar"},"n")]),s(")")]),s(` +`)],-1),a("h2",{id:"type-families",tabindex:"-1"},[s("Type families "),a("a",{class:"header-anchor",href:"#type-families","aria-label":'Permalink to "Type families"'},"​")],-1),a("p",null,[s("In Aya, type families are functions. Consider the following code (they are using the "),a("code",null,"variable A"),s(" defined above):")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Comment"},"// Unit type"),s(` +`),a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Unit",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Unit"},[a("span",{class:"Data"},"Unit")]),s(" | "),a("a",{id:"Mian-Unit-unit",class:"aya-hover","aya-hover-text":"Unit",href:"#Mian-Unit-unit"},[a("span",{class:"Constructor"},"unit")]),s(` + +`),a("span",{class:"Comment"},"// A type family"),s(` +`),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-FromJust",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-FromJust"},[a("span",{class:"Fn"},"FromJust")]),s(" ("),a("a",{id:"v2037764568",class:"aya-hover","aya-hover-text":"Maybe A",href:"#v2037764568"},[a("span",{class:"LocalVar"},"x")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Maybe"},[a("span",{class:"Data"},"Maybe")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1912960603"},[a("span",{class:"Generalized"},"A")]),s(") : "),a("span",{class:"Keyword"},"Type"),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Maybe A",href:"#Mian-Maybe-just"},[a("span",{class:"Constructor"},"just")]),s(),a("a",{id:"v605052357",class:"aya-hover","aya-hover-text":"A",href:"#v605052357"},[a("span",{class:"LocalVar"},"a")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1912960603"},[a("span",{class:"Generalized"},"A")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Maybe A",href:"#Mian-Maybe-nothing"},[a("span",{class:"Constructor"},"nothing")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Unit"},[a("span",{class:"Data"},"Unit")]),s(` + +`),a("span",{class:"Comment"},"// A function that uses the type family"),s(` +`),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-fromJust",class:"aya-hover","aya-hover-text":"FromJust x",href:"#Mian-fromJust"},[a("span",{class:"Fn"},"fromJust")]),s(" ("),a("a",{id:"v238762799",class:"aya-hover","aya-hover-text":"Maybe A",href:"#v238762799"},[a("span",{class:"LocalVar"},"x")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Maybe"},[a("span",{class:"Data"},"Maybe")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1912960603"},[a("span",{class:"Generalized"},"A")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-FromJust"},[a("span",{class:"Fn"},"FromJust")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Maybe A",href:"#v238762799"},[a("span",{class:"LocalVar"},"x")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Maybe A",href:"#Mian-Maybe-just"},[a("span",{class:"Constructor"},"just")]),s(),a("a",{id:"v1267149311",class:"aya-hover","aya-hover-text":"A",href:"#v1267149311"},[a("span",{class:"LocalVar"},"a")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1267149311"},[a("span",{class:"LocalVar"},"a")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Maybe A",href:"#Mian-Maybe-nothing"},[a("span",{class:"Constructor"},"nothing")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Unit",href:"#Mian-Unit-unit"},[a("span",{class:"Constructor"},"unit")])]),s(` +`)],-1),a("p",null,[s("And "),a("code",null,"fromJust (just a)"),s(" will evaluate to "),a("code",null,"a"),s(". In Haskell, you need to use some language extensions alongside some scary keywords. These functions are available in constructors, too:")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Example",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Example"},[a("span",{class:"Data"},"Example")]),s(" ("),a("a",{id:"v2104973502",class:"aya-hover","aya-hover-text":"Type 0",href:"#v2104973502"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("span",{class:"Keyword"},"Type"),s(`) +| `),a("a",{id:"Mian-Example-cons",class:"aya-hover","aya-hover-text":"Example A",href:"#Mian-Example-cons"},[a("span",{class:"Constructor"},"cons")]),s(" ("),a("a",{id:"v735937428",class:"aya-hover","aya-hover-text":"Maybe A",href:"#v735937428"},[a("span",{class:"LocalVar"},"x")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Maybe"},[a("span",{class:"Data"},"Maybe")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v2104973502"},[a("span",{class:"LocalVar"},"A")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-FromJust"},[a("span",{class:"Fn"},"FromJust")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Maybe A",href:"#v735937428"},[a("span",{class:"LocalVar"},"x")]),s(")")]),s(` +`)],-1),h(`

It is recommended to play with it in the REPL to get a feel of it.

There is a famous example of dependent types in Haskell -- the sized vector type:

haskell
{-# LANGUAGE GADTs #-}
+{-# LANGUAGE DataKinds #-}
+-- Maybe you need more, I don't remember exactly
+
+data Vec :: Nat -> Type -> Type where
+  Nil :: Vec Zero a
+  (:<) :: a -> Vec n a -> Vec (Suc n) a
+infixr :<

In Aya, we have a better syntax:

`,4),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Vec",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(" ("),a("a",{id:"v788625466",class:"aya-hover","aya-hover-text":"Nat",href:"#v788625466"},[a("span",{class:"LocalVar"},"n")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(") ("),a("a",{id:"v1753714541",class:"aya-hover","aya-hover-text":"Type 0",href:"#v1753714541"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("span",{class:"Keyword"},"Type"),s(`) +| 0, `),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+V2FybmluZzogVGhlIG5hbWUgPGNvZGUgY2xhc3M9IkF5YSI+QTwvY29kZT4gc2hhZG93cyBhIHByZXZpb3VzIGxvY2FsIGRlZmluaXRpb24gZnJvbSBvdXRlciBzY29wZTwvY29kZT4KPC9wcmU+Cg=="},[a("span",{class:"Warning"},[a("a",{id:"v1095273238",class:"aya-hover","aya-hover-text":"Type 0",href:"#v1095273238"},[a("span",{class:"LocalVar"},"A")])])]),s(" ⇒ "),a("a",{id:"Mian-Vec-nil",class:"aya-hover","aya-hover-text":"Vec 0 A",href:"#Mian-Vec-nil"},[a("span",{class:"Constructor"},"nil")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+V2FybmluZzogVGhlIG5hbWUgPGNvZGUgY2xhc3M9IkF5YSI+bjwvY29kZT4gc2hhZG93cyBhIHByZXZpb3VzIGxvY2FsIGRlZmluaXRpb24gZnJvbSBvdXRlciBzY29wZTwvY29kZT4KPC9wcmU+Cg=="},[a("span",{class:"Warning"},[a("a",{id:"v1423983012",class:"aya-hover","aya-hover-text":"Nat",href:"#v1423983012"},[a("span",{class:"LocalVar"},"n")])])]),s(", "),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+V2FybmluZzogVGhlIG5hbWUgPGNvZGUgY2xhc3M9IkF5YSI+QTwvY29kZT4gc2hhZG93cyBhIHByZXZpb3VzIGxvY2FsIGRlZmluaXRpb24gZnJvbSBvdXRlciBzY29wZTwvY29kZT4KPC9wcmU+Cg=="},[a("span",{class:"Warning"},[a("a",{id:"v746074699",class:"aya-hover","aya-hover-text":"Type 0",href:"#v746074699"},[a("span",{class:"LocalVar"},"A")])])]),s(" ⇒ "),a("span",{class:"Keyword"},"infixr"),s(),a("a",{id:"Mian-Vec-3a3c",class:"aya-hover","aya-hover-text":"Vec (suc n) A",href:"#Mian-Vec-3a3c"},[a("span",{class:"Constructor"},":<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v746074699"},[a("span",{class:"LocalVar"},"A")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1423983012"},[a("span",{class:"LocalVar"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v746074699"},[a("span",{class:"LocalVar"},"A")]),s(")")]),s(` +`)],-1),a("p",null,[s("The "),a("code",null,":<"),s(" constructor is defined as a right-associative infix operator. And yes, you can define like vector append painlessly:")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"variable"),s(),a("a",{id:"v416841088",href:"#v416841088"},[a("span",{class:"Generalized"},"m")]),s(),a("a",{id:"v452121674",href:"#v452121674"},[a("span",{class:"Generalized"},"n")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(` + +`),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"Keyword"},"infixr"),s(),a("a",{id:"Mian-2b2b",class:"aya-hover","aya-hover-text":"Vec (n <+> m) A",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v452121674"},[a("span",{class:"Generalized"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1912960603"},[a("span",{class:"Generalized"},"A")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v416841088"},[a("span",{class:"Generalized"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1912960603"},[a("span",{class:"Generalized"},"A")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v452121674"},[a("span",{class:"Generalized"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3c2b3e"},[a("span",{class:"Fn"},"<+>")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v416841088"},[a("span",{class:"Generalized"},"m")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1912960603"},[a("span",{class:"Generalized"},"A")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Vec 0 A",href:"#Mian-Vec-nil"},[a("span",{class:"Constructor"},"nil")]),s(", "),a("a",{id:"v573200870",class:"aya-hover","aya-hover-text":"Vec m A",href:"#v573200870"},[a("span",{class:"LocalVar"},"ys")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Vec m A",href:"#v573200870"},[a("span",{class:"LocalVar"},"ys")]),s(` +| `),a("a",{id:"v1046665075",class:"aya-hover","aya-hover-text":"A",href:"#v1046665075"},[a("span",{class:"LocalVar"},"x")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (suc n) A",href:"#Mian-Vec-3a3c"},[a("span",{class:"Constructor"},":<")]),s(),a("a",{id:"v1324829744",class:"aya-hover","aya-hover-text":"Vec n A",href:"#v1324829744"},[a("span",{class:"LocalVar"},"xs")]),s(", "),a("a",{id:"v1921242091",class:"aya-hover","aya-hover-text":"Vec m A",href:"#v1921242091"},[a("span",{class:"LocalVar"},"ys")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1046665075"},[a("span",{class:"LocalVar"},"x")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (suc (?n A x xs ys n m)) (?A A x xs ys n m)",href:"#Mian-Vec-3a3c"},[a("span",{class:"Constructor"},":<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec n A",href:"#v1324829744"},[a("span",{class:"LocalVar"},"xs")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (?n A x xs ys n m <+> ?m A x xs ys n m) (?A A x xs ys n m)",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec m A",href:"#v1921242091"},[a("span",{class:"LocalVar"},"ys")]),s(` +`),a("span",{class:"Keyword"},"tighter"),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (suc n) A",href:"#Mian-Vec-3a3c"},[a("span",{class:"Constructor"},":<")])]),s(` +`)],-1),h(`

Imagine how much work this is in Haskell.

Overlapping patterns

There is one more bonus: in Aya, you may modify the definition of <+> to be:

overlap def infixl <+> Nat Nat : Nat
+| 0, n => n
+| n, 0 => n
+| suc m, n => suc (m <+> n)

It says we not only compute 0 + n = n, but when the first parameter is neither 0 nor suc, we may take a look at the second parameter and seek for other potential computations. This is completely useless at runtime, but very good for type checking. For instance, we may want a Vec of size n, and what we have is some Vec of size n + 0. Then having n + 0 to directly reduce to n is very useful, otherwise we will need to write a conversion function that does nothing but changes the type, or use unsafeCoerce.

With n + 0 = n judgmentally, we now have more possibilities. For instance, we can make xs ++ nil = xs. This involves in two steps: we first turni ++ into a overlap def, then we add the following clause to ++:

| xs, nil => xs

This makes ++ compute on more cases too.

For more information about this feature, checkout the tutorial for proof assistant users.

`,9)]))}const D=F(V,[["render",T]]);export{C as __pageData,D as default}; diff --git a/assets/guide_haskeller-tutorial.md.CwlnPH1m.lean.js b/assets/guide_haskeller-tutorial.md.CwlnPH1m.lean.js new file mode 100644 index 0000000..b9fdac0 --- /dev/null +++ b/assets/guide_haskeller-tutorial.md.CwlnPH1m.lean.js @@ -0,0 +1,75 @@ +import{_ as F,c as N,a2 as h,j as a,a as s,o as M}from"./chunks/framework.CoXjB5sU.js";const V={mounted(){const d=new Map;function y(r){const e=r.querySelectorAll("a[href]");for(const t of e){const o=t.href,p=d.get(o)??new Set;p.add(t),d.set(o,p)}for(const t of e)t.onmouseover=function(){for(const o of d.get(this.href))o.classList.add("hover-highlight")},t.onmouseout=function(){for(const o of d.get(this.href))o.classList.remove("hover-highlight")}}function u(r){return decodeURIComponent(atob(r).split("").map(function(e){return"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)}).join(""))}const k=(r=>{const e={};return(...t)=>{const o=JSON.stringify(t);return e[o]=e[o]||r(...t)}})(u);class f{constructor(){this.list=[]}dismiss(e){e&&(e.remove(),this.list=this.list.filter(t=>t!==e))}dismissIfNotUsed(e){e&&(e.markedForDismissal=!0,setTimeout(()=>{!e.userIsThinking&&this.allowAutoDismissal(e)&&this.dismiss(e)},1e3))}allowAutoDismissal(e){return e.markedForDismissal&&!e.userClicked}fireAutoDismissalFor(e){let t=this.list.find(o=>o.userCreatedFrom===e);this.dismissIfNotUsed(t)}createHoverFor(e,t,o){let p=this.list.find(i=>i.userCreatedFrom===e);if(p&&p.userClicked)return p;let x=[];const b=this.list.filter(i=>{if(this.allowAutoDismissal(i))return x.push(i),!1;const l=i.userCreatedFrom,v=e;let c=v;for(;c;){if(c===l)return!0;c=c.parentElement}for(c=l;c;){if(c===v)return!0;c=c.parentElement}return!1});x.forEach(i=>this.dismiss(i));let n=document.createElement("div");n.userCreatedFrom=e,n.innerHTML="×"+k(t),n.classList.add("AyaTooltipPopup"),y(n);let A=this;if(n.handleEvent=function(i){if(i.type==="click"){this.userClicked=!0,this.markedForDismissal=!1;let l=this.children[0];if(!l)return;let v=this;l.style.visibility="visible",l.addEventListener("click",c=>A.dismiss(v))}i.type==="mouseover"&&(this.userIsThinking=!0),i.type==="mouseout"&&(this.userIsThinking=!1,A.dismissIfNotUsed(this))},n.addEventListener("click",n),n.addEventListener("mouseover",n),n.addEventListener("mouseout",n),o.appendChild(n),n.style.left=`${e.offsetLeft}px`,b.length===0){const i=e.getBoundingClientRect(),l=n.getBoundingClientRect();i.bottom+l.height+30>window.innerHeight?n.style.top=`calc(${e.offsetTop-l.height+8}px - 3em)`:n.style.top=`${e.offsetTop+e.offsetHeight+8}px`}else{const i=Math.max(...b.map(l=>l.offsetTop+l.offsetHeight));n.style.top=`${i+8}px`}return this.list.push(n),n}}let g=new f;function m(r){return function(){let e=this;const t=e.getAttribute("data-tooltip-text");t&&(r?g.createHoverFor(e,t,document.body):g.fireAutoDismissalFor(e))}}y(document);{let r=document.getElementsByClassName("aya-tooltip");for(let e=0;eSo you know some Haskell

Great. I expect you to know something about GHCi and algebraic data types. This is an Aya tutorial for Haskell programmers. If you find a bug, open an issue on GitHub!

Working with the REPL

Aya has a REPL that works similar to GHCi. You can start it by running aya -i in your terminal, and you can start typing definitions or expressions.

bash
aya -i

If you're using jar with java, use the following instead:

bash
java --enable-preview -jar cli-fatjar.jar -i

In the REPL, you can use :l to load a file, :q to quit, and :? to get help. Use :t to show the type. Since it's dependent type, you can toggle normalization levels by :normalize followed by NF, WHNF, or NULL (don't normalize).

To work multiline, use the pair :{ and :} -- same as GHCi.

Aya supports pretty-printing of any terms, including ✨lambdas✨. Note that Aya does not automatically support generic lambdas, so typing \\x => x would not work. You need to specify the type of x, like \\(x : Int) => x.

Aya support fn as an alias to \\ instead of λ, similar to Coq and Lean (but not Agda). This is because users (especially mathematicians) are likely to use λ as a variable name. Similarly, we used Fn over Pi or Π for the same reason.

Working with projects

Read project-tutorial, it is very short. It is recommended to practice the following with an Aya project in VSCode, see vscode-tutorial.

About modules:

  • Aya module names are separated by ::, not ..
  • Aya infers the module names automagically, using the same rule as of Haskell.
  • Aya imports (import X) are qualified by default, use open import X to unqualify. This is short for import X followed by open X.
  • Aya supports restricted import open import X using (x) (this only imports x from X) you may also use open import X hiding (x) to import everything except x from X.
  • Aya supports renamed import open import X using (x as y) and the meaning is obvious.
  • To re-export, use a public open.

Ok, let's write some code!

Programming in Aya

Natural numbers. In Haskell:

haskell
data Nat = Zero | Suc Nat

In Aya (we replaced the keyword data with inductive because we want to use it as a package name):

',20),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Nat",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(" | "),a("a",{id:"Mian-Nat-zero",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-zero"},[a("span",{class:"Constructor"},"zero")]),s(" | "),a("a",{id:"Mian-Nat-suc",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")])]),s(` +`)],-1),h(`

We don't enforce capitalization of constructors. The constructors need to be qualified (like Nat::zero) to access. As you may expect, Nat automatically becomes a module, so we can use open and public open to unqualify the constructors.

Bonus: if you define a data type that looks like Nat, then you can use numeric literals.

Functions are defined with def, followed by pattern matching. Consider this natural number addition in Haskell (intentionally not called + to avoid name clash with Prelude):

haskell
(<+>) :: Nat -> Nat -> Nat
+Zero <+> n = n
+Suc m <+> n = Suc (m <+> n)
+
+infixl 6 <+>

In Aya (remember the numeric literal thing?):

`,5),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("a",{href:"#Nat"},"Nat"),s(` +`),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"Keyword"},"infixl"),s(),a("a",{id:"Mian-3c2b3e",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3c2b3e"},[a("span",{class:"Fn"},"<+>")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(` +| 0, `),a("a",{id:"v572145572",class:"aya-hover","aya-hover-text":"Nat",href:"#v572145572"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v572145572"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{id:"v711540569",class:"aya-hover","aya-hover-text":"Nat",href:"#v711540569"},[a("span",{class:"LocalVar"},"m")]),s(", "),a("a",{id:"v1396431506",class:"aya-hover","aya-hover-text":"Nat",href:"#v1396431506"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v711540569"},[a("span",{class:"LocalVar"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3c2b3e"},[a("span",{class:"Fn"},"<+>")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1396431506"},[a("span",{class:"LocalVar"},"n")]),s(")")]),s(` +`)],-1),h(`

There are plenty of differences. Let's go through them one by one.

The infixl declares <+> to be a left-associative infix operator. Other options include infix, infixr, fixl, and fixr. Without it, the function will work the same as normal function. Unlike Haskell, we do not distinguish "operator" names and "function" names.

We do not use a number to denote precedence, but a partial order. This allows arbitrary insertion of new precedence level into previously defined ones. Say you want <+> to have a lower precedence than <*>, you can do:

def infixl <+> Nat Nat : Nat
+/// .... omitted
+looser <*>

You also have tighter, with the obvious meaning.

The parameters and the return type are separated using :. The parameter types can be written directly, without ->. Aya allow naming the parameters like this:

def oh (x : Nat) : Nat

These names can be used for one-linear function bodies:

`,8),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-oh",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-oh"},[a("span",{class:"Fn"},"oh")]),s(" ("),a("a",{id:"v1041109062",class:"aya-hover","aya-hover-text":"Nat",href:"#v1041109062"},[a("span",{class:"LocalVar"},"x")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1041109062"},[a("span",{class:"LocalVar"},"x")])]),s(` +`)],-1),h(`

Aya supports a painless version of the section syntax, where the top-level does not need parentheses. See the following REPL output (the underscored names are internally generated variable names. If you have an idea on how to make them better, open an issue and let's discuss!).

> 1 <+>
+suc
+
+> <+> 1
+λ _7 ⇒ _7 <+> 1
+
+> 1 <+> 1
+suc 1
+
+> 2 <+>
+λ _5 ⇒ suc (suc _5)
+
+> <+> 2
+λ _7 ⇒ _7 <+> 2

When we only need to pattern match on a subset of the parameters, we can use the elim keyword:

`,3),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"example"),s(),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"Keyword"},"infixl"),s(),a("a",{id:"Mian-3aNoExport-5b2b5d",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3aNoExport-5b2b5d"},[a("span",{class:"Fn"},"[+]")]),s(" ("),a("a",{id:"v1351478315",class:"aya-hover","aya-hover-text":"Nat",href:"#v1351478315"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v508512860",class:"aya-hover","aya-hover-text":"Nat",href:"#v508512860"},[a("span",{class:"LocalVar"},"n")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(),a("span",{class:"Keyword"},"elim"),s(),a("a",{href:"#v1351478315"},[a("span",{class:"LocalVar"},"a")]),s(` +| 0 ⇒ `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v508512860"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{id:"v1569754439",class:"aya-hover","aya-hover-text":"Nat",href:"#v1569754439"},[a("span",{class:"LocalVar"},"m")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1569754439"},[a("span",{class:"LocalVar"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3aNoExport-5b2b5d"},[a("span",{class:"Fn"},"[+]")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v508512860"},[a("span",{class:"LocalVar"},"n")]),s(")")]),s(` +`)],-1),h(`

Type-level programming

In Haskell:

haskell
id :: a -> a
+id x = x

In Aya:

`,4),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-id",class:"aya-hover","aya-hover-text":"A",href:"#Mian-id"},[a("span",{class:"Fn"},"id")]),s(" {"),a("a",{id:"v530539368",class:"aya-hover","aya-hover-text":"Type 0",href:"#v530539368"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("span",{class:"Keyword"},"Type"),s("} ("),a("a",{id:"v479920916",class:"aya-hover","aya-hover-text":"A",href:"#v479920916"},[a("span",{class:"LocalVar"},"x")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v530539368"},[a("span",{class:"LocalVar"},"A")]),s(") ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v479920916"},[a("span",{class:"LocalVar"},"x")])]),s(` +`)],-1),h("

Observations:

  • Type parameters have to be explicitly qualified using curly braces.
  • Curly braces denote parameters that are omitted (and will be inferred by type checker) in the pattern matching and invocations. So, parentheses denote parameters that are not omitted.
  • Apart from Type, we also have Set, and ISet. For now, don't use the others.

Type constructors are like {F : Type -> Type} (and yes, the -> denotes function types, works for both values and types), very obvious. Definition of Maybe in Aya:

",3),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Maybe",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Maybe"},[a("span",{class:"Data"},"Maybe")]),s(" ("),a("a",{id:"v1096485705",class:"aya-hover","aya-hover-text":"Type 0",href:"#v1096485705"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("span",{class:"Keyword"},"Type"),s(`) +| `),a("a",{id:"Mian-Maybe-nothing",class:"aya-hover","aya-hover-text":"Maybe A",href:"#Mian-Maybe-nothing"},[a("span",{class:"Constructor"},"nothing")]),s(` +| `),a("a",{id:"Mian-Maybe-just",class:"aya-hover","aya-hover-text":"Maybe A",href:"#Mian-Maybe-just"},[a("span",{class:"Constructor"},"just")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1096485705"},[a("span",{class:"LocalVar"},"A")])]),s(` +`)],-1),a("p",null,[s("Here, "),a("code",null,"(A : Type)"),s(" is an explicit parameter, because you write "),a("code",null,"Maybe Nat"),s(", not just "),a("code",null,"Maybe"),s(".")],-1),a("p",null,[s("There is a way to automagically insert the implicit parameters -- the "),a("code",null,"variable"),s(" keyword.")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"variable"),s(),a("a",{id:"v1912960603",href:"#v1912960603"},[a("span",{class:"Generalized"},"A")]),s(" : "),a("span",{class:"Keyword"},"Type"),s(` + +`),a("span",{class:"Comment"},"// Now, since you are using A, so Aya inserts {A : Type}"),s(` +`),a("span",{class:"Keyword"},"example"),s(),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+V2FybmluZzogVGhlIG5hbWUgPGNvZGUgY2xhc3M9IkF5YSI+aWQ8L2NvZGU+IHNoYWRvd3MgYSBwcmV2aW91cyBsb2NhbCBkZWZpbml0aW9uIGZyb20gb3V0ZXIgc2NvcGU8L2NvZGU+CjwvcHJlPgo="},[a("span",{class:"Warning"},[a("a",{id:"Mian-3aNoExport-id",class:"aya-hover","aya-hover-text":"A",href:"#Mian-3aNoExport-id"},[a("span",{class:"Fn"},"id")])])]),s(" ("),a("a",{id:"v2017797638",class:"aya-hover","aya-hover-text":"A",href:"#v2017797638"},[a("span",{class:"LocalVar"},"x")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1912960603"},[a("span",{class:"Generalized"},"A")]),s(") ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v2017797638"},[a("span",{class:"LocalVar"},"x")])]),s(` +`)],-1),a("p",null,"Aya supports type aliases as functions. For example, we may define the type of binary operators as a function:",-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-BinOp",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-BinOp"},[a("span",{class:"Fn"},"BinOp")]),s(" ("),a("a",{id:"v1150058854",class:"aya-hover","aya-hover-text":"Type 0",href:"#v1150058854"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("span",{class:"Keyword"},"Type"),s(") ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1150058854"},[a("span",{class:"LocalVar"},"A")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1150058854"},[a("span",{class:"LocalVar"},"A")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1150058854"},[a("span",{class:"LocalVar"},"A")])]),s(` +`)],-1),a("p",null,[s("Then, we can define "),a("code",null,"<+>"),s(" as:")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"example"),s(),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"Keyword"},"infixl"),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+V2FybmluZzogVGhlIG5hbWUgPGNvZGUgY2xhc3M9IkF5YSI+Jmx0OysmZ3Q7PC9jb2RlPiBzaGFkb3dzIGEgcHJldmlvdXMgbG9jYWwgZGVmaW5pdGlvbiBmcm9tIG91dGVyIHNjb3BlPC9jb2RlPgo8L3ByZT4K"},[a("span",{class:"Warning"},[a("a",{id:"Mian-3aNoExport-3c2b3e",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3aNoExport-3c2b3e"},[a("span",{class:"Fn"},"<+>")])])]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-BinOp"},[a("span",{class:"Fn"},"BinOp")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(` +| 0, `),a("a",{id:"v1624972302",class:"aya-hover","aya-hover-text":"Nat",href:"#v1624972302"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1624972302"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{id:"v1048098469",class:"aya-hover","aya-hover-text":"Nat",href:"#v1048098469"},[a("span",{class:"LocalVar"},"m")]),s(", "),a("a",{id:"v1989811701",class:"aya-hover","aya-hover-text":"Nat",href:"#v1989811701"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1048098469"},[a("span",{class:"LocalVar"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3aNoExport-3c2b3e"},[a("span",{class:"Fn"},"<+>")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1989811701"},[a("span",{class:"LocalVar"},"n")]),s(")")]),s(` +`)],-1),a("h2",{id:"type-families",tabindex:"-1"},[s("Type families "),a("a",{class:"header-anchor",href:"#type-families","aria-label":'Permalink to "Type families"'},"​")],-1),a("p",null,[s("In Aya, type families are functions. Consider the following code (they are using the "),a("code",null,"variable A"),s(" defined above):")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Comment"},"// Unit type"),s(` +`),a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Unit",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Unit"},[a("span",{class:"Data"},"Unit")]),s(" | "),a("a",{id:"Mian-Unit-unit",class:"aya-hover","aya-hover-text":"Unit",href:"#Mian-Unit-unit"},[a("span",{class:"Constructor"},"unit")]),s(` + +`),a("span",{class:"Comment"},"// A type family"),s(` +`),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-FromJust",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-FromJust"},[a("span",{class:"Fn"},"FromJust")]),s(" ("),a("a",{id:"v2037764568",class:"aya-hover","aya-hover-text":"Maybe A",href:"#v2037764568"},[a("span",{class:"LocalVar"},"x")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Maybe"},[a("span",{class:"Data"},"Maybe")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1912960603"},[a("span",{class:"Generalized"},"A")]),s(") : "),a("span",{class:"Keyword"},"Type"),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Maybe A",href:"#Mian-Maybe-just"},[a("span",{class:"Constructor"},"just")]),s(),a("a",{id:"v605052357",class:"aya-hover","aya-hover-text":"A",href:"#v605052357"},[a("span",{class:"LocalVar"},"a")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1912960603"},[a("span",{class:"Generalized"},"A")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Maybe A",href:"#Mian-Maybe-nothing"},[a("span",{class:"Constructor"},"nothing")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Unit"},[a("span",{class:"Data"},"Unit")]),s(` + +`),a("span",{class:"Comment"},"// A function that uses the type family"),s(` +`),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-fromJust",class:"aya-hover","aya-hover-text":"FromJust x",href:"#Mian-fromJust"},[a("span",{class:"Fn"},"fromJust")]),s(" ("),a("a",{id:"v238762799",class:"aya-hover","aya-hover-text":"Maybe A",href:"#v238762799"},[a("span",{class:"LocalVar"},"x")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Maybe"},[a("span",{class:"Data"},"Maybe")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1912960603"},[a("span",{class:"Generalized"},"A")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-FromJust"},[a("span",{class:"Fn"},"FromJust")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Maybe A",href:"#v238762799"},[a("span",{class:"LocalVar"},"x")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Maybe A",href:"#Mian-Maybe-just"},[a("span",{class:"Constructor"},"just")]),s(),a("a",{id:"v1267149311",class:"aya-hover","aya-hover-text":"A",href:"#v1267149311"},[a("span",{class:"LocalVar"},"a")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1267149311"},[a("span",{class:"LocalVar"},"a")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Maybe A",href:"#Mian-Maybe-nothing"},[a("span",{class:"Constructor"},"nothing")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Unit",href:"#Mian-Unit-unit"},[a("span",{class:"Constructor"},"unit")])]),s(` +`)],-1),a("p",null,[s("And "),a("code",null,"fromJust (just a)"),s(" will evaluate to "),a("code",null,"a"),s(". In Haskell, you need to use some language extensions alongside some scary keywords. These functions are available in constructors, too:")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Example",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Example"},[a("span",{class:"Data"},"Example")]),s(" ("),a("a",{id:"v2104973502",class:"aya-hover","aya-hover-text":"Type 0",href:"#v2104973502"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("span",{class:"Keyword"},"Type"),s(`) +| `),a("a",{id:"Mian-Example-cons",class:"aya-hover","aya-hover-text":"Example A",href:"#Mian-Example-cons"},[a("span",{class:"Constructor"},"cons")]),s(" ("),a("a",{id:"v735937428",class:"aya-hover","aya-hover-text":"Maybe A",href:"#v735937428"},[a("span",{class:"LocalVar"},"x")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Maybe"},[a("span",{class:"Data"},"Maybe")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v2104973502"},[a("span",{class:"LocalVar"},"A")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-FromJust"},[a("span",{class:"Fn"},"FromJust")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Maybe A",href:"#v735937428"},[a("span",{class:"LocalVar"},"x")]),s(")")]),s(` +`)],-1),h(`

It is recommended to play with it in the REPL to get a feel of it.

There is a famous example of dependent types in Haskell -- the sized vector type:

haskell
{-# LANGUAGE GADTs #-}
+{-# LANGUAGE DataKinds #-}
+-- Maybe you need more, I don't remember exactly
+
+data Vec :: Nat -> Type -> Type where
+  Nil :: Vec Zero a
+  (:<) :: a -> Vec n a -> Vec (Suc n) a
+infixr :<

In Aya, we have a better syntax:

`,4),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Vec",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(" ("),a("a",{id:"v788625466",class:"aya-hover","aya-hover-text":"Nat",href:"#v788625466"},[a("span",{class:"LocalVar"},"n")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(") ("),a("a",{id:"v1753714541",class:"aya-hover","aya-hover-text":"Type 0",href:"#v1753714541"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("span",{class:"Keyword"},"Type"),s(`) +| 0, `),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+V2FybmluZzogVGhlIG5hbWUgPGNvZGUgY2xhc3M9IkF5YSI+QTwvY29kZT4gc2hhZG93cyBhIHByZXZpb3VzIGxvY2FsIGRlZmluaXRpb24gZnJvbSBvdXRlciBzY29wZTwvY29kZT4KPC9wcmU+Cg=="},[a("span",{class:"Warning"},[a("a",{id:"v1095273238",class:"aya-hover","aya-hover-text":"Type 0",href:"#v1095273238"},[a("span",{class:"LocalVar"},"A")])])]),s(" ⇒ "),a("a",{id:"Mian-Vec-nil",class:"aya-hover","aya-hover-text":"Vec 0 A",href:"#Mian-Vec-nil"},[a("span",{class:"Constructor"},"nil")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+V2FybmluZzogVGhlIG5hbWUgPGNvZGUgY2xhc3M9IkF5YSI+bjwvY29kZT4gc2hhZG93cyBhIHByZXZpb3VzIGxvY2FsIGRlZmluaXRpb24gZnJvbSBvdXRlciBzY29wZTwvY29kZT4KPC9wcmU+Cg=="},[a("span",{class:"Warning"},[a("a",{id:"v1423983012",class:"aya-hover","aya-hover-text":"Nat",href:"#v1423983012"},[a("span",{class:"LocalVar"},"n")])])]),s(", "),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+V2FybmluZzogVGhlIG5hbWUgPGNvZGUgY2xhc3M9IkF5YSI+QTwvY29kZT4gc2hhZG93cyBhIHByZXZpb3VzIGxvY2FsIGRlZmluaXRpb24gZnJvbSBvdXRlciBzY29wZTwvY29kZT4KPC9wcmU+Cg=="},[a("span",{class:"Warning"},[a("a",{id:"v746074699",class:"aya-hover","aya-hover-text":"Type 0",href:"#v746074699"},[a("span",{class:"LocalVar"},"A")])])]),s(" ⇒ "),a("span",{class:"Keyword"},"infixr"),s(),a("a",{id:"Mian-Vec-3a3c",class:"aya-hover","aya-hover-text":"Vec (suc n) A",href:"#Mian-Vec-3a3c"},[a("span",{class:"Constructor"},":<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v746074699"},[a("span",{class:"LocalVar"},"A")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1423983012"},[a("span",{class:"LocalVar"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v746074699"},[a("span",{class:"LocalVar"},"A")]),s(")")]),s(` +`)],-1),a("p",null,[s("The "),a("code",null,":<"),s(" constructor is defined as a right-associative infix operator. And yes, you can define like vector append painlessly:")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"variable"),s(),a("a",{id:"v416841088",href:"#v416841088"},[a("span",{class:"Generalized"},"m")]),s(),a("a",{id:"v452121674",href:"#v452121674"},[a("span",{class:"Generalized"},"n")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(` + +`),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"Keyword"},"infixr"),s(),a("a",{id:"Mian-2b2b",class:"aya-hover","aya-hover-text":"Vec (n <+> m) A",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v452121674"},[a("span",{class:"Generalized"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1912960603"},[a("span",{class:"Generalized"},"A")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v416841088"},[a("span",{class:"Generalized"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1912960603"},[a("span",{class:"Generalized"},"A")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v452121674"},[a("span",{class:"Generalized"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3c2b3e"},[a("span",{class:"Fn"},"<+>")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v416841088"},[a("span",{class:"Generalized"},"m")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v1912960603"},[a("span",{class:"Generalized"},"A")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Vec 0 A",href:"#Mian-Vec-nil"},[a("span",{class:"Constructor"},"nil")]),s(", "),a("a",{id:"v573200870",class:"aya-hover","aya-hover-text":"Vec m A",href:"#v573200870"},[a("span",{class:"LocalVar"},"ys")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Vec m A",href:"#v573200870"},[a("span",{class:"LocalVar"},"ys")]),s(` +| `),a("a",{id:"v1046665075",class:"aya-hover","aya-hover-text":"A",href:"#v1046665075"},[a("span",{class:"LocalVar"},"x")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (suc n) A",href:"#Mian-Vec-3a3c"},[a("span",{class:"Constructor"},":<")]),s(),a("a",{id:"v1324829744",class:"aya-hover","aya-hover-text":"Vec n A",href:"#v1324829744"},[a("span",{class:"LocalVar"},"xs")]),s(", "),a("a",{id:"v1921242091",class:"aya-hover","aya-hover-text":"Vec m A",href:"#v1921242091"},[a("span",{class:"LocalVar"},"ys")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1046665075"},[a("span",{class:"LocalVar"},"x")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (suc (?n A x xs ys n m)) (?A A x xs ys n m)",href:"#Mian-Vec-3a3c"},[a("span",{class:"Constructor"},":<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec n A",href:"#v1324829744"},[a("span",{class:"LocalVar"},"xs")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (?n A x xs ys n m <+> ?m A x xs ys n m) (?A A x xs ys n m)",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec m A",href:"#v1921242091"},[a("span",{class:"LocalVar"},"ys")]),s(` +`),a("span",{class:"Keyword"},"tighter"),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (suc n) A",href:"#Mian-Vec-3a3c"},[a("span",{class:"Constructor"},":<")])]),s(` +`)],-1),h(`

Imagine how much work this is in Haskell.

Overlapping patterns

There is one more bonus: in Aya, you may modify the definition of <+> to be:

overlap def infixl <+> Nat Nat : Nat
+| 0, n => n
+| n, 0 => n
+| suc m, n => suc (m <+> n)

It says we not only compute 0 + n = n, but when the first parameter is neither 0 nor suc, we may take a look at the second parameter and seek for other potential computations. This is completely useless at runtime, but very good for type checking. For instance, we may want a Vec of size n, and what we have is some Vec of size n + 0. Then having n + 0 to directly reduce to n is very useful, otherwise we will need to write a conversion function that does nothing but changes the type, or use unsafeCoerce.

With n + 0 = n judgmentally, we now have more possibilities. For instance, we can make xs ++ nil = xs. This involves in two steps: we first turni ++ into a overlap def, then we add the following clause to ++:

| xs, nil => xs

This makes ++ compute on more cases too.

For more information about this feature, checkout the tutorial for proof assistant users.

`,9)]))}const D=F(V,[["render",T]]);export{C as __pageData,D as default}; diff --git a/assets/guide_index.md.CiHHc-gO.js b/assets/guide_index.md.CiHHc-gO.js new file mode 100644 index 0000000..3ee2c43 --- /dev/null +++ b/assets/guide_index.md.CiHHc-gO.js @@ -0,0 +1 @@ +import{_ as a,c as t,a2 as r,o as i}from"./chunks/framework.CoXjB5sU.js";const f=JSON.parse('{"title":"The Aya Prover","description":"","frontmatter":{},"headers":[],"relativePath":"guide/index.md","filePath":"guide/index.md","lastUpdated":1717718914000}'),l={name:"guide/index.md"};function n(o,e,s,h,d,p){return i(),t("div",null,e[0]||(e[0]=[r('

The Aya Prover

Aya is a programming language and an interactive proof assistant designed for type-directed programming and formalizing math.

The type system of Aya has the following highlights:

  • Set-level cubical features so funExt and quotients are available without axioms (like Agda, redtt, and Arend but not higher-dimensional),
  • Overlapping and order-independent pattern matching makes simple functions compute better,
  • Practical functional programming features similar to Haskell and Idris: dependent pattern matching, typed holes, enchanted synthesis of implicit arguments.

The implementation of the Aya compiler has the following highlights:

  • Efficient type checking by JIT-compiling well-typed definitions to JVM higher-order abstract syntax, so substitution does not traverse terms,
  • Convenient interactive tools such as a language server for VSCode, a REPL, and hyperlinked document generation (demo),
  • Pre-compiled binary release.
',7)]))}const g=a(l,[["render",n]]);export{f as __pageData,g as default}; diff --git a/assets/guide_index.md.CiHHc-gO.lean.js b/assets/guide_index.md.CiHHc-gO.lean.js new file mode 100644 index 0000000..3ee2c43 --- /dev/null +++ b/assets/guide_index.md.CiHHc-gO.lean.js @@ -0,0 +1 @@ +import{_ as a,c as t,a2 as r,o as i}from"./chunks/framework.CoXjB5sU.js";const f=JSON.parse('{"title":"The Aya Prover","description":"","frontmatter":{},"headers":[],"relativePath":"guide/index.md","filePath":"guide/index.md","lastUpdated":1717718914000}'),l={name:"guide/index.md"};function n(o,e,s,h,d,p){return i(),t("div",null,e[0]||(e[0]=[r('

The Aya Prover

Aya is a programming language and an interactive proof assistant designed for type-directed programming and formalizing math.

The type system of Aya has the following highlights:

  • Set-level cubical features so funExt and quotients are available without axioms (like Agda, redtt, and Arend but not higher-dimensional),
  • Overlapping and order-independent pattern matching makes simple functions compute better,
  • Practical functional programming features similar to Haskell and Idris: dependent pattern matching, typed holes, enchanted synthesis of implicit arguments.

The implementation of the Aya compiler has the following highlights:

  • Efficient type checking by JIT-compiling well-typed definitions to JVM higher-order abstract syntax, so substitution does not traverse terms,
  • Convenient interactive tools such as a language server for VSCode, a REPL, and hyperlinked document generation (demo),
  • Pre-compiled binary release.
',7)]))}const g=a(l,[["render",n]]);export{f as __pageData,g as default}; diff --git a/assets/guide_install.md.NmQ5a4E1.js b/assets/guide_install.md.NmQ5a4E1.js new file mode 100644 index 0000000..8c1c0f5 --- /dev/null +++ b/assets/guide_install.md.NmQ5a4E1.js @@ -0,0 +1,26 @@ +import{_ as s,c as i,a2 as e,o as t}from"./chunks/framework.CoXjB5sU.js";const c=JSON.parse('{"title":"Install Aya","description":"","frontmatter":{},"headers":[],"relativePath":"guide/install.md","filePath":"guide/install.md","lastUpdated":1717718914000}'),n={name:"guide/install.md"};function l(r,a,h,p,o,d){return t(),i("div",null,a[0]||(a[0]=[e(`

Install Aya

At this stage of development, we recommend using the nightly version of Aya. Go to GitHub Release, there will be a plenty of files. It's updated per-commit in the main branch, but the release date displayed is very old and is an issue of GitHub itself.

Checking the section below that fits your platform. After the installation, run aya --help for general instructions and aya -i to start an interactive REPL. If you chose the jlink version, the bin folder contains the executable scripts.

Download from GitHub Release

Aya is available for Windows, Linux, and macOS, as listed below.

x64aarch64
Windowszipzip
Linuxzipzip
macOSzipzip

Here's a hands-on script I wrote to (re)install Aya to $AYA_PREFIX (define the variable somewhere or replace with your preferred prefix, e.g. /opt/aya) on Linux x64:

bash
#!/bin/bash
+sudo mkdir -p \${AYA_PREFIX:-/tmp}
+sudo chown $USER \${AYA_PREFIX:-/tmp}
+rm -rf \${AYA_PREFIX:-/tmp}/*
+cd \${AYA_PREFIX:-/tmp}
+wget https://github.com/aya-prover/aya-dev/releases/download/nightly-build/aya-prover_jlink_linux-x64.zip
+unzip aya-prover_jlink_linux-x64.zip
+rm aya-prover_jlink_linux-x64.zip
+cd -

If it's the first time you install Aya, you may want to do (or replace ~/.bashrc with your shell's rc file):

bash
echo 'export PATH="$AYA_PREFIX/bin:$PATH"' >> ~/.bashrc
+source ~/.bashrc

Use Aya in GitHub Actions

If you want to use Aya in your GitHub Actions workflow, you can use aya-prover/setup-aya like

yaml
- name: Setup Aya
+  uses: aya-prover/setup-aya@latest
+  with:
+    version: 'nightly-build'

The step above will install the latest version of Aya to PATH. You can find the complete example here.

If you already have Java runtime...

Very cool! Now you can try the prebuilt jars (much smaller and platform-independent) or build Aya from source.

We will (hopefully) always be using the latest release of Java, rather than LTS, unless there are breaking changes on the byte code format.

Prebuilt binary

Download the jar version of cli (for using command line) and lsp (for using VSCode) and run it with java --enable-preview -jar [file name].jar.

Build from source

Clone the repository. Then, run build with ./gradlew followed by a task name. If you have problems downloading dependencies (like you are in China), check out how to let gradle use a proxy.

bash
# build Aya and its language server as applications to \`ide-lsp/build/image/current\`
+# the image is usable in Java-free environments 
+./gradlew jlinkAya --rerun-tasks
+# build Aya and its language server as executable
+# jars to <project>/build/libs/<project>-<version>-fat.jar
+./gradlew fatJar
+# build a platform-dependent installer for Aya and its language
+# server with the jlink artifacts to ide-lsp/build/jpackage
+# requires https://wixtoolset.org/releases on Windows
+./gradlew jpackage
+# run tests and generate coverage report to build/reports
+./gradlew testCodeCoverageReport
+# (Windows only) show the coverage report in your default browser
+./gradlew showCCR

Gradle supports short-handed task names, so you can run ./gradlew fJ to invoke fatJar, tCCR to invoke testCodeCoverageReport, and so on.

`,23)]))}const y=s(n,[["render",l]]);export{c as __pageData,y as default}; diff --git a/assets/guide_install.md.NmQ5a4E1.lean.js b/assets/guide_install.md.NmQ5a4E1.lean.js new file mode 100644 index 0000000..8c1c0f5 --- /dev/null +++ b/assets/guide_install.md.NmQ5a4E1.lean.js @@ -0,0 +1,26 @@ +import{_ as s,c as i,a2 as e,o as t}from"./chunks/framework.CoXjB5sU.js";const c=JSON.parse('{"title":"Install Aya","description":"","frontmatter":{},"headers":[],"relativePath":"guide/install.md","filePath":"guide/install.md","lastUpdated":1717718914000}'),n={name:"guide/install.md"};function l(r,a,h,p,o,d){return t(),i("div",null,a[0]||(a[0]=[e(`

Install Aya

At this stage of development, we recommend using the nightly version of Aya. Go to GitHub Release, there will be a plenty of files. It's updated per-commit in the main branch, but the release date displayed is very old and is an issue of GitHub itself.

Checking the section below that fits your platform. After the installation, run aya --help for general instructions and aya -i to start an interactive REPL. If you chose the jlink version, the bin folder contains the executable scripts.

Download from GitHub Release

Aya is available for Windows, Linux, and macOS, as listed below.

x64aarch64
Windowszipzip
Linuxzipzip
macOSzipzip

Here's a hands-on script I wrote to (re)install Aya to $AYA_PREFIX (define the variable somewhere or replace with your preferred prefix, e.g. /opt/aya) on Linux x64:

bash
#!/bin/bash
+sudo mkdir -p \${AYA_PREFIX:-/tmp}
+sudo chown $USER \${AYA_PREFIX:-/tmp}
+rm -rf \${AYA_PREFIX:-/tmp}/*
+cd \${AYA_PREFIX:-/tmp}
+wget https://github.com/aya-prover/aya-dev/releases/download/nightly-build/aya-prover_jlink_linux-x64.zip
+unzip aya-prover_jlink_linux-x64.zip
+rm aya-prover_jlink_linux-x64.zip
+cd -

If it's the first time you install Aya, you may want to do (or replace ~/.bashrc with your shell's rc file):

bash
echo 'export PATH="$AYA_PREFIX/bin:$PATH"' >> ~/.bashrc
+source ~/.bashrc

Use Aya in GitHub Actions

If you want to use Aya in your GitHub Actions workflow, you can use aya-prover/setup-aya like

yaml
- name: Setup Aya
+  uses: aya-prover/setup-aya@latest
+  with:
+    version: 'nightly-build'

The step above will install the latest version of Aya to PATH. You can find the complete example here.

If you already have Java runtime...

Very cool! Now you can try the prebuilt jars (much smaller and platform-independent) or build Aya from source.

We will (hopefully) always be using the latest release of Java, rather than LTS, unless there are breaking changes on the byte code format.

Prebuilt binary

Download the jar version of cli (for using command line) and lsp (for using VSCode) and run it with java --enable-preview -jar [file name].jar.

Build from source

Clone the repository. Then, run build with ./gradlew followed by a task name. If you have problems downloading dependencies (like you are in China), check out how to let gradle use a proxy.

bash
# build Aya and its language server as applications to \`ide-lsp/build/image/current\`
+# the image is usable in Java-free environments 
+./gradlew jlinkAya --rerun-tasks
+# build Aya and its language server as executable
+# jars to <project>/build/libs/<project>-<version>-fat.jar
+./gradlew fatJar
+# build a platform-dependent installer for Aya and its language
+# server with the jlink artifacts to ide-lsp/build/jpackage
+# requires https://wixtoolset.org/releases on Windows
+./gradlew jpackage
+# run tests and generate coverage report to build/reports
+./gradlew testCodeCoverageReport
+# (Windows only) show the coverage report in your default browser
+./gradlew showCCR

Gradle supports short-handed task names, so you can run ./gradlew fJ to invoke fatJar, tCCR to invoke testCodeCoverageReport, and so on.

`,23)]))}const y=s(n,[["render",l]]);export{c as __pageData,y as default}; diff --git a/assets/guide_project-tutorial.md.Brh1y7za.js b/assets/guide_project-tutorial.md.Brh1y7za.js new file mode 100644 index 0000000..fa6691c --- /dev/null +++ b/assets/guide_project-tutorial.md.Brh1y7za.js @@ -0,0 +1,17 @@ +import{_ as a,c as i,a2 as e,o as n}from"./chunks/framework.CoXjB5sU.js";const c=JSON.parse('{"title":"Aya Package","description":"","frontmatter":{},"headers":[],"relativePath":"guide/project-tutorial.md","filePath":"guide/project-tutorial.md","lastUpdated":1717298851000}'),t={name:"guide/project-tutorial.md"};function p(l,s,o,h,r,k){return n(),i("div",null,s[0]||(s[0]=[e(`

Aya Package

An Aya project consists of a directory with a aya.json file (project metadata) and a src directory for source code. Here's a sample aya.json:

json
{
+  "ayaVersion": "0.31",
+  // ^ The version of Aya you are using -- for compatibility checks
+  "name": "<project name>",
+  "version": "<project version>",
+  "group": "<project group>",
+  // ^ The group is used to distinguish different projects with the same modules
+
+  "dependency": {
+    "<name of dependency>": {
+      "file": "<directory to your dependency>"
+    },
+    // We plan to support other sources of dependencies,
+    // but we do not have money to
+    // host a package repository for now.
+  }
+}

To build a project, run aya --make <parent dir of aya.json> (incremental). For force-rebuilding, replace --make with --remake. For jar users, run java --enable-preview -jar cli-fatjar.jar --make <parent dir of aya.json>.

`,4)]))}const E=a(t,[["render",p]]);export{c as __pageData,E as default}; diff --git a/assets/guide_project-tutorial.md.Brh1y7za.lean.js b/assets/guide_project-tutorial.md.Brh1y7za.lean.js new file mode 100644 index 0000000..fa6691c --- /dev/null +++ b/assets/guide_project-tutorial.md.Brh1y7za.lean.js @@ -0,0 +1,17 @@ +import{_ as a,c as i,a2 as e,o as n}from"./chunks/framework.CoXjB5sU.js";const c=JSON.parse('{"title":"Aya Package","description":"","frontmatter":{},"headers":[],"relativePath":"guide/project-tutorial.md","filePath":"guide/project-tutorial.md","lastUpdated":1717298851000}'),t={name:"guide/project-tutorial.md"};function p(l,s,o,h,r,k){return n(),i("div",null,s[0]||(s[0]=[e(`

Aya Package

An Aya project consists of a directory with a aya.json file (project metadata) and a src directory for source code. Here's a sample aya.json:

json
{
+  "ayaVersion": "0.31",
+  // ^ The version of Aya you are using -- for compatibility checks
+  "name": "<project name>",
+  "version": "<project version>",
+  "group": "<project group>",
+  // ^ The group is used to distinguish different projects with the same modules
+
+  "dependency": {
+    "<name of dependency>": {
+      "file": "<directory to your dependency>"
+    },
+    // We plan to support other sources of dependencies,
+    // but we do not have money to
+    // host a package repository for now.
+  }
+}

To build a project, run aya --make <parent dir of aya.json> (incremental). For force-rebuilding, replace --make with --remake. For jar users, run java --enable-preview -jar cli-fatjar.jar --make <parent dir of aya.json>.

`,4)]))}const E=a(t,[["render",p]]);export{c as __pageData,E as default}; diff --git a/assets/guide_prover-tutorial.md.DBob0Be6.js b/assets/guide_prover-tutorial.md.DBob0Be6.js new file mode 100644 index 0000000..e4bd4af --- /dev/null +++ b/assets/guide_prover-tutorial.md.DBob0Be6.js @@ -0,0 +1,98 @@ +import{_ as g,c as w,j as a,a as s,a2 as v,o as I}from"./chunks/framework.CoXjB5sU.js";const T={mounted(){const y=new Map;function p(c){const e=c.querySelectorAll("a[href]");for(const r of e){const n=r.href,i=y.get(n)??new Set;i.add(r),y.set(n,i)}for(const r of e)r.onmouseover=function(){for(const n of y.get(this.href))n.classList.add("hover-highlight")},r.onmouseout=function(){for(const n of y.get(this.href))n.classList.remove("hover-highlight")}}function d(c){return decodeURIComponent(atob(c).split("").map(function(e){return"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)}).join(""))}const x=(c=>{const e={};return(...r)=>{const n=JSON.stringify(r);return e[n]=e[n]||c(...r)}})(d);class u{constructor(){this.list=[]}dismiss(e){e&&(e.remove(),this.list=this.list.filter(r=>r!==e))}dismissIfNotUsed(e){e&&(e.markedForDismissal=!0,setTimeout(()=>{!e.userIsThinking&&this.allowAutoDismissal(e)&&this.dismiss(e)},1e3))}allowAutoDismissal(e){return e.markedForDismissal&&!e.userClicked}fireAutoDismissalFor(e){let r=this.list.find(n=>n.userCreatedFrom===e);this.dismissIfNotUsed(r)}createHoverFor(e,r,n){let i=this.list.find(o=>o.userCreatedFrom===e);if(i&&i.userClicked)return i;let M=[];const A=this.list.filter(o=>{if(this.allowAutoDismissal(o))return M.push(o),!1;const l=o.userCreatedFrom,f=e;let h=f;for(;h;){if(h===l)return!0;h=h.parentElement}for(h=l;h;){if(h===f)return!0;h=h.parentElement}return!1});M.forEach(o=>this.dismiss(o));let t=document.createElement("div");t.userCreatedFrom=e,t.innerHTML="×"+x(r),t.classList.add("AyaTooltipPopup"),p(t);let b=this;if(t.handleEvent=function(o){if(o.type==="click"){this.userClicked=!0,this.markedForDismissal=!1;let l=this.children[0];if(!l)return;let f=this;l.style.visibility="visible",l.addEventListener("click",h=>b.dismiss(f))}o.type==="mouseover"&&(this.userIsThinking=!0),o.type==="mouseout"&&(this.userIsThinking=!1,b.dismissIfNotUsed(this))},t.addEventListener("click",t),t.addEventListener("mouseover",t),t.addEventListener("mouseout",t),n.appendChild(t),t.style.left=`${e.offsetLeft}px`,A.length===0){const o=e.getBoundingClientRect(),l=t.getBoundingClientRect();o.bottom+l.height+30>window.innerHeight?t.style.top=`calc(${e.offsetTop-l.height+8}px - 3em)`:t.style.top=`${e.offsetTop+e.offsetHeight+8}px`}else{const o=Math.max(...A.map(l=>l.offsetTop+l.offsetHeight));t.style.top=`${o+8}px`}return this.list.push(t),t}}let m=new u;function V(c){return function(){let e=this;const r=e.getAttribute("data-tooltip-text");r&&(c?m.createHoverFor(e,r,document.body):m.fireAutoDismissalFor(e))}}p(document);{let c=document.getElementsByClassName("aya-tooltip");for(let e=0;e {??}")]),s(` +`)],-1),a("p",null,"There is no way to prove it in Martin-Löf type theory or Calculus of Constructions. However, you are very smart and realized you can instead show the following:",-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-Goal27",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Goal27"},[a("span",{class:"Fn"},"Goal'")]),s(" ("),a("a",{id:"v1003292107",class:"aya-hover","aya-hover-text":"Bool",href:"#v1003292107"},[a("span",{class:"LocalVar"},"x")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Bool"},[a("span",{class:"Data"},"Bool")]),s(") ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Bool",href:"#Mian-id"},[a("span",{class:"Fn"},"id")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Bool",href:"#v1003292107"},[a("span",{class:"LocalVar"},"x")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Bool",href:"#Mian-not"},[a("span",{class:"Fn"},"not")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Bool",href:"#Mian-not"},[a("span",{class:"Fn"},"not")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Bool",href:"#v1003292107"},[a("span",{class:"LocalVar"},"x")]),s(")")]),s(` +`)],-1),v('

This is pretty much the same theorem!

Now, suppose we need to show a propositional equality between two records. This means we have to show they're memberwise equal. One record has a member \\ p0not (not p0), and the other has id. This time, you cannot cheat by changing the goal type. You post the question on some mailing list and people are telling you that the alternative version of the theorem you have shown does not imply the original, unless "function extensionality" is a theorem in your type theory.

To have function extensionality as a theorem, you came across two distinct type theories: observational type theory and cubical type theory. Aya chose the latter.

Cubical

Here's the proof of function extensionality in Aya:

',5),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-funExt",class:"aya-hover","aya-hover-text":"f = g",href:"#Mian-funExt"},[a("span",{class:"Fn"},"funExt")]),s(" ("),a("a",{id:"v613784740",class:"aya-hover","aya-hover-text":"A → B",href:"#v613784740"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{id:"v271095942",class:"aya-hover","aya-hover-text":"A → B",href:"#v271095942"},[a("span",{class:"LocalVar"},"g")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v2051120548"},[a("span",{class:"Generalized"},"B")]),s(") ("),a("a",{id:"v1323434987",class:"aya-hover","aya-hover-text":"Fn (B : A) → f B = g B",href:"#v1323434987"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("span",{class:"Keyword"},"∀"),s(),a("a",{id:"v895599632",class:"aya-hover","aya-hover-text":"A",href:"#v895599632"},[a("span",{class:"LocalVar"},"a")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v613784740"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v895599632"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v271095942"},[a("span",{class:"LocalVar"},"g")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v895599632"},[a("span",{class:"LocalVar"},"a")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"A → B",href:"#v613784740"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A → B",href:"#v271095942"},[a("span",{class:"LocalVar"},"g")]),s(` + ⇒ `),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v1508059488",href:"#v1508059488"},[a("span",{class:"LocalVar"},"i")]),s(),a("a",{id:"v2082557120",href:"#v2082557120"},[a("span",{class:"LocalVar"},"a")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v1323434987"},[a("span",{class:"LocalVar"},"p")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v2082557120"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v1508059488"},[a("span",{class:"LocalVar"},"i")])]),s(` +`)],-1),v('

Aya has a "cubical" equality type that is not inductively defined. An equality a = b for a, b : A is really just a function IA (as we can see from the proof construction, for f = g we prove it by a lambda abstraction) where:

  • I is a special type that has two closed instances 0 and 1, and we think of there being a propositional equality between 0 and 1, and there is no pattern matching operation that distinguishes them. So, every function that maps out of I must preserve this judgmental equality.
  • For f : I -> A, the corresponding equality type is f 0 = f 1. Hypothetically, let f be the identity function, and we get a propositional equality between 0 and 1, but for technical reasons we don't talk about equality between 0 and 1 directly.

By this definition, we can "prove" reflexivity by creating a constant function:

',3),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-refl",class:"aya-hover","aya-hover-text":"a = a",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(" {"),a("a",{id:"v37981645",class:"aya-hover","aya-hover-text":"A",href:"#v37981645"},[a("span",{class:"LocalVar"},"a")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s("} : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v37981645"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v37981645"},[a("span",{class:"LocalVar"},"a")]),s(" ⇒ "),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v1533524862",href:"#v1533524862"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v37981645"},[a("span",{class:"LocalVar"},"a")])]),s(` +`)],-1),v(`

For f = fn i => a, we need to verify if f 0 equals the left-hand side of the equality and f 1 equals the right-hand side, which are both true.

And to show that f = g, it suffices to construct a function q : I -> (A -> B) such that q 0 = f and q 1 = g. This is true for the proof above:

  (fn i a => p a i) 0    β-reduce
+= fn a => p a 0          p a : f a = g a
+= fn a => f a            η-reduce
+= f

We may also prove the action-on-path theorem, commonly known as cong, but renamed to pmap to avoid a potential future naming clash:

`,4),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-pmap",class:"aya-hover","aya-hover-text":"f a = f b",href:"#Mian-pmap"},[a("span",{class:"Fn"},"pmap")]),s(" ("),a("a",{id:"v418958713",class:"aya-hover","aya-hover-text":"A → B",href:"#v418958713"},[a("span",{class:"LocalVar"},"f")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v2051120548"},[a("span",{class:"Generalized"},"B")]),s(") {"),a("a",{id:"v1042306518",class:"aya-hover","aya-hover-text":"A",href:"#v1042306518"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v1342346098",class:"aya-hover","aya-hover-text":"A",href:"#v1342346098"},[a("span",{class:"LocalVar"},"b")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s("} ("),a("a",{id:"v1358343316",class:"aya-hover","aya-hover-text":"a = b",href:"#v1358343316"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1042306518"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1342346098"},[a("span",{class:"LocalVar"},"b")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v418958713"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1042306518"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v418958713"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1342346098"},[a("span",{class:"LocalVar"},"b")]),s(` + ⇒ `),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v1620948294",href:"#v1620948294"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v418958713"},[a("span",{class:"LocalVar"},"f")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1358343316"},[a("span",{class:"LocalVar"},"p")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v1620948294"},[a("span",{class:"LocalVar"},"i")]),s(")")]),s(` +`)],-1),a("p",null,"Checking the above definition is left as an exercise.",-1),a("p",null,[s("However, we cannot yet define transitivity/symmetry of equality because we do not have the traditional elimination rule of the equality type -- the "),a("code",null,"J"),s(" rule. This will need some advanced proving techniques that are beyond the scope of this simple tutorial, so I'll skim them.")],-1),a("p",null,"We may define the type-safe coercion using it, and this will help us prove the two lemmas about equality:",-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-cast",class:"aya-hover","aya-hover-text":"A → B",href:"#Mian-cast"},[a("span",{class:"Fn"},"cast")]),s(" ("),a("a",{id:"v718571091",class:"aya-hover","aya-hover-text":"A = B",href:"#v718571091"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(),a("span",{class:"Keyword"},"↑"),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 1",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v2051120548"},[a("span",{class:"Generalized"},"B")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v2051120548"},[a("span",{class:"Generalized"},"B")]),s(" ⇒ "),a("span",{class:"Keyword"},"↑"),s(),a("a",{class:"aya-hover","aya-hover-text":"A → B",href:"#Mian-coe"},[a("span",{class:"Primitive"},"coe")]),s(" 0 1 ("),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v807328355",href:"#v807328355"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v718571091"},[a("span",{class:"LocalVar"},"p")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v807328355"},[a("span",{class:"LocalVar"},"i")]),s(")")]),s(` +`)],-1),a("p",null,[s("Then, from "),a("code",null,"p : a = b"),s(" we construct the equivalence "),a("code",null,"(a = a) = (b = a)"),s(" and coerce along this equivalence:")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-pinv",class:"aya-hover","aya-hover-text":"b = a",href:"#Mian-pinv"},[a("span",{class:"Fn"},"pinv")]),s(" {"),a("a",{id:"v1173346575",class:"aya-hover","aya-hover-text":"A",href:"#v1173346575"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v1267149311",class:"aya-hover","aya-hover-text":"A",href:"#v1267149311"},[a("span",{class:"LocalVar"},"b")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s("} ("),a("a",{id:"v52514534",class:"aya-hover","aya-hover-text":"a = b",href:"#v52514534"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1173346575"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1267149311"},[a("span",{class:"LocalVar"},"b")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1267149311"},[a("span",{class:"LocalVar"},"b")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1173346575"},[a("span",{class:"LocalVar"},"a")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"b = a",href:"#Mian-cast"},[a("span",{class:"Fn"},"cast")]),s(" ("),a("span",{class:"Keyword"},"\\"),a("a",{id:"v1025797795",href:"#v1025797795"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v52514534"},[a("span",{class:"LocalVar"},"p")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v1025797795"},[a("span",{class:"LocalVar"},"i")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1173346575"},[a("span",{class:"LocalVar"},"a")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"a = a",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")])]),s(` +`)],-1),a("p",null,[s("From "),a("code",null,"q : b = c"),s(" we construct the equivalence "),a("code",null,"(a = b) = (a = c)"),s(" and coerce along this equivalence:")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-concat",class:"aya-hover","aya-hover-text":"a = c",href:"#Mian-concat"},[a("span",{class:"Fn"},"concat")]),s(" {"),a("a",{id:"v1753714541",class:"aya-hover","aya-hover-text":"A",href:"#v1753714541"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v1095273238",class:"aya-hover","aya-hover-text":"A",href:"#v1095273238"},[a("span",{class:"LocalVar"},"b")]),s(),a("a",{id:"v177140066",class:"aya-hover","aya-hover-text":"A",href:"#v177140066"},[a("span",{class:"LocalVar"},"c")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s("} ("),a("a",{id:"v2059572982",class:"aya-hover","aya-hover-text":"a = b",href:"#v2059572982"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1753714541"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1095273238"},[a("span",{class:"LocalVar"},"b")]),s(") ("),a("a",{id:"v36657658",class:"aya-hover","aya-hover-text":"b = c",href:"#v36657658"},[a("span",{class:"LocalVar"},"q")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1095273238"},[a("span",{class:"LocalVar"},"b")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v177140066"},[a("span",{class:"LocalVar"},"c")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1753714541"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v177140066"},[a("span",{class:"LocalVar"},"c")]),s(` ⇒ + `),a("a",{class:"aya-hover","aya-hover-text":"a = c",href:"#Mian-cast"},[a("span",{class:"Fn"},"cast")]),s(" ("),a("span",{class:"Keyword"},"\\"),a("a",{id:"v873993427",href:"#v873993427"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1753714541"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v36657658"},[a("span",{class:"LocalVar"},"q")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v873993427"},[a("span",{class:"LocalVar"},"i")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"a = b",href:"#v2059572982"},[a("span",{class:"LocalVar"},"p")])]),s(` +`)],-1),a("p",null,"Note that at this point you can already do a bunch of familiar proofs about some simple types such as natural numbers or sized vectors. These are left as exercises, and you are encouraged to try yourself if you are not very sure about how it feels to prove things in Aya.",-1),a("h2",{id:"overlapping-and-order-independent-pattern-matching",tabindex:"-1"},[s("Overlapping and Order-independent Pattern Matching "),a("a",{class:"header-anchor",href:"#overlapping-and-order-independent-pattern-matching","aria-label":'Permalink to "Overlapping and Order-independent Pattern Matching"'},"​")],-1),a("p",null,[s("Remember the "),a("code",null,"+-comm"),s(" proof that you need two lemmas? It is standard to define "),a("code",null,"+"),s(" in the following way:")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"example"),s(),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"Keyword"},"infix"),s(),a("a",{id:"Mian-3aNoExport-2b",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3aNoExport-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(` +| 0, `),a("a",{id:"v164332069",class:"aya-hover","aya-hover-text":"Nat",href:"#v164332069"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v164332069"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{id:"v1650813924",class:"aya-hover","aya-hover-text":"Nat",href:"#v1650813924"},[a("span",{class:"LocalVar"},"m")]),s(", "),a("a",{id:"v400103862",class:"aya-hover","aya-hover-text":"Nat",href:"#v400103862"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1650813924"},[a("span",{class:"LocalVar"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3aNoExport-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v400103862"},[a("span",{class:"LocalVar"},"n")]),s(")")]),s(` +`)],-1),a("p",null,[s("And then you prove that "),a("code",null,"a + 0 = a"),s(" and "),a("code",null,"a + suc b = suc (a + b)"),s(". It is tempting to have "),a("code",null,"| n, 0 => n"),s(" as a computation rule as well, but this is incompatible with the usual semantics of pattern matching, which is compiled to elimination principles during type checking. However, you "),a("em",null,"can"),s(" do that in Aya. You may also add the other lemma as well.")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"overlap"),s(),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"Keyword"},"infix"),s(),a("a",{id:"Mian-2b",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(` +| 0, `),a("a",{id:"v610454273",class:"aya-hover","aya-hover-text":"Nat",href:"#v610454273"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v610454273"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{id:"v431506362",class:"aya-hover","aya-hover-text":"Nat",href:"#v431506362"},[a("span",{class:"LocalVar"},"n")]),s(", 0 ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v431506362"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{id:"v1693226694",class:"aya-hover","aya-hover-text":"Nat",href:"#v1693226694"},[a("span",{class:"LocalVar"},"m")]),s(", "),a("a",{id:"v2003147568",class:"aya-hover","aya-hover-text":"Nat",href:"#v2003147568"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1693226694"},[a("span",{class:"LocalVar"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v2003147568"},[a("span",{class:"LocalVar"},"n")]),s(`) +| `),a("a",{id:"v1164799006",class:"aya-hover","aya-hover-text":"Nat",href:"#v1164799006"},[a("span",{class:"LocalVar"},"m")]),s(", "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{id:"v504582810",class:"aya-hover","aya-hover-text":"Nat",href:"#v504582810"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1164799006"},[a("span",{class:"LocalVar"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v504582810"},[a("span",{class:"LocalVar"},"n")]),s(`) +`),a("span",{class:"Keyword"},"tighter"),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")])]),s(` +`)],-1),a("p",null,[s("This makes all of them definitional equality. So, "),a("code",{class:"Aya"},[a("a",{href:"#Mian-2b-comm"},[a("span",{class:"Fn"},"+-comm")])]),s(" can be simplified to just one pattern matching:")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-2b-comm",class:"aya-hover","aya-hover-text":"(a + b) = (b + a)",href:"#Mian-2b-comm"},[a("span",{class:"Fn"},"+-comm")]),s(" ("),a("a",{id:"v2079565272",class:"aya-hover","aya-hover-text":"Nat",href:"#v2079565272"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v1122130699",class:"aya-hover","aya-hover-text":"Nat",href:"#v1122130699"},[a("span",{class:"LocalVar"},"b")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v2079565272"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1122130699"},[a("span",{class:"LocalVar"},"b")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1122130699"},[a("span",{class:"LocalVar"},"b")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v2079565272"},[a("span",{class:"LocalVar"},"a")]),s(),a("span",{class:"Keyword"},"elim"),s(),a("a",{href:"#v2079565272"},[a("span",{class:"LocalVar"},"a")]),s(` +| 0 ⇒ `),a("a",{class:"aya-hover","aya-hover-text":"b = b",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" _ ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"suc (_ + b) = suc (b + _)",href:"#Mian-pmap"},[a("span",{class:"Fn"},"pmap")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat → Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"(_ + b) = (b + _)",href:"#Mian-2b-comm"},[a("span",{class:"Fn"},"+-comm")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YyMTA2OTAwMTUzIj48c3BhbiBjbGFzcz0iTG9jYWxWYXIiPl88L3NwYW4+PC9hPjwvY29kZT4KPC9wcmU+Cg=="},"_"),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YxNDQzMDU1ODQ2Ij48c3BhbiBjbGFzcz0iTG9jYWxWYXIiPmI8L3NwYW4+PC9hPjwvY29kZT4KPC9wcmU+Cg=="},"_"),s(")")]),s(` +`)],-1),a("p",null,[s("Note that we are using the "),a("code",null,"elim"),s(" keyword, which describes the variables that the function body is pattern matching on.")],-1),a("h2",{id:"heterogeneous-equality",tabindex:"-1"},[s("Heterogeneous equality "),a("a",{class:"header-anchor",href:"#heterogeneous-equality","aria-label":'Permalink to "Heterogeneous equality"'},"​")],-1),a("p",null,"When working with indexed families, you may want to have heterogeneous equality to avoid having mysterious coercions. For example, consider the associativity of sized vector appends. We first need to define sized vectors and the append operation:",-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"variable"),s(),a("a",{id:"v829149076",href:"#v829149076"},[a("span",{class:"Generalized"},"n")]),s(),a("a",{id:"v1678046232",href:"#v1678046232"},[a("span",{class:"Generalized"},"m")]),s(),a("a",{id:"v9797126",href:"#v9797126"},[a("span",{class:"Generalized"},"o")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(` +`),a("span",{class:"Comment"},"// Definitions"),s(` +`),a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Vec",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(" ("),a("a",{id:"v1067599825",class:"aya-hover","aya-hover-text":"Nat",href:"#v1067599825"},[a("span",{class:"LocalVar"},"n")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(") ("),a("a",{id:"v749927456",class:"aya-hover","aya-hover-text":"Type 0",href:"#v749927456"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("span",{class:"Keyword"},"Type"),s(`) +| 0, `),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+V2FybmluZzogVGhlIG5hbWUgPGNvZGUgY2xhc3M9IkF5YSI+QTwvY29kZT4gc2hhZG93cyBhIHByZXZpb3VzIGxvY2FsIGRlZmluaXRpb24gZnJvbSBvdXRlciBzY29wZTwvY29kZT4KPC9wcmU+Cg=="},[a("span",{class:"Warning"},[a("a",{id:"v1330400026",class:"aya-hover","aya-hover-text":"Type 0",href:"#v1330400026"},[a("span",{class:"LocalVar"},"A")])])]),s(" ⇒ "),a("a",{id:"Mian-Vec-nil",class:"aya-hover","aya-hover-text":"Vec 0 A",href:"#Mian-Vec-nil"},[a("span",{class:"Constructor"},"nil")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+V2FybmluZzogVGhlIG5hbWUgPGNvZGUgY2xhc3M9IkF5YSI+bjwvY29kZT4gc2hhZG93cyBhIHByZXZpb3VzIGxvY2FsIGRlZmluaXRpb24gZnJvbSBvdXRlciBzY29wZTwvY29kZT4KPC9wcmU+Cg=="},[a("span",{class:"Warning"},[a("a",{id:"v1318227903",class:"aya-hover","aya-hover-text":"Nat",href:"#v1318227903"},[a("span",{class:"LocalVar"},"n")])])]),s(", "),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+V2FybmluZzogVGhlIG5hbWUgPGNvZGUgY2xhc3M9IkF5YSI+QTwvY29kZT4gc2hhZG93cyBhIHByZXZpb3VzIGxvY2FsIGRlZmluaXRpb24gZnJvbSBvdXRlciBzY29wZTwvY29kZT4KPC9wcmU+Cg=="},[a("span",{class:"Warning"},[a("a",{id:"v892335322",class:"aya-hover","aya-hover-text":"Type 0",href:"#v892335322"},[a("span",{class:"LocalVar"},"A")])])]),s(" ⇒ "),a("span",{class:"Keyword"},"infixr"),s(),a("a",{id:"Mian-Vec-3a3c",class:"aya-hover","aya-hover-text":"Vec (suc n) A",href:"#Mian-Vec-3a3c"},[a("span",{class:"Constructor"},":<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v892335322"},[a("span",{class:"LocalVar"},"A")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1318227903"},[a("span",{class:"LocalVar"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v892335322"},[a("span",{class:"LocalVar"},"A")]),s(`) +`),a("span",{class:"Keyword"},"overlap"),s(),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"Keyword"},"infixr"),s(),a("a",{id:"Mian-2b2b",class:"aya-hover","aya-hover-text":"Vec (n + m) A",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v829149076"},[a("span",{class:"Generalized"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1678046232"},[a("span",{class:"Generalized"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v829149076"},[a("span",{class:"Generalized"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1678046232"},[a("span",{class:"Generalized"},"m")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Vec 0 A",href:"#Mian-Vec-nil"},[a("span",{class:"Constructor"},"nil")]),s(", "),a("a",{id:"v1305935114",class:"aya-hover","aya-hover-text":"Vec m A",href:"#v1305935114"},[a("span",{class:"LocalVar"},"ys")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Vec m A",href:"#v1305935114"},[a("span",{class:"LocalVar"},"ys")]),s(` +| `),a("a",{id:"v1720891078",class:"aya-hover","aya-hover-text":"Vec n A",href:"#v1720891078"},[a("span",{class:"LocalVar"},"ys")]),s(", "),a("a",{class:"aya-hover","aya-hover-text":"Vec 0 A",href:"#Mian-Vec-nil"},[a("span",{class:"Constructor"},"nil")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Vec n A",href:"#v1720891078"},[a("span",{class:"LocalVar"},"ys")]),s(` +| `),a("a",{id:"v970419381",class:"aya-hover","aya-hover-text":"A",href:"#v970419381"},[a("span",{class:"LocalVar"},"x")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (suc n) A",href:"#Mian-Vec-3a3c"},[a("span",{class:"Constructor"},":<")]),s(),a("a",{id:"v1241569743",class:"aya-hover","aya-hover-text":"Vec n A",href:"#v1241569743"},[a("span",{class:"LocalVar"},"xs")]),s(", "),a("a",{id:"v1731656333",class:"aya-hover","aya-hover-text":"Vec m A",href:"#v1731656333"},[a("span",{class:"LocalVar"},"ys")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v970419381"},[a("span",{class:"LocalVar"},"x")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (suc (?n A x xs ys n m)) (?A A x xs ys n m)",href:"#Mian-Vec-3a3c"},[a("span",{class:"Constructor"},":<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec n A",href:"#v1241569743"},[a("span",{class:"LocalVar"},"xs")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (?n A x xs ys n m + ?m A x xs ys n m) (?A A x xs ys n m)",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec m A",href:"#v1731656333"},[a("span",{class:"LocalVar"},"ys")]),s(` +`),a("span",{class:"Keyword"},"tighter"),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (suc n) A",href:"#Mian-Vec-3a3c"},[a("span",{class:"Constructor"},":<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")])]),s(` +`)],-1),v(`

It is tempting to use the below definition:

overlap def ++-assoc (xs : Vec n A) (ys : Vec m A) (zs : Vec o A)
+  : (xs ++ ys) ++ zs = xs ++ (ys ++ zs) elim xs
+| nil => refl
+| x :< xs => pmap (x :<) (++-assoc xs ys zs)

However, this definition is not well-typed:

  • (xs ++ ys) ++ zs is of type Vec ((n + m) + o) A
  • xs ++ (ys ++ zs) is of type Vec (n + (m + o)) A.

They are not the same! Fortunately, we can prove that they are propositionally equal. We need to show that natural number addition is associative, which is the key lemma of this propositional equality:

`,5),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-2b-assoc",class:"aya-hover","aya-hover-text":"((a + b) + c) = (a + (b + c))",href:"#Mian-2b-assoc"},[a("span",{class:"Fn"},"+-assoc")]),s(" {"),a("a",{id:"v551016187",class:"aya-hover","aya-hover-text":"Nat",href:"#v551016187"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v1324843695",class:"aya-hover","aya-hover-text":"Nat",href:"#v1324843695"},[a("span",{class:"LocalVar"},"b")]),s(),a("a",{id:"v299413131",class:"aya-hover","aya-hover-text":"Nat",href:"#v299413131"},[a("span",{class:"LocalVar"},"c")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s("} : ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v551016187"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1324843695"},[a("span",{class:"LocalVar"},"b")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v299413131"},[a("span",{class:"LocalVar"},"c")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v551016187"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1324843695"},[a("span",{class:"LocalVar"},"b")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v299413131"},[a("span",{class:"LocalVar"},"c")]),s(") "),a("span",{class:"Keyword"},"elim"),s(),a("a",{href:"#v551016187"},[a("span",{class:"LocalVar"},"a")]),s(` +| 0 ⇒ `),a("a",{class:"aya-hover","aya-hover-text":"(b + c) = (b + c)",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" _ ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"suc ((_ + b) + c) = suc (_ + (b + c))",href:"#Mian-pmap"},[a("span",{class:"Fn"},"pmap")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat → Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{class:"aya-hover","aya-hover-text":"((_ + b) + c) = (_ + (b + c))",href:"#Mian-2b-assoc"},[a("span",{class:"Fn"},"+-assoc")])]),s(` +`)],-1),v('

Now we can work on the proof of ++-assoc. Here's a lame definition that is well-typed in pre-cubical type theory, and is also hard to prove -- we cast one side of the equation to be other side. So instead of:

xs ++ (ys ++ zs) = (xs ++ ys) ++ zs

We show:

f (xs ++ (ys ++ zs)) = (xs ++ ys) ++ zs

Where f is a function that changes the type of the vector, implemented using cast. The definition looks like this:

',5),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"example"),s(),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-3aNoExport-2b2b-assoc-ty",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3aNoExport-2b2b-assoc-ty"},[a("span",{class:"Fn"},"++-assoc-ty")]),s(" ("),a("a",{id:"v129498568",class:"aya-hover","aya-hover-text":"Vec n A",href:"#v129498568"},[a("span",{class:"LocalVar"},"xs")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v829149076"},[a("span",{class:"Generalized"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") ("),a("a",{id:"v85748029",class:"aya-hover","aya-hover-text":"Vec m A",href:"#v85748029"},[a("span",{class:"LocalVar"},"ys")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1678046232"},[a("span",{class:"Generalized"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") ("),a("a",{id:"v1784131088",class:"aya-hover","aya-hover-text":"Vec o A",href:"#v1784131088"},[a("span",{class:"LocalVar"},"zs")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v9797126"},[a("span",{class:"Generalized"},"o")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(`) + ⇒ `),a("a",{class:"aya-hover","aya-hover-text":"Vec (n + (m + o)) A",href:"#Mian-cast"},[a("span",{class:"Fn"},"cast")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Vec ((n + m) + o) A = Vec (n + (m + o)) A",href:"#Mian-pmap"},[a("span",{class:"Fn"},"pmap")]),s(" ("),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v94157402",href:"#v94157402"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v94157402"},[a("span",{class:"LocalVar"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"((n + m) + o) = (n + (m + o))",href:"#Mian-2b-assoc"},[a("span",{class:"Fn"},"+-assoc")]),s(") (("),a("a",{class:"aya-hover","aya-hover-text":"Vec n A",href:"#v129498568"},[a("span",{class:"LocalVar"},"xs")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (?n n A m o xs ys zs + ?m n A m o xs ys zs) (?A n A m o xs ys zs)",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec m A",href:"#v85748029"},[a("span",{class:"LocalVar"},"ys")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Vec ((n + m) + o) A",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec o A",href:"#v1784131088"},[a("span",{class:"LocalVar"},"zs")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec n A",href:"#v129498568"},[a("span",{class:"LocalVar"},"xs")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (?n n A m o xs ys zs + ?m n A m o xs ys zs) (?A n A m o xs ys zs)",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Vec m A",href:"#v85748029"},[a("span",{class:"LocalVar"},"ys")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (?n n A m o xs ys zs + ?m n A m o xs ys zs) (?A n A m o xs ys zs)",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec o A",href:"#v1784131088"},[a("span",{class:"LocalVar"},"zs")]),s(")")]),s(` +`)],-1),v('

It is harder to prove because in the induction step, one need to show that cast (pmap (\\ p0Vec p0 A) +-assoc) is equivalent to the identity function in order to use the induction hypothesis. For the record, here's the proof:

',1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-castRefl",class:"aya-hover","aya-hover-text":"cast refl a = a",href:"#Mian-castRefl"},[a("span",{class:"Fn"},"castRefl")]),s(" ("),a("a",{id:"v1117871068",class:"aya-hover","aya-hover-text":"A",href:"#v1117871068"},[a("span",{class:"LocalVar"},"a")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#Mian-cast"},[a("span",{class:"Fn"},"cast")]),s(),a("span",{class:"Keyword"},"↑"),s(),a("a",{class:"aya-hover","aya-hover-text":"A = A",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1117871068"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1117871068"},[a("span",{class:"LocalVar"},"a")]),s(" ⇒ "),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v466853180",href:"#v466853180"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#Mian-coe"},[a("span",{class:"Primitive"},"coe")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v466853180"},[a("span",{class:"LocalVar"},"i")]),s(" 1 ("),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v1863953433",href:"#v1863953433"},[a("span",{class:"LocalVar"},"j")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1117871068"},[a("span",{class:"LocalVar"},"a")])]),s(` +`)],-1),a("p",null,"But still, with this lemma it is still hard. Cubical provides a pleasant way of working with heterogeneous equality:",-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-Path27",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Path27"},[a("span",{class:"Fn"},"Path'")]),s(" ("),a("a",{id:"v508378341",class:"aya-hover","aya-hover-text":"I → Type 0",href:"#v508378341"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"ISet",href:"#Mian-I"},[a("span",{class:"Primitive"},"I")]),s(" → "),a("span",{class:"Keyword"},"Type"),s(") ("),a("a",{id:"v1037854997",class:"aya-hover","aya-hover-text":"A 0",href:"#v1037854997"},[a("span",{class:"LocalVar"},"a")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v508378341"},[a("span",{class:"LocalVar"},"A")]),s(" 0) ("),a("a",{id:"v1884155890",class:"aya-hover","aya-hover-text":"A 1",href:"#v1884155890"},[a("span",{class:"LocalVar"},"b")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v508378341"},[a("span",{class:"LocalVar"},"A")]),s(" 1) ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Path"},[a("span",{class:"Primitive"},"Path")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I → Type 0",href:"#v508378341"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A 0",href:"#v1037854997"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A 1",href:"#v1884155890"},[a("span",{class:"LocalVar"},"b")])]),s(` +`)],-1),v("

So if we have X : A = B and a : A, b : B, then Path (\\i => X i) a b expresses the heterogeneous equality between a and b nicely.

We may then use the following type signature:

",2),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-2b2b-assoc-type",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-2b2b-assoc-type"},[a("span",{class:"Fn"},"++-assoc-type")]),s(" ("),a("a",{id:"v464224872",class:"aya-hover","aya-hover-text":"Vec n A",href:"#v464224872"},[a("span",{class:"LocalVar"},"xs")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v829149076"},[a("span",{class:"Generalized"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") ("),a("a",{id:"v170949260",class:"aya-hover","aya-hover-text":"Vec m A",href:"#v170949260"},[a("span",{class:"LocalVar"},"ys")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1678046232"},[a("span",{class:"Generalized"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") ("),a("a",{id:"v1845623216",class:"aya-hover","aya-hover-text":"Vec o A",href:"#v1845623216"},[a("span",{class:"LocalVar"},"zs")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v9797126"},[a("span",{class:"Generalized"},"o")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(`) + ⇒ `),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Path"},[a("span",{class:"Primitive"},"Path")]),s(" ("),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v295485334",href:"#v295485334"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b-assoc"},[a("span",{class:"Fn"},"+-assoc")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v295485334"},[a("span",{class:"LocalVar"},"i")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") (("),a("a",{class:"aya-hover","aya-hover-text":"Vec n A",href:"#v464224872"},[a("span",{class:"LocalVar"},"xs")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (?n n A m o xs ys zs + ?m n A m o xs ys zs) (?A n A m o xs ys zs)",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec m A",href:"#v170949260"},[a("span",{class:"LocalVar"},"ys")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Vec ((n + m) + o) A",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec o A",href:"#v1845623216"},[a("span",{class:"LocalVar"},"zs")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Vec n A",href:"#v464224872"},[a("span",{class:"LocalVar"},"xs")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (?n n A m o xs ys zs + ?m n A m o xs ys zs) (?A n A m o xs ys zs)",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Vec m A",href:"#v170949260"},[a("span",{class:"LocalVar"},"ys")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (?n n A m o xs ys zs + ?m n A m o xs ys zs) (?A n A m o xs ys zs)",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec o A",href:"#v1845623216"},[a("span",{class:"LocalVar"},"zs")]),s("))")]),s(` +`)],-1),a("p",null,"The proof is omitted (try yourself!).",-1),a("h2",{id:"quotient-inductive-types",tabindex:"-1"},[s("Quotient inductive types "),a("a",{class:"header-anchor",href:"#quotient-inductive-types","aria-label":'Permalink to "Quotient inductive types"'},"​")],-1),a("p",null,"Quotient types are types that equates their instances in a non-trivial way. In Aya, they are defined using the following syntax:",-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Interval",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Interval"},[a("span",{class:"Data"},"Interval")]),s(` +| `),a("a",{id:"Mian-Interval-left",class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-left"},[a("span",{class:"Constructor"},"left")]),s(` +| `),a("a",{id:"Mian-Interval-right",class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-right"},[a("span",{class:"Constructor"},"right")]),s(` +| `),a("a",{id:"Mian-Interval-line",class:"aya-hover","aya-hover-text":"left = right",href:"#Mian-Interval-line"},[a("span",{class:"Constructor"},"line")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-left"},[a("span",{class:"Constructor"},"left")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-right"},[a("span",{class:"Constructor"},"right")])]),s(` +`)],-1),v('

This is an uninteresting quotient type, that is basically Bool but saying its two values are equal, so it's really just a unit type, with its unique element being the equivalence class of left and right.

If you're familiar with a proof assistant with an intensional equality like Coq/Agda/Lean/etc., you might find this surprising because a unit type shall not have two distinct elements, and an equality shall not be stated between two distinct constructors. How does this work in Aya?

Actually, in these systems, the equality is defined inductively, and it only has one constructor -- refl. This is not how equality is defined in Aya, so we can cook some interesting equality proofs into it, which includes these equality-looking constructors.

  1. The type of line will be translated into IInterval together with the judgmental equality that line 0 is left and line 1 is right, basically a desugaring of the equality with additional features. This makes line a valid constructor in normal type theory: it takes some parameters and returns Interval.
  2. These judgmental equalities need to be preserved by the elimination rule of Interval. Here is an example elimination:
',4),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"example"),s(),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-3aNoExport-Interval-elim",class:"aya-hover","aya-hover-text":"A",href:"#Mian-3aNoExport-Interval-elim"},[a("span",{class:"Fn"},"Interval-elim")]),s(" {"),a("a",{id:"v313082880",class:"aya-hover","aya-hover-text":"A",href:"#v313082880"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v1783083399",class:"aya-hover","aya-hover-text":"A",href:"#v1783083399"},[a("span",{class:"LocalVar"},"b")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s("} {"),a("a",{id:"v519492428",class:"aya-hover","aya-hover-text":"a = b",href:"#v519492428"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v313082880"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1783083399"},[a("span",{class:"LocalVar"},"b")]),s("} ("),a("a",{id:"v1176968662",class:"aya-hover","aya-hover-text":"Interval",href:"#v1176968662"},[a("span",{class:"LocalVar"},"i")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Interval"},[a("span",{class:"Data"},"Interval")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(),a("span",{class:"Keyword"},"elim"),s(),a("a",{href:"#v1176968662"},[a("span",{class:"LocalVar"},"i")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-left"},[a("span",{class:"Constructor"},"left")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v313082880"},[a("span",{class:"LocalVar"},"a")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-right"},[a("span",{class:"Constructor"},"right")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1783083399"},[a("span",{class:"LocalVar"},"b")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"left = right",href:"#Mian-Interval-line"},[a("span",{class:"Constructor"},"line")]),s(),a("a",{id:"v1225568095",class:"aya-hover","aya-hover-text":"I",href:"#v1225568095"},[a("span",{class:"LocalVar"},"j")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v519492428"},[a("span",{class:"LocalVar"},"p")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v1225568095"},[a("span",{class:"LocalVar"},"j")])]),s(` +`)],-1),v("

Note that the term pmap Interval-elim line, which reduces to p, has type Interval-elim left = Interval-elim right, so we need to check if p 0 equals Interval-elim left, and p 1 equals Interval-elim right. This is a confluence check that ensures the elimination is well-defined.

What's interesting about this type, is that its elimination implies function extensionality:

",2),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"private"),s(),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-lemma",class:"aya-hover","aya-hover-text":"B",href:"#Mian-lemma"},[a("span",{class:"Fn"},"lemma")]),s(` + (`),a("a",{id:"v193178046",class:"aya-hover","aya-hover-text":"A → B",href:"#v193178046"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{id:"v638169719",class:"aya-hover","aya-hover-text":"A → B",href:"#v638169719"},[a("span",{class:"LocalVar"},"g")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v2051120548"},[a("span",{class:"Generalized"},"B")]),s(") ("),a("a",{id:"v1080476785",class:"aya-hover","aya-hover-text":"Fn (B : A) → f B = g B",href:"#v1080476785"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("span",{class:"Keyword"},"∀"),s(),a("a",{id:"v1899141525",class:"aya-hover","aya-hover-text":"A",href:"#v1899141525"},[a("span",{class:"LocalVar"},"x")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v193178046"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1899141525"},[a("span",{class:"LocalVar"},"x")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v638169719"},[a("span",{class:"LocalVar"},"g")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1899141525"},[a("span",{class:"LocalVar"},"x")]),s(`) + (`),a("a",{id:"v722951168",class:"aya-hover","aya-hover-text":"Interval",href:"#v722951168"},[a("span",{class:"LocalVar"},"i")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Interval"},[a("span",{class:"Data"},"Interval")]),s(") ("),a("a",{id:"v1052253947",class:"aya-hover","aya-hover-text":"A",href:"#v1052253947"},[a("span",{class:"LocalVar"},"a")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v2051120548"},[a("span",{class:"Generalized"},"B")]),s(),a("span",{class:"Keyword"},"elim"),s(),a("a",{href:"#v722951168"},[a("span",{class:"LocalVar"},"i")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-left"},[a("span",{class:"Constructor"},"left")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v193178046"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1052253947"},[a("span",{class:"LocalVar"},"a")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-right"},[a("span",{class:"Constructor"},"right")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v638169719"},[a("span",{class:"LocalVar"},"g")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1052253947"},[a("span",{class:"LocalVar"},"a")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"left = right",href:"#Mian-Interval-line"},[a("span",{class:"Constructor"},"line")]),s(),a("a",{id:"v428696898",class:"aya-hover","aya-hover-text":"I",href:"#v428696898"},[a("span",{class:"LocalVar"},"j")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v1080476785"},[a("span",{class:"LocalVar"},"p")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1052253947"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v428696898"},[a("span",{class:"LocalVar"},"j")]),s(` + +`),a("span",{class:"Keyword"},"example"),s(),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-3aNoExport-funExt27",class:"aya-hover","aya-hover-text":"f = g",href:"#Mian-3aNoExport-funExt27"},[a("span",{class:"Fn"},"funExt'")]),s(" ("),a("a",{id:"v1987360300",class:"aya-hover","aya-hover-text":"A → B",href:"#v1987360300"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{id:"v434610528",class:"aya-hover","aya-hover-text":"A → B",href:"#v434610528"},[a("span",{class:"LocalVar"},"g")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v2051120548"},[a("span",{class:"Generalized"},"B")]),s(") ("),a("a",{id:"v380812044",class:"aya-hover","aya-hover-text":"Fn (B : A) → f B = g B",href:"#v380812044"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("span",{class:"Keyword"},"∀"),s(),a("a",{id:"v1989132530",class:"aya-hover","aya-hover-text":"A",href:"#v1989132530"},[a("span",{class:"LocalVar"},"a")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v1987360300"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1989132530"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v434610528"},[a("span",{class:"LocalVar"},"g")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1989132530"},[a("span",{class:"LocalVar"},"a")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"A → B",href:"#v1987360300"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A → B",href:"#v434610528"},[a("span",{class:"LocalVar"},"g")]),s(` ⇒ + `),a("a",{class:"aya-hover","aya-hover-text":"lemma f g p left = lemma f g p right",href:"#Mian-pmap"},[a("span",{class:"Fn"},"pmap")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Interval → A → B",href:"#Mian-lemma"},[a("span",{class:"Fn"},"lemma")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A → B",href:"#v1987360300"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A → B",href:"#v434610528"},[a("span",{class:"LocalVar"},"g")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Fn (B : A) → f B = g B",href:"#v380812044"},[a("span",{class:"LocalVar"},"p")]),s(") ("),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v1414845278",href:"#v1414845278"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-line"},[a("span",{class:"Constructor"},"line")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v1414845278"},[a("span",{class:"LocalVar"},"i")]),s(")")]),s(` +`)],-1),a("p",null,[s("Note that even though we are using equation combinators like "),a("code",{class:"Aya"},[a("a",{href:"#Mian-pmap"},[a("span",{class:"Fn"},"pmap")])]),s(" which are implemented using path application and abstraction, it is not considered cheating because these are already theorems in MLTT anyway.")],-1),a("p",null,"We can define other interesting quotients such as a symmetric integer:",-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Int",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Int"},[a("span",{class:"Data"},"Int")]),s(` +| `),a("a",{id:"Mian-Int-pos",class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-pos"},[a("span",{class:"Constructor"},"pos")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(" | "),a("a",{id:"Mian-Int-neg",class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-neg"},[a("span",{class:"Constructor"},"neg")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(` +| `),a("a",{id:"Mian-Int-zro",class:"aya-hover","aya-hover-text":"pos 0 = neg 0",href:"#Mian-Int-zro"},[a("span",{class:"Constructor"},"zro")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-pos"},[a("span",{class:"Constructor"},"pos")]),s(" 0 "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-neg"},[a("span",{class:"Constructor"},"neg")]),s(" 0")]),s(` +`)],-1),a("p",null,[s("Some operations on "),a("code",{class:"Aya"},[a("a",{href:"#Mian-Int"},[a("span",{class:"Data"},"Int")])]),s(":")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-succ",class:"aya-hover","aya-hover-text":"Int",href:"#Mian-succ"},[a("span",{class:"Fn"},"succ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Int"},[a("span",{class:"Data"},"Int")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Int"},[a("span",{class:"Data"},"Int")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-pos"},[a("span",{class:"Constructor"},"pos")]),s(),a("a",{id:"v1920907467",class:"aya-hover","aya-hover-text":"Nat",href:"#v1920907467"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-pos"},[a("span",{class:"Constructor"},"pos")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1920907467"},[a("span",{class:"LocalVar"},"n")]),s(`) +| `),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-neg"},[a("span",{class:"Constructor"},"neg")]),s(" 0 ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-pos"},[a("span",{class:"Constructor"},"pos")]),s(` 1 +| `),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-neg"},[a("span",{class:"Constructor"},"neg")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{id:"v970535245",class:"aya-hover","aya-hover-text":"Nat",href:"#v970535245"},[a("span",{class:"LocalVar"},"n")]),s(") ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-neg"},[a("span",{class:"Constructor"},"neg")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v970535245"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"pos 0 = neg 0",href:"#Mian-Int-zro"},[a("span",{class:"Constructor"},"zro")]),s(),a("a",{id:"v194481424",class:"aya-hover","aya-hover-text":"I",href:"#v194481424"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-pos"},[a("span",{class:"Constructor"},"pos")]),s(` 1 + +`),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-abs",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-abs"},[a("span",{class:"Fn"},"abs")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Int"},[a("span",{class:"Data"},"Int")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-pos"},[a("span",{class:"Constructor"},"pos")]),s(),a("a",{id:"v753321708",class:"aya-hover","aya-hover-text":"Nat",href:"#v753321708"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v753321708"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-neg"},[a("span",{class:"Constructor"},"neg")]),s(),a("a",{id:"v464400749",class:"aya-hover","aya-hover-text":"Nat",href:"#v464400749"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v464400749"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"pos 0 = neg 0",href:"#Mian-Int-zro"},[a("span",{class:"Constructor"},"zro")]),s(" _ ⇒ 0")]),s(` +`)],-1),v('

The succ operator has the first three clauses straightforward, and the last one is a proof of succ (neg 0) equals succ (pos 0), as we should preserve the judgmental equality in the type of zro. We need to do the same for abs.

',1)]))}const z=g(T,[["render",N]]);export{B as __pageData,z as default}; diff --git a/assets/guide_prover-tutorial.md.DBob0Be6.lean.js b/assets/guide_prover-tutorial.md.DBob0Be6.lean.js new file mode 100644 index 0000000..e4bd4af --- /dev/null +++ b/assets/guide_prover-tutorial.md.DBob0Be6.lean.js @@ -0,0 +1,98 @@ +import{_ as g,c as w,j as a,a as s,a2 as v,o as I}from"./chunks/framework.CoXjB5sU.js";const T={mounted(){const y=new Map;function p(c){const e=c.querySelectorAll("a[href]");for(const r of e){const n=r.href,i=y.get(n)??new Set;i.add(r),y.set(n,i)}for(const r of e)r.onmouseover=function(){for(const n of y.get(this.href))n.classList.add("hover-highlight")},r.onmouseout=function(){for(const n of y.get(this.href))n.classList.remove("hover-highlight")}}function d(c){return decodeURIComponent(atob(c).split("").map(function(e){return"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)}).join(""))}const x=(c=>{const e={};return(...r)=>{const n=JSON.stringify(r);return e[n]=e[n]||c(...r)}})(d);class u{constructor(){this.list=[]}dismiss(e){e&&(e.remove(),this.list=this.list.filter(r=>r!==e))}dismissIfNotUsed(e){e&&(e.markedForDismissal=!0,setTimeout(()=>{!e.userIsThinking&&this.allowAutoDismissal(e)&&this.dismiss(e)},1e3))}allowAutoDismissal(e){return e.markedForDismissal&&!e.userClicked}fireAutoDismissalFor(e){let r=this.list.find(n=>n.userCreatedFrom===e);this.dismissIfNotUsed(r)}createHoverFor(e,r,n){let i=this.list.find(o=>o.userCreatedFrom===e);if(i&&i.userClicked)return i;let M=[];const A=this.list.filter(o=>{if(this.allowAutoDismissal(o))return M.push(o),!1;const l=o.userCreatedFrom,f=e;let h=f;for(;h;){if(h===l)return!0;h=h.parentElement}for(h=l;h;){if(h===f)return!0;h=h.parentElement}return!1});M.forEach(o=>this.dismiss(o));let t=document.createElement("div");t.userCreatedFrom=e,t.innerHTML="×"+x(r),t.classList.add("AyaTooltipPopup"),p(t);let b=this;if(t.handleEvent=function(o){if(o.type==="click"){this.userClicked=!0,this.markedForDismissal=!1;let l=this.children[0];if(!l)return;let f=this;l.style.visibility="visible",l.addEventListener("click",h=>b.dismiss(f))}o.type==="mouseover"&&(this.userIsThinking=!0),o.type==="mouseout"&&(this.userIsThinking=!1,b.dismissIfNotUsed(this))},t.addEventListener("click",t),t.addEventListener("mouseover",t),t.addEventListener("mouseout",t),n.appendChild(t),t.style.left=`${e.offsetLeft}px`,A.length===0){const o=e.getBoundingClientRect(),l=t.getBoundingClientRect();o.bottom+l.height+30>window.innerHeight?t.style.top=`calc(${e.offsetTop-l.height+8}px - 3em)`:t.style.top=`${e.offsetTop+e.offsetHeight+8}px`}else{const o=Math.max(...A.map(l=>l.offsetTop+l.offsetHeight));t.style.top=`${o+8}px`}return this.list.push(t),t}}let m=new u;function V(c){return function(){let e=this;const r=e.getAttribute("data-tooltip-text");r&&(c?m.createHoverFor(e,r,document.body):m.fireAutoDismissalFor(e))}}p(document);{let c=document.getElementsByClassName("aya-tooltip");for(let e=0;e {??}")]),s(` +`)],-1),a("p",null,"There is no way to prove it in Martin-Löf type theory or Calculus of Constructions. However, you are very smart and realized you can instead show the following:",-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-Goal27",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Goal27"},[a("span",{class:"Fn"},"Goal'")]),s(" ("),a("a",{id:"v1003292107",class:"aya-hover","aya-hover-text":"Bool",href:"#v1003292107"},[a("span",{class:"LocalVar"},"x")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Bool"},[a("span",{class:"Data"},"Bool")]),s(") ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Bool",href:"#Mian-id"},[a("span",{class:"Fn"},"id")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Bool",href:"#v1003292107"},[a("span",{class:"LocalVar"},"x")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Bool",href:"#Mian-not"},[a("span",{class:"Fn"},"not")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Bool",href:"#Mian-not"},[a("span",{class:"Fn"},"not")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Bool",href:"#v1003292107"},[a("span",{class:"LocalVar"},"x")]),s(")")]),s(` +`)],-1),v('

This is pretty much the same theorem!

Now, suppose we need to show a propositional equality between two records. This means we have to show they're memberwise equal. One record has a member \\ p0not (not p0), and the other has id. This time, you cannot cheat by changing the goal type. You post the question on some mailing list and people are telling you that the alternative version of the theorem you have shown does not imply the original, unless "function extensionality" is a theorem in your type theory.

To have function extensionality as a theorem, you came across two distinct type theories: observational type theory and cubical type theory. Aya chose the latter.

Cubical

Here's the proof of function extensionality in Aya:

',5),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-funExt",class:"aya-hover","aya-hover-text":"f = g",href:"#Mian-funExt"},[a("span",{class:"Fn"},"funExt")]),s(" ("),a("a",{id:"v613784740",class:"aya-hover","aya-hover-text":"A → B",href:"#v613784740"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{id:"v271095942",class:"aya-hover","aya-hover-text":"A → B",href:"#v271095942"},[a("span",{class:"LocalVar"},"g")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v2051120548"},[a("span",{class:"Generalized"},"B")]),s(") ("),a("a",{id:"v1323434987",class:"aya-hover","aya-hover-text":"Fn (B : A) → f B = g B",href:"#v1323434987"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("span",{class:"Keyword"},"∀"),s(),a("a",{id:"v895599632",class:"aya-hover","aya-hover-text":"A",href:"#v895599632"},[a("span",{class:"LocalVar"},"a")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v613784740"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v895599632"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v271095942"},[a("span",{class:"LocalVar"},"g")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v895599632"},[a("span",{class:"LocalVar"},"a")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"A → B",href:"#v613784740"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A → B",href:"#v271095942"},[a("span",{class:"LocalVar"},"g")]),s(` + ⇒ `),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v1508059488",href:"#v1508059488"},[a("span",{class:"LocalVar"},"i")]),s(),a("a",{id:"v2082557120",href:"#v2082557120"},[a("span",{class:"LocalVar"},"a")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v1323434987"},[a("span",{class:"LocalVar"},"p")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v2082557120"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v1508059488"},[a("span",{class:"LocalVar"},"i")])]),s(` +`)],-1),v('

Aya has a "cubical" equality type that is not inductively defined. An equality a = b for a, b : A is really just a function IA (as we can see from the proof construction, for f = g we prove it by a lambda abstraction) where:

  • I is a special type that has two closed instances 0 and 1, and we think of there being a propositional equality between 0 and 1, and there is no pattern matching operation that distinguishes them. So, every function that maps out of I must preserve this judgmental equality.
  • For f : I -> A, the corresponding equality type is f 0 = f 1. Hypothetically, let f be the identity function, and we get a propositional equality between 0 and 1, but for technical reasons we don't talk about equality between 0 and 1 directly.

By this definition, we can "prove" reflexivity by creating a constant function:

',3),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-refl",class:"aya-hover","aya-hover-text":"a = a",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(" {"),a("a",{id:"v37981645",class:"aya-hover","aya-hover-text":"A",href:"#v37981645"},[a("span",{class:"LocalVar"},"a")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s("} : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v37981645"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v37981645"},[a("span",{class:"LocalVar"},"a")]),s(" ⇒ "),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v1533524862",href:"#v1533524862"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v37981645"},[a("span",{class:"LocalVar"},"a")])]),s(` +`)],-1),v(`

For f = fn i => a, we need to verify if f 0 equals the left-hand side of the equality and f 1 equals the right-hand side, which are both true.

And to show that f = g, it suffices to construct a function q : I -> (A -> B) such that q 0 = f and q 1 = g. This is true for the proof above:

  (fn i a => p a i) 0    β-reduce
+= fn a => p a 0          p a : f a = g a
+= fn a => f a            η-reduce
+= f

We may also prove the action-on-path theorem, commonly known as cong, but renamed to pmap to avoid a potential future naming clash:

`,4),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-pmap",class:"aya-hover","aya-hover-text":"f a = f b",href:"#Mian-pmap"},[a("span",{class:"Fn"},"pmap")]),s(" ("),a("a",{id:"v418958713",class:"aya-hover","aya-hover-text":"A → B",href:"#v418958713"},[a("span",{class:"LocalVar"},"f")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v2051120548"},[a("span",{class:"Generalized"},"B")]),s(") {"),a("a",{id:"v1042306518",class:"aya-hover","aya-hover-text":"A",href:"#v1042306518"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v1342346098",class:"aya-hover","aya-hover-text":"A",href:"#v1342346098"},[a("span",{class:"LocalVar"},"b")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s("} ("),a("a",{id:"v1358343316",class:"aya-hover","aya-hover-text":"a = b",href:"#v1358343316"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1042306518"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1342346098"},[a("span",{class:"LocalVar"},"b")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v418958713"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1042306518"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v418958713"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1342346098"},[a("span",{class:"LocalVar"},"b")]),s(` + ⇒ `),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v1620948294",href:"#v1620948294"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v418958713"},[a("span",{class:"LocalVar"},"f")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1358343316"},[a("span",{class:"LocalVar"},"p")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v1620948294"},[a("span",{class:"LocalVar"},"i")]),s(")")]),s(` +`)],-1),a("p",null,"Checking the above definition is left as an exercise.",-1),a("p",null,[s("However, we cannot yet define transitivity/symmetry of equality because we do not have the traditional elimination rule of the equality type -- the "),a("code",null,"J"),s(" rule. This will need some advanced proving techniques that are beyond the scope of this simple tutorial, so I'll skim them.")],-1),a("p",null,"We may define the type-safe coercion using it, and this will help us prove the two lemmas about equality:",-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-cast",class:"aya-hover","aya-hover-text":"A → B",href:"#Mian-cast"},[a("span",{class:"Fn"},"cast")]),s(" ("),a("a",{id:"v718571091",class:"aya-hover","aya-hover-text":"A = B",href:"#v718571091"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(),a("span",{class:"Keyword"},"↑"),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 1",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v2051120548"},[a("span",{class:"Generalized"},"B")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v2051120548"},[a("span",{class:"Generalized"},"B")]),s(" ⇒ "),a("span",{class:"Keyword"},"↑"),s(),a("a",{class:"aya-hover","aya-hover-text":"A → B",href:"#Mian-coe"},[a("span",{class:"Primitive"},"coe")]),s(" 0 1 ("),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v807328355",href:"#v807328355"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v718571091"},[a("span",{class:"LocalVar"},"p")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v807328355"},[a("span",{class:"LocalVar"},"i")]),s(")")]),s(` +`)],-1),a("p",null,[s("Then, from "),a("code",null,"p : a = b"),s(" we construct the equivalence "),a("code",null,"(a = a) = (b = a)"),s(" and coerce along this equivalence:")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-pinv",class:"aya-hover","aya-hover-text":"b = a",href:"#Mian-pinv"},[a("span",{class:"Fn"},"pinv")]),s(" {"),a("a",{id:"v1173346575",class:"aya-hover","aya-hover-text":"A",href:"#v1173346575"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v1267149311",class:"aya-hover","aya-hover-text":"A",href:"#v1267149311"},[a("span",{class:"LocalVar"},"b")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s("} ("),a("a",{id:"v52514534",class:"aya-hover","aya-hover-text":"a = b",href:"#v52514534"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1173346575"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1267149311"},[a("span",{class:"LocalVar"},"b")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1267149311"},[a("span",{class:"LocalVar"},"b")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1173346575"},[a("span",{class:"LocalVar"},"a")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"b = a",href:"#Mian-cast"},[a("span",{class:"Fn"},"cast")]),s(" ("),a("span",{class:"Keyword"},"\\"),a("a",{id:"v1025797795",href:"#v1025797795"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v52514534"},[a("span",{class:"LocalVar"},"p")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v1025797795"},[a("span",{class:"LocalVar"},"i")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1173346575"},[a("span",{class:"LocalVar"},"a")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"a = a",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")])]),s(` +`)],-1),a("p",null,[s("From "),a("code",null,"q : b = c"),s(" we construct the equivalence "),a("code",null,"(a = b) = (a = c)"),s(" and coerce along this equivalence:")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-concat",class:"aya-hover","aya-hover-text":"a = c",href:"#Mian-concat"},[a("span",{class:"Fn"},"concat")]),s(" {"),a("a",{id:"v1753714541",class:"aya-hover","aya-hover-text":"A",href:"#v1753714541"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v1095273238",class:"aya-hover","aya-hover-text":"A",href:"#v1095273238"},[a("span",{class:"LocalVar"},"b")]),s(),a("a",{id:"v177140066",class:"aya-hover","aya-hover-text":"A",href:"#v177140066"},[a("span",{class:"LocalVar"},"c")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s("} ("),a("a",{id:"v2059572982",class:"aya-hover","aya-hover-text":"a = b",href:"#v2059572982"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1753714541"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1095273238"},[a("span",{class:"LocalVar"},"b")]),s(") ("),a("a",{id:"v36657658",class:"aya-hover","aya-hover-text":"b = c",href:"#v36657658"},[a("span",{class:"LocalVar"},"q")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1095273238"},[a("span",{class:"LocalVar"},"b")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v177140066"},[a("span",{class:"LocalVar"},"c")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1753714541"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v177140066"},[a("span",{class:"LocalVar"},"c")]),s(` ⇒ + `),a("a",{class:"aya-hover","aya-hover-text":"a = c",href:"#Mian-cast"},[a("span",{class:"Fn"},"cast")]),s(" ("),a("span",{class:"Keyword"},"\\"),a("a",{id:"v873993427",href:"#v873993427"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1753714541"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v36657658"},[a("span",{class:"LocalVar"},"q")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v873993427"},[a("span",{class:"LocalVar"},"i")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"a = b",href:"#v2059572982"},[a("span",{class:"LocalVar"},"p")])]),s(` +`)],-1),a("p",null,"Note that at this point you can already do a bunch of familiar proofs about some simple types such as natural numbers or sized vectors. These are left as exercises, and you are encouraged to try yourself if you are not very sure about how it feels to prove things in Aya.",-1),a("h2",{id:"overlapping-and-order-independent-pattern-matching",tabindex:"-1"},[s("Overlapping and Order-independent Pattern Matching "),a("a",{class:"header-anchor",href:"#overlapping-and-order-independent-pattern-matching","aria-label":'Permalink to "Overlapping and Order-independent Pattern Matching"'},"​")],-1),a("p",null,[s("Remember the "),a("code",null,"+-comm"),s(" proof that you need two lemmas? It is standard to define "),a("code",null,"+"),s(" in the following way:")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"example"),s(),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"Keyword"},"infix"),s(),a("a",{id:"Mian-3aNoExport-2b",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3aNoExport-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(` +| 0, `),a("a",{id:"v164332069",class:"aya-hover","aya-hover-text":"Nat",href:"#v164332069"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v164332069"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{id:"v1650813924",class:"aya-hover","aya-hover-text":"Nat",href:"#v1650813924"},[a("span",{class:"LocalVar"},"m")]),s(", "),a("a",{id:"v400103862",class:"aya-hover","aya-hover-text":"Nat",href:"#v400103862"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1650813924"},[a("span",{class:"LocalVar"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-3aNoExport-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v400103862"},[a("span",{class:"LocalVar"},"n")]),s(")")]),s(` +`)],-1),a("p",null,[s("And then you prove that "),a("code",null,"a + 0 = a"),s(" and "),a("code",null,"a + suc b = suc (a + b)"),s(". It is tempting to have "),a("code",null,"| n, 0 => n"),s(" as a computation rule as well, but this is incompatible with the usual semantics of pattern matching, which is compiled to elimination principles during type checking. However, you "),a("em",null,"can"),s(" do that in Aya. You may also add the other lemma as well.")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"overlap"),s(),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"Keyword"},"infix"),s(),a("a",{id:"Mian-2b",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(` +| 0, `),a("a",{id:"v610454273",class:"aya-hover","aya-hover-text":"Nat",href:"#v610454273"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v610454273"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{id:"v431506362",class:"aya-hover","aya-hover-text":"Nat",href:"#v431506362"},[a("span",{class:"LocalVar"},"n")]),s(", 0 ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v431506362"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{id:"v1693226694",class:"aya-hover","aya-hover-text":"Nat",href:"#v1693226694"},[a("span",{class:"LocalVar"},"m")]),s(", "),a("a",{id:"v2003147568",class:"aya-hover","aya-hover-text":"Nat",href:"#v2003147568"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1693226694"},[a("span",{class:"LocalVar"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v2003147568"},[a("span",{class:"LocalVar"},"n")]),s(`) +| `),a("a",{id:"v1164799006",class:"aya-hover","aya-hover-text":"Nat",href:"#v1164799006"},[a("span",{class:"LocalVar"},"m")]),s(", "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{id:"v504582810",class:"aya-hover","aya-hover-text":"Nat",href:"#v504582810"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1164799006"},[a("span",{class:"LocalVar"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v504582810"},[a("span",{class:"LocalVar"},"n")]),s(`) +`),a("span",{class:"Keyword"},"tighter"),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")])]),s(` +`)],-1),a("p",null,[s("This makes all of them definitional equality. So, "),a("code",{class:"Aya"},[a("a",{href:"#Mian-2b-comm"},[a("span",{class:"Fn"},"+-comm")])]),s(" can be simplified to just one pattern matching:")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-2b-comm",class:"aya-hover","aya-hover-text":"(a + b) = (b + a)",href:"#Mian-2b-comm"},[a("span",{class:"Fn"},"+-comm")]),s(" ("),a("a",{id:"v2079565272",class:"aya-hover","aya-hover-text":"Nat",href:"#v2079565272"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v1122130699",class:"aya-hover","aya-hover-text":"Nat",href:"#v1122130699"},[a("span",{class:"LocalVar"},"b")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v2079565272"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1122130699"},[a("span",{class:"LocalVar"},"b")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1122130699"},[a("span",{class:"LocalVar"},"b")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v2079565272"},[a("span",{class:"LocalVar"},"a")]),s(),a("span",{class:"Keyword"},"elim"),s(),a("a",{href:"#v2079565272"},[a("span",{class:"LocalVar"},"a")]),s(` +| 0 ⇒ `),a("a",{class:"aya-hover","aya-hover-text":"b = b",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" _ ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"suc (_ + b) = suc (b + _)",href:"#Mian-pmap"},[a("span",{class:"Fn"},"pmap")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat → Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"(_ + b) = (b + _)",href:"#Mian-2b-comm"},[a("span",{class:"Fn"},"+-comm")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YyMTA2OTAwMTUzIj48c3BhbiBjbGFzcz0iTG9jYWxWYXIiPl88L3NwYW4+PC9hPjwvY29kZT4KPC9wcmU+Cg=="},"_"),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+PGEgaHJlZj0iI3YxNDQzMDU1ODQ2Ij48c3BhbiBjbGFzcz0iTG9jYWxWYXIiPmI8L3NwYW4+PC9hPjwvY29kZT4KPC9wcmU+Cg=="},"_"),s(")")]),s(` +`)],-1),a("p",null,[s("Note that we are using the "),a("code",null,"elim"),s(" keyword, which describes the variables that the function body is pattern matching on.")],-1),a("h2",{id:"heterogeneous-equality",tabindex:"-1"},[s("Heterogeneous equality "),a("a",{class:"header-anchor",href:"#heterogeneous-equality","aria-label":'Permalink to "Heterogeneous equality"'},"​")],-1),a("p",null,"When working with indexed families, you may want to have heterogeneous equality to avoid having mysterious coercions. For example, consider the associativity of sized vector appends. We first need to define sized vectors and the append operation:",-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"variable"),s(),a("a",{id:"v829149076",href:"#v829149076"},[a("span",{class:"Generalized"},"n")]),s(),a("a",{id:"v1678046232",href:"#v1678046232"},[a("span",{class:"Generalized"},"m")]),s(),a("a",{id:"v9797126",href:"#v9797126"},[a("span",{class:"Generalized"},"o")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(` +`),a("span",{class:"Comment"},"// Definitions"),s(` +`),a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Vec",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(" ("),a("a",{id:"v1067599825",class:"aya-hover","aya-hover-text":"Nat",href:"#v1067599825"},[a("span",{class:"LocalVar"},"n")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(") ("),a("a",{id:"v749927456",class:"aya-hover","aya-hover-text":"Type 0",href:"#v749927456"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("span",{class:"Keyword"},"Type"),s(`) +| 0, `),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+V2FybmluZzogVGhlIG5hbWUgPGNvZGUgY2xhc3M9IkF5YSI+QTwvY29kZT4gc2hhZG93cyBhIHByZXZpb3VzIGxvY2FsIGRlZmluaXRpb24gZnJvbSBvdXRlciBzY29wZTwvY29kZT4KPC9wcmU+Cg=="},[a("span",{class:"Warning"},[a("a",{id:"v1330400026",class:"aya-hover","aya-hover-text":"Type 0",href:"#v1330400026"},[a("span",{class:"LocalVar"},"A")])])]),s(" ⇒ "),a("a",{id:"Mian-Vec-nil",class:"aya-hover","aya-hover-text":"Vec 0 A",href:"#Mian-Vec-nil"},[a("span",{class:"Constructor"},"nil")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+V2FybmluZzogVGhlIG5hbWUgPGNvZGUgY2xhc3M9IkF5YSI+bjwvY29kZT4gc2hhZG93cyBhIHByZXZpb3VzIGxvY2FsIGRlZmluaXRpb24gZnJvbSBvdXRlciBzY29wZTwvY29kZT4KPC9wcmU+Cg=="},[a("span",{class:"Warning"},[a("a",{id:"v1318227903",class:"aya-hover","aya-hover-text":"Nat",href:"#v1318227903"},[a("span",{class:"LocalVar"},"n")])])]),s(", "),a("span",{class:"aya-tooltip","data-tooltip-text":"PHByZSBjbGFzcz0iQXlhIj4KPGNvZGU+V2FybmluZzogVGhlIG5hbWUgPGNvZGUgY2xhc3M9IkF5YSI+QTwvY29kZT4gc2hhZG93cyBhIHByZXZpb3VzIGxvY2FsIGRlZmluaXRpb24gZnJvbSBvdXRlciBzY29wZTwvY29kZT4KPC9wcmU+Cg=="},[a("span",{class:"Warning"},[a("a",{id:"v892335322",class:"aya-hover","aya-hover-text":"Type 0",href:"#v892335322"},[a("span",{class:"LocalVar"},"A")])])]),s(" ⇒ "),a("span",{class:"Keyword"},"infixr"),s(),a("a",{id:"Mian-Vec-3a3c",class:"aya-hover","aya-hover-text":"Vec (suc n) A",href:"#Mian-Vec-3a3c"},[a("span",{class:"Constructor"},":<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v892335322"},[a("span",{class:"LocalVar"},"A")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1318227903"},[a("span",{class:"LocalVar"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v892335322"},[a("span",{class:"LocalVar"},"A")]),s(`) +`),a("span",{class:"Keyword"},"overlap"),s(),a("span",{class:"Keyword"},"def"),s(),a("span",{class:"Keyword"},"infixr"),s(),a("a",{id:"Mian-2b2b",class:"aya-hover","aya-hover-text":"Vec (n + m) A",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v829149076"},[a("span",{class:"Generalized"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1678046232"},[a("span",{class:"Generalized"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v829149076"},[a("span",{class:"Generalized"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1678046232"},[a("span",{class:"Generalized"},"m")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Vec 0 A",href:"#Mian-Vec-nil"},[a("span",{class:"Constructor"},"nil")]),s(", "),a("a",{id:"v1305935114",class:"aya-hover","aya-hover-text":"Vec m A",href:"#v1305935114"},[a("span",{class:"LocalVar"},"ys")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Vec m A",href:"#v1305935114"},[a("span",{class:"LocalVar"},"ys")]),s(` +| `),a("a",{id:"v1720891078",class:"aya-hover","aya-hover-text":"Vec n A",href:"#v1720891078"},[a("span",{class:"LocalVar"},"ys")]),s(", "),a("a",{class:"aya-hover","aya-hover-text":"Vec 0 A",href:"#Mian-Vec-nil"},[a("span",{class:"Constructor"},"nil")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Vec n A",href:"#v1720891078"},[a("span",{class:"LocalVar"},"ys")]),s(` +| `),a("a",{id:"v970419381",class:"aya-hover","aya-hover-text":"A",href:"#v970419381"},[a("span",{class:"LocalVar"},"x")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (suc n) A",href:"#Mian-Vec-3a3c"},[a("span",{class:"Constructor"},":<")]),s(),a("a",{id:"v1241569743",class:"aya-hover","aya-hover-text":"Vec n A",href:"#v1241569743"},[a("span",{class:"LocalVar"},"xs")]),s(", "),a("a",{id:"v1731656333",class:"aya-hover","aya-hover-text":"Vec m A",href:"#v1731656333"},[a("span",{class:"LocalVar"},"ys")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v970419381"},[a("span",{class:"LocalVar"},"x")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (suc (?n A x xs ys n m)) (?A A x xs ys n m)",href:"#Mian-Vec-3a3c"},[a("span",{class:"Constructor"},":<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec n A",href:"#v1241569743"},[a("span",{class:"LocalVar"},"xs")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (?n A x xs ys n m + ?m A x xs ys n m) (?A A x xs ys n m)",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec m A",href:"#v1731656333"},[a("span",{class:"LocalVar"},"ys")]),s(` +`),a("span",{class:"Keyword"},"tighter"),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (suc n) A",href:"#Mian-Vec-3a3c"},[a("span",{class:"Constructor"},":<")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")])]),s(` +`)],-1),v(`

It is tempting to use the below definition:

overlap def ++-assoc (xs : Vec n A) (ys : Vec m A) (zs : Vec o A)
+  : (xs ++ ys) ++ zs = xs ++ (ys ++ zs) elim xs
+| nil => refl
+| x :< xs => pmap (x :<) (++-assoc xs ys zs)

However, this definition is not well-typed:

  • (xs ++ ys) ++ zs is of type Vec ((n + m) + o) A
  • xs ++ (ys ++ zs) is of type Vec (n + (m + o)) A.

They are not the same! Fortunately, we can prove that they are propositionally equal. We need to show that natural number addition is associative, which is the key lemma of this propositional equality:

`,5),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-2b-assoc",class:"aya-hover","aya-hover-text":"((a + b) + c) = (a + (b + c))",href:"#Mian-2b-assoc"},[a("span",{class:"Fn"},"+-assoc")]),s(" {"),a("a",{id:"v551016187",class:"aya-hover","aya-hover-text":"Nat",href:"#v551016187"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v1324843695",class:"aya-hover","aya-hover-text":"Nat",href:"#v1324843695"},[a("span",{class:"LocalVar"},"b")]),s(),a("a",{id:"v299413131",class:"aya-hover","aya-hover-text":"Nat",href:"#v299413131"},[a("span",{class:"LocalVar"},"c")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s("} : ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v551016187"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1324843695"},[a("span",{class:"LocalVar"},"b")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v299413131"},[a("span",{class:"LocalVar"},"c")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v551016187"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1324843695"},[a("span",{class:"LocalVar"},"b")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b"},[a("span",{class:"Fn"},"+")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v299413131"},[a("span",{class:"LocalVar"},"c")]),s(") "),a("span",{class:"Keyword"},"elim"),s(),a("a",{href:"#v551016187"},[a("span",{class:"LocalVar"},"a")]),s(` +| 0 ⇒ `),a("a",{class:"aya-hover","aya-hover-text":"(b + c) = (b + c)",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(" _ ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"suc ((_ + b) + c) = suc (_ + (b + c))",href:"#Mian-pmap"},[a("span",{class:"Fn"},"pmap")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat → Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{class:"aya-hover","aya-hover-text":"((_ + b) + c) = (_ + (b + c))",href:"#Mian-2b-assoc"},[a("span",{class:"Fn"},"+-assoc")])]),s(` +`)],-1),v('

Now we can work on the proof of ++-assoc. Here's a lame definition that is well-typed in pre-cubical type theory, and is also hard to prove -- we cast one side of the equation to be other side. So instead of:

xs ++ (ys ++ zs) = (xs ++ ys) ++ zs

We show:

f (xs ++ (ys ++ zs)) = (xs ++ ys) ++ zs

Where f is a function that changes the type of the vector, implemented using cast. The definition looks like this:

',5),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"example"),s(),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-3aNoExport-2b2b-assoc-ty",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3aNoExport-2b2b-assoc-ty"},[a("span",{class:"Fn"},"++-assoc-ty")]),s(" ("),a("a",{id:"v129498568",class:"aya-hover","aya-hover-text":"Vec n A",href:"#v129498568"},[a("span",{class:"LocalVar"},"xs")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v829149076"},[a("span",{class:"Generalized"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") ("),a("a",{id:"v85748029",class:"aya-hover","aya-hover-text":"Vec m A",href:"#v85748029"},[a("span",{class:"LocalVar"},"ys")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1678046232"},[a("span",{class:"Generalized"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") ("),a("a",{id:"v1784131088",class:"aya-hover","aya-hover-text":"Vec o A",href:"#v1784131088"},[a("span",{class:"LocalVar"},"zs")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v9797126"},[a("span",{class:"Generalized"},"o")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(`) + ⇒ `),a("a",{class:"aya-hover","aya-hover-text":"Vec (n + (m + o)) A",href:"#Mian-cast"},[a("span",{class:"Fn"},"cast")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Vec ((n + m) + o) A = Vec (n + (m + o)) A",href:"#Mian-pmap"},[a("span",{class:"Fn"},"pmap")]),s(" ("),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v94157402",href:"#v94157402"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v94157402"},[a("span",{class:"LocalVar"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"((n + m) + o) = (n + (m + o))",href:"#Mian-2b-assoc"},[a("span",{class:"Fn"},"+-assoc")]),s(") (("),a("a",{class:"aya-hover","aya-hover-text":"Vec n A",href:"#v129498568"},[a("span",{class:"LocalVar"},"xs")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (?n n A m o xs ys zs + ?m n A m o xs ys zs) (?A n A m o xs ys zs)",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec m A",href:"#v85748029"},[a("span",{class:"LocalVar"},"ys")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Vec ((n + m) + o) A",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec o A",href:"#v1784131088"},[a("span",{class:"LocalVar"},"zs")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec n A",href:"#v129498568"},[a("span",{class:"LocalVar"},"xs")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (?n n A m o xs ys zs + ?m n A m o xs ys zs) (?A n A m o xs ys zs)",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Vec m A",href:"#v85748029"},[a("span",{class:"LocalVar"},"ys")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (?n n A m o xs ys zs + ?m n A m o xs ys zs) (?A n A m o xs ys zs)",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec o A",href:"#v1784131088"},[a("span",{class:"LocalVar"},"zs")]),s(")")]),s(` +`)],-1),v('

It is harder to prove because in the induction step, one need to show that cast (pmap (\\ p0Vec p0 A) +-assoc) is equivalent to the identity function in order to use the induction hypothesis. For the record, here's the proof:

',1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-castRefl",class:"aya-hover","aya-hover-text":"cast refl a = a",href:"#Mian-castRefl"},[a("span",{class:"Fn"},"castRefl")]),s(" ("),a("a",{id:"v1117871068",class:"aya-hover","aya-hover-text":"A",href:"#v1117871068"},[a("span",{class:"LocalVar"},"a")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#Mian-cast"},[a("span",{class:"Fn"},"cast")]),s(),a("span",{class:"Keyword"},"↑"),s(),a("a",{class:"aya-hover","aya-hover-text":"A = A",href:"#Mian-refl"},[a("span",{class:"Fn"},"refl")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1117871068"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1117871068"},[a("span",{class:"LocalVar"},"a")]),s(" ⇒ "),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v466853180",href:"#v466853180"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#Mian-coe"},[a("span",{class:"Primitive"},"coe")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v466853180"},[a("span",{class:"LocalVar"},"i")]),s(" 1 ("),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v1863953433",href:"#v1863953433"},[a("span",{class:"LocalVar"},"j")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1117871068"},[a("span",{class:"LocalVar"},"a")])]),s(` +`)],-1),a("p",null,"But still, with this lemma it is still hard. Cubical provides a pleasant way of working with heterogeneous equality:",-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-Path27",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Path27"},[a("span",{class:"Fn"},"Path'")]),s(" ("),a("a",{id:"v508378341",class:"aya-hover","aya-hover-text":"I → Type 0",href:"#v508378341"},[a("span",{class:"LocalVar"},"A")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"ISet",href:"#Mian-I"},[a("span",{class:"Primitive"},"I")]),s(" → "),a("span",{class:"Keyword"},"Type"),s(") ("),a("a",{id:"v1037854997",class:"aya-hover","aya-hover-text":"A 0",href:"#v1037854997"},[a("span",{class:"LocalVar"},"a")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v508378341"},[a("span",{class:"LocalVar"},"A")]),s(" 0) ("),a("a",{id:"v1884155890",class:"aya-hover","aya-hover-text":"A 1",href:"#v1884155890"},[a("span",{class:"LocalVar"},"b")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v508378341"},[a("span",{class:"LocalVar"},"A")]),s(" 1) ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Path"},[a("span",{class:"Primitive"},"Path")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I → Type 0",href:"#v508378341"},[a("span",{class:"LocalVar"},"A")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A 0",href:"#v1037854997"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A 1",href:"#v1884155890"},[a("span",{class:"LocalVar"},"b")])]),s(` +`)],-1),v("

So if we have X : A = B and a : A, b : B, then Path (\\i => X i) a b expresses the heterogeneous equality between a and b nicely.

We may then use the following type signature:

",2),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-2b2b-assoc-type",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-2b2b-assoc-type"},[a("span",{class:"Fn"},"++-assoc-type")]),s(" ("),a("a",{id:"v464224872",class:"aya-hover","aya-hover-text":"Vec n A",href:"#v464224872"},[a("span",{class:"LocalVar"},"xs")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v829149076"},[a("span",{class:"Generalized"},"n")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") ("),a("a",{id:"v170949260",class:"aya-hover","aya-hover-text":"Vec m A",href:"#v170949260"},[a("span",{class:"LocalVar"},"ys")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1678046232"},[a("span",{class:"Generalized"},"m")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") ("),a("a",{id:"v1845623216",class:"aya-hover","aya-hover-text":"Vec o A",href:"#v1845623216"},[a("span",{class:"LocalVar"},"zs")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v9797126"},[a("span",{class:"Generalized"},"o")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(`) + ⇒ `),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Path"},[a("span",{class:"Primitive"},"Path")]),s(" ("),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v295485334",href:"#v295485334"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Vec"},[a("span",{class:"Data"},"Vec")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-2b-assoc"},[a("span",{class:"Fn"},"+-assoc")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v295485334"},[a("span",{class:"LocalVar"},"i")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") (("),a("a",{class:"aya-hover","aya-hover-text":"Vec n A",href:"#v464224872"},[a("span",{class:"LocalVar"},"xs")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (?n n A m o xs ys zs + ?m n A m o xs ys zs) (?A n A m o xs ys zs)",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec m A",href:"#v170949260"},[a("span",{class:"LocalVar"},"ys")]),s(") "),a("a",{class:"aya-hover","aya-hover-text":"Vec ((n + m) + o) A",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec o A",href:"#v1845623216"},[a("span",{class:"LocalVar"},"zs")]),s(") ("),a("a",{class:"aya-hover","aya-hover-text":"Vec n A",href:"#v464224872"},[a("span",{class:"LocalVar"},"xs")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (?n n A m o xs ys zs + ?m n A m o xs ys zs) (?A n A m o xs ys zs)",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Vec m A",href:"#v170949260"},[a("span",{class:"LocalVar"},"ys")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec (?n n A m o xs ys zs + ?m n A m o xs ys zs) (?A n A m o xs ys zs)",href:"#Mian-2b2b"},[a("span",{class:"Fn"},"++")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Vec o A",href:"#v1845623216"},[a("span",{class:"LocalVar"},"zs")]),s("))")]),s(` +`)],-1),a("p",null,"The proof is omitted (try yourself!).",-1),a("h2",{id:"quotient-inductive-types",tabindex:"-1"},[s("Quotient inductive types "),a("a",{class:"header-anchor",href:"#quotient-inductive-types","aria-label":'Permalink to "Quotient inductive types"'},"​")],-1),a("p",null,"Quotient types are types that equates their instances in a non-trivial way. In Aya, they are defined using the following syntax:",-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Interval",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Interval"},[a("span",{class:"Data"},"Interval")]),s(` +| `),a("a",{id:"Mian-Interval-left",class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-left"},[a("span",{class:"Constructor"},"left")]),s(` +| `),a("a",{id:"Mian-Interval-right",class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-right"},[a("span",{class:"Constructor"},"right")]),s(` +| `),a("a",{id:"Mian-Interval-line",class:"aya-hover","aya-hover-text":"left = right",href:"#Mian-Interval-line"},[a("span",{class:"Constructor"},"line")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-left"},[a("span",{class:"Constructor"},"left")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-right"},[a("span",{class:"Constructor"},"right")])]),s(` +`)],-1),v('

This is an uninteresting quotient type, that is basically Bool but saying its two values are equal, so it's really just a unit type, with its unique element being the equivalence class of left and right.

If you're familiar with a proof assistant with an intensional equality like Coq/Agda/Lean/etc., you might find this surprising because a unit type shall not have two distinct elements, and an equality shall not be stated between two distinct constructors. How does this work in Aya?

Actually, in these systems, the equality is defined inductively, and it only has one constructor -- refl. This is not how equality is defined in Aya, so we can cook some interesting equality proofs into it, which includes these equality-looking constructors.

  1. The type of line will be translated into IInterval together with the judgmental equality that line 0 is left and line 1 is right, basically a desugaring of the equality with additional features. This makes line a valid constructor in normal type theory: it takes some parameters and returns Interval.
  2. These judgmental equalities need to be preserved by the elimination rule of Interval. Here is an example elimination:
',4),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"example"),s(),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-3aNoExport-Interval-elim",class:"aya-hover","aya-hover-text":"A",href:"#Mian-3aNoExport-Interval-elim"},[a("span",{class:"Fn"},"Interval-elim")]),s(" {"),a("a",{id:"v313082880",class:"aya-hover","aya-hover-text":"A",href:"#v313082880"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{id:"v1783083399",class:"aya-hover","aya-hover-text":"A",href:"#v1783083399"},[a("span",{class:"LocalVar"},"b")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s("} {"),a("a",{id:"v519492428",class:"aya-hover","aya-hover-text":"a = b",href:"#v519492428"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v313082880"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1783083399"},[a("span",{class:"LocalVar"},"b")]),s("} ("),a("a",{id:"v1176968662",class:"aya-hover","aya-hover-text":"Interval",href:"#v1176968662"},[a("span",{class:"LocalVar"},"i")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Interval"},[a("span",{class:"Data"},"Interval")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(),a("span",{class:"Keyword"},"elim"),s(),a("a",{href:"#v1176968662"},[a("span",{class:"LocalVar"},"i")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-left"},[a("span",{class:"Constructor"},"left")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v313082880"},[a("span",{class:"LocalVar"},"a")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-right"},[a("span",{class:"Constructor"},"right")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1783083399"},[a("span",{class:"LocalVar"},"b")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"left = right",href:"#Mian-Interval-line"},[a("span",{class:"Constructor"},"line")]),s(),a("a",{id:"v1225568095",class:"aya-hover","aya-hover-text":"I",href:"#v1225568095"},[a("span",{class:"LocalVar"},"j")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v519492428"},[a("span",{class:"LocalVar"},"p")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v1225568095"},[a("span",{class:"LocalVar"},"j")])]),s(` +`)],-1),v("

Note that the term pmap Interval-elim line, which reduces to p, has type Interval-elim left = Interval-elim right, so we need to check if p 0 equals Interval-elim left, and p 1 equals Interval-elim right. This is a confluence check that ensures the elimination is well-defined.

What's interesting about this type, is that its elimination implies function extensionality:

",2),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"private"),s(),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-lemma",class:"aya-hover","aya-hover-text":"B",href:"#Mian-lemma"},[a("span",{class:"Fn"},"lemma")]),s(` + (`),a("a",{id:"v193178046",class:"aya-hover","aya-hover-text":"A → B",href:"#v193178046"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{id:"v638169719",class:"aya-hover","aya-hover-text":"A → B",href:"#v638169719"},[a("span",{class:"LocalVar"},"g")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v2051120548"},[a("span",{class:"Generalized"},"B")]),s(") ("),a("a",{id:"v1080476785",class:"aya-hover","aya-hover-text":"Fn (B : A) → f B = g B",href:"#v1080476785"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("span",{class:"Keyword"},"∀"),s(),a("a",{id:"v1899141525",class:"aya-hover","aya-hover-text":"A",href:"#v1899141525"},[a("span",{class:"LocalVar"},"x")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v193178046"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1899141525"},[a("span",{class:"LocalVar"},"x")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v638169719"},[a("span",{class:"LocalVar"},"g")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1899141525"},[a("span",{class:"LocalVar"},"x")]),s(`) + (`),a("a",{id:"v722951168",class:"aya-hover","aya-hover-text":"Interval",href:"#v722951168"},[a("span",{class:"LocalVar"},"i")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Interval"},[a("span",{class:"Data"},"Interval")]),s(") ("),a("a",{id:"v1052253947",class:"aya-hover","aya-hover-text":"A",href:"#v1052253947"},[a("span",{class:"LocalVar"},"a")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v2051120548"},[a("span",{class:"Generalized"},"B")]),s(),a("span",{class:"Keyword"},"elim"),s(),a("a",{href:"#v722951168"},[a("span",{class:"LocalVar"},"i")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-left"},[a("span",{class:"Constructor"},"left")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v193178046"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1052253947"},[a("span",{class:"LocalVar"},"a")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-right"},[a("span",{class:"Constructor"},"right")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v638169719"},[a("span",{class:"LocalVar"},"g")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1052253947"},[a("span",{class:"LocalVar"},"a")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"left = right",href:"#Mian-Interval-line"},[a("span",{class:"Constructor"},"line")]),s(),a("a",{id:"v428696898",class:"aya-hover","aya-hover-text":"I",href:"#v428696898"},[a("span",{class:"LocalVar"},"j")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v1080476785"},[a("span",{class:"LocalVar"},"p")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1052253947"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v428696898"},[a("span",{class:"LocalVar"},"j")]),s(` + +`),a("span",{class:"Keyword"},"example"),s(),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-3aNoExport-funExt27",class:"aya-hover","aya-hover-text":"f = g",href:"#Mian-3aNoExport-funExt27"},[a("span",{class:"Fn"},"funExt'")]),s(" ("),a("a",{id:"v1987360300",class:"aya-hover","aya-hover-text":"A → B",href:"#v1987360300"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{id:"v434610528",class:"aya-hover","aya-hover-text":"A → B",href:"#v434610528"},[a("span",{class:"LocalVar"},"g")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v769530879"},[a("span",{class:"Generalized"},"A")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#v2051120548"},[a("span",{class:"Generalized"},"B")]),s(") ("),a("a",{id:"v380812044",class:"aya-hover","aya-hover-text":"Fn (B : A) → f B = g B",href:"#v380812044"},[a("span",{class:"LocalVar"},"p")]),s(" : "),a("span",{class:"Keyword"},"∀"),s(),a("a",{id:"v1989132530",class:"aya-hover","aya-hover-text":"A",href:"#v1989132530"},[a("span",{class:"LocalVar"},"a")]),s(" → "),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v1987360300"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1989132530"},[a("span",{class:"LocalVar"},"a")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"B",href:"#v434610528"},[a("span",{class:"LocalVar"},"g")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A",href:"#v1989132530"},[a("span",{class:"LocalVar"},"a")]),s(") : "),a("a",{class:"aya-hover","aya-hover-text":"A → B",href:"#v1987360300"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A → B",href:"#v434610528"},[a("span",{class:"LocalVar"},"g")]),s(` ⇒ + `),a("a",{class:"aya-hover","aya-hover-text":"lemma f g p left = lemma f g p right",href:"#Mian-pmap"},[a("span",{class:"Fn"},"pmap")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Interval → A → B",href:"#Mian-lemma"},[a("span",{class:"Fn"},"lemma")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A → B",href:"#v1987360300"},[a("span",{class:"LocalVar"},"f")]),s(),a("a",{class:"aya-hover","aya-hover-text":"A → B",href:"#v434610528"},[a("span",{class:"LocalVar"},"g")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Fn (B : A) → f B = g B",href:"#v380812044"},[a("span",{class:"LocalVar"},"p")]),s(") ("),a("span",{class:"Keyword"},"fn"),s(),a("a",{id:"v1414845278",href:"#v1414845278"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Interval",href:"#Mian-Interval-line"},[a("span",{class:"Constructor"},"line")]),s(),a("a",{class:"aya-hover","aya-hover-text":"I",href:"#v1414845278"},[a("span",{class:"LocalVar"},"i")]),s(")")]),s(` +`)],-1),a("p",null,[s("Note that even though we are using equation combinators like "),a("code",{class:"Aya"},[a("a",{href:"#Mian-pmap"},[a("span",{class:"Fn"},"pmap")])]),s(" which are implemented using path application and abstraction, it is not considered cheating because these are already theorems in MLTT anyway.")],-1),a("p",null,"We can define other interesting quotients such as a symmetric integer:",-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"open"),s(),a("span",{class:"Keyword"},"inductive"),s(),a("a",{id:"Mian-Int",class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Int"},[a("span",{class:"Data"},"Int")]),s(` +| `),a("a",{id:"Mian-Int-pos",class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-pos"},[a("span",{class:"Constructor"},"pos")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(" | "),a("a",{id:"Mian-Int-neg",class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-neg"},[a("span",{class:"Constructor"},"neg")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(` +| `),a("a",{id:"Mian-Int-zro",class:"aya-hover","aya-hover-text":"pos 0 = neg 0",href:"#Mian-Int-zro"},[a("span",{class:"Constructor"},"zro")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-pos"},[a("span",{class:"Constructor"},"pos")]),s(" 0 "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-3d"},[a("span",{class:"Fn"},"=")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-neg"},[a("span",{class:"Constructor"},"neg")]),s(" 0")]),s(` +`)],-1),a("p",null,[s("Some operations on "),a("code",{class:"Aya"},[a("a",{href:"#Mian-Int"},[a("span",{class:"Data"},"Int")])]),s(":")],-1),a("pre",{class:"Aya"},[s(""),a("code",null,[a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-succ",class:"aya-hover","aya-hover-text":"Int",href:"#Mian-succ"},[a("span",{class:"Fn"},"succ")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Int"},[a("span",{class:"Data"},"Int")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Int"},[a("span",{class:"Data"},"Int")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-pos"},[a("span",{class:"Constructor"},"pos")]),s(),a("a",{id:"v1920907467",class:"aya-hover","aya-hover-text":"Nat",href:"#v1920907467"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-pos"},[a("span",{class:"Constructor"},"pos")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v1920907467"},[a("span",{class:"LocalVar"},"n")]),s(`) +| `),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-neg"},[a("span",{class:"Constructor"},"neg")]),s(" 0 ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-pos"},[a("span",{class:"Constructor"},"pos")]),s(` 1 +| `),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-neg"},[a("span",{class:"Constructor"},"neg")]),s(" ("),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-Nat-suc"},[a("span",{class:"Constructor"},"suc")]),s(),a("a",{id:"v970535245",class:"aya-hover","aya-hover-text":"Nat",href:"#v970535245"},[a("span",{class:"LocalVar"},"n")]),s(") ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-neg"},[a("span",{class:"Constructor"},"neg")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v970535245"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"pos 0 = neg 0",href:"#Mian-Int-zro"},[a("span",{class:"Constructor"},"zro")]),s(),a("a",{id:"v194481424",class:"aya-hover","aya-hover-text":"I",href:"#v194481424"},[a("span",{class:"LocalVar"},"i")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-pos"},[a("span",{class:"Constructor"},"pos")]),s(` 1 + +`),a("span",{class:"Keyword"},"def"),s(),a("a",{id:"Mian-abs",class:"aya-hover","aya-hover-text":"Nat",href:"#Mian-abs"},[a("span",{class:"Fn"},"abs")]),s(),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Int"},[a("span",{class:"Data"},"Int")]),s(" : "),a("a",{class:"aya-hover","aya-hover-text":"Type 0",href:"#Mian-Nat"},[a("span",{class:"Data"},"Nat")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-pos"},[a("span",{class:"Constructor"},"pos")]),s(),a("a",{id:"v753321708",class:"aya-hover","aya-hover-text":"Nat",href:"#v753321708"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v753321708"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"Int",href:"#Mian-Int-neg"},[a("span",{class:"Constructor"},"neg")]),s(),a("a",{id:"v464400749",class:"aya-hover","aya-hover-text":"Nat",href:"#v464400749"},[a("span",{class:"LocalVar"},"n")]),s(" ⇒ "),a("a",{class:"aya-hover","aya-hover-text":"Nat",href:"#v464400749"},[a("span",{class:"LocalVar"},"n")]),s(` +| `),a("a",{class:"aya-hover","aya-hover-text":"pos 0 = neg 0",href:"#Mian-Int-zro"},[a("span",{class:"Constructor"},"zro")]),s(" _ ⇒ 0")]),s(` +`)],-1),v('

The succ operator has the first three clauses straightforward, and the last one is a proof of succ (neg 0) equals succ (pos 0), as we should preserve the judgmental equality in the type of zro. We need to do the same for abs.

',1)]))}const z=g(T,[["render",N]]);export{B as __pageData,z as default}; diff --git a/assets/guide_readings.md.zYAL6Jj9.js b/assets/guide_readings.md.zYAL6Jj9.js new file mode 100644 index 0000000..b910e88 --- /dev/null +++ b/assets/guide_readings.md.zYAL6Jj9.js @@ -0,0 +1 @@ +import{d as b,c as y,j as i,a as o,G as w,k as C,B as P,o as T}from"./chunks/framework.CoXjB5sU.js";const I={name:"Conor McBride",link:"http://strictlypositive.org"},s={name:"Thierry Coquand",link:"https://www.cse.chalmers.se/~coquand"},S={name:"Cyril Cohen",link:"https://perso.crans.org/cohen"},n={name:"András Kovács",link:"https://andraskovacs.github.io"},r={name:"Ambrus Kaposi",link:"https://akaposi.github.io"},l={name:"Simon Huber",link:"https://simhu.github.io"},A={name:"Guillaume Brunerie",link:"https://guillaumebrunerie.github.io"},a={name:"Andreas Abel",link:"https://www.cse.chalmers.se/~abela"},m={name:"Andrea Vezzosi",link:"https://saizan.github.io"},u={name:"Anders Mörtberg",link:"https://staff.math.su.se/anders.mortberg"},d={name:"Jesper Cockx",link:"https://jesper.sikanda.be"},L={name:"Robert Harper",link:"https://www.cs.cmu.edu/~rwh"},t={name:"Carlo Angiuli",link:"https://carloangiuli.com"},c={name:"Daniel Gratzer",link:"https://www.danielgratzer.com"},p={name:"Jon Sterling",link:"https://www.jonmsterling.com"},g={name:"Loïc Pujet",link:"https://pujet.fr"},f={name:"Nicolas Tabareau",link:"https://tabareau.fr"},k={name:"Kuen-Bang Hou (Favonia)",link:"https://favonia.org"},h={name:"Benjamin Grégoire",link:"https://www-sop.inria.fr/members/Benjamin.Gregoire"},x={name:"Brigitte Pientka",link:"https://www.cs.mcgill.ca/~bpientka"},D={name:"Thorsten Altenkirch",link:"https://people.cs.nott.ac.uk/psztxa"},F={name:"Jason Reed",link:"http://jcreed.org"},M=[{title:"Crude but Effective Stratification",authors:[I],links:[["slides","https://personal.cis.strath.ac.uk/conor.mcbride/Crude.pdf"]]},{title:"Generalized Universe Hierarchies and First-Class Universe Levels",authors:[n],links:[["arxiv","2103.00223"]]},{title:"Dependently typed lambda calculus with a lifting operator",authors:[{name:"Damien Rouhling",link:"https://www-sop.inria.fr/members/Damien.Rouhling"}],links:[["online","https://www-sop.inria.fr/members/Damien.Rouhling/data/internships/M1Report.pdf"]]},{title:"An Order-Theoretic Analysis of Universe Polymorphism",venue:"POPL 2023",authors:[k,t,{name:"Reed Mullanix"}],links:[["online","https://favonia.org/files/mugen.pdf"],["doi","10.1145/3571250"]]},{title:"Impredicative Observational Equality",authors:[f,g],venue:"POPL 2023",links:[["hal","hal-03857705"],["doi","10.1145/3571739"]]},{title:"Failure of Normalization in Impredicative Type Theory with Proof-Irrelevant Propositional Equality",authors:[a,s],venue:"LMCS 2020",links:[["arxiv","1911.08174"]]}],B=[{title:"Separating Path and Identity Types in Presheaf Models of Univalent Type Theory",authors:[{name:"Andrew Swan"}],links:[["arxiv","1808.00920"]]},{title:"A Syntax for Higher Inductive-Inductive Types",authors:[r,n],venue:"FSCD 2018",links:[["doi","10.4230/LIPIcs.FSCD.2018.20"]]},{title:"Signatures and Induction Principles for Higher Inductive-Inductive Types",venue:"LMCS 2020",authors:[r,n],links:[["arxiv","1902.00297"],["doi","10.23638/LMCS-16(1:10)2020"]]},{title:"Type Theory in Type Theory using Quotient Inductive Types",authors:[D,r],venue:"POPL 2016",links:[["doi","10.1145/2837614.2837638"],["online","https://people.cs.nott.ac.uk/psztxa/publ/tt-in-tt.pdf"]]},{title:"Contributions to Multimode and Presheaf Type Theory",authors:[{name:"Andreas Nuyts"}],links:[["online","https://lirias.kuleuven.be/retrieve/581985"]]},{title:"Observational Equality: Now for Good",venue:"POPL 2022",authors:[g,f],links:[["doi","10.1145/3498693"]]}],R=[{title:"Cubical Agda: A Dependently Typed Programming Language with Univalence and Higher Inductive Types",authors:[m,a,u],venue:"ICFP 2019",links:[["doi","10.1145/3341691"],["online","https://staff.math.su.se/anders.mortberg/papers/cubicalagda2.pdf"]]},{title:"Normalization for Cubical Type theory",authors:[p,t],venue:"LICS 2020",links:[["doi","10.1109/LICS52264.2021.9470719"],["arxiv","2101.11479"],["online","https://www.jonmsterling.com/papers/sterling-angiuli-2021.pdf"],["slides","https://www.jonmsterling.com/slides/sterling-angiuli-2021.pdf"]]},{title:"Automating Kan composition",authors:[{name:"Maximilian Doré"}],links:[["slides","https://europroofnet.github.io/assets/wg6/stockholm-kickoff-slides/dore-europroofnet-stockholm-slides.pdf"]]},{title:"Syntax and models of Cartesian cubical type theory",authors:[t,A,s,L,k,{name:"Daniel R. Licata"}],venue:"MSCS 2021",links:[["doi","10.1017/S0960129521000347"],["online","https://www.cs.cmu.edu/~cangiuli/papers/abcfhl.pdf"]]},{title:"A cubical type theory for higher inductive types",authors:[l],links:[["online","https://www.cse.chalmers.se/~simonhu/misc/hcomp.pdf"]]},{title:"Cubical Type Theory: a constructive interpretation of the univalence axiom",venue:"TYPES 2015",authors:[S,s,l,u],links:[["arxiv","1611.02108"],["doi","10.4230/LIPIcs.TYPES.2015.5"]]},{title:"On Higher Inductive Types in Cubical Type Theory",venue:"LICS 2018",authors:[s,l,u],links:[["arxiv","1802.01170"],["doi","10.1145/3209108.3209197"]]},{title:"Computational Semantics of Cartesian Cubical Type Theory",venue:"PhD thesis",authors:[t],links:[["online","https://carloangiuli.com/papers/thesis.pdf"]]},{title:"A Cubical Language for Bishop Sets",venue:"LMCS 2022",authors:[p,t,c],links:[["arxiv","2003.01491"],["doi","10.46298/lmcs-18%281%3A43%292022"]]},{title:"Cubical Syntax for Reflection-Free Extensional Equality",venue:"FSCD 2019",authors:[p,t,c],links:[["arxiv","1904.08562"],["doi","10.4230/LIPIcs.FSCD.2019.31"]]}],j=[{title:"Staged Compilation with Two-Level Type Theory",authors:[n],venue:"ICFP 2022",links:[["github","AndrasKovacs/staged"],["online","https://andraskovacs.github.io/pdfs/2ltt.pdf"],["doi","10.1145/3547641"]]},{title:"Full Reduction at Full Throttle",authors:[{name:"Mathieu Boespflug"},{name:"Maxime Dénès"},h],venue:"CPP 2011",links:[["hal","hal-00650940"],["doi","10.1007/978-3-642-25379-9_26"]]},{title:"A Compiled Implementation of Strong Reduction",authors:[h,{name:"Xavier Leroy"}],venue:"ICFP 2002",links:[["doi","10.1145/581478.581501"]]}],E=[{title:"A Categorical Perspective on Pattern Unification",authors:[m,a],links:[["online","https://saizan.github.io/papers/pattern-unif.pdf"]]},{title:'The "Elaboration Zoo"',authors:[n],links:[["github","AndrasKovacs/elaboration-zoo"]]},{title:"Elaboration with First-Class Implicit Function Types",authors:[n],venue:"ICFP 2020",links:[["github","AndrasKovacs/implicit-fun-elaboration"],["doi","10.1145/3408983"]]},{title:"Higher-Order Constraint Simplification In Dependent Type Theory",authors:[F],venue:"LFMTP 2009",links:[["doi","10.1145/1577824.1577832"],["online","https://www.cs.cmu.edu/~jcreed/papers/csl08-hocs.pdf"]]},{title:"Getting into the Flow: Towards Better Type Error Messages for Constraint-Based Type Inference",authors:[{name:"Ishan Bhanuka"},{name:"Lionel Parreaux"},{name:"David Binder"},{name:"Jonathan Immanuel Brachthäuser"}],links:[["doi","10.1145/3622812"]]}],z=[{title:"Copatterns: programming infinite structures by observations",authors:[a,x,{name:"David Thibodeau"},{name:"Anton Setzer"}],venue:"POPL 2013",links:[["doi","10.1145/2480359.2429075"],["online","https://www.cse.chalmers.se/~abela/popl13.pdf"]]},{title:"Overlapping and Order-Independent Patterns",links:[["online","https://jesper.sikanda.be/files/overlapping-and-order-independent-patterns.pdf"]],authors:[d,{name:"Dominique Devriese"},{name:"Frank Piessens"}]},{title:"Elaborating Dependent (Co)Pattern Matching",links:[["doi","10.1145/3236770"]],authors:[d,a],venue:"ICFP 2018"}],O=[{type:"Universes",items:M},{type:"Equality and Higher/Quotient Inductive Types",items:B},{type:"Cubical Type Theory",items:R},{type:"Compilation and Code Generation",items:j},{type:"Unification, Implicits, and Constraints",items:E},{type:"Pattern Matching",items:z},{type:"Miscellaneous",items:[{title:"Coq's Vibrant Ecosystem for Verification Engineering",venue:"CPP 2022",authors:[{name:"Andrew W. Appel",link:"https://orcid.org/0000-0001-6009-0325"}],links:[["online","https://www.cs.princeton.edu/~appel/papers/ecosystem.pdf"],["doi","10.1145/3497775.3503951"]]},{title:"The End of History? Using a Proof Assistant to Replace Language Design with Library Design",authors:[{name:"Adam Chlipala"},{name:"Benjamin Delaware"},{name:"Samuel Duchovni"},{name:"Jason Gross"},{name:"Clément Pit-Claudel"},{name:"Sorawit Suriyakarn"},{name:"Peng Wang"},{name:"Katherine Ye"}],venue:"SNAPL 2017",links:[["doi","10.4230/LIPIcs.SNAPL.2017.3"],["online","https://drops.dagstuhl.de/opus/volltexte/2017/7123/pdf/LIPIcs-SNAPL-2017-3.pdf"]]}]}],U=JSON.parse('{"title":"Recommended Reading","description":"","frontmatter":{},"headers":[],"relativePath":"guide/readings.md","filePath":"guide/readings.md","lastUpdated":1668050816000}'),G={name:"guide/readings.md"},_=b({...G,setup(H){return(N,e)=>{const v=P("Publications");return T(),y("div",null,[e[0]||(e[0]=i("h1",{id:"recommended-reading",tabindex:"-1"},[o("Recommended Reading "),i("a",{class:"header-anchor",href:"#recommended-reading","aria-label":'Permalink to "Recommended Reading"'},"​")],-1)),e[1]||(e[1]=i("p",null,"This is a list of documents that are helpful or simply related to the design & implementation of Aya, randomly ordered.",-1)),e[2]||(e[2]=i("p",null,[o("Beware that you are encouraged to suggest changes to this page! Just go to the bottom of this page and there will be a link. Apart from this list, Jon Sterling's "),i("a",{href:"https://www.jonmsterling.com/cubical-bibliography.html",target:"_blank",rel:"noreferrer"},"cubical bibliography"),o(" is also a good source of information.")],-1)),w(v,{pubs:C(O)},null,8,["pubs"])])}}});export{U as __pageData,_ as default}; diff --git a/assets/guide_readings.md.zYAL6Jj9.lean.js b/assets/guide_readings.md.zYAL6Jj9.lean.js new file mode 100644 index 0000000..b910e88 --- /dev/null +++ b/assets/guide_readings.md.zYAL6Jj9.lean.js @@ -0,0 +1 @@ +import{d as b,c as y,j as i,a as o,G as w,k as C,B as P,o as T}from"./chunks/framework.CoXjB5sU.js";const I={name:"Conor McBride",link:"http://strictlypositive.org"},s={name:"Thierry Coquand",link:"https://www.cse.chalmers.se/~coquand"},S={name:"Cyril Cohen",link:"https://perso.crans.org/cohen"},n={name:"András Kovács",link:"https://andraskovacs.github.io"},r={name:"Ambrus Kaposi",link:"https://akaposi.github.io"},l={name:"Simon Huber",link:"https://simhu.github.io"},A={name:"Guillaume Brunerie",link:"https://guillaumebrunerie.github.io"},a={name:"Andreas Abel",link:"https://www.cse.chalmers.se/~abela"},m={name:"Andrea Vezzosi",link:"https://saizan.github.io"},u={name:"Anders Mörtberg",link:"https://staff.math.su.se/anders.mortberg"},d={name:"Jesper Cockx",link:"https://jesper.sikanda.be"},L={name:"Robert Harper",link:"https://www.cs.cmu.edu/~rwh"},t={name:"Carlo Angiuli",link:"https://carloangiuli.com"},c={name:"Daniel Gratzer",link:"https://www.danielgratzer.com"},p={name:"Jon Sterling",link:"https://www.jonmsterling.com"},g={name:"Loïc Pujet",link:"https://pujet.fr"},f={name:"Nicolas Tabareau",link:"https://tabareau.fr"},k={name:"Kuen-Bang Hou (Favonia)",link:"https://favonia.org"},h={name:"Benjamin Grégoire",link:"https://www-sop.inria.fr/members/Benjamin.Gregoire"},x={name:"Brigitte Pientka",link:"https://www.cs.mcgill.ca/~bpientka"},D={name:"Thorsten Altenkirch",link:"https://people.cs.nott.ac.uk/psztxa"},F={name:"Jason Reed",link:"http://jcreed.org"},M=[{title:"Crude but Effective Stratification",authors:[I],links:[["slides","https://personal.cis.strath.ac.uk/conor.mcbride/Crude.pdf"]]},{title:"Generalized Universe Hierarchies and First-Class Universe Levels",authors:[n],links:[["arxiv","2103.00223"]]},{title:"Dependently typed lambda calculus with a lifting operator",authors:[{name:"Damien Rouhling",link:"https://www-sop.inria.fr/members/Damien.Rouhling"}],links:[["online","https://www-sop.inria.fr/members/Damien.Rouhling/data/internships/M1Report.pdf"]]},{title:"An Order-Theoretic Analysis of Universe Polymorphism",venue:"POPL 2023",authors:[k,t,{name:"Reed Mullanix"}],links:[["online","https://favonia.org/files/mugen.pdf"],["doi","10.1145/3571250"]]},{title:"Impredicative Observational Equality",authors:[f,g],venue:"POPL 2023",links:[["hal","hal-03857705"],["doi","10.1145/3571739"]]},{title:"Failure of Normalization in Impredicative Type Theory with Proof-Irrelevant Propositional Equality",authors:[a,s],venue:"LMCS 2020",links:[["arxiv","1911.08174"]]}],B=[{title:"Separating Path and Identity Types in Presheaf Models of Univalent Type Theory",authors:[{name:"Andrew Swan"}],links:[["arxiv","1808.00920"]]},{title:"A Syntax for Higher Inductive-Inductive Types",authors:[r,n],venue:"FSCD 2018",links:[["doi","10.4230/LIPIcs.FSCD.2018.20"]]},{title:"Signatures and Induction Principles for Higher Inductive-Inductive Types",venue:"LMCS 2020",authors:[r,n],links:[["arxiv","1902.00297"],["doi","10.23638/LMCS-16(1:10)2020"]]},{title:"Type Theory in Type Theory using Quotient Inductive Types",authors:[D,r],venue:"POPL 2016",links:[["doi","10.1145/2837614.2837638"],["online","https://people.cs.nott.ac.uk/psztxa/publ/tt-in-tt.pdf"]]},{title:"Contributions to Multimode and Presheaf Type Theory",authors:[{name:"Andreas Nuyts"}],links:[["online","https://lirias.kuleuven.be/retrieve/581985"]]},{title:"Observational Equality: Now for Good",venue:"POPL 2022",authors:[g,f],links:[["doi","10.1145/3498693"]]}],R=[{title:"Cubical Agda: A Dependently Typed Programming Language with Univalence and Higher Inductive Types",authors:[m,a,u],venue:"ICFP 2019",links:[["doi","10.1145/3341691"],["online","https://staff.math.su.se/anders.mortberg/papers/cubicalagda2.pdf"]]},{title:"Normalization for Cubical Type theory",authors:[p,t],venue:"LICS 2020",links:[["doi","10.1109/LICS52264.2021.9470719"],["arxiv","2101.11479"],["online","https://www.jonmsterling.com/papers/sterling-angiuli-2021.pdf"],["slides","https://www.jonmsterling.com/slides/sterling-angiuli-2021.pdf"]]},{title:"Automating Kan composition",authors:[{name:"Maximilian Doré"}],links:[["slides","https://europroofnet.github.io/assets/wg6/stockholm-kickoff-slides/dore-europroofnet-stockholm-slides.pdf"]]},{title:"Syntax and models of Cartesian cubical type theory",authors:[t,A,s,L,k,{name:"Daniel R. Licata"}],venue:"MSCS 2021",links:[["doi","10.1017/S0960129521000347"],["online","https://www.cs.cmu.edu/~cangiuli/papers/abcfhl.pdf"]]},{title:"A cubical type theory for higher inductive types",authors:[l],links:[["online","https://www.cse.chalmers.se/~simonhu/misc/hcomp.pdf"]]},{title:"Cubical Type Theory: a constructive interpretation of the univalence axiom",venue:"TYPES 2015",authors:[S,s,l,u],links:[["arxiv","1611.02108"],["doi","10.4230/LIPIcs.TYPES.2015.5"]]},{title:"On Higher Inductive Types in Cubical Type Theory",venue:"LICS 2018",authors:[s,l,u],links:[["arxiv","1802.01170"],["doi","10.1145/3209108.3209197"]]},{title:"Computational Semantics of Cartesian Cubical Type Theory",venue:"PhD thesis",authors:[t],links:[["online","https://carloangiuli.com/papers/thesis.pdf"]]},{title:"A Cubical Language for Bishop Sets",venue:"LMCS 2022",authors:[p,t,c],links:[["arxiv","2003.01491"],["doi","10.46298/lmcs-18%281%3A43%292022"]]},{title:"Cubical Syntax for Reflection-Free Extensional Equality",venue:"FSCD 2019",authors:[p,t,c],links:[["arxiv","1904.08562"],["doi","10.4230/LIPIcs.FSCD.2019.31"]]}],j=[{title:"Staged Compilation with Two-Level Type Theory",authors:[n],venue:"ICFP 2022",links:[["github","AndrasKovacs/staged"],["online","https://andraskovacs.github.io/pdfs/2ltt.pdf"],["doi","10.1145/3547641"]]},{title:"Full Reduction at Full Throttle",authors:[{name:"Mathieu Boespflug"},{name:"Maxime Dénès"},h],venue:"CPP 2011",links:[["hal","hal-00650940"],["doi","10.1007/978-3-642-25379-9_26"]]},{title:"A Compiled Implementation of Strong Reduction",authors:[h,{name:"Xavier Leroy"}],venue:"ICFP 2002",links:[["doi","10.1145/581478.581501"]]}],E=[{title:"A Categorical Perspective on Pattern Unification",authors:[m,a],links:[["online","https://saizan.github.io/papers/pattern-unif.pdf"]]},{title:'The "Elaboration Zoo"',authors:[n],links:[["github","AndrasKovacs/elaboration-zoo"]]},{title:"Elaboration with First-Class Implicit Function Types",authors:[n],venue:"ICFP 2020",links:[["github","AndrasKovacs/implicit-fun-elaboration"],["doi","10.1145/3408983"]]},{title:"Higher-Order Constraint Simplification In Dependent Type Theory",authors:[F],venue:"LFMTP 2009",links:[["doi","10.1145/1577824.1577832"],["online","https://www.cs.cmu.edu/~jcreed/papers/csl08-hocs.pdf"]]},{title:"Getting into the Flow: Towards Better Type Error Messages for Constraint-Based Type Inference",authors:[{name:"Ishan Bhanuka"},{name:"Lionel Parreaux"},{name:"David Binder"},{name:"Jonathan Immanuel Brachthäuser"}],links:[["doi","10.1145/3622812"]]}],z=[{title:"Copatterns: programming infinite structures by observations",authors:[a,x,{name:"David Thibodeau"},{name:"Anton Setzer"}],venue:"POPL 2013",links:[["doi","10.1145/2480359.2429075"],["online","https://www.cse.chalmers.se/~abela/popl13.pdf"]]},{title:"Overlapping and Order-Independent Patterns",links:[["online","https://jesper.sikanda.be/files/overlapping-and-order-independent-patterns.pdf"]],authors:[d,{name:"Dominique Devriese"},{name:"Frank Piessens"}]},{title:"Elaborating Dependent (Co)Pattern Matching",links:[["doi","10.1145/3236770"]],authors:[d,a],venue:"ICFP 2018"}],O=[{type:"Universes",items:M},{type:"Equality and Higher/Quotient Inductive Types",items:B},{type:"Cubical Type Theory",items:R},{type:"Compilation and Code Generation",items:j},{type:"Unification, Implicits, and Constraints",items:E},{type:"Pattern Matching",items:z},{type:"Miscellaneous",items:[{title:"Coq's Vibrant Ecosystem for Verification Engineering",venue:"CPP 2022",authors:[{name:"Andrew W. Appel",link:"https://orcid.org/0000-0001-6009-0325"}],links:[["online","https://www.cs.princeton.edu/~appel/papers/ecosystem.pdf"],["doi","10.1145/3497775.3503951"]]},{title:"The End of History? Using a Proof Assistant to Replace Language Design with Library Design",authors:[{name:"Adam Chlipala"},{name:"Benjamin Delaware"},{name:"Samuel Duchovni"},{name:"Jason Gross"},{name:"Clément Pit-Claudel"},{name:"Sorawit Suriyakarn"},{name:"Peng Wang"},{name:"Katherine Ye"}],venue:"SNAPL 2017",links:[["doi","10.4230/LIPIcs.SNAPL.2017.3"],["online","https://drops.dagstuhl.de/opus/volltexte/2017/7123/pdf/LIPIcs-SNAPL-2017-3.pdf"]]}]}],U=JSON.parse('{"title":"Recommended Reading","description":"","frontmatter":{},"headers":[],"relativePath":"guide/readings.md","filePath":"guide/readings.md","lastUpdated":1668050816000}'),G={name:"guide/readings.md"},_=b({...G,setup(H){return(N,e)=>{const v=P("Publications");return T(),y("div",null,[e[0]||(e[0]=i("h1",{id:"recommended-reading",tabindex:"-1"},[o("Recommended Reading "),i("a",{class:"header-anchor",href:"#recommended-reading","aria-label":'Permalink to "Recommended Reading"'},"​")],-1)),e[1]||(e[1]=i("p",null,"This is a list of documents that are helpful or simply related to the design & implementation of Aya, randomly ordered.",-1)),e[2]||(e[2]=i("p",null,[o("Beware that you are encouraged to suggest changes to this page! Just go to the bottom of this page and there will be a link. Apart from this list, Jon Sterling's "),i("a",{href:"https://www.jonmsterling.com/cubical-bibliography.html",target:"_blank",rel:"noreferrer"},"cubical bibliography"),o(" is also a good source of information.")],-1)),w(v,{pubs:C(O)},null,8,["pubs"])])}}});export{U as __pageData,_ as default}; diff --git a/assets/guide_vscode-tutorial.md.DiZyYf9h.js b/assets/guide_vscode-tutorial.md.DiZyYf9h.js new file mode 100644 index 0000000..f399c64 --- /dev/null +++ b/assets/guide_vscode-tutorial.md.DiZyYf9h.js @@ -0,0 +1 @@ +import{_ as o,c as t,a2 as a,o as r}from"./chunks/framework.CoXjB5sU.js";const p=JSON.parse('{"title":"So you are using VSCode","description":"","frontmatter":{},"headers":[],"relativePath":"guide/vscode-tutorial.md","filePath":"guide/vscode-tutorial.md","lastUpdated":1689586300000}'),s={name:"guide/vscode-tutorial.md"};function i(n,e,d,c,l,h){return r(),t("div",null,e[0]||(e[0]=[a('

So you are using VSCode

Go to GitHub Releases, click the latest successful run, scroll down to the bottom of the page, download the "aya-prover-vscode-extension", and unzip it. Then, follow VSCode docs to install the extension.

It remains to configure the Aya language server. There are two ways to use the server. First, open settings, search for "Aya path", you should see a text box. Then, you have a choice:

  1. Use a jar file. Put your lsp-fatjar.jar file path there. Make sure you have a java executable in the Path (recommended) or in java.home key in the settings json.
  2. Use the jlink version of Aya. Put the aya-lsp (or aya-lsp.bat if you are on Windows) file path there, which is under the bin folder of the jlink distribution. In this case, you don't need to have a java executable in the Path.

Then, open a directory that is an Aya project (see project-tutorial). Open any .aya file, you should see some basic highlight (keywords, comments, etc.). Wait for VSCode to activate the extension, and hit Ctrl+L Ctrl+L to load the file. At this point, you should see advanced highlight (type names, constructors, etc.), with clickable definitions.

The rest of the features should be quite discoverable for regular programmers, such as hovering a red or a yellow wavy line to see the error message, etc. Please create issues and discuss ideas on how to improve the error reports.

',6)]))}const f=o(s,[["render",i]]);export{p as __pageData,f as default}; diff --git a/assets/guide_vscode-tutorial.md.DiZyYf9h.lean.js b/assets/guide_vscode-tutorial.md.DiZyYf9h.lean.js new file mode 100644 index 0000000..f399c64 --- /dev/null +++ b/assets/guide_vscode-tutorial.md.DiZyYf9h.lean.js @@ -0,0 +1 @@ +import{_ as o,c as t,a2 as a,o as r}from"./chunks/framework.CoXjB5sU.js";const p=JSON.parse('{"title":"So you are using VSCode","description":"","frontmatter":{},"headers":[],"relativePath":"guide/vscode-tutorial.md","filePath":"guide/vscode-tutorial.md","lastUpdated":1689586300000}'),s={name:"guide/vscode-tutorial.md"};function i(n,e,d,c,l,h){return r(),t("div",null,e[0]||(e[0]=[a('

So you are using VSCode

Go to GitHub Releases, click the latest successful run, scroll down to the bottom of the page, download the "aya-prover-vscode-extension", and unzip it. Then, follow VSCode docs to install the extension.

It remains to configure the Aya language server. There are two ways to use the server. First, open settings, search for "Aya path", you should see a text box. Then, you have a choice:

  1. Use a jar file. Put your lsp-fatjar.jar file path there. Make sure you have a java executable in the Path (recommended) or in java.home key in the settings json.
  2. Use the jlink version of Aya. Put the aya-lsp (or aya-lsp.bat if you are on Windows) file path there, which is under the bin folder of the jlink distribution. In this case, you don't need to have a java executable in the Path.

Then, open a directory that is an Aya project (see project-tutorial). Open any .aya file, you should see some basic highlight (keywords, comments, etc.). Wait for VSCode to activate the extension, and hit Ctrl+L Ctrl+L to load the file. At this point, you should see advanced highlight (type names, constructors, etc.), with clickable definitions.

The rest of the features should be quite discoverable for regular programmers, such as hovering a red or a yellow wavy line to see the error message, etc. Please create issues and discuss ideas on how to improve the error reports.

',6)]))}const f=o(s,[["render",i]]);export{p as __pageData,f as default}; diff --git a/assets/index.md.CMxZ7gZj.js b/assets/index.md.CMxZ7gZj.js new file mode 100644 index 0000000..207a365 --- /dev/null +++ b/assets/index.md.CMxZ7gZj.js @@ -0,0 +1 @@ +import{_ as e,c as t,o as a}from"./chunks/framework.CoXjB5sU.js";const l=JSON.parse('{"title":"Aya Prover","description":"","frontmatter":{"layout":"home","title":"Aya Prover","hero":{"name":"Aya Prover","text":null,"tagline":"A proof assistant designed for formalizing math and type-directed programming."}},"headers":[],"relativePath":"index.md","filePath":"index.md","lastUpdated":1717718914000}'),r={name:"index.md"};function o(n,i,d,s,c,m){return a(),t("div")}const f=e(r,[["render",o]]);export{l as __pageData,f as default}; diff --git a/assets/index.md.CMxZ7gZj.lean.js b/assets/index.md.CMxZ7gZj.lean.js new file mode 100644 index 0000000..207a365 --- /dev/null +++ b/assets/index.md.CMxZ7gZj.lean.js @@ -0,0 +1 @@ +import{_ as e,c as t,o as a}from"./chunks/framework.CoXjB5sU.js";const l=JSON.parse('{"title":"Aya Prover","description":"","frontmatter":{"layout":"home","title":"Aya Prover","hero":{"name":"Aya Prover","text":null,"tagline":"A proof assistant designed for formalizing math and type-directed programming."}},"headers":[],"relativePath":"index.md","filePath":"index.md","lastUpdated":1717718914000}'),r={name:"index.md"};function o(n,i,d,s,c,m){return a(),t("div")}const f=e(r,[["render",o]]);export{l as __pageData,f as default}; diff --git a/assets/inter-italic-cyrillic-ext.r48I6akx.woff2 b/assets/inter-italic-cyrillic-ext.r48I6akx.woff2 new file mode 100644 index 0000000..b6b603d Binary files /dev/null and b/assets/inter-italic-cyrillic-ext.r48I6akx.woff2 differ diff --git a/assets/inter-italic-cyrillic.By2_1cv3.woff2 b/assets/inter-italic-cyrillic.By2_1cv3.woff2 new file mode 100644 index 0000000..def40a4 Binary files /dev/null and b/assets/inter-italic-cyrillic.By2_1cv3.woff2 differ diff --git a/assets/inter-italic-greek-ext.1u6EdAuj.woff2 b/assets/inter-italic-greek-ext.1u6EdAuj.woff2 new file mode 100644 index 0000000..e070c3d Binary files /dev/null and b/assets/inter-italic-greek-ext.1u6EdAuj.woff2 differ diff --git a/assets/inter-italic-greek.DJ8dCoTZ.woff2 b/assets/inter-italic-greek.DJ8dCoTZ.woff2 new file mode 100644 index 0000000..a3c16ca Binary files /dev/null and b/assets/inter-italic-greek.DJ8dCoTZ.woff2 differ diff --git a/assets/inter-italic-latin-ext.CN1xVJS-.woff2 b/assets/inter-italic-latin-ext.CN1xVJS-.woff2 new file mode 100644 index 0000000..2210a89 Binary files /dev/null and b/assets/inter-italic-latin-ext.CN1xVJS-.woff2 differ diff --git a/assets/inter-italic-latin.C2AdPX0b.woff2 b/assets/inter-italic-latin.C2AdPX0b.woff2 new file mode 100644 index 0000000..790d62d Binary files /dev/null and b/assets/inter-italic-latin.C2AdPX0b.woff2 differ diff --git a/assets/inter-italic-vietnamese.BSbpV94h.woff2 b/assets/inter-italic-vietnamese.BSbpV94h.woff2 new file mode 100644 index 0000000..1eec077 Binary files /dev/null and b/assets/inter-italic-vietnamese.BSbpV94h.woff2 differ diff --git a/assets/inter-roman-cyrillic-ext.BBPuwvHQ.woff2 b/assets/inter-roman-cyrillic-ext.BBPuwvHQ.woff2 new file mode 100644 index 0000000..2cfe615 Binary files /dev/null and b/assets/inter-roman-cyrillic-ext.BBPuwvHQ.woff2 differ diff --git a/assets/inter-roman-cyrillic.C5lxZ8CY.woff2 b/assets/inter-roman-cyrillic.C5lxZ8CY.woff2 new file mode 100644 index 0000000..e3886dd Binary files /dev/null and b/assets/inter-roman-cyrillic.C5lxZ8CY.woff2 differ diff --git a/assets/inter-roman-greek-ext.CqjqNYQ-.woff2 b/assets/inter-roman-greek-ext.CqjqNYQ-.woff2 new file mode 100644 index 0000000..36d6748 Binary files /dev/null and b/assets/inter-roman-greek-ext.CqjqNYQ-.woff2 differ diff --git a/assets/inter-roman-greek.BBVDIX6e.woff2 b/assets/inter-roman-greek.BBVDIX6e.woff2 new file mode 100644 index 0000000..2bed1e8 Binary files /dev/null and b/assets/inter-roman-greek.BBVDIX6e.woff2 differ diff --git a/assets/inter-roman-latin-ext.4ZJIpNVo.woff2 b/assets/inter-roman-latin-ext.4ZJIpNVo.woff2 new file mode 100644 index 0000000..9a8d1e2 Binary files /dev/null and b/assets/inter-roman-latin-ext.4ZJIpNVo.woff2 differ diff --git a/assets/inter-roman-latin.Di8DUHzh.woff2 b/assets/inter-roman-latin.Di8DUHzh.woff2 new file mode 100644 index 0000000..07d3c53 Binary files /dev/null and b/assets/inter-roman-latin.Di8DUHzh.woff2 differ diff --git a/assets/inter-roman-vietnamese.BjW4sHH5.woff2 b/assets/inter-roman-vietnamese.BjW4sHH5.woff2 new file mode 100644 index 0000000..57bdc22 Binary files /dev/null and b/assets/inter-roman-vietnamese.BjW4sHH5.woff2 differ diff --git a/assets/pubs_index.md.D4yWMioC.js b/assets/pubs_index.md.D4yWMioC.js new file mode 100644 index 0000000..5b36a56 --- /dev/null +++ b/assets/pubs_index.md.D4yWMioC.js @@ -0,0 +1 @@ +import{d as n,c as s,j as i,a as o,G as l,k as r,B as p,o as u}from"./chunks/framework.CoXjB5sU.js";const t={name:"Tesla Zhang",link:"https://ice1000.org"},c=[{type:"Papers",items:[{title:"A simpler encoding of indexed types",venue:"TyDe 2021",authors:[t],links:[["arxiv","2103.15408"],["doi","10.1145/3471875.3472991"]]}]},{type:"Notes",items:[{title:"(Co)conditions hit the path",authors:[t],links:[["arxiv","2405.12994"]]},{title:"Two tricks to trivialize higher-indexed families",authors:[t],links:[["arxiv","2309.14187"]]},{title:"A tutorial on implementing De Morgan cubical type theory",authors:[t],links:[["arxiv","2210.08232"]]},{title:"Elegant elaboration with function invocation",authors:[t],links:[["arxiv","2105.14840"]]}]}],x=JSON.parse('{"title":"Publications","description":"","frontmatter":{},"headers":[],"relativePath":"pubs/index.md","filePath":"pubs/index.md","lastUpdated":1716592923000}'),d={name:"pubs/index.md"},f=n({...d,setup(h){return(m,e)=>{const a=p("Publications");return u(),s("div",null,[e[0]||(e[0]=i("h1",{id:"publications",tabindex:"-1"},[o("Publications "),i("a",{class:"header-anchor",href:"#publications","aria-label":'Permalink to "Publications"'},"​")],-1)),e[1]||(e[1]=i("p",null,"This is a list of publications related to Aya by the Aya developers.",-1)),l(a,{pubs:r(c)},null,8,["pubs"])])}}});export{x as __pageData,f as default}; diff --git a/assets/pubs_index.md.D4yWMioC.lean.js b/assets/pubs_index.md.D4yWMioC.lean.js new file mode 100644 index 0000000..5b36a56 --- /dev/null +++ b/assets/pubs_index.md.D4yWMioC.lean.js @@ -0,0 +1 @@ +import{d as n,c as s,j as i,a as o,G as l,k as r,B as p,o as u}from"./chunks/framework.CoXjB5sU.js";const t={name:"Tesla Zhang",link:"https://ice1000.org"},c=[{type:"Papers",items:[{title:"A simpler encoding of indexed types",venue:"TyDe 2021",authors:[t],links:[["arxiv","2103.15408"],["doi","10.1145/3471875.3472991"]]}]},{type:"Notes",items:[{title:"(Co)conditions hit the path",authors:[t],links:[["arxiv","2405.12994"]]},{title:"Two tricks to trivialize higher-indexed families",authors:[t],links:[["arxiv","2309.14187"]]},{title:"A tutorial on implementing De Morgan cubical type theory",authors:[t],links:[["arxiv","2210.08232"]]},{title:"Elegant elaboration with function invocation",authors:[t],links:[["arxiv","2105.14840"]]}]}],x=JSON.parse('{"title":"Publications","description":"","frontmatter":{},"headers":[],"relativePath":"pubs/index.md","filePath":"pubs/index.md","lastUpdated":1716592923000}'),d={name:"pubs/index.md"},f=n({...d,setup(h){return(m,e)=>{const a=p("Publications");return u(),s("div",null,[e[0]||(e[0]=i("h1",{id:"publications",tabindex:"-1"},[o("Publications "),i("a",{class:"header-anchor",href:"#publications","aria-label":'Permalink to "Publications"'},"​")],-1)),e[1]||(e[1]=i("p",null,"This is a list of publications related to Aya by the Aya developers.",-1)),l(a,{pubs:r(c)},null,8,["pubs"])])}}});export{x as __pageData,f as default}; diff --git a/assets/style.BNdGpwCa.css b/assets/style.BNdGpwCa.css new file mode 100644 index 0000000..0e3595a --- /dev/null +++ b/assets/style.BNdGpwCa.css @@ -0,0 +1 @@ +.Aya a,.Aya a:hover{text-decoration-line:none;text-decoration-color:inherit;text-underline-position:inherit}:root{--Doc-Term-Highlight-BackgroundColor: #B4EEB4}.Aya a[href]:hover,.Aya [href].hover-highlight{background-color:var(--Doc-Term-Highlight-BackgroundColor)}:root{--Doc-Hover-BackgroundColor: rgba(18, 26, 44, .8);--Doc-Hover-TextColor: #fff;--Doc-Hover-BoxShadowColor: rgba(0, 0, 0, .1)}.Aya .aya-hover{position:relative;cursor:pointer}.Aya [aya-hover-text]:after{content:attr(aya-hover-text);visibility:hidden;position:absolute;top:0;left:0;transform:translateY(-110%);white-space:pre;padding:5px 10px;background-color:var(--Doc-Hover-BackgroundColor);color:var(--Doc-Hover-TextColor);box-shadow:1px 1px 14px var(--Doc-Hover-BoxShadowColor)}.Aya .aya-hover:hover:after{transform:translateY(-110%);visibility:visible;display:block}:root{--Doc-Tooltip-BackgroundColor: #f6f6f7;--Doc-Tooltip-TextColor: #3c3c43;--Doc-Tooltip-BoxShadowColor: rgba(0, 0, 255, .2);--Doc-Tooltip-BorderColor: #333}.AyaTooltipPopup{position:absolute;z-index:100;font-size:.85em;padding:4px 8px;background-color:var(--Doc-Tooltip-BackgroundColor);color:var(--Doc-Tooltip-TextColor);box-shadow:1px 1px 20px 1px var(--Doc-Tooltip-BoxShadowColor);border:2px solid var(--Doc-Tooltip-BorderColor)}.AyaTooltipPopup #AyaTooltipPopupClose{float:right;display:inline-block;padding:0 5px;margin:-4px -8px;visibility:hidden;background-color:var(--Doc-Tooltip-BackgroundColor)}.AyaTooltipPopup #AyaTooltipPopupClose:hover{color:red}@font-face{font-family:Inter;font-style:normal;font-weight:100 900;font-display:swap;src:url(/assets/inter-roman-cyrillic-ext.BBPuwvHQ.woff2) format("woff2");unicode-range:U+0460-052F,U+1C80-1C88,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:Inter;font-style:normal;font-weight:100 900;font-display:swap;src:url(/assets/inter-roman-cyrillic.C5lxZ8CY.woff2) format("woff2");unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:Inter;font-style:normal;font-weight:100 900;font-display:swap;src:url(/assets/inter-roman-greek-ext.CqjqNYQ-.woff2) format("woff2");unicode-range:U+1F00-1FFF}@font-face{font-family:Inter;font-style:normal;font-weight:100 900;font-display:swap;src:url(/assets/inter-roman-greek.BBVDIX6e.woff2) format("woff2");unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:Inter;font-style:normal;font-weight:100 900;font-display:swap;src:url(/assets/inter-roman-vietnamese.BjW4sHH5.woff2) format("woff2");unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Inter;font-style:normal;font-weight:100 900;font-display:swap;src:url(/assets/inter-roman-latin-ext.4ZJIpNVo.woff2) format("woff2");unicode-range:U+0100-02AF,U+0304,U+0308,U+0329,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Inter;font-style:normal;font-weight:100 900;font-display:swap;src:url(/assets/inter-roman-latin.Di8DUHzh.woff2) format("woff2");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+2074,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Inter;font-style:italic;font-weight:100 900;font-display:swap;src:url(/assets/inter-italic-cyrillic-ext.r48I6akx.woff2) format("woff2");unicode-range:U+0460-052F,U+1C80-1C88,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F}@font-face{font-family:Inter;font-style:italic;font-weight:100 900;font-display:swap;src:url(/assets/inter-italic-cyrillic.By2_1cv3.woff2) format("woff2");unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}@font-face{font-family:Inter;font-style:italic;font-weight:100 900;font-display:swap;src:url(/assets/inter-italic-greek-ext.1u6EdAuj.woff2) format("woff2");unicode-range:U+1F00-1FFF}@font-face{font-family:Inter;font-style:italic;font-weight:100 900;font-display:swap;src:url(/assets/inter-italic-greek.DJ8dCoTZ.woff2) format("woff2");unicode-range:U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF}@font-face{font-family:Inter;font-style:italic;font-weight:100 900;font-display:swap;src:url(/assets/inter-italic-vietnamese.BSbpV94h.woff2) format("woff2");unicode-range:U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB}@font-face{font-family:Inter;font-style:italic;font-weight:100 900;font-display:swap;src:url(/assets/inter-italic-latin-ext.CN1xVJS-.woff2) format("woff2");unicode-range:U+0100-02AF,U+0304,U+0308,U+0329,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}@font-face{font-family:Inter;font-style:italic;font-weight:100 900;font-display:swap;src:url(/assets/inter-italic-latin.C2AdPX0b.woff2) format("woff2");unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+2074,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}@font-face{font-family:Punctuation SC;font-weight:400;src:local("PingFang SC Regular"),local("Noto Sans CJK SC"),local("Microsoft YaHei");unicode-range:U+201C,U+201D,U+2018,U+2019,U+2E3A,U+2014,U+2013,U+2026,U+00B7,U+007E,U+002F}@font-face{font-family:Punctuation SC;font-weight:500;src:local("PingFang SC Medium"),local("Noto Sans CJK SC"),local("Microsoft YaHei");unicode-range:U+201C,U+201D,U+2018,U+2019,U+2E3A,U+2014,U+2013,U+2026,U+00B7,U+007E,U+002F}@font-face{font-family:Punctuation SC;font-weight:600;src:local("PingFang SC Semibold"),local("Noto Sans CJK SC Bold"),local("Microsoft YaHei Bold");unicode-range:U+201C,U+201D,U+2018,U+2019,U+2E3A,U+2014,U+2013,U+2026,U+00B7,U+007E,U+002F}@font-face{font-family:Punctuation SC;font-weight:700;src:local("PingFang SC Semibold"),local("Noto Sans CJK SC Bold"),local("Microsoft YaHei Bold");unicode-range:U+201C,U+201D,U+2018,U+2019,U+2E3A,U+2014,U+2013,U+2026,U+00B7,U+007E,U+002F}:root{--vp-c-white: #ffffff;--vp-c-black: #000000;--vp-c-neutral: var(--vp-c-black);--vp-c-neutral-inverse: var(--vp-c-white)}.dark{--vp-c-neutral: var(--vp-c-white);--vp-c-neutral-inverse: var(--vp-c-black)}:root{--vp-c-gray-1: #dddde3;--vp-c-gray-2: #e4e4e9;--vp-c-gray-3: #ebebef;--vp-c-gray-soft: rgba(142, 150, 170, .14);--vp-c-indigo-1: #3451b2;--vp-c-indigo-2: #3a5ccc;--vp-c-indigo-3: #5672cd;--vp-c-indigo-soft: rgba(100, 108, 255, .14);--vp-c-purple-1: #6f42c1;--vp-c-purple-2: #7e4cc9;--vp-c-purple-3: #8e5cd9;--vp-c-purple-soft: rgba(159, 122, 234, .14);--vp-c-green-1: #18794e;--vp-c-green-2: #299764;--vp-c-green-3: #30a46c;--vp-c-green-soft: rgba(16, 185, 129, .14);--vp-c-yellow-1: #915930;--vp-c-yellow-2: #946300;--vp-c-yellow-3: #9f6a00;--vp-c-yellow-soft: rgba(234, 179, 8, .14);--vp-c-red-1: #b8272c;--vp-c-red-2: #d5393e;--vp-c-red-3: #e0575b;--vp-c-red-soft: rgba(244, 63, 94, .14);--vp-c-sponsor: #db2777}.dark{--vp-c-gray-1: #515c67;--vp-c-gray-2: #414853;--vp-c-gray-3: #32363f;--vp-c-gray-soft: rgba(101, 117, 133, .16);--vp-c-indigo-1: #a8b1ff;--vp-c-indigo-2: #5c73e7;--vp-c-indigo-3: #3e63dd;--vp-c-indigo-soft: rgba(100, 108, 255, .16);--vp-c-purple-1: #c8abfa;--vp-c-purple-2: #a879e6;--vp-c-purple-3: #8e5cd9;--vp-c-purple-soft: rgba(159, 122, 234, .16);--vp-c-green-1: #3dd68c;--vp-c-green-2: #30a46c;--vp-c-green-3: #298459;--vp-c-green-soft: rgba(16, 185, 129, .16);--vp-c-yellow-1: #f9b44e;--vp-c-yellow-2: #da8b17;--vp-c-yellow-3: #a46a0a;--vp-c-yellow-soft: rgba(234, 179, 8, .16);--vp-c-red-1: #f66f81;--vp-c-red-2: #f14158;--vp-c-red-3: #b62a3c;--vp-c-red-soft: rgba(244, 63, 94, .16)}:root{--vp-c-bg: #ffffff;--vp-c-bg-alt: #f6f6f7;--vp-c-bg-elv: #ffffff;--vp-c-bg-soft: #f6f6f7}.dark{--vp-c-bg: #1b1b1f;--vp-c-bg-alt: #161618;--vp-c-bg-elv: #202127;--vp-c-bg-soft: #202127}:root{--vp-c-border: #c2c2c4;--vp-c-divider: #e2e2e3;--vp-c-gutter: #e2e2e3}.dark{--vp-c-border: #3c3f44;--vp-c-divider: #2e2e32;--vp-c-gutter: #000000}:root{--vp-c-text-1: rgba(60, 60, 67);--vp-c-text-2: rgba(60, 60, 67, .78);--vp-c-text-3: rgba(60, 60, 67, .56)}.dark{--vp-c-text-1: rgba(255, 255, 245, .86);--vp-c-text-2: rgba(235, 235, 245, .6);--vp-c-text-3: rgba(235, 235, 245, .38)}:root{--vp-c-default-1: var(--vp-c-gray-1);--vp-c-default-2: var(--vp-c-gray-2);--vp-c-default-3: var(--vp-c-gray-3);--vp-c-default-soft: var(--vp-c-gray-soft);--vp-c-brand-1: var(--vp-c-indigo-1);--vp-c-brand-2: var(--vp-c-indigo-2);--vp-c-brand-3: var(--vp-c-indigo-3);--vp-c-brand-soft: var(--vp-c-indigo-soft);--vp-c-brand: var(--vp-c-brand-1);--vp-c-tip-1: var(--vp-c-brand-1);--vp-c-tip-2: var(--vp-c-brand-2);--vp-c-tip-3: var(--vp-c-brand-3);--vp-c-tip-soft: var(--vp-c-brand-soft);--vp-c-note-1: var(--vp-c-brand-1);--vp-c-note-2: var(--vp-c-brand-2);--vp-c-note-3: var(--vp-c-brand-3);--vp-c-note-soft: var(--vp-c-brand-soft);--vp-c-success-1: var(--vp-c-green-1);--vp-c-success-2: var(--vp-c-green-2);--vp-c-success-3: var(--vp-c-green-3);--vp-c-success-soft: var(--vp-c-green-soft);--vp-c-important-1: var(--vp-c-purple-1);--vp-c-important-2: var(--vp-c-purple-2);--vp-c-important-3: var(--vp-c-purple-3);--vp-c-important-soft: var(--vp-c-purple-soft);--vp-c-warning-1: var(--vp-c-yellow-1);--vp-c-warning-2: var(--vp-c-yellow-2);--vp-c-warning-3: var(--vp-c-yellow-3);--vp-c-warning-soft: var(--vp-c-yellow-soft);--vp-c-danger-1: var(--vp-c-red-1);--vp-c-danger-2: var(--vp-c-red-2);--vp-c-danger-3: var(--vp-c-red-3);--vp-c-danger-soft: var(--vp-c-red-soft);--vp-c-caution-1: var(--vp-c-red-1);--vp-c-caution-2: var(--vp-c-red-2);--vp-c-caution-3: var(--vp-c-red-3);--vp-c-caution-soft: var(--vp-c-red-soft)}:root{--vp-font-family-base: "Inter", ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";--vp-font-family-mono: ui-monospace, "Menlo", "Monaco", "Consolas", "Liberation Mono", "Courier New", monospace;font-optical-sizing:auto}:root:where(:lang(zh)){--vp-font-family-base: "Punctuation SC", "Inter", ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"}:root{--vp-shadow-1: 0 1px 2px rgba(0, 0, 0, .04), 0 1px 2px rgba(0, 0, 0, .06);--vp-shadow-2: 0 3px 12px rgba(0, 0, 0, .07), 0 1px 4px rgba(0, 0, 0, .07);--vp-shadow-3: 0 12px 32px rgba(0, 0, 0, .1), 0 2px 6px rgba(0, 0, 0, .08);--vp-shadow-4: 0 14px 44px rgba(0, 0, 0, .12), 0 3px 9px rgba(0, 0, 0, .12);--vp-shadow-5: 0 18px 56px rgba(0, 0, 0, .16), 0 4px 12px rgba(0, 0, 0, .16)}:root{--vp-z-index-footer: 10;--vp-z-index-local-nav: 20;--vp-z-index-nav: 30;--vp-z-index-layout-top: 40;--vp-z-index-backdrop: 50;--vp-z-index-sidebar: 60}@media (min-width: 960px){:root{--vp-z-index-sidebar: 25}}:root{--vp-layout-max-width: 1440px}:root{--vp-header-anchor-symbol: "#"}:root{--vp-code-line-height: 1.7;--vp-code-font-size: .875em;--vp-code-color: var(--vp-c-brand-1);--vp-code-link-color: var(--vp-c-brand-1);--vp-code-link-hover-color: var(--vp-c-brand-2);--vp-code-bg: var(--vp-c-default-soft);--vp-code-block-color: var(--vp-c-text-2);--vp-code-block-bg: var(--vp-c-bg-alt);--vp-code-block-divider-color: var(--vp-c-gutter);--vp-code-lang-color: var(--vp-c-text-3);--vp-code-line-highlight-color: var(--vp-c-default-soft);--vp-code-line-number-color: var(--vp-c-text-3);--vp-code-line-diff-add-color: var(--vp-c-success-soft);--vp-code-line-diff-add-symbol-color: var(--vp-c-success-1);--vp-code-line-diff-remove-color: var(--vp-c-danger-soft);--vp-code-line-diff-remove-symbol-color: var(--vp-c-danger-1);--vp-code-line-warning-color: var(--vp-c-warning-soft);--vp-code-line-error-color: var(--vp-c-danger-soft);--vp-code-copy-code-border-color: var(--vp-c-divider);--vp-code-copy-code-bg: var(--vp-c-bg-soft);--vp-code-copy-code-hover-border-color: var(--vp-c-divider);--vp-code-copy-code-hover-bg: var(--vp-c-bg);--vp-code-copy-code-active-text: var(--vp-c-text-2);--vp-code-copy-copied-text-content: "Copied";--vp-code-tab-divider: var(--vp-code-block-divider-color);--vp-code-tab-text-color: var(--vp-c-text-2);--vp-code-tab-bg: var(--vp-code-block-bg);--vp-code-tab-hover-text-color: var(--vp-c-text-1);--vp-code-tab-active-text-color: var(--vp-c-text-1);--vp-code-tab-active-bar-color: var(--vp-c-brand-1)}:root{--vp-button-brand-border: transparent;--vp-button-brand-text: var(--vp-c-white);--vp-button-brand-bg: var(--vp-c-brand-3);--vp-button-brand-hover-border: transparent;--vp-button-brand-hover-text: var(--vp-c-white);--vp-button-brand-hover-bg: var(--vp-c-brand-2);--vp-button-brand-active-border: transparent;--vp-button-brand-active-text: var(--vp-c-white);--vp-button-brand-active-bg: var(--vp-c-brand-1);--vp-button-alt-border: transparent;--vp-button-alt-text: var(--vp-c-text-1);--vp-button-alt-bg: var(--vp-c-default-3);--vp-button-alt-hover-border: transparent;--vp-button-alt-hover-text: var(--vp-c-text-1);--vp-button-alt-hover-bg: var(--vp-c-default-2);--vp-button-alt-active-border: transparent;--vp-button-alt-active-text: var(--vp-c-text-1);--vp-button-alt-active-bg: var(--vp-c-default-1);--vp-button-sponsor-border: var(--vp-c-text-2);--vp-button-sponsor-text: var(--vp-c-text-2);--vp-button-sponsor-bg: transparent;--vp-button-sponsor-hover-border: var(--vp-c-sponsor);--vp-button-sponsor-hover-text: var(--vp-c-sponsor);--vp-button-sponsor-hover-bg: transparent;--vp-button-sponsor-active-border: var(--vp-c-sponsor);--vp-button-sponsor-active-text: var(--vp-c-sponsor);--vp-button-sponsor-active-bg: transparent}:root{--vp-custom-block-font-size: 14px;--vp-custom-block-code-font-size: 13px;--vp-custom-block-info-border: transparent;--vp-custom-block-info-text: var(--vp-c-text-1);--vp-custom-block-info-bg: var(--vp-c-default-soft);--vp-custom-block-info-code-bg: var(--vp-c-default-soft);--vp-custom-block-note-border: transparent;--vp-custom-block-note-text: var(--vp-c-text-1);--vp-custom-block-note-bg: var(--vp-c-default-soft);--vp-custom-block-note-code-bg: var(--vp-c-default-soft);--vp-custom-block-tip-border: transparent;--vp-custom-block-tip-text: var(--vp-c-text-1);--vp-custom-block-tip-bg: var(--vp-c-tip-soft);--vp-custom-block-tip-code-bg: var(--vp-c-tip-soft);--vp-custom-block-important-border: transparent;--vp-custom-block-important-text: var(--vp-c-text-1);--vp-custom-block-important-bg: var(--vp-c-important-soft);--vp-custom-block-important-code-bg: var(--vp-c-important-soft);--vp-custom-block-warning-border: transparent;--vp-custom-block-warning-text: var(--vp-c-text-1);--vp-custom-block-warning-bg: var(--vp-c-warning-soft);--vp-custom-block-warning-code-bg: var(--vp-c-warning-soft);--vp-custom-block-danger-border: transparent;--vp-custom-block-danger-text: var(--vp-c-text-1);--vp-custom-block-danger-bg: var(--vp-c-danger-soft);--vp-custom-block-danger-code-bg: var(--vp-c-danger-soft);--vp-custom-block-caution-border: transparent;--vp-custom-block-caution-text: var(--vp-c-text-1);--vp-custom-block-caution-bg: var(--vp-c-caution-soft);--vp-custom-block-caution-code-bg: var(--vp-c-caution-soft);--vp-custom-block-details-border: var(--vp-custom-block-info-border);--vp-custom-block-details-text: var(--vp-custom-block-info-text);--vp-custom-block-details-bg: var(--vp-custom-block-info-bg);--vp-custom-block-details-code-bg: var(--vp-custom-block-info-code-bg)}:root{--vp-input-border-color: var(--vp-c-border);--vp-input-bg-color: var(--vp-c-bg-alt);--vp-input-switch-bg-color: var(--vp-c-default-soft)}:root{--vp-nav-height: 64px;--vp-nav-bg-color: var(--vp-c-bg);--vp-nav-screen-bg-color: var(--vp-c-bg);--vp-nav-logo-height: 24px}.hide-nav{--vp-nav-height: 0px}.hide-nav .VPSidebar{--vp-nav-height: 22px}:root{--vp-local-nav-bg-color: var(--vp-c-bg)}:root{--vp-sidebar-width: 272px;--vp-sidebar-bg-color: var(--vp-c-bg-alt)}:root{--vp-backdrop-bg-color: rgba(0, 0, 0, .6)}:root{--vp-home-hero-name-color: var(--vp-c-brand-1);--vp-home-hero-name-background: transparent;--vp-home-hero-image-background-image: none;--vp-home-hero-image-filter: none}:root{--vp-badge-info-border: transparent;--vp-badge-info-text: var(--vp-c-text-2);--vp-badge-info-bg: var(--vp-c-default-soft);--vp-badge-tip-border: transparent;--vp-badge-tip-text: var(--vp-c-tip-1);--vp-badge-tip-bg: var(--vp-c-tip-soft);--vp-badge-warning-border: transparent;--vp-badge-warning-text: var(--vp-c-warning-1);--vp-badge-warning-bg: var(--vp-c-warning-soft);--vp-badge-danger-border: transparent;--vp-badge-danger-text: var(--vp-c-danger-1);--vp-badge-danger-bg: var(--vp-c-danger-soft)}:root{--vp-carbon-ads-text-color: var(--vp-c-text-1);--vp-carbon-ads-poweredby-color: var(--vp-c-text-2);--vp-carbon-ads-bg-color: var(--vp-c-bg-soft);--vp-carbon-ads-hover-text-color: var(--vp-c-brand-1);--vp-carbon-ads-hover-poweredby-color: var(--vp-c-text-1)}:root{--vp-local-search-bg: var(--vp-c-bg);--vp-local-search-result-bg: var(--vp-c-bg);--vp-local-search-result-border: var(--vp-c-divider);--vp-local-search-result-selected-bg: var(--vp-c-bg);--vp-local-search-result-selected-border: var(--vp-c-brand-1);--vp-local-search-highlight-bg: var(--vp-c-brand-1);--vp-local-search-highlight-text: var(--vp-c-neutral-inverse)}@media (prefers-reduced-motion: reduce){*,:before,:after{animation-delay:-1ms!important;animation-duration:1ms!important;animation-iteration-count:1!important;background-attachment:initial!important;scroll-behavior:auto!important;transition-duration:0s!important;transition-delay:0s!important}}*,:before,:after{box-sizing:border-box}html{line-height:1.4;font-size:16px;-webkit-text-size-adjust:100%}html.dark{color-scheme:dark}body{margin:0;width:100%;min-width:320px;min-height:100vh;line-height:24px;font-family:var(--vp-font-family-base);font-size:16px;font-weight:400;color:var(--vp-c-text-1);background-color:var(--vp-c-bg);font-synthesis:style;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}main{display:block}h1,h2,h3,h4,h5,h6{margin:0;line-height:24px;font-size:16px;font-weight:400}p{margin:0}strong,b{font-weight:600}a,area,button,[role=button],input,label,select,summary,textarea{touch-action:manipulation}a{color:inherit;text-decoration:inherit}ol,ul{list-style:none;margin:0;padding:0}blockquote{margin:0}pre,code,kbd,samp{font-family:var(--vp-font-family-mono)}img,svg,video,canvas,audio,iframe,embed,object{display:block}figure{margin:0}img,video{max-width:100%;height:auto}button,input,optgroup,select,textarea{border:0;padding:0;line-height:inherit;color:inherit}button{padding:0;font-family:inherit;background-color:transparent;background-image:none}button:enabled,[role=button]:enabled{cursor:pointer}button:focus,button:focus-visible{outline:1px dotted;outline:4px auto -webkit-focus-ring-color}button:focus:not(:focus-visible){outline:none!important}input:focus,textarea:focus,select:focus{outline:none}table{border-collapse:collapse}input{background-color:transparent}input:-ms-input-placeholder,textarea:-ms-input-placeholder{color:var(--vp-c-text-3)}input::-ms-input-placeholder,textarea::-ms-input-placeholder{color:var(--vp-c-text-3)}input::placeholder,textarea::placeholder{color:var(--vp-c-text-3)}input::-webkit-outer-spin-button,input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}input[type=number]{-moz-appearance:textfield}textarea{resize:vertical}select{-webkit-appearance:none}fieldset{margin:0;padding:0}h1,h2,h3,h4,h5,h6,li,p{overflow-wrap:break-word}vite-error-overlay{z-index:9999}mjx-container{overflow-x:auto}mjx-container>svg{display:inline-block;margin:auto}[class^=vpi-],[class*=" vpi-"],.vp-icon{width:1em;height:1em}[class^=vpi-].bg,[class*=" vpi-"].bg,.vp-icon.bg{background-size:100% 100%;background-color:transparent}[class^=vpi-]:not(.bg),[class*=" vpi-"]:not(.bg),.vp-icon:not(.bg){-webkit-mask:var(--icon) no-repeat;mask:var(--icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit}.vpi-align-left{--icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='M21 6H3M15 12H3M17 18H3'/%3E%3C/svg%3E")}.vpi-arrow-right,.vpi-arrow-down,.vpi-arrow-left,.vpi-arrow-up{--icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='M5 12h14M12 5l7 7-7 7'/%3E%3C/svg%3E")}.vpi-chevron-right,.vpi-chevron-down,.vpi-chevron-left,.vpi-chevron-up{--icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='m9 18 6-6-6-6'/%3E%3C/svg%3E")}.vpi-chevron-down,.vpi-arrow-down{transform:rotate(90deg)}.vpi-chevron-left,.vpi-arrow-left{transform:rotate(180deg)}.vpi-chevron-up,.vpi-arrow-up{transform:rotate(-90deg)}.vpi-square-pen{--icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7'/%3E%3Cpath d='M18.375 2.625a2.121 2.121 0 1 1 3 3L12 15l-4 1 1-4Z'/%3E%3C/svg%3E")}.vpi-plus{--icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='M5 12h14M12 5v14'/%3E%3C/svg%3E")}.vpi-sun{--icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='4'/%3E%3Cpath d='M12 2v2M12 20v2M4.93 4.93l1.41 1.41M17.66 17.66l1.41 1.41M2 12h2M20 12h2M6.34 17.66l-1.41 1.41M19.07 4.93l-1.41 1.41'/%3E%3C/svg%3E")}.vpi-moon{--icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z'/%3E%3C/svg%3E")}.vpi-more-horizontal{--icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='1'/%3E%3Ccircle cx='19' cy='12' r='1'/%3E%3Ccircle cx='5' cy='12' r='1'/%3E%3C/svg%3E")}.vpi-languages{--icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='m5 8 6 6M4 14l6-6 2-3M2 5h12M7 2h1M22 22l-5-10-5 10M14 18h6'/%3E%3C/svg%3E")}.vpi-heart{--icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='M19 14c1.49-1.46 3-3.21 3-5.5A5.5 5.5 0 0 0 16.5 3c-1.76 0-3 .5-4.5 2-1.5-1.5-2.74-2-4.5-2A5.5 5.5 0 0 0 2 8.5c0 2.3 1.5 4.05 3 5.5l7 7Z'/%3E%3C/svg%3E")}.vpi-search{--icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cpath d='m21 21-4.3-4.3'/%3E%3C/svg%3E")}.vpi-layout-list{--icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Crect width='7' height='7' x='3' y='3' rx='1'/%3E%3Crect width='7' height='7' x='3' y='14' rx='1'/%3E%3Cpath d='M14 4h7M14 9h7M14 15h7M14 20h7'/%3E%3C/svg%3E")}.vpi-delete{--icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='M20 5H9l-7 7 7 7h11a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2ZM18 9l-6 6M12 9l6 6'/%3E%3C/svg%3E")}.vpi-corner-down-left{--icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='m9 10-5 5 5 5'/%3E%3Cpath d='M20 4v7a4 4 0 0 1-4 4H4'/%3E%3C/svg%3E")}:root{--vp-icon-copy: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='rgba(128,128,128,1)' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Crect width='8' height='4' x='8' y='2' rx='1' ry='1'/%3E%3Cpath d='M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2'/%3E%3C/svg%3E");--vp-icon-copied: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' stroke='rgba(128,128,128,1)' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Crect width='8' height='4' x='8' y='2' rx='1' ry='1'/%3E%3Cpath d='M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2'/%3E%3Cpath d='m9 14 2 2 4-4'/%3E%3C/svg%3E")}.visually-hidden{position:absolute;width:1px;height:1px;white-space:nowrap;clip:rect(0 0 0 0);clip-path:inset(50%);overflow:hidden}.custom-block{border:1px solid transparent;border-radius:8px;padding:16px 16px 8px;line-height:24px;font-size:var(--vp-custom-block-font-size);color:var(--vp-c-text-2)}.custom-block.info{border-color:var(--vp-custom-block-info-border);color:var(--vp-custom-block-info-text);background-color:var(--vp-custom-block-info-bg)}.custom-block.info a,.custom-block.info code{color:var(--vp-c-brand-1)}.custom-block.info a:hover,.custom-block.info a:hover>code{color:var(--vp-c-brand-2)}.custom-block.info code{background-color:var(--vp-custom-block-info-code-bg)}.custom-block.note{border-color:var(--vp-custom-block-note-border);color:var(--vp-custom-block-note-text);background-color:var(--vp-custom-block-note-bg)}.custom-block.note a,.custom-block.note code{color:var(--vp-c-brand-1)}.custom-block.note a:hover,.custom-block.note a:hover>code{color:var(--vp-c-brand-2)}.custom-block.note code{background-color:var(--vp-custom-block-note-code-bg)}.custom-block.tip{border-color:var(--vp-custom-block-tip-border);color:var(--vp-custom-block-tip-text);background-color:var(--vp-custom-block-tip-bg)}.custom-block.tip a,.custom-block.tip code{color:var(--vp-c-tip-1)}.custom-block.tip a:hover,.custom-block.tip a:hover>code{color:var(--vp-c-tip-2)}.custom-block.tip code{background-color:var(--vp-custom-block-tip-code-bg)}.custom-block.important{border-color:var(--vp-custom-block-important-border);color:var(--vp-custom-block-important-text);background-color:var(--vp-custom-block-important-bg)}.custom-block.important a,.custom-block.important code{color:var(--vp-c-important-1)}.custom-block.important a:hover,.custom-block.important a:hover>code{color:var(--vp-c-important-2)}.custom-block.important code{background-color:var(--vp-custom-block-important-code-bg)}.custom-block.warning{border-color:var(--vp-custom-block-warning-border);color:var(--vp-custom-block-warning-text);background-color:var(--vp-custom-block-warning-bg)}.custom-block.warning a,.custom-block.warning code{color:var(--vp-c-warning-1)}.custom-block.warning a:hover,.custom-block.warning a:hover>code{color:var(--vp-c-warning-2)}.custom-block.warning code{background-color:var(--vp-custom-block-warning-code-bg)}.custom-block.danger{border-color:var(--vp-custom-block-danger-border);color:var(--vp-custom-block-danger-text);background-color:var(--vp-custom-block-danger-bg)}.custom-block.danger a,.custom-block.danger code{color:var(--vp-c-danger-1)}.custom-block.danger a:hover,.custom-block.danger a:hover>code{color:var(--vp-c-danger-2)}.custom-block.danger code{background-color:var(--vp-custom-block-danger-code-bg)}.custom-block.caution{border-color:var(--vp-custom-block-caution-border);color:var(--vp-custom-block-caution-text);background-color:var(--vp-custom-block-caution-bg)}.custom-block.caution a,.custom-block.caution code{color:var(--vp-c-caution-1)}.custom-block.caution a:hover,.custom-block.caution a:hover>code{color:var(--vp-c-caution-2)}.custom-block.caution code{background-color:var(--vp-custom-block-caution-code-bg)}.custom-block.details{border-color:var(--vp-custom-block-details-border);color:var(--vp-custom-block-details-text);background-color:var(--vp-custom-block-details-bg)}.custom-block.details a{color:var(--vp-c-brand-1)}.custom-block.details a:hover,.custom-block.details a:hover>code{color:var(--vp-c-brand-2)}.custom-block.details code{background-color:var(--vp-custom-block-details-code-bg)}.custom-block-title{font-weight:600}.custom-block p+p{margin:8px 0}.custom-block.details summary{margin:0 0 8px;font-weight:700;cursor:pointer;-webkit-user-select:none;user-select:none}.custom-block.details summary+p{margin:8px 0}.custom-block a{color:inherit;font-weight:600;text-decoration:underline;text-underline-offset:2px;transition:opacity .25s}.custom-block a:hover{opacity:.75}.custom-block code{font-size:var(--vp-custom-block-code-font-size)}.custom-block.custom-block th,.custom-block.custom-block blockquote>p{font-size:var(--vp-custom-block-font-size);color:inherit}.dark .vp-code span{color:var(--shiki-dark, inherit)}html:not(.dark) .vp-code span{color:var(--shiki-light, inherit)}.vp-code-group{margin-top:16px}.vp-code-group .tabs{position:relative;display:flex;margin-right:-24px;margin-left:-24px;padding:0 12px;background-color:var(--vp-code-tab-bg);overflow-x:auto;overflow-y:hidden;box-shadow:inset 0 -1px var(--vp-code-tab-divider)}@media (min-width: 640px){.vp-code-group .tabs{margin-right:0;margin-left:0;border-radius:8px 8px 0 0}}.vp-code-group .tabs input{position:fixed;opacity:0;pointer-events:none}.vp-code-group .tabs label{position:relative;display:inline-block;border-bottom:1px solid transparent;padding:0 12px;line-height:48px;font-size:14px;font-weight:500;color:var(--vp-code-tab-text-color);white-space:nowrap;cursor:pointer;transition:color .25s}.vp-code-group .tabs label:after{position:absolute;right:8px;bottom:-1px;left:8px;z-index:1;height:2px;border-radius:2px;content:"";background-color:transparent;transition:background-color .25s}.vp-code-group label:hover{color:var(--vp-code-tab-hover-text-color)}.vp-code-group input:checked+label{color:var(--vp-code-tab-active-text-color)}.vp-code-group input:checked+label:after{background-color:var(--vp-code-tab-active-bar-color)}.vp-code-group div[class*=language-],.vp-block{display:none;margin-top:0!important;border-top-left-radius:0!important;border-top-right-radius:0!important}.vp-code-group div[class*=language-].active,.vp-block.active{display:block}.vp-block{padding:20px 24px}.vp-doc h1,.vp-doc h2,.vp-doc h3,.vp-doc h4,.vp-doc h5,.vp-doc h6{position:relative;font-weight:600;outline:none}.vp-doc h1{letter-spacing:-.02em;line-height:40px;font-size:28px}.vp-doc h2{margin:48px 0 16px;border-top:1px solid var(--vp-c-divider);padding-top:24px;letter-spacing:-.02em;line-height:32px;font-size:24px}.vp-doc h3{margin:32px 0 0;letter-spacing:-.01em;line-height:28px;font-size:20px}.vp-doc h4{margin:24px 0 0;letter-spacing:-.01em;line-height:24px;font-size:18px}.vp-doc .header-anchor{position:absolute;top:0;left:0;margin-left:-.87em;font-weight:500;-webkit-user-select:none;user-select:none;opacity:0;text-decoration:none;transition:color .25s,opacity .25s}.vp-doc .header-anchor:before{content:var(--vp-header-anchor-symbol)}.vp-doc h1:hover .header-anchor,.vp-doc h1 .header-anchor:focus,.vp-doc h2:hover .header-anchor,.vp-doc h2 .header-anchor:focus,.vp-doc h3:hover .header-anchor,.vp-doc h3 .header-anchor:focus,.vp-doc h4:hover .header-anchor,.vp-doc h4 .header-anchor:focus,.vp-doc h5:hover .header-anchor,.vp-doc h5 .header-anchor:focus,.vp-doc h6:hover .header-anchor,.vp-doc h6 .header-anchor:focus{opacity:1}@media (min-width: 768px){.vp-doc h1{letter-spacing:-.02em;line-height:40px;font-size:32px}}.vp-doc h2 .header-anchor{top:24px}.vp-doc p,.vp-doc summary{margin:16px 0}.vp-doc p{line-height:28px}.vp-doc blockquote{margin:16px 0;border-left:2px solid var(--vp-c-divider);padding-left:16px;transition:border-color .5s;color:var(--vp-c-text-2)}.vp-doc blockquote>p{margin:0;font-size:16px;transition:color .5s}.vp-doc a{font-weight:500;color:var(--vp-c-brand-1);text-decoration:underline;text-underline-offset:2px;transition:color .25s,opacity .25s}.vp-doc a:hover{color:var(--vp-c-brand-2)}.vp-doc strong{font-weight:600}.vp-doc ul,.vp-doc ol{padding-left:1.25rem;margin:16px 0}.vp-doc ul{list-style:disc}.vp-doc ol{list-style:decimal}.vp-doc li+li{margin-top:8px}.vp-doc li>ol,.vp-doc li>ul{margin:8px 0 0}.vp-doc table{display:block;border-collapse:collapse;margin:20px 0;overflow-x:auto}.vp-doc tr{background-color:var(--vp-c-bg);border-top:1px solid var(--vp-c-divider);transition:background-color .5s}.vp-doc tr:nth-child(2n){background-color:var(--vp-c-bg-soft)}.vp-doc th,.vp-doc td{border:1px solid var(--vp-c-divider);padding:8px 16px}.vp-doc th{text-align:left;font-size:14px;font-weight:600;color:var(--vp-c-text-2);background-color:var(--vp-c-bg-soft)}.vp-doc td{font-size:14px}.vp-doc hr{margin:16px 0;border:none;border-top:1px solid var(--vp-c-divider)}.vp-doc .custom-block{margin:16px 0}.vp-doc .custom-block p{margin:8px 0;line-height:24px}.vp-doc .custom-block p:first-child{margin:0}.vp-doc .custom-block div[class*=language-]{margin:8px 0;border-radius:8px}.vp-doc .custom-block div[class*=language-] code{font-weight:400;background-color:transparent}.vp-doc .custom-block .vp-code-group .tabs{margin:0;border-radius:8px 8px 0 0}.vp-doc :not(pre,h1,h2,h3,h4,h5,h6)>code{font-size:var(--vp-code-font-size);color:var(--vp-code-color)}.vp-doc :not(pre)>code{border-radius:4px;padding:3px 6px;background-color:var(--vp-code-bg);transition:color .25s,background-color .5s}.vp-doc a>code{color:var(--vp-code-link-color)}.vp-doc a:hover>code{color:var(--vp-code-link-hover-color)}.vp-doc h1>code,.vp-doc h2>code,.vp-doc h3>code,.vp-doc h4>code{font-size:.9em}.vp-doc div[class*=language-],.vp-block{position:relative;margin:16px -24px;background-color:var(--vp-code-block-bg);overflow-x:auto;transition:background-color .5s}@media (min-width: 640px){.vp-doc div[class*=language-],.vp-block{border-radius:8px;margin:16px 0}}@media (max-width: 639px){.vp-doc li div[class*=language-]{border-radius:8px 0 0 8px}}.vp-doc div[class*=language-]+div[class*=language-],.vp-doc div[class$=-api]+div[class*=language-],.vp-doc div[class*=language-]+div[class$=-api]>div[class*=language-]{margin-top:-8px}.vp-doc [class*=language-] pre,.vp-doc [class*=language-] code{direction:ltr;text-align:left;white-space:pre;word-spacing:normal;word-break:normal;word-wrap:normal;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-hyphens:none;-moz-hyphens:none;-ms-hyphens:none;hyphens:none}.vp-doc [class*=language-] pre{position:relative;z-index:1;margin:0;padding:20px 0;background:transparent;overflow-x:auto}.vp-doc [class*=language-] code{display:block;padding:0 24px;width:fit-content;min-width:100%;line-height:var(--vp-code-line-height);font-size:var(--vp-code-font-size);color:var(--vp-code-block-color);transition:color .5s}.vp-doc [class*=language-] code .highlighted{background-color:var(--vp-code-line-highlight-color);transition:background-color .5s;margin:0 -24px;padding:0 24px;width:calc(100% + 48px);display:inline-block}.vp-doc [class*=language-] code .highlighted.error{background-color:var(--vp-code-line-error-color)}.vp-doc [class*=language-] code .highlighted.warning{background-color:var(--vp-code-line-warning-color)}.vp-doc [class*=language-] code .diff{transition:background-color .5s;margin:0 -24px;padding:0 24px;width:calc(100% + 48px);display:inline-block}.vp-doc [class*=language-] code .diff:before{position:absolute;left:10px}.vp-doc [class*=language-] .has-focused-lines .line:not(.has-focus){filter:blur(.095rem);opacity:.4;transition:filter .35s,opacity .35s}.vp-doc [class*=language-] .has-focused-lines .line:not(.has-focus){opacity:.7;transition:filter .35s,opacity .35s}.vp-doc [class*=language-]:hover .has-focused-lines .line:not(.has-focus){filter:blur(0);opacity:1}.vp-doc [class*=language-] code .diff.remove{background-color:var(--vp-code-line-diff-remove-color);opacity:.7}.vp-doc [class*=language-] code .diff.remove:before{content:"-";color:var(--vp-code-line-diff-remove-symbol-color)}.vp-doc [class*=language-] code .diff.add{background-color:var(--vp-code-line-diff-add-color)}.vp-doc [class*=language-] code .diff.add:before{content:"+";color:var(--vp-code-line-diff-add-symbol-color)}.vp-doc div[class*=language-].line-numbers-mode{padding-left:32px}.vp-doc .line-numbers-wrapper{position:absolute;top:0;bottom:0;left:0;z-index:3;border-right:1px solid var(--vp-code-block-divider-color);padding-top:20px;width:32px;text-align:center;font-family:var(--vp-font-family-mono);line-height:var(--vp-code-line-height);font-size:var(--vp-code-font-size);color:var(--vp-code-line-number-color);transition:border-color .5s,color .5s}.vp-doc [class*=language-]>button.copy{direction:ltr;position:absolute;top:12px;right:12px;z-index:3;border:1px solid var(--vp-code-copy-code-border-color);border-radius:4px;width:40px;height:40px;background-color:var(--vp-code-copy-code-bg);opacity:0;cursor:pointer;background-image:var(--vp-icon-copy);background-position:50%;background-size:20px;background-repeat:no-repeat;transition:border-color .25s,background-color .25s,opacity .25s}.vp-doc [class*=language-]:hover>button.copy,.vp-doc [class*=language-]>button.copy:focus{opacity:1}.vp-doc [class*=language-]>button.copy:hover,.vp-doc [class*=language-]>button.copy.copied{border-color:var(--vp-code-copy-code-hover-border-color);background-color:var(--vp-code-copy-code-hover-bg)}.vp-doc [class*=language-]>button.copy.copied,.vp-doc [class*=language-]>button.copy:hover.copied{border-radius:0 4px 4px 0;background-color:var(--vp-code-copy-code-hover-bg);background-image:var(--vp-icon-copied)}.vp-doc [class*=language-]>button.copy.copied:before,.vp-doc [class*=language-]>button.copy:hover.copied:before{position:relative;top:-1px;transform:translate(calc(-100% - 1px));display:flex;justify-content:center;align-items:center;border:1px solid var(--vp-code-copy-code-hover-border-color);border-right:0;border-radius:4px 0 0 4px;padding:0 10px;width:fit-content;height:40px;text-align:center;font-size:12px;font-weight:500;color:var(--vp-code-copy-code-active-text);background-color:var(--vp-code-copy-code-hover-bg);white-space:nowrap;content:var(--vp-code-copy-copied-text-content)}.vp-doc [class*=language-]>span.lang{position:absolute;top:2px;right:8px;z-index:2;font-size:12px;font-weight:500;-webkit-user-select:none;user-select:none;color:var(--vp-code-lang-color);transition:color .4s,opacity .4s}.vp-doc [class*=language-]:hover>button.copy+span.lang,.vp-doc [class*=language-]>button.copy:focus+span.lang{opacity:0}.vp-doc .VPTeamMembers{margin-top:24px}.vp-doc .VPTeamMembers.small.count-1 .container{margin:0!important;max-width:calc((100% - 24px)/2)!important}.vp-doc .VPTeamMembers.small.count-2 .container,.vp-doc .VPTeamMembers.small.count-3 .container{max-width:100%!important}.vp-doc .VPTeamMembers.medium.count-1 .container{margin:0!important;max-width:calc((100% - 24px)/2)!important}:is(.vp-external-link-icon,.vp-doc a[href*="://"],.vp-doc a[target=_blank]):not(.no-icon):after{display:inline-block;margin-top:-1px;margin-left:4px;width:11px;height:11px;background:currentColor;color:var(--vp-c-text-3);flex-shrink:0;--icon: url("data:image/svg+xml, %3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' %3E%3Cpath d='M0 0h24v24H0V0z' fill='none' /%3E%3Cpath d='M9 5v2h6.59L4 18.59 5.41 20 17 8.41V15h2V5H9z' /%3E%3C/svg%3E");-webkit-mask-image:var(--icon);mask-image:var(--icon)}.vp-external-link-icon:after{content:""}.external-link-icon-enabled :is(.vp-doc a[href*="://"],.vp-doc a[target=_blank]):after{content:"";color:currentColor}.vp-sponsor{border-radius:16px;overflow:hidden}.vp-sponsor.aside{border-radius:12px}.vp-sponsor-section+.vp-sponsor-section{margin-top:4px}.vp-sponsor-tier{margin:0 0 4px!important;text-align:center;letter-spacing:1px!important;line-height:24px;width:100%;font-weight:600;color:var(--vp-c-text-2);background-color:var(--vp-c-bg-soft)}.vp-sponsor.normal .vp-sponsor-tier{padding:13px 0 11px;font-size:14px}.vp-sponsor.aside .vp-sponsor-tier{padding:9px 0 7px;font-size:12px}.vp-sponsor-grid+.vp-sponsor-tier{margin-top:4px}.vp-sponsor-grid{display:flex;flex-wrap:wrap;gap:4px}.vp-sponsor-grid.xmini .vp-sponsor-grid-link{height:64px}.vp-sponsor-grid.xmini .vp-sponsor-grid-image{max-width:64px;max-height:22px}.vp-sponsor-grid.mini .vp-sponsor-grid-link{height:72px}.vp-sponsor-grid.mini .vp-sponsor-grid-image{max-width:96px;max-height:24px}.vp-sponsor-grid.small .vp-sponsor-grid-link{height:96px}.vp-sponsor-grid.small .vp-sponsor-grid-image{max-width:96px;max-height:24px}.vp-sponsor-grid.medium .vp-sponsor-grid-link{height:112px}.vp-sponsor-grid.medium .vp-sponsor-grid-image{max-width:120px;max-height:36px}.vp-sponsor-grid.big .vp-sponsor-grid-link{height:184px}.vp-sponsor-grid.big .vp-sponsor-grid-image{max-width:192px;max-height:56px}.vp-sponsor-grid[data-vp-grid="2"] .vp-sponsor-grid-item{width:calc((100% - 4px)/2)}.vp-sponsor-grid[data-vp-grid="3"] .vp-sponsor-grid-item{width:calc((100% - 4px * 2) / 3)}.vp-sponsor-grid[data-vp-grid="4"] .vp-sponsor-grid-item{width:calc((100% - 12px)/4)}.vp-sponsor-grid[data-vp-grid="5"] .vp-sponsor-grid-item{width:calc((100% - 16px)/5)}.vp-sponsor-grid[data-vp-grid="6"] .vp-sponsor-grid-item{width:calc((100% - 4px * 5) / 6)}.vp-sponsor-grid-item{flex-shrink:0;width:100%;background-color:var(--vp-c-bg-soft);transition:background-color .25s}.vp-sponsor-grid-item:hover{background-color:var(--vp-c-default-soft)}.vp-sponsor-grid-item:hover .vp-sponsor-grid-image{filter:grayscale(0) invert(0)}.vp-sponsor-grid-item.empty:hover{background-color:var(--vp-c-bg-soft)}.dark .vp-sponsor-grid-item:hover{background-color:var(--vp-c-white)}.dark .vp-sponsor-grid-item.empty:hover{background-color:var(--vp-c-bg-soft)}.vp-sponsor-grid-link{display:flex}.vp-sponsor-grid-box{display:flex;justify-content:center;align-items:center;width:100%}.vp-sponsor-grid-image{max-width:100%;filter:grayscale(1);transition:filter .25s}.dark .vp-sponsor-grid-image{filter:grayscale(1) invert(1)}.VPBadge{display:inline-block;margin-left:2px;border:1px solid transparent;border-radius:12px;padding:0 10px;line-height:22px;font-size:12px;font-weight:500;transform:translateY(-2px)}.VPBadge.small{padding:0 6px;line-height:18px;font-size:10px;transform:translateY(-8px)}.VPDocFooter .VPBadge{display:none}.vp-doc h1>.VPBadge{margin-top:4px;vertical-align:top}.vp-doc h2>.VPBadge{margin-top:3px;padding:0 8px;vertical-align:top}.vp-doc h3>.VPBadge{vertical-align:middle}.vp-doc h4>.VPBadge,.vp-doc h5>.VPBadge,.vp-doc h6>.VPBadge{vertical-align:middle;line-height:18px}.VPBadge.info{border-color:var(--vp-badge-info-border);color:var(--vp-badge-info-text);background-color:var(--vp-badge-info-bg)}.VPBadge.tip{border-color:var(--vp-badge-tip-border);color:var(--vp-badge-tip-text);background-color:var(--vp-badge-tip-bg)}.VPBadge.warning{border-color:var(--vp-badge-warning-border);color:var(--vp-badge-warning-text);background-color:var(--vp-badge-warning-bg)}.VPBadge.danger{border-color:var(--vp-badge-danger-border);color:var(--vp-badge-danger-text);background-color:var(--vp-badge-danger-bg)}.VPBackdrop[data-v-2bf0c4a0]{position:fixed;top:0;right:0;bottom:0;left:0;z-index:var(--vp-z-index-backdrop);background:var(--vp-backdrop-bg-color);transition:opacity .5s}.VPBackdrop.fade-enter-from[data-v-2bf0c4a0],.VPBackdrop.fade-leave-to[data-v-2bf0c4a0]{opacity:0}.VPBackdrop.fade-leave-active[data-v-2bf0c4a0]{transition-duration:.25s}@media (min-width: 1280px){.VPBackdrop[data-v-2bf0c4a0]{display:none}}.NotFound[data-v-a5285cbb]{padding:64px 24px 96px;text-align:center}@media (min-width: 768px){.NotFound[data-v-a5285cbb]{padding:96px 32px 168px}}.code[data-v-a5285cbb]{line-height:64px;font-size:64px;font-weight:600}.title[data-v-a5285cbb]{padding-top:12px;letter-spacing:2px;line-height:20px;font-size:20px;font-weight:700}.divider[data-v-a5285cbb]{margin:24px auto 18px;width:64px;height:1px;background-color:var(--vp-c-divider)}.quote[data-v-a5285cbb]{margin:0 auto;max-width:256px;font-size:14px;font-weight:500;color:var(--vp-c-text-2)}.action[data-v-a5285cbb]{padding-top:20px}.link[data-v-a5285cbb]{display:inline-block;border:1px solid var(--vp-c-brand-1);border-radius:16px;padding:3px 16px;font-size:14px;font-weight:500;color:var(--vp-c-brand-1);transition:border-color .25s,color .25s}.link[data-v-a5285cbb]:hover{border-color:var(--vp-c-brand-2);color:var(--vp-c-brand-2)}.root[data-v-6fc04da0]{position:relative;z-index:1}.nested[data-v-6fc04da0]{padding-right:16px;padding-left:16px}.outline-link[data-v-6fc04da0]{display:block;line-height:32px;font-size:14px;font-weight:400;color:var(--vp-c-text-2);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;transition:color .5s}.outline-link[data-v-6fc04da0]:hover,.outline-link.active[data-v-6fc04da0]{color:var(--vp-c-text-1);transition:color .25s}.outline-link.nested[data-v-6fc04da0]{padding-left:13px}.VPDocAsideOutline[data-v-0c0cedaf]{display:none}.VPDocAsideOutline.has-outline[data-v-0c0cedaf]{display:block}.content[data-v-0c0cedaf]{position:relative;border-left:1px solid var(--vp-c-divider);padding-left:16px;font-size:13px;font-weight:500}.outline-marker[data-v-0c0cedaf]{position:absolute;top:32px;left:-1px;z-index:0;opacity:0;width:2px;border-radius:2px;height:18px;background-color:var(--vp-c-brand-1);transition:top .25s cubic-bezier(0,1,.5,1),background-color .5s,opacity .25s}.outline-title[data-v-0c0cedaf]{line-height:32px;font-size:14px;font-weight:600}.VPDocAside[data-v-1a813d93]{display:flex;flex-direction:column;flex-grow:1}.spacer[data-v-1a813d93]{flex-grow:1}.VPDocAside[data-v-1a813d93] .spacer+.VPDocAsideSponsors,.VPDocAside[data-v-1a813d93] .spacer+.VPDocAsideCarbonAds{margin-top:24px}.VPDocAside[data-v-1a813d93] .VPDocAsideSponsors+.VPDocAsideCarbonAds{margin-top:16px}.VPLastUpdated[data-v-6cdca359]{line-height:24px;font-size:14px;font-weight:500;color:var(--vp-c-text-2)}@media (min-width: 640px){.VPLastUpdated[data-v-6cdca359]{line-height:32px;font-size:14px;font-weight:500}}.VPDocFooter[data-v-623a8dfe]{margin-top:64px}.edit-info[data-v-623a8dfe]{padding-bottom:18px}@media (min-width: 640px){.edit-info[data-v-623a8dfe]{display:flex;justify-content:space-between;align-items:center;padding-bottom:14px}}.edit-link-button[data-v-623a8dfe]{display:flex;align-items:center;border:0;line-height:32px;font-size:14px;font-weight:500;color:var(--vp-c-brand-1);transition:color .25s}.edit-link-button[data-v-623a8dfe]:hover{color:var(--vp-c-brand-2)}.edit-link-icon[data-v-623a8dfe]{margin-right:8px}.prev-next[data-v-623a8dfe]{border-top:1px solid var(--vp-c-divider);padding-top:24px;display:grid;grid-row-gap:8px}@media (min-width: 640px){.prev-next[data-v-623a8dfe]{grid-template-columns:repeat(2,1fr);grid-column-gap:16px}}.pager-link[data-v-623a8dfe]{display:block;border:1px solid var(--vp-c-divider);border-radius:8px;padding:11px 16px 13px;width:100%;height:100%;transition:border-color .25s}.pager-link[data-v-623a8dfe]:hover{border-color:var(--vp-c-brand-1)}.pager-link.next[data-v-623a8dfe]{margin-left:auto;text-align:right}.desc[data-v-623a8dfe]{display:block;line-height:20px;font-size:12px;font-weight:500;color:var(--vp-c-text-2)}.title[data-v-623a8dfe]{display:block;line-height:20px;font-size:14px;font-weight:500;color:var(--vp-c-brand-1);transition:color .25s}.VPDoc[data-v-dd7190e0]{padding:32px 24px 96px;width:100%}@media (min-width: 768px){.VPDoc[data-v-dd7190e0]{padding:48px 32px 128px}}@media (min-width: 960px){.VPDoc[data-v-dd7190e0]{padding:48px 32px 0}.VPDoc:not(.has-sidebar) .container[data-v-dd7190e0]{display:flex;justify-content:center;max-width:992px}.VPDoc:not(.has-sidebar) .content[data-v-dd7190e0]{max-width:752px}}@media (min-width: 1280px){.VPDoc .container[data-v-dd7190e0]{display:flex;justify-content:center}.VPDoc .aside[data-v-dd7190e0]{display:block}}@media (min-width: 1440px){.VPDoc:not(.has-sidebar) .content[data-v-dd7190e0]{max-width:784px}.VPDoc:not(.has-sidebar) .container[data-v-dd7190e0]{max-width:1104px}}.container[data-v-dd7190e0]{margin:0 auto;width:100%}.aside[data-v-dd7190e0]{position:relative;display:none;order:2;flex-grow:1;padding-left:32px;width:100%;max-width:256px}.left-aside[data-v-dd7190e0]{order:1;padding-left:unset;padding-right:32px}.aside-container[data-v-dd7190e0]{position:fixed;top:0;padding-top:calc(var(--vp-nav-height) + var(--vp-layout-top-height, 0px) + var(--vp-doc-top-height, 0px) + 48px);width:224px;height:100vh;overflow-x:hidden;overflow-y:auto;scrollbar-width:none}.aside-container[data-v-dd7190e0]::-webkit-scrollbar{display:none}.aside-curtain[data-v-dd7190e0]{position:fixed;bottom:0;z-index:10;width:224px;height:32px;background:linear-gradient(transparent,var(--vp-c-bg) 70%)}.aside-content[data-v-dd7190e0]{display:flex;flex-direction:column;min-height:calc(100vh - (var(--vp-nav-height) + var(--vp-layout-top-height, 0px) + 48px));padding-bottom:32px}.content[data-v-dd7190e0]{position:relative;margin:0 auto;width:100%}@media (min-width: 960px){.content[data-v-dd7190e0]{padding:0 32px 128px}}@media (min-width: 1280px){.content[data-v-dd7190e0]{order:1;margin:0;min-width:640px}}.content-container[data-v-dd7190e0]{margin:0 auto}.VPDoc.has-aside .content-container[data-v-dd7190e0]{max-width:688px}.VPButton[data-v-48d0230e]{display:inline-block;border:1px solid transparent;text-align:center;font-weight:600;white-space:nowrap;transition:color .25s,border-color .25s,background-color .25s}.VPButton[data-v-48d0230e]:active{transition:color .1s,border-color .1s,background-color .1s}.VPButton.medium[data-v-48d0230e]{border-radius:20px;padding:0 20px;line-height:38px;font-size:14px}.VPButton.big[data-v-48d0230e]{border-radius:24px;padding:0 24px;line-height:46px;font-size:16px}.VPButton.brand[data-v-48d0230e]{border-color:var(--vp-button-brand-border);color:var(--vp-button-brand-text);background-color:var(--vp-button-brand-bg)}.VPButton.brand[data-v-48d0230e]:hover{border-color:var(--vp-button-brand-hover-border);color:var(--vp-button-brand-hover-text);background-color:var(--vp-button-brand-hover-bg)}.VPButton.brand[data-v-48d0230e]:active{border-color:var(--vp-button-brand-active-border);color:var(--vp-button-brand-active-text);background-color:var(--vp-button-brand-active-bg)}.VPButton.alt[data-v-48d0230e]{border-color:var(--vp-button-alt-border);color:var(--vp-button-alt-text);background-color:var(--vp-button-alt-bg)}.VPButton.alt[data-v-48d0230e]:hover{border-color:var(--vp-button-alt-hover-border);color:var(--vp-button-alt-hover-text);background-color:var(--vp-button-alt-hover-bg)}.VPButton.alt[data-v-48d0230e]:active{border-color:var(--vp-button-alt-active-border);color:var(--vp-button-alt-active-text);background-color:var(--vp-button-alt-active-bg)}.VPButton.sponsor[data-v-48d0230e]{border-color:var(--vp-button-sponsor-border);color:var(--vp-button-sponsor-text);background-color:var(--vp-button-sponsor-bg)}.VPButton.sponsor[data-v-48d0230e]:hover{border-color:var(--vp-button-sponsor-hover-border);color:var(--vp-button-sponsor-hover-text);background-color:var(--vp-button-sponsor-hover-bg)}.VPButton.sponsor[data-v-48d0230e]:active{border-color:var(--vp-button-sponsor-active-border);color:var(--vp-button-sponsor-active-text);background-color:var(--vp-button-sponsor-active-bg)}html:not(.dark) .VPImage.dark[data-v-d440722e]{display:none}.dark .VPImage.light[data-v-d440722e]{display:none}.VPHero[data-v-1990d40c]{margin-top:calc((var(--vp-nav-height) + var(--vp-layout-top-height, 0px)) * -1);padding:calc(var(--vp-nav-height) + var(--vp-layout-top-height, 0px) + 48px) 24px 48px}@media (min-width: 640px){.VPHero[data-v-1990d40c]{padding:calc(var(--vp-nav-height) + var(--vp-layout-top-height, 0px) + 80px) 48px 64px}}@media (min-width: 960px){.VPHero[data-v-1990d40c]{padding:calc(var(--vp-nav-height) + var(--vp-layout-top-height, 0px) + 80px) 64px 64px}}.container[data-v-1990d40c]{display:flex;flex-direction:column;margin:0 auto;max-width:1152px}@media (min-width: 960px){.container[data-v-1990d40c]{flex-direction:row}}.main[data-v-1990d40c]{position:relative;z-index:10;order:2;flex-grow:1;flex-shrink:0}.VPHero.has-image .container[data-v-1990d40c]{text-align:center}@media (min-width: 960px){.VPHero.has-image .container[data-v-1990d40c]{text-align:left}}@media (min-width: 960px){.main[data-v-1990d40c]{order:1;width:calc((100% / 3) * 2)}.VPHero.has-image .main[data-v-1990d40c]{max-width:592px}}.name[data-v-1990d40c],.text[data-v-1990d40c]{max-width:392px;letter-spacing:-.4px;line-height:40px;font-size:32px;font-weight:700;white-space:pre-wrap}.VPHero.has-image .name[data-v-1990d40c],.VPHero.has-image .text[data-v-1990d40c]{margin:0 auto}.name[data-v-1990d40c]{color:var(--vp-home-hero-name-color)}.clip[data-v-1990d40c]{background:var(--vp-home-hero-name-background);-webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:var(--vp-home-hero-name-color)}@media (min-width: 640px){.name[data-v-1990d40c],.text[data-v-1990d40c]{max-width:576px;line-height:56px;font-size:48px}}@media (min-width: 960px){.name[data-v-1990d40c],.text[data-v-1990d40c]{line-height:64px;font-size:56px}.VPHero.has-image .name[data-v-1990d40c],.VPHero.has-image .text[data-v-1990d40c]{margin:0}}.tagline[data-v-1990d40c]{padding-top:8px;max-width:392px;line-height:28px;font-size:18px;font-weight:500;white-space:pre-wrap;color:var(--vp-c-text-2)}.VPHero.has-image .tagline[data-v-1990d40c]{margin:0 auto}@media (min-width: 640px){.tagline[data-v-1990d40c]{padding-top:12px;max-width:576px;line-height:32px;font-size:20px}}@media (min-width: 960px){.tagline[data-v-1990d40c]{line-height:36px;font-size:24px}.VPHero.has-image .tagline[data-v-1990d40c]{margin:0}}.actions[data-v-1990d40c]{display:flex;flex-wrap:wrap;margin:-6px;padding-top:24px}.VPHero.has-image .actions[data-v-1990d40c]{justify-content:center}@media (min-width: 640px){.actions[data-v-1990d40c]{padding-top:32px}}@media (min-width: 960px){.VPHero.has-image .actions[data-v-1990d40c]{justify-content:flex-start}}.action[data-v-1990d40c]{flex-shrink:0;padding:6px}.image[data-v-1990d40c]{order:1;margin:-76px -24px -48px}@media (min-width: 640px){.image[data-v-1990d40c]{margin:-108px -24px -48px}}@media (min-width: 960px){.image[data-v-1990d40c]{flex-grow:1;order:2;margin:0;min-height:100%}}.image-container[data-v-1990d40c]{position:relative;margin:0 auto;width:320px;height:320px}@media (min-width: 640px){.image-container[data-v-1990d40c]{width:392px;height:392px}}@media (min-width: 960px){.image-container[data-v-1990d40c]{display:flex;justify-content:center;align-items:center;width:100%;height:100%;transform:translate(-32px,-32px)}}.image-bg[data-v-1990d40c]{position:absolute;top:50%;left:50%;border-radius:50%;width:192px;height:192px;background-image:var(--vp-home-hero-image-background-image);filter:var(--vp-home-hero-image-filter);transform:translate(-50%,-50%)}@media (min-width: 640px){.image-bg[data-v-1990d40c]{width:256px;height:256px}}@media (min-width: 960px){.image-bg[data-v-1990d40c]{width:320px;height:320px}}[data-v-1990d40c] .image-src{position:absolute;top:50%;left:50%;max-width:192px;max-height:192px;transform:translate(-50%,-50%)}@media (min-width: 640px){[data-v-1990d40c] .image-src{max-width:256px;max-height:256px}}@media (min-width: 960px){[data-v-1990d40c] .image-src{max-width:320px;max-height:320px}}.VPFeature[data-v-a96f5862]{display:block;border:1px solid var(--vp-c-bg-soft);border-radius:12px;height:100%;background-color:var(--vp-c-bg-soft);transition:border-color .25s,background-color .25s}.VPFeature.link[data-v-a96f5862]:hover{border-color:var(--vp-c-brand-1)}.box[data-v-a96f5862]{display:flex;flex-direction:column;padding:24px;height:100%}.box[data-v-a96f5862]>.VPImage{margin-bottom:20px}.icon[data-v-a96f5862]{display:flex;justify-content:center;align-items:center;margin-bottom:20px;border-radius:6px;background-color:var(--vp-c-default-soft);width:48px;height:48px;font-size:24px;transition:background-color .25s}.title[data-v-a96f5862]{line-height:24px;font-size:16px;font-weight:600}.details[data-v-a96f5862]{flex-grow:1;padding-top:8px;line-height:24px;font-size:14px;font-weight:500;color:var(--vp-c-text-2)}.link-text[data-v-a96f5862]{padding-top:8px}.link-text-value[data-v-a96f5862]{display:flex;align-items:center;font-size:14px;font-weight:500;color:var(--vp-c-brand-1)}.link-text-icon[data-v-a96f5862]{margin-left:6px}.VPFeatures[data-v-64091ee1]{position:relative;padding:0 24px}@media (min-width: 640px){.VPFeatures[data-v-64091ee1]{padding:0 48px}}@media (min-width: 960px){.VPFeatures[data-v-64091ee1]{padding:0 64px}}.container[data-v-64091ee1]{margin:0 auto;max-width:1152px}.items[data-v-64091ee1]{display:flex;flex-wrap:wrap;margin:-8px}.item[data-v-64091ee1]{padding:8px;width:100%}@media (min-width: 640px){.item.grid-2[data-v-64091ee1],.item.grid-4[data-v-64091ee1],.item.grid-6[data-v-64091ee1]{width:50%}}@media (min-width: 768px){.item.grid-2[data-v-64091ee1],.item.grid-4[data-v-64091ee1]{width:50%}.item.grid-3[data-v-64091ee1],.item.grid-6[data-v-64091ee1]{width:calc(100% / 3)}}@media (min-width: 960px){.item.grid-4[data-v-64091ee1]{width:25%}}.container[data-v-7350a991]{margin:auto;width:100%;max-width:1280px;padding:0 24px}@media (min-width: 640px){.container[data-v-7350a991]{padding:0 48px}}@media (min-width: 960px){.container[data-v-7350a991]{width:100%;padding:0 64px}}.vp-doc[data-v-7350a991] .VPHomeSponsors,.vp-doc[data-v-7350a991] .VPTeamPage{margin-left:var(--vp-offset, calc(50% - 50vw) );margin-right:var(--vp-offset, calc(50% - 50vw) )}.vp-doc[data-v-7350a991] .VPHomeSponsors h2{border-top:none;letter-spacing:normal}.vp-doc[data-v-7350a991] .VPHomeSponsors a,.vp-doc[data-v-7350a991] .VPTeamPage a{text-decoration:none}.VPHome[data-v-5664ecf3]{margin-bottom:96px}@media (min-width: 768px){.VPHome[data-v-5664ecf3]{margin-bottom:128px}}.VPContent[data-v-9b48e573]{flex-grow:1;flex-shrink:0;margin:var(--vp-layout-top-height, 0px) auto 0;width:100%}.VPContent.is-home[data-v-9b48e573]{width:100%;max-width:100%}.VPContent.has-sidebar[data-v-9b48e573]{margin:0}@media (min-width: 960px){.VPContent[data-v-9b48e573]{padding-top:var(--vp-nav-height)}.VPContent.has-sidebar[data-v-9b48e573]{margin:var(--vp-layout-top-height, 0px) 0 0;padding-left:var(--vp-sidebar-width)}}@media (min-width: 1440px){.VPContent.has-sidebar[data-v-9b48e573]{padding-right:calc((100vw - var(--vp-layout-max-width)) / 2);padding-left:calc((100vw - var(--vp-layout-max-width)) / 2 + var(--vp-sidebar-width))}}.VPFooter[data-v-3e99d79d]{position:relative;z-index:var(--vp-z-index-footer);border-top:1px solid var(--vp-c-gutter);padding:32px 24px;background-color:var(--vp-c-bg)}.VPFooter.has-sidebar[data-v-3e99d79d]{display:none}.VPFooter[data-v-3e99d79d] a{text-decoration-line:underline;text-underline-offset:2px;transition:color .25s}.VPFooter[data-v-3e99d79d] a:hover{color:var(--vp-c-text-1)}@media (min-width: 768px){.VPFooter[data-v-3e99d79d]{padding:32px}}.container[data-v-3e99d79d]{margin:0 auto;max-width:var(--vp-layout-max-width);text-align:center}.message[data-v-3e99d79d],.copyright[data-v-3e99d79d]{line-height:24px;font-size:14px;font-weight:500;color:var(--vp-c-text-2)}.VPLocalNavOutlineDropdown[data-v-90060d6b]{padding:12px 20px 11px}@media (min-width: 960px){.VPLocalNavOutlineDropdown[data-v-90060d6b]{padding:12px 36px 11px}}.VPLocalNavOutlineDropdown button[data-v-90060d6b]{display:block;font-size:12px;font-weight:500;line-height:24px;color:var(--vp-c-text-2);transition:color .5s;position:relative}.VPLocalNavOutlineDropdown button[data-v-90060d6b]:hover{color:var(--vp-c-text-1);transition:color .25s}.VPLocalNavOutlineDropdown button.open[data-v-90060d6b]{color:var(--vp-c-text-1)}.icon[data-v-90060d6b]{display:inline-block;vertical-align:middle;margin-left:2px;font-size:14px;transform:rotate(0);transition:transform .25s}@media (min-width: 960px){.VPLocalNavOutlineDropdown button[data-v-90060d6b]{font-size:14px}.icon[data-v-90060d6b]{font-size:16px}}.open>.icon[data-v-90060d6b]{transform:rotate(90deg)}.items[data-v-90060d6b]{position:absolute;top:40px;right:16px;left:16px;display:grid;gap:1px;border:1px solid var(--vp-c-border);border-radius:8px;background-color:var(--vp-c-gutter);max-height:calc(var(--vp-vh, 100vh) - 86px);overflow:hidden auto;box-shadow:var(--vp-shadow-3)}@media (min-width: 960px){.items[data-v-90060d6b]{right:auto;left:calc(var(--vp-sidebar-width) + 32px);width:320px}}.header[data-v-90060d6b]{background-color:var(--vp-c-bg-soft)}.top-link[data-v-90060d6b]{display:block;padding:0 16px;line-height:48px;font-size:14px;font-weight:500;color:var(--vp-c-brand-1)}.outline[data-v-90060d6b]{padding:8px 0;background-color:var(--vp-c-bg-soft)}.flyout-enter-active[data-v-90060d6b]{transition:all .2s ease-out}.flyout-leave-active[data-v-90060d6b]{transition:all .15s ease-in}.flyout-enter-from[data-v-90060d6b],.flyout-leave-to[data-v-90060d6b]{opacity:0;transform:translateY(-16px)}.VPLocalNav[data-v-d66dc387]{position:sticky;top:0;left:0;z-index:var(--vp-z-index-local-nav);border-bottom:1px solid var(--vp-c-gutter);padding-top:var(--vp-layout-top-height, 0px);width:100%;background-color:var(--vp-local-nav-bg-color)}.VPLocalNav.fixed[data-v-d66dc387]{position:fixed}@media (min-width: 960px){.VPLocalNav[data-v-d66dc387]{top:var(--vp-nav-height)}.VPLocalNav.has-sidebar[data-v-d66dc387]{padding-left:var(--vp-sidebar-width)}.VPLocalNav.empty[data-v-d66dc387]{display:none}}@media (min-width: 1280px){.VPLocalNav[data-v-d66dc387]{display:none}}@media (min-width: 1440px){.VPLocalNav.has-sidebar[data-v-d66dc387]{padding-left:calc((100vw - var(--vp-layout-max-width)) / 2 + var(--vp-sidebar-width))}}.container[data-v-d66dc387]{display:flex;justify-content:space-between;align-items:center}.menu[data-v-d66dc387]{display:flex;align-items:center;padding:12px 24px 11px;line-height:24px;font-size:12px;font-weight:500;color:var(--vp-c-text-2);transition:color .5s}.menu[data-v-d66dc387]:hover{color:var(--vp-c-text-1);transition:color .25s}@media (min-width: 768px){.menu[data-v-d66dc387]{padding:0 32px}}@media (min-width: 960px){.menu[data-v-d66dc387]{display:none}}.menu-icon[data-v-d66dc387]{margin-right:8px;font-size:14px}.VPOutlineDropdown[data-v-d66dc387]{padding:12px 24px 11px}@media (min-width: 768px){.VPOutlineDropdown[data-v-d66dc387]{padding:12px 32px 11px}}.VPSwitch[data-v-813ef981]{position:relative;border-radius:11px;display:block;width:40px;height:22px;flex-shrink:0;border:1px solid var(--vp-input-border-color);background-color:var(--vp-input-switch-bg-color);transition:border-color .25s!important}.VPSwitch[data-v-813ef981]:hover{border-color:var(--vp-c-brand-1)}.check[data-v-813ef981]{position:absolute;top:1px;left:1px;width:18px;height:18px;border-radius:50%;background-color:var(--vp-c-neutral-inverse);box-shadow:var(--vp-shadow-1);transition:transform .25s!important}.icon[data-v-813ef981]{position:relative;display:block;width:18px;height:18px;border-radius:50%;overflow:hidden}.icon[data-v-813ef981] [class^=vpi-]{position:absolute;top:3px;left:3px;width:12px;height:12px;color:var(--vp-c-text-2)}.dark .icon[data-v-813ef981] [class^=vpi-]{color:var(--vp-c-text-1);transition:opacity .25s!important}.sun[data-v-da7ec100]{opacity:1}.moon[data-v-da7ec100],.dark .sun[data-v-da7ec100]{opacity:0}.dark .moon[data-v-da7ec100]{opacity:1}.dark .VPSwitchAppearance[data-v-da7ec100] .check{transform:translate(18px)}.VPNavBarAppearance[data-v-1b2826e7]{display:none}@media (min-width: 1280px){.VPNavBarAppearance[data-v-1b2826e7]{display:flex;align-items:center}}.VPMenuGroup+.VPMenuLink[data-v-89a5c348]{margin:12px -12px 0;border-top:1px solid var(--vp-c-divider);padding:12px 12px 0}.link[data-v-89a5c348]{display:block;border-radius:6px;padding:0 12px;line-height:32px;font-size:14px;font-weight:500;color:var(--vp-c-text-1);white-space:nowrap;transition:background-color .25s,color .25s}.link[data-v-89a5c348]:hover{color:var(--vp-c-brand-1);background-color:var(--vp-c-default-soft)}.link.active[data-v-89a5c348]{color:var(--vp-c-brand-1)}.VPMenuGroup[data-v-56396be0]{margin:12px -12px 0;border-top:1px solid var(--vp-c-divider);padding:12px 12px 0}.VPMenuGroup[data-v-56396be0]:first-child{margin-top:0;border-top:0;padding-top:0}.VPMenuGroup+.VPMenuGroup[data-v-56396be0]{margin-top:12px;border-top:1px solid var(--vp-c-divider)}.title[data-v-56396be0]{padding:0 12px;line-height:32px;font-size:14px;font-weight:600;color:var(--vp-c-text-2);white-space:nowrap;transition:color .25s}.VPMenu[data-v-e6ae5541]{border-radius:12px;padding:12px;min-width:128px;border:1px solid var(--vp-c-divider);background-color:var(--vp-c-bg-elv);box-shadow:var(--vp-shadow-3);transition:background-color .5s;max-height:calc(100vh - var(--vp-nav-height));overflow-y:auto}.VPMenu[data-v-e6ae5541] .group{margin:0 -12px;padding:0 12px 12px}.VPMenu[data-v-e6ae5541] .group+.group{border-top:1px solid var(--vp-c-divider);padding:11px 12px 12px}.VPMenu[data-v-e6ae5541] .group:last-child{padding-bottom:0}.VPMenu[data-v-e6ae5541] .group+.item{border-top:1px solid var(--vp-c-divider);padding:11px 16px 0}.VPMenu[data-v-e6ae5541] .item{padding:0 16px;white-space:nowrap}.VPMenu[data-v-e6ae5541] .label{flex-grow:1;line-height:28px;font-size:12px;font-weight:500;color:var(--vp-c-text-2);transition:color .5s}.VPMenu[data-v-e6ae5541] .action{padding-left:24px}.VPFlyout[data-v-c7dcff6d]{position:relative}.VPFlyout[data-v-c7dcff6d]:hover{color:var(--vp-c-brand-1);transition:color .25s}.VPFlyout:hover .text[data-v-c7dcff6d]{color:var(--vp-c-text-2)}.VPFlyout:hover .icon[data-v-c7dcff6d]{fill:var(--vp-c-text-2)}.VPFlyout.active .text[data-v-c7dcff6d]{color:var(--vp-c-brand-1)}.VPFlyout.active:hover .text[data-v-c7dcff6d]{color:var(--vp-c-brand-2)}.button[aria-expanded=false]+.menu[data-v-c7dcff6d]{opacity:0;visibility:hidden;transform:translateY(0)}.VPFlyout:hover .menu[data-v-c7dcff6d],.button[aria-expanded=true]+.menu[data-v-c7dcff6d]{opacity:1;visibility:visible;transform:translateY(0)}.button[data-v-c7dcff6d]{display:flex;align-items:center;padding:0 12px;height:var(--vp-nav-height);color:var(--vp-c-text-1);transition:color .5s}.text[data-v-c7dcff6d]{display:flex;align-items:center;line-height:var(--vp-nav-height);font-size:14px;font-weight:500;color:var(--vp-c-text-1);transition:color .25s}.option-icon[data-v-c7dcff6d]{margin-right:0;font-size:16px}.text-icon[data-v-c7dcff6d]{margin-left:4px;font-size:14px}.icon[data-v-c7dcff6d]{font-size:20px;transition:fill .25s}.menu[data-v-c7dcff6d]{position:absolute;top:calc(var(--vp-nav-height) / 2 + 20px);right:0;opacity:0;visibility:hidden;transition:opacity .25s,visibility .25s,transform .25s}.VPSocialLink[data-v-a1268182]{display:flex;justify-content:center;align-items:center;width:36px;height:36px;color:var(--vp-c-text-2);transition:color .5s}.VPSocialLink[data-v-a1268182]:hover{color:var(--vp-c-text-1);transition:color .25s}.VPSocialLink[data-v-a1268182]>svg,.VPSocialLink[data-v-a1268182]>[class^=vpi-social-]{width:20px;height:20px;fill:currentColor}.VPSocialLinks[data-v-d71f35b5]{display:flex;justify-content:center}.VPNavBarExtra[data-v-0c20fffb]{display:none;margin-right:-12px}@media (min-width: 768px){.VPNavBarExtra[data-v-0c20fffb]{display:block}}@media (min-width: 1280px){.VPNavBarExtra[data-v-0c20fffb]{display:none}}.trans-title[data-v-0c20fffb]{padding:0 24px 0 12px;line-height:32px;font-size:14px;font-weight:700;color:var(--vp-c-text-1)}.item.appearance[data-v-0c20fffb],.item.social-links[data-v-0c20fffb]{display:flex;align-items:center;padding:0 12px}.item.appearance[data-v-0c20fffb]{min-width:176px}.appearance-action[data-v-0c20fffb]{margin-right:-2px}.social-links-list[data-v-0c20fffb]{margin:-4px -8px}.VPNavBarHamburger[data-v-1006ddd6]{display:flex;justify-content:center;align-items:center;width:48px;height:var(--vp-nav-height)}@media (min-width: 768px){.VPNavBarHamburger[data-v-1006ddd6]{display:none}}.container[data-v-1006ddd6]{position:relative;width:16px;height:14px;overflow:hidden}.VPNavBarHamburger:hover .top[data-v-1006ddd6]{top:0;left:0;transform:translate(4px)}.VPNavBarHamburger:hover .middle[data-v-1006ddd6]{top:6px;left:0;transform:translate(0)}.VPNavBarHamburger:hover .bottom[data-v-1006ddd6]{top:12px;left:0;transform:translate(8px)}.VPNavBarHamburger.active .top[data-v-1006ddd6]{top:6px;transform:translate(0) rotate(225deg)}.VPNavBarHamburger.active .middle[data-v-1006ddd6]{top:6px;transform:translate(16px)}.VPNavBarHamburger.active .bottom[data-v-1006ddd6]{top:6px;transform:translate(0) rotate(135deg)}.VPNavBarHamburger.active:hover .top[data-v-1006ddd6],.VPNavBarHamburger.active:hover .middle[data-v-1006ddd6],.VPNavBarHamburger.active:hover .bottom[data-v-1006ddd6]{background-color:var(--vp-c-text-2);transition:top .25s,background-color .25s,transform .25s}.top[data-v-1006ddd6],.middle[data-v-1006ddd6],.bottom[data-v-1006ddd6]{position:absolute;width:16px;height:2px;background-color:var(--vp-c-text-1);transition:top .25s,background-color .5s,transform .25s}.top[data-v-1006ddd6]{top:0;left:0;transform:translate(0)}.middle[data-v-1006ddd6]{top:6px;left:0;transform:translate(8px)}.bottom[data-v-1006ddd6]{top:12px;left:0;transform:translate(4px)}.VPNavBarMenuLink[data-v-89faf8bb]{display:flex;align-items:center;padding:0 12px;line-height:var(--vp-nav-height);font-size:14px;font-weight:500;color:var(--vp-c-text-1);transition:color .25s}.VPNavBarMenuLink.active[data-v-89faf8bb],.VPNavBarMenuLink[data-v-89faf8bb]:hover{color:var(--vp-c-brand-1)}.VPNavBarMenu[data-v-ec1f35aa]{display:none}@media (min-width: 768px){.VPNavBarMenu[data-v-ec1f35aa]{display:flex}}/*! @docsearch/css 3.8.0 | MIT License | © Algolia, Inc. and contributors | https://docsearch.algolia.com */:root{--docsearch-primary-color:#5468ff;--docsearch-text-color:#1c1e21;--docsearch-spacing:12px;--docsearch-icon-stroke-width:1.4;--docsearch-highlight-color:var(--docsearch-primary-color);--docsearch-muted-color:#969faf;--docsearch-container-background:rgba(101,108,133,.8);--docsearch-logo-color:#5468ff;--docsearch-modal-width:560px;--docsearch-modal-height:600px;--docsearch-modal-background:#f5f6f7;--docsearch-modal-shadow:inset 1px 1px 0 0 hsla(0,0%,100%,.5),0 3px 8px 0 #555a64;--docsearch-searchbox-height:56px;--docsearch-searchbox-background:#ebedf0;--docsearch-searchbox-focus-background:#fff;--docsearch-searchbox-shadow:inset 0 0 0 2px var(--docsearch-primary-color);--docsearch-hit-height:56px;--docsearch-hit-color:#444950;--docsearch-hit-active-color:#fff;--docsearch-hit-background:#fff;--docsearch-hit-shadow:0 1px 3px 0 #d4d9e1;--docsearch-key-gradient:linear-gradient(-225deg,#d5dbe4,#f8f8f8);--docsearch-key-shadow:inset 0 -2px 0 0 #cdcde6,inset 0 0 1px 1px #fff,0 1px 2px 1px rgba(30,35,90,.4);--docsearch-key-pressed-shadow:inset 0 -2px 0 0 #cdcde6,inset 0 0 1px 1px #fff,0 1px 1px 0 rgba(30,35,90,.4);--docsearch-footer-height:44px;--docsearch-footer-background:#fff;--docsearch-footer-shadow:0 -1px 0 0 #e0e3e8,0 -3px 6px 0 rgba(69,98,155,.12)}html[data-theme=dark]{--docsearch-text-color:#f5f6f7;--docsearch-container-background:rgba(9,10,17,.8);--docsearch-modal-background:#15172a;--docsearch-modal-shadow:inset 1px 1px 0 0 #2c2e40,0 3px 8px 0 #000309;--docsearch-searchbox-background:#090a11;--docsearch-searchbox-focus-background:#000;--docsearch-hit-color:#bec3c9;--docsearch-hit-shadow:none;--docsearch-hit-background:#090a11;--docsearch-key-gradient:linear-gradient(-26.5deg,#565872,#31355b);--docsearch-key-shadow:inset 0 -2px 0 0 #282d55,inset 0 0 1px 1px #51577d,0 2px 2px 0 rgba(3,4,9,.3);--docsearch-key-pressed-shadow:inset 0 -2px 0 0 #282d55,inset 0 0 1px 1px #51577d,0 1px 1px 0 #0304094d;--docsearch-footer-background:#1e2136;--docsearch-footer-shadow:inset 0 1px 0 0 rgba(73,76,106,.5),0 -4px 8px 0 rgba(0,0,0,.2);--docsearch-logo-color:#fff;--docsearch-muted-color:#7f8497}.DocSearch-Button{align-items:center;background:var(--docsearch-searchbox-background);border:0;border-radius:40px;color:var(--docsearch-muted-color);cursor:pointer;display:flex;font-weight:500;height:36px;justify-content:space-between;margin:0 0 0 16px;padding:0 8px;-webkit-user-select:none;user-select:none}.DocSearch-Button:active,.DocSearch-Button:focus,.DocSearch-Button:hover{background:var(--docsearch-searchbox-focus-background);box-shadow:var(--docsearch-searchbox-shadow);color:var(--docsearch-text-color);outline:none}.DocSearch-Button-Container{align-items:center;display:flex}.DocSearch-Search-Icon{stroke-width:1.6}.DocSearch-Button .DocSearch-Search-Icon{color:var(--docsearch-text-color)}.DocSearch-Button-Placeholder{font-size:1rem;padding:0 12px 0 6px}.DocSearch-Button-Keys{display:flex;min-width:calc(40px + .8em)}.DocSearch-Button-Key{align-items:center;background:var(--docsearch-key-gradient);border:0;border-radius:3px;box-shadow:var(--docsearch-key-shadow);color:var(--docsearch-muted-color);display:flex;height:18px;justify-content:center;margin-right:.4em;padding:0 0 2px;position:relative;top:-1px;width:20px}.DocSearch-Button-Key--pressed{box-shadow:var(--docsearch-key-pressed-shadow);transform:translate3d(0,1px,0)}@media (max-width:768px){.DocSearch-Button-Keys,.DocSearch-Button-Placeholder{display:none}}.DocSearch--active{overflow:hidden!important}.DocSearch-Container,.DocSearch-Container *{box-sizing:border-box}.DocSearch-Container{background-color:var(--docsearch-container-background);height:100vh;left:0;position:fixed;top:0;width:100vw;z-index:200}.DocSearch-Container a{text-decoration:none}.DocSearch-Link{-webkit-appearance:none;-moz-appearance:none;appearance:none;background:none;border:0;color:var(--docsearch-highlight-color);cursor:pointer;font:inherit;margin:0;padding:0}.DocSearch-Modal{background:var(--docsearch-modal-background);border-radius:6px;box-shadow:var(--docsearch-modal-shadow);flex-direction:column;margin:60px auto auto;max-width:var(--docsearch-modal-width);position:relative}.DocSearch-SearchBar{display:flex;padding:var(--docsearch-spacing) var(--docsearch-spacing) 0}.DocSearch-Form{align-items:center;background:var(--docsearch-searchbox-focus-background);border-radius:4px;box-shadow:var(--docsearch-searchbox-shadow);display:flex;height:var(--docsearch-searchbox-height);margin:0;padding:0 var(--docsearch-spacing);position:relative;width:100%}.DocSearch-Input{-webkit-appearance:none;-moz-appearance:none;appearance:none;background:transparent;border:0;color:var(--docsearch-text-color);flex:1;font:inherit;font-size:1.2em;height:100%;outline:none;padding:0 0 0 8px;width:80%}.DocSearch-Input::placeholder{color:var(--docsearch-muted-color);opacity:1}.DocSearch-Input::-webkit-search-cancel-button,.DocSearch-Input::-webkit-search-decoration,.DocSearch-Input::-webkit-search-results-button,.DocSearch-Input::-webkit-search-results-decoration{display:none}.DocSearch-LoadingIndicator,.DocSearch-MagnifierLabel,.DocSearch-Reset{margin:0;padding:0}.DocSearch-MagnifierLabel,.DocSearch-Reset{align-items:center;color:var(--docsearch-highlight-color);display:flex;justify-content:center}.DocSearch-Container--Stalled .DocSearch-MagnifierLabel,.DocSearch-LoadingIndicator{display:none}.DocSearch-Container--Stalled .DocSearch-LoadingIndicator{align-items:center;color:var(--docsearch-highlight-color);display:flex;justify-content:center}@media screen and (prefers-reduced-motion:reduce){.DocSearch-Reset{animation:none;-webkit-appearance:none;-moz-appearance:none;appearance:none;background:none;border:0;border-radius:50%;color:var(--docsearch-icon-color);cursor:pointer;right:0;stroke-width:var(--docsearch-icon-stroke-width)}}.DocSearch-Reset{animation:fade-in .1s ease-in forwards;-webkit-appearance:none;-moz-appearance:none;appearance:none;background:none;border:0;border-radius:50%;color:var(--docsearch-icon-color);cursor:pointer;padding:2px;right:0;stroke-width:var(--docsearch-icon-stroke-width)}.DocSearch-Reset[hidden]{display:none}.DocSearch-Reset:hover{color:var(--docsearch-highlight-color)}.DocSearch-LoadingIndicator svg,.DocSearch-MagnifierLabel svg{height:24px;width:24px}.DocSearch-Cancel{display:none}.DocSearch-Dropdown{max-height:calc(var(--docsearch-modal-height) - var(--docsearch-searchbox-height) - var(--docsearch-spacing) - var(--docsearch-footer-height));min-height:var(--docsearch-spacing);overflow-y:auto;overflow-y:overlay;padding:0 var(--docsearch-spacing);scrollbar-color:var(--docsearch-muted-color) var(--docsearch-modal-background);scrollbar-width:thin}.DocSearch-Dropdown::-webkit-scrollbar{width:12px}.DocSearch-Dropdown::-webkit-scrollbar-track{background:transparent}.DocSearch-Dropdown::-webkit-scrollbar-thumb{background-color:var(--docsearch-muted-color);border:3px solid var(--docsearch-modal-background);border-radius:20px}.DocSearch-Dropdown ul{list-style:none;margin:0;padding:0}.DocSearch-Label{font-size:.75em;line-height:1.6em}.DocSearch-Help,.DocSearch-Label{color:var(--docsearch-muted-color)}.DocSearch-Help{font-size:.9em;margin:0;-webkit-user-select:none;user-select:none}.DocSearch-Title{font-size:1.2em}.DocSearch-Logo a{display:flex}.DocSearch-Logo svg{color:var(--docsearch-logo-color);margin-left:8px}.DocSearch-Hits:last-of-type{margin-bottom:24px}.DocSearch-Hits mark{background:none;color:var(--docsearch-highlight-color)}.DocSearch-HitsFooter{color:var(--docsearch-muted-color);display:flex;font-size:.85em;justify-content:center;margin-bottom:var(--docsearch-spacing);padding:var(--docsearch-spacing)}.DocSearch-HitsFooter a{border-bottom:1px solid;color:inherit}.DocSearch-Hit{border-radius:4px;display:flex;padding-bottom:4px;position:relative}@media screen and (prefers-reduced-motion:reduce){.DocSearch-Hit--deleting{transition:none}}.DocSearch-Hit--deleting{opacity:0;transition:all .25s linear}@media screen and (prefers-reduced-motion:reduce){.DocSearch-Hit--favoriting{transition:none}}.DocSearch-Hit--favoriting{transform:scale(0);transform-origin:top center;transition:all .25s linear;transition-delay:.25s}.DocSearch-Hit a{background:var(--docsearch-hit-background);border-radius:4px;box-shadow:var(--docsearch-hit-shadow);display:block;padding-left:var(--docsearch-spacing);width:100%}.DocSearch-Hit-source{background:var(--docsearch-modal-background);color:var(--docsearch-highlight-color);font-size:.85em;font-weight:600;line-height:32px;margin:0 -4px;padding:8px 4px 0;position:sticky;top:0;z-index:10}.DocSearch-Hit-Tree{color:var(--docsearch-muted-color);height:var(--docsearch-hit-height);opacity:.5;stroke-width:var(--docsearch-icon-stroke-width);width:24px}.DocSearch-Hit[aria-selected=true] a{background-color:var(--docsearch-highlight-color)}.DocSearch-Hit[aria-selected=true] mark{text-decoration:underline}.DocSearch-Hit-Container{align-items:center;color:var(--docsearch-hit-color);display:flex;flex-direction:row;height:var(--docsearch-hit-height);padding:0 var(--docsearch-spacing) 0 0}.DocSearch-Hit-icon{height:20px;width:20px}.DocSearch-Hit-action,.DocSearch-Hit-icon{color:var(--docsearch-muted-color);stroke-width:var(--docsearch-icon-stroke-width)}.DocSearch-Hit-action{align-items:center;display:flex;height:22px;width:22px}.DocSearch-Hit-action svg{display:block;height:18px;width:18px}.DocSearch-Hit-action+.DocSearch-Hit-action{margin-left:6px}.DocSearch-Hit-action-button{-webkit-appearance:none;-moz-appearance:none;appearance:none;background:none;border:0;border-radius:50%;color:inherit;cursor:pointer;padding:2px}svg.DocSearch-Hit-Select-Icon{display:none}.DocSearch-Hit[aria-selected=true] .DocSearch-Hit-Select-Icon{display:block}.DocSearch-Hit-action-button:focus,.DocSearch-Hit-action-button:hover{background:#0003;transition:background-color .1s ease-in}@media screen and (prefers-reduced-motion:reduce){.DocSearch-Hit-action-button:focus,.DocSearch-Hit-action-button:hover{transition:none}}.DocSearch-Hit-action-button:focus path,.DocSearch-Hit-action-button:hover path{fill:#fff}.DocSearch-Hit-content-wrapper{display:flex;flex:1 1 auto;flex-direction:column;font-weight:500;justify-content:center;line-height:1.2em;margin:0 8px;overflow-x:hidden;position:relative;text-overflow:ellipsis;white-space:nowrap;width:80%}.DocSearch-Hit-title{font-size:.9em}.DocSearch-Hit-path{color:var(--docsearch-muted-color);font-size:.75em}.DocSearch-Hit[aria-selected=true] .DocSearch-Hit-Tree,.DocSearch-Hit[aria-selected=true] .DocSearch-Hit-action,.DocSearch-Hit[aria-selected=true] .DocSearch-Hit-icon,.DocSearch-Hit[aria-selected=true] .DocSearch-Hit-path,.DocSearch-Hit[aria-selected=true] .DocSearch-Hit-text,.DocSearch-Hit[aria-selected=true] .DocSearch-Hit-title,.DocSearch-Hit[aria-selected=true] mark{color:var(--docsearch-hit-active-color)!important}@media screen and (prefers-reduced-motion:reduce){.DocSearch-Hit-action-button:focus,.DocSearch-Hit-action-button:hover{background:#0003;transition:none}}.DocSearch-ErrorScreen,.DocSearch-NoResults,.DocSearch-StartScreen{font-size:.9em;margin:0 auto;padding:36px 0;text-align:center;width:80%}.DocSearch-Screen-Icon{color:var(--docsearch-muted-color);padding-bottom:12px}.DocSearch-NoResults-Prefill-List{display:inline-block;padding-bottom:24px;text-align:left}.DocSearch-NoResults-Prefill-List ul{display:inline-block;padding:8px 0 0}.DocSearch-NoResults-Prefill-List li{list-style-position:inside;list-style-type:"» "}.DocSearch-Prefill{-webkit-appearance:none;-moz-appearance:none;appearance:none;background:none;border:0;border-radius:1em;color:var(--docsearch-highlight-color);cursor:pointer;display:inline-block;font-size:1em;font-weight:700;padding:0}.DocSearch-Prefill:focus,.DocSearch-Prefill:hover{outline:none;text-decoration:underline}.DocSearch-Footer{align-items:center;background:var(--docsearch-footer-background);border-radius:0 0 8px 8px;box-shadow:var(--docsearch-footer-shadow);display:flex;flex-direction:row-reverse;flex-shrink:0;height:var(--docsearch-footer-height);justify-content:space-between;padding:0 var(--docsearch-spacing);position:relative;-webkit-user-select:none;user-select:none;width:100%;z-index:300}.DocSearch-Commands{color:var(--docsearch-muted-color);display:flex;list-style:none;margin:0;padding:0}.DocSearch-Commands li{align-items:center;display:flex}.DocSearch-Commands li:not(:last-of-type){margin-right:.8em}.DocSearch-Commands-Key{align-items:center;background:var(--docsearch-key-gradient);border:0;border-radius:2px;box-shadow:var(--docsearch-key-shadow);color:var(--docsearch-muted-color);display:flex;height:18px;justify-content:center;margin-right:.4em;padding:0 0 1px;width:20px}.DocSearch-VisuallyHiddenForAccessibility{clip:rect(0 0 0 0);clip-path:inset(50%);height:1px;overflow:hidden;position:absolute;white-space:nowrap;width:1px}@media (max-width:768px){:root{--docsearch-spacing:10px;--docsearch-footer-height:40px}.DocSearch-Dropdown{height:100%}.DocSearch-Container{height:100vh;height:-webkit-fill-available;height:calc(var(--docsearch-vh, 1vh)*100);position:absolute}.DocSearch-Footer{border-radius:0;bottom:0;position:absolute}.DocSearch-Hit-content-wrapper{display:flex;position:relative;width:80%}.DocSearch-Modal{border-radius:0;box-shadow:none;height:100vh;height:-webkit-fill-available;height:calc(var(--docsearch-vh, 1vh)*100);margin:0;max-width:100%;width:100%}.DocSearch-Dropdown{max-height:calc(var(--docsearch-vh, 1vh)*100 - var(--docsearch-searchbox-height) - var(--docsearch-spacing) - var(--docsearch-footer-height))}.DocSearch-Cancel{-webkit-appearance:none;-moz-appearance:none;appearance:none;background:none;border:0;color:var(--docsearch-highlight-color);cursor:pointer;display:inline-block;flex:none;font:inherit;font-size:1em;font-weight:500;margin-left:var(--docsearch-spacing);outline:none;overflow:hidden;padding:0;-webkit-user-select:none;user-select:none;white-space:nowrap}.DocSearch-Commands,.DocSearch-Hit-Tree{display:none}}@keyframes fade-in{0%{opacity:0}to{opacity:1}}[class*=DocSearch]{--docsearch-primary-color: var(--vp-c-brand-1);--docsearch-highlight-color: var(--docsearch-primary-color);--docsearch-text-color: var(--vp-c-text-1);--docsearch-muted-color: var(--vp-c-text-2);--docsearch-searchbox-shadow: none;--docsearch-searchbox-background: transparent;--docsearch-searchbox-focus-background: transparent;--docsearch-key-gradient: transparent;--docsearch-key-shadow: none;--docsearch-modal-background: var(--vp-c-bg-soft);--docsearch-footer-background: var(--vp-c-bg)}.dark [class*=DocSearch]{--docsearch-modal-shadow: none;--docsearch-footer-shadow: none;--docsearch-logo-color: var(--vp-c-text-2);--docsearch-hit-background: var(--vp-c-default-soft);--docsearch-hit-color: var(--vp-c-text-2);--docsearch-hit-shadow: none}.DocSearch-Button{display:flex;justify-content:center;align-items:center;margin:0;padding:0;width:48px;height:55px;background:transparent;transition:border-color .25s}.DocSearch-Button:hover{background:transparent}.DocSearch-Button:focus{outline:1px dotted;outline:5px auto -webkit-focus-ring-color}.DocSearch-Button-Key--pressed{transform:none;box-shadow:none}.DocSearch-Button:focus:not(:focus-visible){outline:none!important}@media (min-width: 768px){.DocSearch-Button{justify-content:flex-start;border:1px solid transparent;border-radius:8px;padding:0 10px 0 12px;width:100%;height:40px;background-color:var(--vp-c-bg-alt)}.DocSearch-Button:hover{border-color:var(--vp-c-brand-1);background:var(--vp-c-bg-alt)}}.DocSearch-Button .DocSearch-Button-Container{display:flex;align-items:center}.DocSearch-Button .DocSearch-Search-Icon{position:relative;width:16px;height:16px;color:var(--vp-c-text-1);fill:currentColor;transition:color .5s}.DocSearch-Button:hover .DocSearch-Search-Icon{color:var(--vp-c-text-1)}@media (min-width: 768px){.DocSearch-Button .DocSearch-Search-Icon{top:1px;margin-right:8px;width:14px;height:14px;color:var(--vp-c-text-2)}}.DocSearch-Button .DocSearch-Button-Placeholder{display:none;margin-top:2px;padding:0 16px 0 0;font-size:13px;font-weight:500;color:var(--vp-c-text-2);transition:color .5s}.DocSearch-Button:hover .DocSearch-Button-Placeholder{color:var(--vp-c-text-1)}@media (min-width: 768px){.DocSearch-Button .DocSearch-Button-Placeholder{display:inline-block}}.DocSearch-Button .DocSearch-Button-Keys{direction:ltr;display:none;min-width:auto}@media (min-width: 768px){.DocSearch-Button .DocSearch-Button-Keys{display:flex;align-items:center}}.DocSearch-Button .DocSearch-Button-Key{display:block;margin:2px 0 0;border:1px solid var(--vp-c-divider);border-right:none;border-radius:4px 0 0 4px;padding-left:6px;min-width:0;width:auto;height:22px;line-height:22px;font-family:var(--vp-font-family-base);font-size:12px;font-weight:500;transition:color .5s,border-color .5s}.DocSearch-Button .DocSearch-Button-Key+.DocSearch-Button-Key{border-right:1px solid var(--vp-c-divider);border-left:none;border-radius:0 4px 4px 0;padding-left:2px;padding-right:6px}.DocSearch-Button .DocSearch-Button-Key:first-child{font-size:0!important}.DocSearch-Button .DocSearch-Button-Key:first-child:after{content:"Ctrl";font-size:12px;letter-spacing:normal;color:var(--docsearch-muted-color)}.mac .DocSearch-Button .DocSearch-Button-Key:first-child:after{content:"⌘"}.DocSearch-Button .DocSearch-Button-Key:first-child>*{display:none}.DocSearch-Search-Icon{--icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' stroke-width='1.6' viewBox='0 0 20 20'%3E%3Cpath fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' d='m14.386 14.386 4.088 4.088-4.088-4.088A7.533 7.533 0 1 1 3.733 3.733a7.533 7.533 0 0 1 10.653 10.653z'/%3E%3C/svg%3E")}.VPNavBarSearch{display:flex;align-items:center}@media (min-width: 768px){.VPNavBarSearch{flex-grow:1;padding-left:24px}}@media (min-width: 960px){.VPNavBarSearch{padding-left:32px}}.dark .DocSearch-Footer{border-top:1px solid var(--vp-c-divider)}.DocSearch-Form{border:1px solid var(--vp-c-brand-1);background-color:var(--vp-c-white)}.dark .DocSearch-Form{background-color:var(--vp-c-default-soft)}.DocSearch-Screen-Icon>svg{margin:auto}.VPNavBarSocialLinks[data-v-bc5763b5]{display:none}@media (min-width: 1280px){.VPNavBarSocialLinks[data-v-bc5763b5]{display:flex;align-items:center}}.title[data-v-a1a198d5]{display:flex;align-items:center;border-bottom:1px solid transparent;width:100%;height:var(--vp-nav-height);font-size:16px;font-weight:600;color:var(--vp-c-text-1);transition:opacity .25s}@media (min-width: 960px){.title[data-v-a1a198d5]{flex-shrink:0}.VPNavBarTitle.has-sidebar .title[data-v-a1a198d5]{border-bottom-color:var(--vp-c-divider)}}[data-v-a1a198d5] .logo{margin-right:8px;height:var(--vp-nav-logo-height)}.VPNavBarTranslations[data-v-73c6375d]{display:none}@media (min-width: 1280px){.VPNavBarTranslations[data-v-73c6375d]{display:flex;align-items:center}}.title[data-v-73c6375d]{padding:0 24px 0 12px;line-height:32px;font-size:14px;font-weight:700;color:var(--vp-c-text-1)}.VPNavBar[data-v-cb65f61d]{position:relative;height:var(--vp-nav-height);pointer-events:none;white-space:nowrap;transition:background-color .25s}.VPNavBar.screen-open[data-v-cb65f61d]{transition:none;background-color:var(--vp-nav-bg-color);border-bottom:1px solid var(--vp-c-divider)}.VPNavBar[data-v-cb65f61d]:not(.home){background-color:var(--vp-nav-bg-color)}@media (min-width: 960px){.VPNavBar[data-v-cb65f61d]:not(.home){background-color:transparent}.VPNavBar[data-v-cb65f61d]:not(.has-sidebar):not(.home.top){background-color:var(--vp-nav-bg-color)}}.wrapper[data-v-cb65f61d]{padding:0 8px 0 24px}@media (min-width: 768px){.wrapper[data-v-cb65f61d]{padding:0 32px}}@media (min-width: 960px){.VPNavBar.has-sidebar .wrapper[data-v-cb65f61d]{padding:0}}.container[data-v-cb65f61d]{display:flex;justify-content:space-between;margin:0 auto;max-width:calc(var(--vp-layout-max-width) - 64px);height:var(--vp-nav-height);pointer-events:none}.container>.title[data-v-cb65f61d],.container>.content[data-v-cb65f61d]{pointer-events:none}.container[data-v-cb65f61d] *{pointer-events:auto}@media (min-width: 960px){.VPNavBar.has-sidebar .container[data-v-cb65f61d]{max-width:100%}}.title[data-v-cb65f61d]{flex-shrink:0;height:calc(var(--vp-nav-height) - 1px);transition:background-color .5s}@media (min-width: 960px){.VPNavBar.has-sidebar .title[data-v-cb65f61d]{position:absolute;top:0;left:0;z-index:2;padding:0 32px;width:var(--vp-sidebar-width);height:var(--vp-nav-height);background-color:transparent}}@media (min-width: 1440px){.VPNavBar.has-sidebar .title[data-v-cb65f61d]{padding-left:max(32px,calc((100% - (var(--vp-layout-max-width) - 64px)) / 2));width:calc((100% - (var(--vp-layout-max-width) - 64px)) / 2 + var(--vp-sidebar-width) - 32px)}}.content[data-v-cb65f61d]{flex-grow:1}@media (min-width: 960px){.VPNavBar.has-sidebar .content[data-v-cb65f61d]{position:relative;z-index:1;padding-right:32px;padding-left:var(--vp-sidebar-width)}}@media (min-width: 1440px){.VPNavBar.has-sidebar .content[data-v-cb65f61d]{padding-right:calc((100vw - var(--vp-layout-max-width)) / 2 + 32px);padding-left:calc((100vw - var(--vp-layout-max-width)) / 2 + var(--vp-sidebar-width))}}.content-body[data-v-cb65f61d]{display:flex;justify-content:flex-end;align-items:center;height:var(--vp-nav-height);transition:background-color .5s}@media (min-width: 960px){.VPNavBar:not(.home.top) .content-body[data-v-cb65f61d]{position:relative;background-color:var(--vp-nav-bg-color)}.VPNavBar:not(.has-sidebar):not(.home.top) .content-body[data-v-cb65f61d]{background-color:transparent}}@media (max-width: 767px){.content-body[data-v-cb65f61d]{column-gap:.5rem}}.menu+.translations[data-v-cb65f61d]:before,.menu+.appearance[data-v-cb65f61d]:before,.menu+.social-links[data-v-cb65f61d]:before,.translations+.appearance[data-v-cb65f61d]:before,.appearance+.social-links[data-v-cb65f61d]:before{margin-right:8px;margin-left:8px;width:1px;height:24px;background-color:var(--vp-c-divider);content:""}.menu+.appearance[data-v-cb65f61d]:before,.translations+.appearance[data-v-cb65f61d]:before{margin-right:16px}.appearance+.social-links[data-v-cb65f61d]:before{margin-left:16px}.social-links[data-v-cb65f61d]{margin-right:-8px}.divider[data-v-cb65f61d]{width:100%;height:1px}@media (min-width: 960px){.VPNavBar.has-sidebar .divider[data-v-cb65f61d]{padding-left:var(--vp-sidebar-width)}}@media (min-width: 1440px){.VPNavBar.has-sidebar .divider[data-v-cb65f61d]{padding-left:calc((100vw - var(--vp-layout-max-width)) / 2 + var(--vp-sidebar-width))}}.divider-line[data-v-cb65f61d]{width:100%;height:1px;transition:background-color .5s}.VPNavBar:not(.home) .divider-line[data-v-cb65f61d]{background-color:var(--vp-c-gutter)}@media (min-width: 960px){.VPNavBar:not(.home.top) .divider-line[data-v-cb65f61d]{background-color:var(--vp-c-gutter)}.VPNavBar:not(.has-sidebar):not(.home.top) .divider[data-v-cb65f61d]{background-color:var(--vp-c-gutter)}}.VPNavScreenAppearance[data-v-70a76bde]{display:flex;justify-content:space-between;align-items:center;border-radius:8px;padding:12px 14px 12px 16px;background-color:var(--vp-c-bg-soft)}.text[data-v-70a76bde]{line-height:24px;font-size:12px;font-weight:500;color:var(--vp-c-text-2)}.VPNavScreenMenuLink[data-v-2cea500d]{display:block;border-bottom:1px solid var(--vp-c-divider);padding:12px 0 11px;line-height:24px;font-size:14px;font-weight:500;color:var(--vp-c-text-1);transition:border-color .25s,color .25s}.VPNavScreenMenuLink[data-v-2cea500d]:hover{color:var(--vp-c-brand-1)}.VPNavScreenMenuGroupLink[data-v-d196ed44]{display:block;margin-left:12px;line-height:32px;font-size:14px;font-weight:400;color:var(--vp-c-text-1);transition:color .25s}.VPNavScreenMenuGroupLink[data-v-d196ed44]:hover{color:var(--vp-c-brand-1)}.VPNavScreenMenuGroupSection[data-v-a62d7f92]{display:block}.title[data-v-a62d7f92]{line-height:32px;font-size:13px;font-weight:700;color:var(--vp-c-text-2);transition:color .25s}.VPNavScreenMenuGroup[data-v-13bc299f]{border-bottom:1px solid var(--vp-c-divider);height:48px;overflow:hidden;transition:border-color .5s}.VPNavScreenMenuGroup .items[data-v-13bc299f]{visibility:hidden}.VPNavScreenMenuGroup.open .items[data-v-13bc299f]{visibility:visible}.VPNavScreenMenuGroup.open[data-v-13bc299f]{padding-bottom:10px;height:auto}.VPNavScreenMenuGroup.open .button[data-v-13bc299f]{padding-bottom:6px;color:var(--vp-c-brand-1)}.VPNavScreenMenuGroup.open .button-icon[data-v-13bc299f]{transform:rotate(45deg)}.button[data-v-13bc299f]{display:flex;justify-content:space-between;align-items:center;padding:12px 4px 11px 0;width:100%;line-height:24px;font-size:14px;font-weight:500;color:var(--vp-c-text-1);transition:color .25s}.button[data-v-13bc299f]:hover{color:var(--vp-c-brand-1)}.button-icon[data-v-13bc299f]{transition:transform .25s}.group[data-v-13bc299f]:first-child{padding-top:0}.group+.group[data-v-13bc299f],.group+.item[data-v-13bc299f]{padding-top:4px}.VPNavScreenTranslations[data-v-925440ed]{height:24px;overflow:hidden}.VPNavScreenTranslations.open[data-v-925440ed]{height:auto}.title[data-v-925440ed]{display:flex;align-items:center;font-size:14px;font-weight:500;color:var(--vp-c-text-1)}.icon[data-v-925440ed]{font-size:16px}.icon.lang[data-v-925440ed]{margin-right:8px}.icon.chevron[data-v-925440ed]{margin-left:4px}.list[data-v-925440ed]{padding:4px 0 0 24px}.link[data-v-925440ed]{line-height:32px;font-size:13px;color:var(--vp-c-text-1)}.VPNavScreen[data-v-9d48cc3b]{position:fixed;top:calc(var(--vp-nav-height) + var(--vp-layout-top-height, 0px));right:0;bottom:0;left:0;padding:0 32px;width:100%;background-color:var(--vp-nav-screen-bg-color);overflow-y:auto;transition:background-color .25s;pointer-events:auto}.VPNavScreen.fade-enter-active[data-v-9d48cc3b],.VPNavScreen.fade-leave-active[data-v-9d48cc3b]{transition:opacity .25s}.VPNavScreen.fade-enter-active .container[data-v-9d48cc3b],.VPNavScreen.fade-leave-active .container[data-v-9d48cc3b]{transition:transform .25s ease}.VPNavScreen.fade-enter-from[data-v-9d48cc3b],.VPNavScreen.fade-leave-to[data-v-9d48cc3b]{opacity:0}.VPNavScreen.fade-enter-from .container[data-v-9d48cc3b],.VPNavScreen.fade-leave-to .container[data-v-9d48cc3b]{transform:translateY(-8px)}@media (min-width: 768px){.VPNavScreen[data-v-9d48cc3b]{display:none}}.container[data-v-9d48cc3b]{margin:0 auto;padding:24px 0 96px;max-width:288px}.menu+.translations[data-v-9d48cc3b],.menu+.appearance[data-v-9d48cc3b],.translations+.appearance[data-v-9d48cc3b]{margin-top:24px}.menu+.social-links[data-v-9d48cc3b]{margin-top:16px}.appearance+.social-links[data-v-9d48cc3b]{margin-top:16px}.VPNav[data-v-21f5ce95]{position:relative;top:var(--vp-layout-top-height, 0px);left:0;z-index:var(--vp-z-index-nav);width:100%;pointer-events:none;transition:background-color .5s}@media (min-width: 960px){.VPNav[data-v-21f5ce95]{position:fixed}}.VPSidebarItem.level-0[data-v-ca8d42a6]{padding-bottom:24px}.VPSidebarItem.collapsed.level-0[data-v-ca8d42a6]{padding-bottom:10px}.item[data-v-ca8d42a6]{position:relative;display:flex;width:100%}.VPSidebarItem.collapsible>.item[data-v-ca8d42a6]{cursor:pointer}.indicator[data-v-ca8d42a6]{position:absolute;top:6px;bottom:6px;left:-17px;width:2px;border-radius:2px;transition:background-color .25s}.VPSidebarItem.level-2.is-active>.item>.indicator[data-v-ca8d42a6],.VPSidebarItem.level-3.is-active>.item>.indicator[data-v-ca8d42a6],.VPSidebarItem.level-4.is-active>.item>.indicator[data-v-ca8d42a6],.VPSidebarItem.level-5.is-active>.item>.indicator[data-v-ca8d42a6]{background-color:var(--vp-c-brand-1)}.link[data-v-ca8d42a6]{display:flex;align-items:center;flex-grow:1}.text[data-v-ca8d42a6]{flex-grow:1;padding:4px 0;line-height:24px;font-size:14px;transition:color .25s}.VPSidebarItem.level-0 .text[data-v-ca8d42a6]{font-weight:700;color:var(--vp-c-text-1)}.VPSidebarItem.level-1 .text[data-v-ca8d42a6],.VPSidebarItem.level-2 .text[data-v-ca8d42a6],.VPSidebarItem.level-3 .text[data-v-ca8d42a6],.VPSidebarItem.level-4 .text[data-v-ca8d42a6],.VPSidebarItem.level-5 .text[data-v-ca8d42a6]{font-weight:500;color:var(--vp-c-text-2)}.VPSidebarItem.level-0.is-link>.item>.link:hover .text[data-v-ca8d42a6],.VPSidebarItem.level-1.is-link>.item>.link:hover .text[data-v-ca8d42a6],.VPSidebarItem.level-2.is-link>.item>.link:hover .text[data-v-ca8d42a6],.VPSidebarItem.level-3.is-link>.item>.link:hover .text[data-v-ca8d42a6],.VPSidebarItem.level-4.is-link>.item>.link:hover .text[data-v-ca8d42a6],.VPSidebarItem.level-5.is-link>.item>.link:hover .text[data-v-ca8d42a6]{color:var(--vp-c-brand-1)}.VPSidebarItem.level-0.has-active>.item>.text[data-v-ca8d42a6],.VPSidebarItem.level-1.has-active>.item>.text[data-v-ca8d42a6],.VPSidebarItem.level-2.has-active>.item>.text[data-v-ca8d42a6],.VPSidebarItem.level-3.has-active>.item>.text[data-v-ca8d42a6],.VPSidebarItem.level-4.has-active>.item>.text[data-v-ca8d42a6],.VPSidebarItem.level-5.has-active>.item>.text[data-v-ca8d42a6],.VPSidebarItem.level-0.has-active>.item>.link>.text[data-v-ca8d42a6],.VPSidebarItem.level-1.has-active>.item>.link>.text[data-v-ca8d42a6],.VPSidebarItem.level-2.has-active>.item>.link>.text[data-v-ca8d42a6],.VPSidebarItem.level-3.has-active>.item>.link>.text[data-v-ca8d42a6],.VPSidebarItem.level-4.has-active>.item>.link>.text[data-v-ca8d42a6],.VPSidebarItem.level-5.has-active>.item>.link>.text[data-v-ca8d42a6]{color:var(--vp-c-text-1)}.VPSidebarItem.level-0.is-active>.item .link>.text[data-v-ca8d42a6],.VPSidebarItem.level-1.is-active>.item .link>.text[data-v-ca8d42a6],.VPSidebarItem.level-2.is-active>.item .link>.text[data-v-ca8d42a6],.VPSidebarItem.level-3.is-active>.item .link>.text[data-v-ca8d42a6],.VPSidebarItem.level-4.is-active>.item .link>.text[data-v-ca8d42a6],.VPSidebarItem.level-5.is-active>.item .link>.text[data-v-ca8d42a6]{color:var(--vp-c-brand-1)}.caret[data-v-ca8d42a6]{display:flex;justify-content:center;align-items:center;margin-right:-7px;width:32px;height:32px;color:var(--vp-c-text-3);cursor:pointer;transition:color .25s;flex-shrink:0}.item:hover .caret[data-v-ca8d42a6]{color:var(--vp-c-text-2)}.item:hover .caret[data-v-ca8d42a6]:hover{color:var(--vp-c-text-1)}.caret-icon[data-v-ca8d42a6]{font-size:18px;transform:rotate(90deg);transition:transform .25s}.VPSidebarItem.collapsed .caret-icon[data-v-ca8d42a6]{transform:rotate(0)}.VPSidebarItem.level-1 .items[data-v-ca8d42a6],.VPSidebarItem.level-2 .items[data-v-ca8d42a6],.VPSidebarItem.level-3 .items[data-v-ca8d42a6],.VPSidebarItem.level-4 .items[data-v-ca8d42a6],.VPSidebarItem.level-5 .items[data-v-ca8d42a6]{border-left:1px solid var(--vp-c-divider);padding-left:16px}.VPSidebarItem.collapsed .items[data-v-ca8d42a6]{display:none}.no-transition[data-v-4fb3f82c] .caret-icon{transition:none}.group+.group[data-v-4fb3f82c]{border-top:1px solid var(--vp-c-divider);padding-top:10px}@media (min-width: 960px){.group[data-v-4fb3f82c]{padding-top:10px;width:calc(var(--vp-sidebar-width) - 64px)}}.VPSidebar[data-v-7fee7a11]{position:fixed;top:var(--vp-layout-top-height, 0px);bottom:0;left:0;z-index:var(--vp-z-index-sidebar);padding:32px 32px 96px;width:calc(100vw - 64px);max-width:320px;background-color:var(--vp-sidebar-bg-color);opacity:0;box-shadow:var(--vp-c-shadow-3);overflow-x:hidden;overflow-y:auto;transform:translate(-100%);transition:opacity .5s,transform .25s ease;overscroll-behavior:contain}.VPSidebar.open[data-v-7fee7a11]{opacity:1;visibility:visible;transform:translate(0);transition:opacity .25s,transform .5s cubic-bezier(.19,1,.22,1)}.dark .VPSidebar[data-v-7fee7a11]{box-shadow:var(--vp-shadow-1)}@media (min-width: 960px){.VPSidebar[data-v-7fee7a11]{padding-top:var(--vp-nav-height);width:var(--vp-sidebar-width);max-width:100%;background-color:var(--vp-sidebar-bg-color);opacity:1;visibility:visible;box-shadow:none;transform:translate(0)}}@media (min-width: 1440px){.VPSidebar[data-v-7fee7a11]{padding-left:max(32px,calc((100% - (var(--vp-layout-max-width) - 64px)) / 2));width:calc((100% - (var(--vp-layout-max-width) - 64px)) / 2 + var(--vp-sidebar-width) - 32px)}}@media (min-width: 960px){.curtain[data-v-7fee7a11]{position:sticky;top:-64px;left:0;z-index:1;margin-top:calc(var(--vp-nav-height) * -1);margin-right:-32px;margin-left:-32px;height:var(--vp-nav-height);background-color:var(--vp-sidebar-bg-color)}}.nav[data-v-7fee7a11]{outline:0}.VPSkipLink[data-v-f3ab029e]{top:8px;left:8px;padding:8px 16px;z-index:999;border-radius:8px;font-size:12px;font-weight:700;text-decoration:none;color:var(--vp-c-brand-1);box-shadow:var(--vp-shadow-3);background-color:var(--vp-c-bg)}.VPSkipLink[data-v-f3ab029e]:focus{height:auto;width:auto;clip:auto;clip-path:none}@media (min-width: 1280px){.VPSkipLink[data-v-f3ab029e]{top:14px;left:16px}}.Layout[data-v-a5ebdd2e]{display:flex;flex-direction:column;min-height:100vh}.VPHomeSponsors[data-v-a0249031]{border-top:1px solid var(--vp-c-gutter);padding-top:88px!important}.VPHomeSponsors[data-v-a0249031]{margin:96px 0}@media (min-width: 768px){.VPHomeSponsors[data-v-a0249031]{margin:128px 0}}.VPHomeSponsors[data-v-a0249031]{padding:0 24px}@media (min-width: 768px){.VPHomeSponsors[data-v-a0249031]{padding:0 48px}}@media (min-width: 960px){.VPHomeSponsors[data-v-a0249031]{padding:0 64px}}.container[data-v-a0249031]{margin:0 auto;max-width:1152px}.love[data-v-a0249031]{margin:0 auto;width:fit-content;font-size:28px;color:var(--vp-c-text-3)}.icon[data-v-a0249031]{display:inline-block}.message[data-v-a0249031]{margin:0 auto;padding-top:10px;max-width:320px;text-align:center;line-height:24px;font-size:16px;font-weight:500;color:var(--vp-c-text-2)}.sponsors[data-v-a0249031]{padding-top:32px}.action[data-v-a0249031]{padding-top:40px;text-align:center}.VPTeamPage[data-v-03e97851]{margin:96px 0}@media (min-width: 768px){.VPTeamPage[data-v-03e97851]{margin:128px 0}}.VPHome .VPTeamPageTitle[data-v-03e97851-s]{border-top:1px solid var(--vp-c-gutter);padding-top:88px!important}.VPTeamPageSection+.VPTeamPageSection[data-v-03e97851-s],.VPTeamMembers+.VPTeamPageSection[data-v-03e97851-s]{margin-top:64px}.VPTeamMembers+.VPTeamMembers[data-v-03e97851-s]{margin-top:24px}@media (min-width: 768px){.VPTeamPageTitle+.VPTeamPageSection[data-v-03e97851-s]{margin-top:16px}.VPTeamPageSection+.VPTeamPageSection[data-v-03e97851-s],.VPTeamMembers+.VPTeamPageSection[data-v-03e97851-s]{margin-top:96px}}.VPTeamMembers[data-v-03e97851-s]{padding:0 24px}@media (min-width: 768px){.VPTeamMembers[data-v-03e97851-s]{padding:0 48px}}@media (min-width: 960px){.VPTeamMembers[data-v-03e97851-s]{padding:0 64px}}.VPTeamPageTitle[data-v-eb5fc163]{padding:48px 32px;text-align:center}@media (min-width: 768px){.VPTeamPageTitle[data-v-eb5fc163]{padding:64px 48px 48px}}@media (min-width: 960px){.VPTeamPageTitle[data-v-eb5fc163]{padding:80px 64px 48px}}.title[data-v-eb5fc163]{letter-spacing:0;line-height:44px;font-size:36px;font-weight:500}@media (min-width: 768px){.title[data-v-eb5fc163]{letter-spacing:-.5px;line-height:56px;font-size:48px}}.lead[data-v-eb5fc163]{margin:0 auto;max-width:512px;padding-top:12px;line-height:24px;font-size:16px;font-weight:500;color:var(--vp-c-text-2)}@media (min-width: 768px){.lead[data-v-eb5fc163]{max-width:592px;letter-spacing:.15px;line-height:28px;font-size:20px}}.VPTeamPageSection[data-v-c69cbb4c]{padding:0 32px}@media (min-width: 768px){.VPTeamPageSection[data-v-c69cbb4c]{padding:0 48px}}@media (min-width: 960px){.VPTeamPageSection[data-v-c69cbb4c]{padding:0 64px}}.title[data-v-c69cbb4c]{position:relative;margin:0 auto;max-width:1152px;text-align:center;color:var(--vp-c-text-2)}.title-line[data-v-c69cbb4c]{position:absolute;top:16px;left:0;width:100%;height:1px;background-color:var(--vp-c-divider)}.title-text[data-v-c69cbb4c]{position:relative;display:inline-block;padding:0 24px;letter-spacing:0;line-height:32px;font-size:20px;font-weight:500;background-color:var(--vp-c-bg)}.lead[data-v-c69cbb4c]{margin:0 auto;max-width:480px;padding-top:12px;text-align:center;line-height:24px;font-size:16px;font-weight:500;color:var(--vp-c-text-2)}.members[data-v-c69cbb4c]{padding-top:40px}.VPTeamMembersItem[data-v-7c7d4603]{display:flex;flex-direction:column;gap:2px;border-radius:12px;width:100%;height:100%;overflow:hidden}.VPTeamMembersItem.small .profile[data-v-7c7d4603]{padding:32px}.VPTeamMembersItem.small .data[data-v-7c7d4603]{padding-top:20px}.VPTeamMembersItem.small .avatar[data-v-7c7d4603]{width:64px;height:64px}.VPTeamMembersItem.small .name[data-v-7c7d4603]{line-height:24px;font-size:16px}.VPTeamMembersItem.small .affiliation[data-v-7c7d4603]{padding-top:4px;line-height:20px;font-size:14px}.VPTeamMembersItem.small .desc[data-v-7c7d4603]{padding-top:12px;line-height:20px;font-size:14px}.VPTeamMembersItem.small .links[data-v-7c7d4603]{margin:0 -16px -20px;padding:10px 0 0}.VPTeamMembersItem.medium .profile[data-v-7c7d4603]{padding:48px 32px}.VPTeamMembersItem.medium .data[data-v-7c7d4603]{padding-top:24px;text-align:center}.VPTeamMembersItem.medium .avatar[data-v-7c7d4603]{width:96px;height:96px}.VPTeamMembersItem.medium .name[data-v-7c7d4603]{letter-spacing:.15px;line-height:28px;font-size:20px}.VPTeamMembersItem.medium .affiliation[data-v-7c7d4603]{padding-top:4px;font-size:16px}.VPTeamMembersItem.medium .desc[data-v-7c7d4603]{padding-top:16px;max-width:288px;font-size:16px}.VPTeamMembersItem.medium .links[data-v-7c7d4603]{margin:0 -16px -12px;padding:16px 12px 0}.profile[data-v-7c7d4603]{flex-grow:1;background-color:var(--vp-c-bg-soft)}.data[data-v-7c7d4603]{text-align:center}.avatar[data-v-7c7d4603]{position:relative;flex-shrink:0;margin:0 auto;border-radius:50%;box-shadow:var(--vp-shadow-3)}.avatar-img[data-v-7c7d4603]{position:absolute;top:0;right:0;bottom:0;left:0;border-radius:50%;object-fit:cover}.name[data-v-7c7d4603]{margin:0;font-weight:600}.affiliation[data-v-7c7d4603]{margin:0;font-weight:500;color:var(--vp-c-text-2)}.org.link[data-v-7c7d4603]{color:var(--vp-c-text-2);transition:color .25s}.org.link[data-v-7c7d4603]:hover{color:var(--vp-c-brand-1)}.desc[data-v-7c7d4603]{margin:0 auto}.desc[data-v-7c7d4603] a{font-weight:500;color:var(--vp-c-brand-1);text-decoration-style:dotted;transition:color .25s}.links[data-v-7c7d4603]{display:flex;justify-content:center;height:56px}.sp-link[data-v-7c7d4603]{display:flex;justify-content:center;align-items:center;text-align:center;padding:16px;font-size:14px;font-weight:500;color:var(--vp-c-sponsor);background-color:var(--vp-c-bg-soft);transition:color .25s,background-color .25s}.sp .sp-link.link[data-v-7c7d4603]:hover,.sp .sp-link.link[data-v-7c7d4603]:focus{outline:none;color:var(--vp-c-white);background-color:var(--vp-c-sponsor)}.sp-icon[data-v-7c7d4603]{margin-right:8px;font-size:16px}.VPTeamMembers.small .container[data-v-d6b2c90b]{grid-template-columns:repeat(auto-fit,minmax(224px,1fr))}.VPTeamMembers.small.count-1 .container[data-v-d6b2c90b]{max-width:276px}.VPTeamMembers.small.count-2 .container[data-v-d6b2c90b]{max-width:576px}.VPTeamMembers.small.count-3 .container[data-v-d6b2c90b]{max-width:876px}.VPTeamMembers.medium .container[data-v-d6b2c90b]{grid-template-columns:repeat(auto-fit,minmax(256px,1fr))}@media (min-width: 375px){.VPTeamMembers.medium .container[data-v-d6b2c90b]{grid-template-columns:repeat(auto-fit,minmax(288px,1fr))}}.VPTeamMembers.medium.count-1 .container[data-v-d6b2c90b]{max-width:368px}.VPTeamMembers.medium.count-2 .container[data-v-d6b2c90b]{max-width:760px}.container[data-v-d6b2c90b]{display:grid;gap:24px;margin:0 auto;max-width:1152px}:root{--vp-font-family-base: Merriweather, serif, "Inter var experimental", "Inter var", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;--vp-font-family-mono: Menlo, Monaco, "JetBrains Mono", "Fira Code", Consolas, "Courier New", monospace}:root{--Aya-Keyword: #ff6d00;--Aya-Generalized: #8b5d5d;--Aya-Fn: #005dac;--Aya-Primitive: #005dac;--Aya-Data: #218c21;--Aya-Constructor: #a021ef;--Aya-Struct: #218c21;--Aya-Field: #a021ef;--Aya-PlainText: var(--vp-c-text-1);--Aya-HoverBg: #edebfc}.dark{--Aya-Keyword: #ff6d00;--Aya-Generalized: #ffbfbf;--Aya-Fn: #79c0ff;--Aya-Primitive: #79c0ff;--Aya-Data: #33d333;--Aya-Constructor: #d2a8ff;--Aya-Struct: #33d333;--Aya-Field: #d2a8ff;--Aya-PlainText: var(--vp-c-text-1);--Aya-HoverBg: #344134}.Aya a[href]:hover,.Aya [href].hover-highlight{background-color:var(--Aya-HoverBg)!important}.Aya a{color:var(--Aya-PlainText)}.Aya .Fn{color:var(--Aya-Fn)}.Aya .Constructor{color:var(--Aya-Constructor)}.Aya .Struct{color:var(--Aya-Struct)}.Aya .Generalized{color:var(--Aya-Generalized)}.Aya .Data{color:var(--Aya-Data)}.Aya .Primitive{color:var(--Aya-Primitive)}.Aya .Keyword{font-weight:700;color:var(--Aya-Keyword)}.Aya .Field{color:var(--Aya-Field)}:root{--vp-c-accent: #DB5A6B;--vp-c-brand: #DB5A6B;--vp-c-brand-light: #DB5A6B;--vp-c-brand-lighter: #DB5A6B;--vp-c-brand-dark: #DB5A6B;--vp-c-brand-darker: #DB5A6B}.dark{--vp-code-block-bg: rgba(0,0,0,.2);--vp-c-text-code: #c0cec0;--vp-custom-block-tip-text: rgb(18, 181, 157);--vp-custom-block-tip-border: rgba(18, 181, 157, .5);--vp-custom-block-tip-bg: rgba(18, 181, 157, .1);--vp-c-text-dark-2: rgba(235, 235, 235, .6)}:root{--vp-button-brand-border: var(--vp-c-brand-light);--vp-button-brand-text: var(--vp-c-text-dark-1);--vp-button-brand-bg: var(--vp-c-brand);--vp-button-brand-hover-border: var(--vp-c-brand-light);--vp-button-brand-hover-text: var(--vp-c-text-dark-1);--vp-button-brand-hover-bg: var(--vp-c-brand-light);--vp-button-brand-active-border: var(--vp-c-brand-light);--vp-button-brand-active-text: var(--vp-c-text-dark-1);--vp-button-brand-active-bg: var(--vp-button-brand-bg)}:root{--vp-home-hero-name-color: transparent;--vp-home-hero-name-background: -webkit-linear-gradient( 120deg, #DB5A6B 30%, #edd532 )}.tagline{color:#fff!important}@media (min-width: 640px){:root{--vp-home-hero-image-filter: blur(56px)}}@media (min-width: 960px){:root{--vp-home-hero-image-filter: blur(72px)}}.DocSearch{--docsearch-primary-color: var(--vp-c-brand) !important}.header-img[data-v-26586a7a]{position:absolute;top:var(--vp-nav-height);width:100%;height:100vh;filter:brightness(50%);background-image:url(/header.jpg);background-size:cover;background-position:left}.header-img-copyright[data-v-26586a7a]{position:absolute;bottom:10px;right:10px;opacity:.5;color:#fff;font-size:10px}.spacer[data-v-26586a7a]{position:relative;top:0;left:0}.VPLocalSearchBox[data-v-2eb8502c]{position:fixed;z-index:100;top:0;right:0;bottom:0;left:0;display:flex}.backdrop[data-v-2eb8502c]{position:absolute;top:0;right:0;bottom:0;left:0;background:var(--vp-backdrop-bg-color);transition:opacity .5s}.shell[data-v-2eb8502c]{position:relative;padding:12px;margin:64px auto;display:flex;flex-direction:column;gap:16px;background:var(--vp-local-search-bg);width:min(100vw - 60px,900px);height:min-content;max-height:min(100vh - 128px,900px);border-radius:6px}@media (max-width: 767px){.shell[data-v-2eb8502c]{margin:0;width:100vw;height:100vh;max-height:none;border-radius:0}}.search-bar[data-v-2eb8502c]{border:1px solid var(--vp-c-divider);border-radius:4px;display:flex;align-items:center;padding:0 12px;cursor:text}@media (max-width: 767px){.search-bar[data-v-2eb8502c]{padding:0 8px}}.search-bar[data-v-2eb8502c]:focus-within{border-color:var(--vp-c-brand-1)}.local-search-icon[data-v-2eb8502c]{display:block;font-size:18px}.navigate-icon[data-v-2eb8502c]{display:block;font-size:14px}.search-icon[data-v-2eb8502c]{margin:8px}@media (max-width: 767px){.search-icon[data-v-2eb8502c]{display:none}}.search-input[data-v-2eb8502c]{padding:6px 12px;font-size:inherit;width:100%}@media (max-width: 767px){.search-input[data-v-2eb8502c]{padding:6px 4px}}.search-actions[data-v-2eb8502c]{display:flex;gap:4px}@media (any-pointer: coarse){.search-actions[data-v-2eb8502c]{gap:8px}}@media (min-width: 769px){.search-actions.before[data-v-2eb8502c]{display:none}}.search-actions button[data-v-2eb8502c]{padding:8px}.search-actions button[data-v-2eb8502c]:not([disabled]):hover,.toggle-layout-button.detailed-list[data-v-2eb8502c]{color:var(--vp-c-brand-1)}.search-actions button.clear-button[data-v-2eb8502c]:disabled{opacity:.37}.search-keyboard-shortcuts[data-v-2eb8502c]{font-size:.8rem;opacity:75%;display:flex;flex-wrap:wrap;gap:16px;line-height:14px}.search-keyboard-shortcuts span[data-v-2eb8502c]{display:flex;align-items:center;gap:4px}@media (max-width: 767px){.search-keyboard-shortcuts[data-v-2eb8502c]{display:none}}.search-keyboard-shortcuts kbd[data-v-2eb8502c]{background:#8080801a;border-radius:4px;padding:3px 6px;min-width:24px;display:inline-block;text-align:center;vertical-align:middle;border:1px solid rgba(128,128,128,.15);box-shadow:0 2px 2px #0000001a}.results[data-v-2eb8502c]{display:flex;flex-direction:column;gap:6px;overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain}.result[data-v-2eb8502c]{display:flex;align-items:center;gap:8px;border-radius:4px;transition:none;line-height:1rem;border:solid 2px var(--vp-local-search-result-border);outline:none}.result>div[data-v-2eb8502c]{margin:12px;width:100%;overflow:hidden}@media (max-width: 767px){.result>div[data-v-2eb8502c]{margin:8px}}.titles[data-v-2eb8502c]{display:flex;flex-wrap:wrap;gap:4px;position:relative;z-index:1001;padding:2px 0}.title[data-v-2eb8502c]{display:flex;align-items:center;gap:4px}.title.main[data-v-2eb8502c]{font-weight:500}.title-icon[data-v-2eb8502c]{opacity:.5;font-weight:500;color:var(--vp-c-brand-1)}.title svg[data-v-2eb8502c]{opacity:.5}.result.selected[data-v-2eb8502c]{--vp-local-search-result-bg: var(--vp-local-search-result-selected-bg);border-color:var(--vp-local-search-result-selected-border)}.excerpt-wrapper[data-v-2eb8502c]{position:relative}.excerpt[data-v-2eb8502c]{opacity:50%;pointer-events:none;max-height:140px;overflow:hidden;position:relative;margin-top:4px}.result.selected .excerpt[data-v-2eb8502c]{opacity:1}.excerpt[data-v-2eb8502c] *{font-size:.8rem!important;line-height:130%!important}.titles[data-v-2eb8502c] mark,.excerpt[data-v-2eb8502c] mark{background-color:var(--vp-local-search-highlight-bg);color:var(--vp-local-search-highlight-text);border-radius:2px;padding:0 2px}.excerpt[data-v-2eb8502c] .vp-code-group .tabs{display:none}.excerpt[data-v-2eb8502c] .vp-code-group div[class*=language-]{border-radius:8px!important}.excerpt-gradient-bottom[data-v-2eb8502c]{position:absolute;bottom:-1px;left:0;width:100%;height:8px;background:linear-gradient(transparent,var(--vp-local-search-result-bg));z-index:1000}.excerpt-gradient-top[data-v-2eb8502c]{position:absolute;top:-1px;left:0;width:100%;height:8px;background:linear-gradient(var(--vp-local-search-result-bg),transparent);z-index:1000}.result.selected .titles[data-v-2eb8502c],.result.selected .title-icon[data-v-2eb8502c]{color:var(--vp-c-brand-1)!important}.no-results[data-v-2eb8502c]{font-size:.9rem;text-align:center;padding:12px}svg[data-v-2eb8502c]{flex:none} diff --git a/blog/binops.html b/blog/binops.html new file mode 100644 index 0000000..03b198d --- /dev/null +++ b/blog/binops.html @@ -0,0 +1,39 @@ + + + + + + Binary operators in Aya | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Binary operators in Aya

We have designed a binary operator system in Aya which happens to be (we didn't copy!) very similar to Rhombus (a.k.a. Racket 2) and Swift 5.7.

TL;DR: it supports making any identifier a custom operator with precedences specified by a partial ordering. Left and right associativities are supported.

The precedence and associativity information is bound to a name, not a definition. This means we can import a name from another module with changes to its name, associativity, and precedence. Importing with renaming is an established feature, but changing associativity and precedence is not that popular (though implemented in Agda already).

Here are some code examples (implementations are omitted for simplicity):

-- Left-associative
+def infixl + (x y : Nat) : Nat => {??}
+-- Left-associative, bind tighter than +
+def infixl * (x y : Nat) : Nat => {??} tighter +
+-- Prefix operator
+def fixl ! (x : Nat) : Nat => {??}
+-- Postfix operator
+def fixr ? (x : Nat) : Nat => {??}

The tighter keyword works like this: when there are expressions like a * b + c which may either mean (a * b) + c or a * (b + c), we will put the tighter operator in the parenthesis. In case we found the two operators share the same priority, Aya will report an error.

With imports, it looks like this:

open import Primitives using (
+  invol       as fixl  ~  tighter =, \/, /\,
+  intervalMin as infix /\ tighter \/,
+  intervalMax as infix \/,
+)

Specifying operator precedences with a partial ordering is way better than with a number. In Haskell, if we already have infix 3 + and infix 4 * and we hope to add a new operator which has higher precedence than + but lower than *, it's going to be impossible. Agda introduced float-point precedence levels to address the issue, but I think it does not solve the essential problem: that I have to lookup the numbers (of existing operator precedences) every time I write a new operator.

In the future, we plan to support mixfix operators as in Agda (the current framework can support mixfix easily, but abusing mixfix notations can harm readability).

+ + + + \ No newline at end of file diff --git a/blog/bye-hott.html b/blog/bye-hott.html new file mode 100644 index 0000000..79db443 --- /dev/null +++ b/blog/bye-hott.html @@ -0,0 +1,28 @@ + + + + + + Moving away from univalent type theory | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Moving away from univalent type theory

Aya is now moving away from univalent type theory.

Note that this does not mean we are moving away from cubical type theory -- we are trying to adapt an extensional version cubical type theory, called XTT, which is a cubical approach towards observational equality (the idea is due to Altenkirch and McBride): the equality type a =_A b is no longer defined uniformly for all types A, but rather defined by assuming a closed (inductive-recursive) universe, and defining a type family (A : Type) -> A -> A -> Type by casing on what A is. For function types, we can define it as pointwise equality, which makes function extensionality true by definition.

In case of cubical, this is automatic, due to how path types are defined.

The reference for XTT can be found in the paper A Cubical Language for Bishop Sets by Sterling, Angiuli, and Gratzer. This paper has a previous version which has a universe hierarchy, called Cubical Syntax for Reflection-Free Extensional Equality, by the same authors.

We plan to use XTT as the basis for Aya's type theory. We will change the following in v0.30 Aya:

  1. We will implement a universe à la Tarski to reuse the type checking of subtypes and paths.
  2. The impredicative Prop universe will be removed due to the complications it caused.
  3. The binding representation will be changed to locally nameless. By that we can make closed term completely serializable.
  4. We will try to implement definition-level controlling unfolding. This has a several advantages: the type checking order of bodies can be inferred from the annotations, and we can detect more cycles instead of reporting errors due to not being able to unfold unchecked function.
  5. We wish to remove implicitness information from core terms, and keep them a feature related to function calls. Π\Pi-types should not know the name of the parameter, which is natural due to α\alpha-equality. This means named arguments will only work for direct function calls.

Yes, the last two items indicate a major change in the implementation of Aya, which is essentially a rewrite of the type checker. We took this chance to revisit a couple of old issues and fix them. Currently, we have suceeded in extracting a Java module for the syntax definition from the type checker module, which will benefit third-party libraries who want to deal with serialized Aya terms.

We will not adapt the following features from XTT:

  1. Partial elements are first-class citizens, i.e. they have manifest "cubical" phases. Instead we will have first class total elements and use a Partial type to represent partial elements.
  2. Intervals are not types. We will adapt the 2LTT-style solution from Cubical Agda, which has some universes to classify exo-types.
  3. The type-case operator will remain internal to the type checker. While this might be useful in the future development related to metaprogramming, we do not see any immediate use for it except for implementing the computation of generalized coercion.
  4. As we already said, we do not intend to add an impredicative Prop universe, while the XTT paper said they intend to add it. We encourage the users to embrace the axiom of propositional resizing, which makes not just Props to be impredicative, but also all h-props (e.g. types that are provably props) to be impredicative.

The development is still in a private work-in-progress repository, which we will open-source and be ported to the main repo once we can compile this website with the new type checker, which implies complete support for inductive types except for the positivity checker.

We will also have to rewrite some guides about higher inductive types, and instead use some quotient type examples.

From that, we will start considering support for classes with extensions, and try to formalize some mathematics and do some real-world programming with Aya, partially bootstrapping the type checker.

Stay tuned!

+ + + + \ No newline at end of file diff --git a/blog/class-defeq.html b/blog/class-defeq.html new file mode 100644 index 0000000..100f7dc --- /dev/null +++ b/blog/class-defeq.html @@ -0,0 +1,39 @@ + + + + + + Class extension with definitional projection | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Class extension with definitional projection

We want a class system with the following basic capabilities:

  • Classes can be extended with new fields (similar to extends in Java).
  • Multiple inheritance is possible, because we can detect conflicts, and in case that really happens, we reject it.
  • Subtyping is available and uses coercion. This will be discussed in another post.

To add more flexibility to it, we want the following feature.

Anonymous extensions

Suppose we have a class Precat for precategories (written in pseudocode):

class Precat
+| Ob : Type
+| Hom : Ob -> Ob -> Type
+| Hom-set (A B : Ob) : isSet (Hom A B)
+| id (A : Ob) : Hom A A
+| ....

Suppose the syntax for creating an instance of a class is new Precat { Ob := .., Hom := .., ... }. I want the following:

  • Precat is the type for all instances of the class Precat.
  • Precat { Ob := Group } is the type for all instances of the class Precat whose Ob field is (definitionally) Group.
  • Precat { Ob := Group, Hom := GroupHom } is the type for all instances of the class Precat whose Ob field is Group and Hom field is GroupHom.
  • etc.

This is called anonymous class extension, already implemented in the Arend language. As a syntactic sugar, we may write Precat { Ob := Group } as Precat Group, where the application is ordered the same as the fields in the class definition.

Definitional projection

We further want definitional projection:

  • Suppose A : Precat Group, then A.Ob is definitionally equal to Group.
  • Suppose A : Precat Group GroupHom, then A.Hom is definitionally equal to GroupHom.

This concludes the basic features of the class system. To implement this, it may seem that we need to have access to types in the normalizer, which makes it very heavy (in contrast to the lightweight normalizer you can have for plain MLTT).

Implementation

A uniform implementation of this definitional projection requires the definitional equality to commute with substitution, say, we may have

A:PrecatA.Ob:U{A : \text{Precat} ⊢ A.\text{Ob} : \mathcal U}

This is a normal form. Then, we have Grp : Precat Group (so Grp.Ob is definitionally equal to Group), and we may perform the substitution [Grp/A][\text{Grp} / \text{A}] on the above normal form:

Grp:Precat GroupGrp.Ob:U\text{Grp} : \text{Precat}~\text{Group} ⊢ \text{Grp}.\text{Ob} : \mathcal U

We want the above to be equal to Group as well. Without access to contexts, it seems really hard!

Here's a trick: whenever we see A : Precat Group, we elaborate it into (the idea is similar to an η-expansion):

A ==> new Precat
+  { Ob := Group
+  , Hom := A.Hom
+  , Hom-set := A.Hom-set
+  , id := A.id
+  , ...
+  }

By that, we will never have A.Ob in the source language, because it always gets elaborated into Group directly. In case we partially know about A from the type, we really elaborate the type information right into the core term. So, we don't even have a chance to touch the bare A (not being projected) in the core language, and anything of a class type is always in an introduction form.

This should implement the definitional projection feature without even modifying the MLTT normalizer.

The idea of this feature comes from the treatment of extension types inspired from cooltt, see relevant post.

+ + + + \ No newline at end of file diff --git a/blog/extended-pruning.html b/blog/extended-pruning.html new file mode 100644 index 0000000..ffd9fa6 --- /dev/null +++ b/blog/extended-pruning.html @@ -0,0 +1,78 @@ + + + + + + Extended pruning for pattern unification | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Extended pruning for pattern unification

prim I
+prim Path (A : IType) (a : A 0) (b : A 1) : Type
+

The vanilla pattern unification is very limited. Consider:

 Path (fn iVec (+-assoc i) A)
+      ((xs ++ ys) ++ zs)
+      (xs ++ (ys ++ zs))
+

This is the equality between two sized vectors: (xs ++ (ys ++ zs)) and ((xs ++ ys) ++ zs), the left hand side has type Vec (xs.size ++ (ys.size ++ zs.size)) A, and the right hand side has type Vec ((xs.size ++ ys.size) ++ zs.size).

So, the equality type is heterogeneous, and I introduce a type Vec (+-assoc i) A for it, where +-assoc is the associativity.

So this should type check, right? But pattern unification fails! I've left the two sides of +-assoc implicit, so I'm supposed to infer what numbers' associativity I care about, using pattern unification.

Then, pattern unification fails because the constraints are generated from cubical boundaries, where the "interval" variable is substituted to its sides. So, we have this type (the Path is called PathP in Agda):

Γ ­⊢ Path (fn i => Vec (+-assoc i) Nat) vecA vecB

Note the type of +-assoc is Fn (o p q : Nat) → ((o + p) + q) = (o + (p + q)).

So elaboration inserts metavariables:

Γ ­⊢ Path (fn i => Vec (+-assoc {?} {?} {?} i) Nat) vecA vecB

Where these metavariables have the following scope:

Γ , i : I ­⊢ ? : Nat

Note that the i : I binding is in-scope. So the metavariables with their spines added together becomes:

Γ ­⊢ Path (fn i => Vec (+-assoc {?a Γ i} {?b Γ i} {?c Γ i} i) Nat) vecA vecB

Then, we get the following tycking problems, according to the rules of Path:

vecA : Vec (+-assoc {?a Γ 0} {?b Γ 0} {?c Γ 0} 0) Nat
+vecB : Vec (+-assoc {?a Γ 1} {?b Γ 1} {?c Γ 1} 1) Nat

Look at the spines of all of these metavariables. None of them are in pattern fragment. So every equality constraint cannot be solved by pattern, because they're always equality after a substitution!

This can be solved by further extending your algorithm with pruning or a constraint system with a "lax" mode of solving metas when your equations rely essentially on non-pattern equations, but I feel it has defeated the point of finding the most general solution, which I used to believe to be the purpose of pattern unification....

Case Study

Right now Aya will try to prune these non-pattern arguments out and try to solve them. This obviously generates non-unique solutions, but I think it will be useful in practice.

In Agda, the following code is in the library:

++-assoc : ∀ {m n k} (xs : Vec A m) (ys : Vec A n) (zs : Vec A k) →
+          PathP (λ i → Vec A (+-assoc m n k (~ i)))
+          ((xs ++ ys) ++ zs) (xs ++ ys ++ zs)
+++-assoc {m = zero} [] ys zs = refl
+++-assoc {m = suc m} (x ∷ xs) ys zs i = x ∷ ++-assoc xs ys zs i

However, if we replace the m with _, Agda will fail with the following error:

Failed to solve the following constraints:
+  _41 (xs = (x ∷ xs)) (ys = ys) (zs = zs) = x ∷ ++-assoc xs ys zs i1
+    : Vec A
+      (+-assoc (_m_39 (xs = (x ∷ xs)) (ys = ys) (zs = zs) (i = i1)) n k
+       (~ i1))
+    (blocked on any(_41, _57))
+  _40 (xs = (x ∷ xs)) (ys = ys) (zs = zs) = x ∷ ++-assoc xs ys zs i0
+    : Vec A
+      (+-assoc (_m_39 (xs = (x ∷ xs)) (ys = ys) (zs = zs) (i = i0)) n k
+       (~ i0))
+    (blocked on any(_40, _57))
+  +-assoc (_m_39 (xs = xs) (ys = ys) (zs = zs) (i = i)) n k (~ i)
+    = _n_49
+    : ℕ
+    (blocked on _n_49)
+  +-assoc (_m_39 (xs = (x ∷ xs)) (ys = ys) (zs = zs) (i = i)) n k
+  (~ i)
+    = ℕ.suc _n_49
+    : ℕ
+    (blocked on _m_39)
+  _40 (xs = []) (ys = ys) (zs = zs)
+    = _41 (xs = []) (ys = ys) (zs = zs)
+    : _x.A_43
+    (blocked on any(_40, _41))
+  _x.A_43
+    = Vec A
+      (+-assoc (_m_39 (xs = []) (ys = ys) (zs = zs) (i = i)) n k (~ i))
+    : Type
+    (blocked on _x.A_43)
+  _m_39 (i = i0) = m : ℕ (blocked on _m_39)
+  _m_39 (i = i1) + (n + k) = m + (n + k) : ℕ (blocked on _m_39)

In Aya, this will raise the following warning:

  6 │       def ++-assoc-type (xs : Vec n A) (ys : Vec m A) (zs : Vec o A)
+  7 │         => Path (fn i => Vec (+-assoc i) A)
+  8 │         (xs ++ (ys ++ zs))
+    │          ╰──────────────╯ ?a n A m o xs ys zs 0 >= n, ?b n A m o xs ys zs 0 >= m,
+                                ?c n A m o xs ys zs 0 >= o
+  9 │         ((xs ++ ys) ++ zs)
+    │          ╰──────────────╯
+    │          ╰──────────────╯ ?a n A m o xs ys zs 1 >= n, ?b n A m o xs ys zs 1 >= m,
+                                ?c n A m o xs ys zs 1 >= o
+
+Info: Solving equation(s) with not very general solution(s)

The inline equations are the type checking problems that Aya did something bad to solve.

Conor McBride told me pattern unification is a good algorithm, but the problem of interest might not be what we think it is. It is good for undergraduate induction, i.e. the object being induct on is a variable, and the motive of such induction is pattern. This is an enlightening perspective! But now that we have more problems, I think we might want to extend it. Just think about how many people use --lossy-unification in Agda.

+ + + + \ No newline at end of file diff --git a/blog/ind-prop.html b/blog/ind-prop.html new file mode 100644 index 0000000..c4e57bf --- /dev/null +++ b/blog/ind-prop.html @@ -0,0 +1,45 @@ + + + + + + Impredicative Props are hard | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Impredicative Props are hard

Throughout this blog post, I will use the term Prop to mean the type of propositions, which does not have to be strict, but has the property that it cannot eliminate to Type.

Motivation

Long time ago I wrote a PASE question regarding definitional irrelevance. An important pro of Prop in my opinion is that it is more convenient to be turned impredicative. Mathematicians want impredicativity for various reasons, one thing being that it is natural to have a proposition being a quantification over types, which I think is true.

Now I want to point out several reasons to avoid Prop and impredicativity based on Prop. Note that I'm not asking you to get rid of impredicativity in general!

Ad-hoc termination rules of impredicative Prop

There is another related PASE question regarding termination. You don't have to read it, I'll paraphrase the example.

Usually, for structural induction, we have the notion of "comparing term size". For instance, if we have a pattern suc n, then recursively call the function itself with n on the same position is considered good, because we think n < suc n. But consider the following example.

It makes sense to define the following type:

haskell
data BrouwerTree
+  = Leaf Bool
+  | Branch (Nat -> BrouwerTree)

and have the following structural-induction:

haskell
left :: BrouwerTree -> Bool
+left (Leaf b) = b
+left (Branch xs) = left (xs 0)

Note that in the clause of left (Branch xs), the recursive call left (xs 0) is considered smaller, in other words, we think xs 0 < Branch xs.

This assumption is called 'predicative assumption'. As you may tell from the name, it can only be made on things that are predicative, and we know Prop is usually impredicative, so we should not allow this. At this point, you might expect a proof of false using predicative assumption on Prop, which I'll show in this blog post.

Note that allowing such recursion pattern is very important! The famous W-type is also using this assumption.

A counterexample with Prop looks like this (since we need to talk about universes and dependent types, we start using Agda syntax instead of Haskell):

data Bad : Prop where
+  branch : ((P : Prop) → P → P) → Bad
+
+bad : Bad
+bad = branch (λ P p → p)
+
+no-bad : Bad → ⊥
+no-bad (branch x) = no-bad (x Bad bad)
+
+very-bad : ⊥
+very-bad = no-bad bad

Notice that the no-bad (branch x) clause uses the recursion no-bad (x Bad bad), which is only valid with the predicative assumption. So, having this predicative assumption actually proves false for Prop, so for Prop, we need to patch the termination checker to ban this rule. So, how hard is it to patch the termination checker?

Coq and Lean have a similar problem, but they are generating eliminators for inductive definitions, so they can generate the correct eliminator for Prop, instead of patching the termination checker. Then, Coq carefully implements a comparison function for size-decreasing arguments (this means eliminators are not the "most primitive" thing in Coq, but the termination checker is also part of it. I got this piece of information from Lysxia and Meven Lennon-Bertrand). In Coq, the eliminator for Bad is

Bad_ind : forall P : Prop,
+    ((forall p : Prop, p -> p) -> P) ->
+    Bad -> P

Note that there is no recursive arguments, so there is no recursion allowed.

Now, this sounds like just adding some if statements to the termination checker, but the situation is actually worse. In Agda, metavariables are pervasive, like the following code is partially accepted:

data Bad : Prop where
+  b : ((P : { }0) → P → P) → Bad

Agda will not fail on this code, but then what to do in the termination checker is really unclear. If you're using a termination checker, you want to get rid of impredicativity of Prop! This eliminates the need of a universe-based irrelevance.

Alternative ways to impredicativity

We may use axioms to get impredicativity. Suppose we define (since we no longer have it in the language) Prop := Σ (A : Type) (isProp A), there are two different axioms that imply impredicativity of Prop:

  • Propositional resizing, which is basically a restatement of impredicativity.
  • Classical axioms, which implies that A : Prop is either or , which further implies that Prop ≅ Bool, which implies resizing.
  • A completely separate layer in the type theory that only concerns logic and propositions. This is similar to the solution in Russell's original simple theory of types, where we replace the "simple type" with dependent types.

If we think of the right way of doing math is to work with classical axioms, why on earth are we forging a weaker theorem as part of the language?

+ + + + \ No newline at end of file diff --git a/blog/index-unification.html b/blog/index-unification.html new file mode 100644 index 0000000..356e2fc --- /dev/null +++ b/blog/index-unification.html @@ -0,0 +1,34 @@ + + + + + + Index unification and forced patterns in Aya | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Index unification and forced patterns in Aya

Aya implements a version of index unification algorithm that allows emission of obvious patterns. Here's an example. Consider the famous "sized-vector" Vec (n : Nat) (A : Type) definition, and we can perform some pattern matching:

len : ∀ {A} -> (n : Nat) -> Vec n A -> Nat
+len a vnil = 0
+len a (vcons _ x) = suc (len _ x)

This code may seem obviously correct, but why would I write about it if it's so simple? 😉 Let's run the type checking in our head, clause by clause and pattern by pattern.

  1. The first pattern in the first clause, a, is a valid pattern for Nat. This means we will substitute the codomain of the pattern matching with [a/n], where n is the corresponding name in the telescope and a is the term corresponding to the pattern.
  2. The second pattern in the first clause, vnil, is a pattern for Vec zero A. However, the expected type is Vec a A, which does not match the type of the pattern.

So, here is the problem! The well-typed version of the program is actually:

len : ∀ {A} -> (n : Nat) -> Vec n A -> Nat
+len zero vnil = 0
+len (suc a) (vcons _ x) = suc (len a x)

However, isn't it obvious that the first pattern in the first clause must be zero? It would be nice if the type checker can figure this out by itself. In fact, both Agda and Idris can do this! In Agda, the feature is called "dotted patterns" in the documentation and "inaccessible patterns" in the paper. I will prefer calling it "forced patterns" because the patterns are actually accessible (in the sense that the bindings in the patterns are used) and does not use the Agda dot syntax.

Forced patterns are not easy to implement. The simplest pattern type checking algorithm can be quite straightforward: we check the type of the pattern, add the bindings to the context so we can type the rest of the telescope, and check the body of the clause. With forced patterns, we will need to change the existing well-typed variable patterns into constructor patterns, so the algorithm becomes stateful.

In Aya, I introduced the concept of "meta patteriables" which is a funny reference to "meta variables" used in unification in conversion check.

The so-called "meta patteriables"

Related PR: #198

When we see a variable pattern, we transform it into a MetaPat which is a "unification variable" pattern that can be "solved" into another pattern. A reference to a MetaPat is converted into a special meta variable that has a mutable reference to the MetaPat (this can be replaced by a mutable map in the type checking state when you need purity, but I prefer mutable references for implementation simplicity).

When we are type checking a pattern of type D a for D an indexed inductive family and the expected type is D b where b is the special meta variable, we claim that b is solved to a, and the MetaPat that corresponds to b will be transformed into a when we finalize the type checking results.

There are two more cases to deal with:

  1. In case a MetaPat is not "solved", we just let it be a variable pattern.
  2. In case a MetaPat is "solved" more than once, we must make sure the solutions are identical.

Note that a MetaPat may contain bindings, but these bindings are already from the current context, so we do not need to add them again to the context.

Now, let's run the new algorithm:

len : ∀ {A} -> (n : Nat) -> Vec n A -> Nat
+len a vnil = 0
+len a (vcons _ x) = suc (len _ x)
  1. The first pattern in the first clause, a, is a valid pattern for Nat, so we generate a MetaPat(a) and substitute the codomain with MetaPatRef(a), e.g. Vec MetaPatRef(a) A -> Nat.
  2. The second pattern in the first clause, vnil, is a pattern for Vec zero A. The expected type is Vec MetaPatRef(a) A, and we solve MetaPat(a) to zero.
  3. Now we check the body and finalize the clause. Since a is solved to zero, we generate the well-typed clause len zero vnil = 0 which is exactly what we need.

Thanks for reading!

+ + + + \ No newline at end of file diff --git a/blog/index.html b/blog/index.html new file mode 100644 index 0000000..a4f3b46 --- /dev/null +++ b/blog/index.html @@ -0,0 +1,28 @@ + + + + + + Aya blogs | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Aya blogs

See the sidebar 👈 for the list of blog posts.

Note that some posts are written before some breaking syntax changes. The code examples may not work with the latest version of Aya.

+ + + + \ No newline at end of file diff --git a/blog/lang-exts.html b/blog/lang-exts.html new file mode 100644 index 0000000..59d5854 --- /dev/null +++ b/blog/lang-exts.html @@ -0,0 +1,28 @@ + + + + + + Haskell or Agda style extensions | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Haskell or Agda style extensions

In Haskell, you can do {-# LANGUAGE TypeFamilies #-}, and similarly in Agda you can {-# OPTIONS --two-levels #-}. These "pragma" can also be specified via command line arguments. Since Haskell is too weak and even basic features need extensions, I'll be avoiding talking about it and stick to Agda.

Agda's extensions

The purpose of these pragma is threefold:

  • Disable or enable (particularly disable) certain checks or compiler phases such as positivity checks, termination checks, deletion rule in unification, etc.
  • Modify the compiler by changing some parameters, such as termination check's recursion depth, use call-by-name instead of call-by-need, cumulativity, etc.
  • Disable or enable (particularly enable) certain language features, such as cubical features, sized types, custom rewriting rules, etc.

One special pragma is to ensure that no known inconsistent flag or combination of flags is turned on -- --safe. Let's discuss it later.

The current status of Agda libraries, that having separate cubical, HoTT library, and standard library, implementing the basic features individually, is a significant evidence that Agda is barely a programming language, but a collection of programming languages that share a lot in common and have good interoperability. Each flag that enables a certain language feature makes Agda a different language, and it is difficult in general to make two different language source-to-source compatible (see Kotlin-Java, Scala-Java, etc).

It is good to keep your language evolving like Agda (adding new features aggressively), and indeed Agda is the proof assistant with the richest set of language features I've known so far. However, this also negatively impacts Agda's reputation to some extent, that people say it's an experiment in type theory. Well, maybe it's not a negative impact, but it prevents big customers (such as Mathematicians looking for a tool to formalize math) from choosing the language. At least, we don't want this to happen to our language.

Aya's choice?

So, we will not introduce any "feature" flags, and will have only one base library. Aya will be one language, its features are its features. If we decide on removing a feature, then we remove it from the language (not going to keep it as an optional flag). If we decide on adding a feature, we add it and it should be available without any options.

It should still be encouraged to add some fancy, experimental features, but I think they should stay in branches or forks and will be either enlisted to the language or abandoned eventually.

However, the "parameters" part is not as bad. For example, it is very easy to allow type-in-type in the type checker -- we just disable the level solver. This is useful when the level solver prevents us from experimenting something classical using our language features but unfortunately the level solver is just unhappy with something minor. We can also like tweak the conversion checking algorithm we use, like we can use a simpler one that only solves first-order equations or we can enable the full-blown pattern unification algorithm. Verbosity levels, can also be seen as such parameter, and it's extremely useful for debugging the compiler. So we can apply that.

Safe flag?

To be honest, it's hard to decide on a semantic of the word "safe", and relate that to the Agda pragma --safe. To me, it means "logical consistency", and if we can set --safe as the last argument of an Agda file, it should be guaranteed by Agda that it cannot provide you a proof of false. There are many related discussion in the Agda issue tracker that talks 'bout how should --safe behave. Sometimes it fits my guess (for logical consistency), sometimes it implies more stuffs.

Anyway, a "logical consistency" flag seems useful, and will probably appear in Aya.

For disabling or enabling some checks, if we disable a check that is required to be consistent, then it should break --safe. I think we will of course enable all of these checks by default, so exploiting the disabledness of a check can lead to inconsistency eventually. So, we can use an "unsafe" flag to ensure that our language is only unsafe when we want it to be. It is quite meaningful as well to have an "unsafe" mode, from a real-world programming perspective.

Conclusion

We'll have a language, with some flags that tweaks the parameters of some algorithms (which are no-harm), and some flags for disabling some checks (which will lead to an error at the end of tycking), and an unsafe flag that enables a set of features such as sorry and suppresses the error of disabling checks.

Library Design

Speaking of the base library design, I have some vague ideas in mind. I'd like it to be split into three parts (not sure if we're gonna make it three modules inside one stdlib or three standalone libraries):

  • The base part, for basic definitions like lists, trees, sorting, rings, categories, path lemmas, simple tactics like rewrites, etc.
  • The programming part, for I/O, effects, unsafe operations, FFI, etc.
  • The math part, like arend-lib or Lean's mathlib.

Then, we can use these libraries on-demand.

+ + + + \ No newline at end of file diff --git a/blog/path-elab.html b/blog/path-elab.html new file mode 100644 index 0000000..ff77fbb --- /dev/null +++ b/blog/path-elab.html @@ -0,0 +1,48 @@ + + + + + + Elaboration of the "extension" type | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Elaboration of the "extension" type

Aya uses the so-called "extension" type (probably first-appeared here) as a generalized version of path type.

Instead of using the conventional path type, as in Cubical Agda:

  • PathP (λ i → A i) a b for a : A 0 and b : A 1
  • λ i → a : PathP (λ i → A i) (a 0) (a 1) for a : A i
  • p i : A i for p : PathP (λ i → A i) a b
    • p 0 = a and p 1 = b

This type looks good, but it does not scale to higher dimensions. Consider, for example, the type of a square with four faces specified (from Agda's cubical library):

Square :
+  {a₀₀ a₀₁ : A} (a₀₋ : a₀₀ ≡ a₀₁)
+  {a₁₀ a₁₁ : A} (a₁₋ : a₁₀ ≡ a₁₁)
+  (a₋₀ : a₀₀ ≡ a₁₀) (a₋₁ : a₀₁ ≡ a₁₁)
+  → Type _
+Square a₀₋ a₁₋ a₋₀ a₋₁ = PathP (λ i → a₋₀ i ≡ a₋₁ i) a₀₋ a₁₋

It gets even worse when the type is heterogeneous:

SquareP :
+  (A : I → I → Type ℓ)
+  {a₀₀ : A i0 i0} {a₀₁ : A i0 i1} (a₀₋ : PathP (λ j → A i0 j) a₀₀ a₀₁)
+  {a₁₀ : A i1 i0} {a₁₁ : A i1 i1} (a₁₋ : PathP (λ j → A i1 j) a₁₀ a₁₁)
+  (a₋₀ : PathP (λ i → A i i0) a₀₀ a₁₀) (a₋₁ : PathP (λ i → A i i1) a₀₁ a₁₁)
+  → Type ℓ
+SquareP A a₀₋ a₁₋ a₋₀ a₋₁ = PathP (λ i → PathP (λ j → A i j) (a₋₀ i) (a₋₁ i)) a₀₋ a₁₋

We have decided to use a partial element to represent these faces, and so we can freely add or delete these a face, without having to explicitly write down all faces for generality. This leads to the following syntax:

--------  ↓ type           ↓ the "i = 0" end is b
+[| i |] (A i) {| i := a | ~ i := b |}
+-- ^ interval         ^ the "i = 1" end is a

The above type is equivalent to PathP (λ i → A i) a b. We may use this to simplify the type signature of path concatenation:

def concat {A : Type}
+  (p : [| i |] A {| |})
+  (q : [| i |] A {| ~ i := p 1 |})
+  : [| i |] A {| ~ i := p 0 | i := q 1 |}

It has fewer parameters than the conventional version:

def concat {A : Type}
+  {a b c : A}
+  (p : Path A a b)
+  (q : Path A b c)
+  : Path A a c

Now, how to implement this type? We have decided to overload lambdas and expressions as Cubical Agda did, but we have encountered several problems. Here's the story, in chronological order.

Below, we use "type checking" and we actually mean "elaboration".

First attempt

Principle: do not annotate the terms (including variable references) with types, because this is going to harm efficiency and the code that tries to generate terms (now they'll have to generate the types as well, pain!).

Problem: reduction of path application is type-directed, like p 1 will reduce according to the type of p.

Solution: annotate the path applications instead. Every time we do type checking & we get a term of path type, we "η-expand" it into a normal lambda expression with a path application inside. This secures the reduction of path applications.

New Problem: we expand too much. In case we want to check the type of term against a path type, the term is actually η-expanded and has a Π-type. So, we have the manually write path lambdas everywhere, e.g. given p : Path A a b, and only λ i → p i is a valid term of type Path A a b, not p (which is internally a lambda).

Lesson: we need to preserve the types somehow, generate path applications only when necessary.

Second attempt

New Solution: when checking something against a path type, we directly apply the boundary checks, instead of trying to invoke synthesize and unify the types. This eliminates a lot of λ i → p i problems.

New Problem: this is incompatible with implicit arguments. Consider the following problem:

  • have: idp : {a : A} -> Path A a a
  • elaborated: λ i → idp i : {a : A} -> I -> A
  • check: idp : Path Nat zero zero

The new solution will try to apply the boundary before inserting the implicit arguments, which leads to type-incorrect terms.

Lesson: we probably should not change the bidirectional type checking algorithm too much.

Third attempt

New Solution: the type information is known in the bidirectional type checking anyway, so we only generate path applications during the type checking of application terms.

This has worked so far, with some unsolved problems (yet to be discussed):

  • Is p : [| i |] A {| |} an instance of type [| i |] A {| i := a |}?
    • Currently, Aya do not think so.
  • Can we automatically turn Agda-style squares to its preferred version in generalized path type?
    • Related issue: 530
    • A sort of "flattening"

If you have any thoughts, feel free to reach out :)

Update (2023-03-24)

The implementation has been updated to solve some the above problems partially. Essentially, we need to do one thing: coercive subtyping. Since the type checking already respects the type (say, does not change the type), it remains to insert an η-expansion when the subtyping is invoked. We also need to store the boundary information in the path application term to have simple normalization algorithm.

Carlo Angiuli told me that in cooltt, the path type is decoded (in the sense of the universe à la Tarski el operator) into a Π-type that returns a cubical subtype, and since el is not required to be injective, this should be fine. At first, I was worried about the fibrancy of the path type, because a Π-type into a subtype is not fibrant, but it turns out that this is unrelated. We don't talk about the fibrancy of the types, but only the fibrancy of the type codes.

+ + + + \ No newline at end of file diff --git a/blog/pathcon-elab.html b/blog/pathcon-elab.html new file mode 100644 index 0000000..2d3f171 --- /dev/null +++ b/blog/pathcon-elab.html @@ -0,0 +1,37 @@ + + + + + + Elaboration of path constructors | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Elaboration of path constructors

This is not a blog post, but a reference for developers and type theory implementers.

Content below assumes knowledge on cubical type theory, for example the extension type and higher inductive types.

Syntax

  • [i]X{φu}[\overline i] X\{\overline{φ↦ u}\}: extension types, PathP A a b in Agda corresponds to [i]A i{i=0a,i=1b}[i] A~i\{i=0↦ a, i=1↦ b\}.
  • ii is sometimes used to denote i=1i=1 and ¬i¬ i is used to denote i=0i=0.

Flattening

Used in higher inductive type elaboration.

A[i]X{}AΠ(x:X)Yflatten(A):=A\newcommand{\flattenOp}[1]{\textsf{flatten}(#1)} \cfrac{A \ne [\overline i] X\set{\cdots} \quad A\ne Π(x:X)→ Y} {\flattenOp{A} := A}

flatten(X):=[j]Y{φu}flatten([i]X{φu}):=[i,j]Y{φu @ j,φu}\newcommand{\flattenOp}[1]{\textsf{flatten}(#1)} \cfrac {\flattenOp{X}:=[\overline j] Y\set{\overline{φ'↦ u'}}} {\flattenOp{[\overline i] X\set{\overline{φ↦ u}}} := [\overline i,\overline j] Y\set{\overline{φ'↦ u'~@~\overline j},\overline{φ↦ u}}}

flatten(Π(x:X)Y):=Π(x:X)flatten(Y)\newcommand{\flattenOp}[1]{\textsf{flatten}(#1)} \cfrac{} {\flattenOp{Π(x:X)→ Y}:=Π(x:X)→ \flattenOp{Y}}

Example

isProp(A):=Π(a b:A)[i]A{ia,¬ib}isSet(A):=Π(a b:A)isProp([i]A{ia,¬ib})\begin{align*} \textsf{isProp}(A)&:=Π(a~b:A) → [i]A\set{i↦ a,¬ i↦ b}\\ \textsf{isSet}(A)&:=Π(a~b:A)→\textsf{isProp}([i]A\set{i↦ a,¬ i↦ b})\\ \end{align*}

So the normal form of isSet is:

Π(a b:A)Π(p q:[i]A{ia,¬ib})[j]([i]A{ia,¬ib}){jq,¬jp}\begin{align*} Π(a~b:A)&→Π(p~q:[i]A\set{i↦ a,¬ i↦ b})\\ &→ \big[j\big] \big([i]A\set{i↦ a,¬ i↦ b}\big) \Set{j↦ q, ¬ j↦ p}\\ \end{align*}

And flattenOp(isSet(A))\textsf{flattenOp}(\textsf{isSet}(A)) is:

Π(a b:A)Π(p q:[i]A{ia,¬ib})[j i]A{ia,¬ib,jq @ i,¬jp @ i}\begin{align*} Π(a~b:A)&→Π(p~q:[i]A\set{i↦ a,¬ i↦ b})\\ &→ \big[j~i\big] A \Set{i↦ a,¬ i↦ b,j↦ q~@~i, ¬ j↦ p~@~i}\\ \end{align*}

So for example, set truncation from HoTT looks like this:

inductive SetTrunc (A : Type)
+| mk : A -> SetTrunc A
+| trunc : isSet (SetTrunc A)

The trunc constructor is elaborated to cubical syntax by flattening the type and attach the partial on the return type to the constructor, something like this:

trunc : Π (a b : SetTrunc A)
+    -> (p q : a = b)
+    -> (j i : I) -> SetTrunc A
+  { i = 1 -> a
+  ; i = 0 -> b
+  ; j = 1 -> q @ i
+  ; j = 0 -> p @ i
+  }

Aya is currently working on the so-called IApplyConfluence problem for recursive higher inductive types like SetTrunc, see this question which is a problem I'm wrapping my head around at the moment. More details will be posted later.

+ + + + \ No newline at end of file diff --git a/blog/redirect.html b/blog/redirect.html new file mode 100644 index 0000000..3234cf8 --- /dev/null +++ b/blog/redirect.html @@ -0,0 +1,28 @@ + + + + + + Aya Prover + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/blog/tt-in-tt-qiit.html b/blog/tt-in-tt-qiit.html new file mode 100644 index 0000000..15a765f --- /dev/null +++ b/blog/tt-in-tt-qiit.html @@ -0,0 +1,94 @@ + + + + + + Type Theory in Type Theory using Quotient Inductive Types | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Type Theory in Type Theory using Quotient Inductive Types

Link to the paper.

Here's a self-contained full definition.

Prelude

prim I
+prim Path
+prim coe
+
+variable A B : Type
+def infix = (a b : A) : TypePath (\iA) a b
+def refl {a : A} : a = a\ia
+def pmap (f : AB) {a b : A} (p : a = b) : f a = f b\if (p i)
+
+// Copied from Carlo Angiuli's thesis
+def transport {a b : A} (B : AType) (p : a = b) (x : B a) : B b
+  ⇒ coe 0 1 (\yB (p y)) x
+

Context

open inductive Con : Type
+| 
+| infix  (Γ : Con) (Ty Γ)
+

An instance of the type Con corresponds to the ΓΓ in the judgment Γ ctxΓ~\text{ctx}, and these constructors correspond (on-the-nose) to:

 ctxΓ ctxΓA typeΓA ctx\cfrac{}{·~\text{ctx}} \quad \cfrac{Γ~\text{ctx} \quad Γ⊢A~\text{type}}{Γ \vartriangleright A~\text{ctx}}

It uses the judgment ΓA typeΓ⊢A~\text{type}, which is defined below.

Types

open inductive Ty (Γ : Con) : Type
+| U
+| Π (A : Ty Γ) (B : Ty (Γ  A))
+| El (A : Tm Γ U)
+| Subst {Δ : Con} (Ty Δ) (s : Γ << Δ)
+| SubId {A : Ty Γ} : Subst A (id refl) = A
+| SubAss {Δ Θ : Con} {A : Ty Θ} {θ : Γ << Δ} {δ : Δ << Θ}
+  : Subst (Subst A δ) θ = Subst A (δ  θ)
+| SubU {Δ : Con} (δ : Γ << Δ) : Subst U δ = U
+| SubEl {Δ : Con} {δ : Γ << Δ} {a : Tm Δ U}
+  : Subst (El a) δ = El (transport (Tm _) (SubU δ) (sub a))
+| SubΠ {Δ : Con} (σ : Γ << Δ) {A : Ty Δ} {B : Ty (Δ  A)}
+  : Subst (Π A B) σ = Π (Subst A σ) (Subst B (ext σ A))
+

The ext operator corresponds to the ↑ operator in the paper:

def ext {Γ Δ : Con} (δ : Γ << Δ) (A : Ty Δ) : Γ  Subst A δ << Δ  A ⇒
+  δ  π₁ (id refl)  transport (Tm _) SubAss (π₂ (id refl))
+

An instance of the type Ty Γ corresponds to the AA in the judgment ΓA typeΓ⊢A~\text{type}. The constructor U corresponds to the following rule:

ΓU type\cfrac{}{Γ⊢\mathcal{U}~\text{type}}

I believe you already know how Π works. The constructor El computes the type corresponds to an instance of U:

ΓA:UΓEl(A) type\cfrac{Γ⊢A:\mathcal{U}}{Γ⊢\text{El}(A)~\text{type}}

Note that it uses the judgment ΓA:UΓ⊢A:\mathcal{U}, which is defined below.

Substitution objects

open inductive infix << (Γ : Con) (Δ : Con) : Type
+   tighter = looser 
+| _, ε
+| _, Δ'  Ainfixr  (δ : Γ << Δ') (Tm Γ (Subst A δ)) tighter =
+| infix  {Θ : Con} (Θ << Δ) (Γ << Θ) tighter = 
+| π₁ {A : Ty Δ} (Γ << Δ  A)
+| id (Γ = Δ)
+| idl• {s : Γ << Δ} : id refl  s = s
+| idr• {s : Γ << Δ} : s  id refl = s
+| ass {Θ Ξ : Con} {ν : Γ << Ξ} {δ : Ξ << Θ} {σ : Θ << Δ}
+  : (σ  δ)  ν = σ  (δ  ν)
+| π₁β {δ : Γ << Δ} {A : Ty Δ} (t : Tm Γ (Subst A δ)) : π₁ (δ  t) = δ
+| _, _  _ ⇒ πη {δ : Γ << Δ} : (π₁ δ  π₂ δ) = δ
+| _, Δ'  A∷∘ {Θ : Con} {σ : Θ << Δ'} {δ : Γ << Θ} {t : Tm Θ (Subst A σ)}
+  : (σ  t)  δ = (σ  δ)  transport (Tm _) SubAss (sub t)
+| _, εη {δ : Γ << } : δ = ε
+

An instance of type Γ << Δ corresponds to the σσ in the substitution typing Γσ:ΔΓ ⊢ σ : Δ.

Terms

open inductive Tm (Γ : Con) (Ty Γ) : Type
+| _, Π A Bλ (Tm (Γ  A) B)
+| Γ'  A, Bapp (Tm Γ' (Π A B))
+| _, Subst A δsub (Tm _ A)
+| _, Subst A (π₁ δ) ⇒ π₂ (Γ << _  A)
+| _, Subst B δ as Aπ₂β {Δ : Con} (t : Tm Γ A)
+  : transport (Tm _) (pmap (Subst B) (π₁β t)) (π₂ (δ  t)) = t
+| _  _, AΠβ (f : Tm Γ A) : app (λ f) = f
+| _, Π _ _ as AΠη (f : Tm Γ A) : λ (app f) = f
+| _, Π A Bsubλ {Δ : Con} {σ : Γ << Δ} {A' : Ty Δ} {B' : Ty (Δ  A')}
+  (fording : Π (Subst A' σ) (Subst B' _) = Π A B) {t : Tm (Δ  A') B'}
+  : let ford := transport (Tm _) fording
+    in ford (transport (Tm _) (SubΠ σ) (sub (λ t)))
+     = ford (λ (sub t))
+

An instance of type Tm Γ A corresponds to the tt in the judgment Γt:AΓ⊢t:A.

+ + + + \ No newline at end of file diff --git a/guide/fake-literate.html b/guide/fake-literate.html new file mode 100644 index 0000000..be91b5c --- /dev/null +++ b/guide/fake-literate.html @@ -0,0 +1,72 @@ + + + + + + Fake literate mode | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Fake literate mode

The Aya compiler generates styled (e.g. with colors and text attributes) code snippets for many targets, like HTML, LaTeX, etc., and it's tempting to use the same tool but for different languages. This is what the fake literate mode is for. Let me know if you want other backend supports.

To start, install the latest version of Aya, put the following code in a file named hello.flcl:

keyword: data where;
+symbol: ≃;
+data: Int;
+constructor: zero succ;
+------
+data Int where
+  zero : Int
+  succ : Int ≃ Int

Then, run the following command to generate literate output, where you replace <AYA> with either java -jar <path-to-aya.jar> or aya depending on your installation:

<AYA> --fake-literate hello.flcl

Then it will print the following output:

\AyaKeyword{data}\hspace{0.5em}\AyaData{Int}\hspace{0.5em}\AyaKeyword{where}~\\
+\hspace{1.0em}\AyaConstructor{zero}\hspace{0.5em}:\hspace{0.5em}\AyaData{Int}~\\
+\hspace{1.0em}\AyaConstructor{succ}\hspace{0.5em}:\hspace{0.5em}\AyaData{Int}\hspace{0.5em}≃\hspace{0.5em}\AyaData{Int}

You may add -o hello.tex to let it write to a file instead of printing to the console. With minimal configurations such as below, you can compile it with any LaTeX toolchain:

tex
\usepackage{newunicodechar}
+\newunicodechar{≃}{\ensuremath{\mathrel{\simeq}}}
+
+\usepackage{xcolor}
+
+% Aya highlighting
+\definecolor{AyaFn}{HTML}{00627a}
+\definecolor{AyaConstructor}{HTML}{067d17}
+\definecolor{AyaStruct}{HTML}{00627a}
+\definecolor{AyaGeneralized}{HTML}{00627a}
+\definecolor{AyaData}{HTML}{00627a}
+\definecolor{AyaPrimitive}{HTML}{00627a}
+\definecolor{AyaKeyword}{HTML}{0033b3}
+\definecolor{AyaComment}{HTML}{8c8c8c}
+\definecolor{AyaField}{HTML}{871094}
+\newcommand\AyaFn[1]{\textcolor{AyaFn}{#1}}
+\newcommand\AyaConstructor[1]{\textcolor{AyaConstructor}{#1}}
+\newcommand\AyaCall[1]{#1}
+\newcommand\AyaStruct[1]{\textcolor{AyaStruct}{#1}}
+\newcommand\AyaGeneralized[1]{\textcolor{AyaGeneralized}{#1}}
+\newcommand\AyaData[1]{\textcolor{AyaData}{#1}}
+\newcommand\AyaPrimitive[1]{\textcolor{AyaPrimitive}{#1}}
+\newcommand\AyaKeyword[1]{\textcolor{AyaKeyword}{#1}}
+\newcommand\AyaLocalVar[1]{\textit{#1}}
+\newcommand\AyaComment[1]{\textit{\textcolor{AyaComment}{#1}}}
+\newcommand\AyaField[1]{\textcolor{AyaField}{#1}}

The following code provides a quick macro to include the generated code:

tex
\newcommand{\includeFlcl}[1]{{
+\vspace{0.15cm}
+\RaggedRight
+% https://tex.stackexchange.com/a/35936/145304
+\setlength\parindent{0pt}
+\setlength{\leftskip}{1cm}
+\input{#1}
+
+\setlength{\leftskip}{0cm}
+\vspace{0.15cm}
+}}

Use \includeFlcl{hello} to include the generated code in your document.

+ + + + \ No newline at end of file diff --git a/guide/haskeller-tutorial.html b/guide/haskeller-tutorial.html new file mode 100644 index 0000000..8d3b423 --- /dev/null +++ b/guide/haskeller-tutorial.html @@ -0,0 +1,102 @@ + + + + + + So you know some Haskell | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

So you know some Haskell

Great. I expect you to know something about GHCi and algebraic data types. This is an Aya tutorial for Haskell programmers. If you find a bug, open an issue on GitHub!

Working with the REPL

Aya has a REPL that works similar to GHCi. You can start it by running aya -i in your terminal, and you can start typing definitions or expressions.

bash
aya -i

If you're using jar with java, use the following instead:

bash
java --enable-preview -jar cli-fatjar.jar -i

In the REPL, you can use :l to load a file, :q to quit, and :? to get help. Use :t to show the type. Since it's dependent type, you can toggle normalization levels by :normalize followed by NF, WHNF, or NULL (don't normalize).

To work multiline, use the pair :{ and :} -- same as GHCi.

Aya supports pretty-printing of any terms, including ✨lambdas✨. Note that Aya does not automatically support generic lambdas, so typing \x => x would not work. You need to specify the type of x, like \(x : Int) => x.

Aya support fn as an alias to \ instead of λ, similar to Coq and Lean (but not Agda). This is because users (especially mathematicians) are likely to use λ as a variable name. Similarly, we used Fn over Pi or Π for the same reason.

Working with projects

Read project-tutorial, it is very short. It is recommended to practice the following with an Aya project in VSCode, see vscode-tutorial.

About modules:

  • Aya module names are separated by ::, not ..
  • Aya infers the module names automagically, using the same rule as of Haskell.
  • Aya imports (import X) are qualified by default, use open import X to unqualify. This is short for import X followed by open X.
  • Aya supports restricted import open import X using (x) (this only imports x from X) you may also use open import X hiding (x) to import everything except x from X.
  • Aya supports renamed import open import X using (x as y) and the meaning is obvious.
  • To re-export, use a public open.

Ok, let's write some code!

Programming in Aya

Natural numbers. In Haskell:

haskell
data Nat = Zero | Suc Nat

In Aya (we replaced the keyword data with inductive because we want to use it as a package name):

inductive Nat | zero | suc Nat
+

We don't enforce capitalization of constructors. The constructors need to be qualified (like Nat::zero) to access. As you may expect, Nat automatically becomes a module, so we can use open and public open to unqualify the constructors.

Bonus: if you define a data type that looks like Nat, then you can use numeric literals.

Functions are defined with def, followed by pattern matching. Consider this natural number addition in Haskell (intentionally not called + to avoid name clash with Prelude):

haskell
(<+>) :: Nat -> Nat -> Nat
+Zero <+> n = n
+Suc m <+> n = Suc (m <+> n)
+
+infixl 6 <+>

In Aya (remember the numeric literal thing?):

open Nat
+def infixl <+> Nat Nat : Nat
+| 0, nn
+| suc m, nsuc (m <+> n)
+

There are plenty of differences. Let's go through them one by one.

The infixl declares <+> to be a left-associative infix operator. Other options include infix, infixr, fixl, and fixr. Without it, the function will work the same as normal function. Unlike Haskell, we do not distinguish "operator" names and "function" names.

We do not use a number to denote precedence, but a partial order. This allows arbitrary insertion of new precedence level into previously defined ones. Say you want <+> to have a lower precedence than <*>, you can do:

def infixl <+> Nat Nat : Nat
+/// .... omitted
+looser <*>

You also have tighter, with the obvious meaning.

The parameters and the return type are separated using :. The parameter types can be written directly, without ->. Aya allow naming the parameters like this:

def oh (x : Nat) : Nat

These names can be used for one-linear function bodies:

def oh (x : Nat) : Natx
+

Aya supports a painless version of the section syntax, where the top-level does not need parentheses. See the following REPL output (the underscored names are internally generated variable names. If you have an idea on how to make them better, open an issue and let's discuss!).

> 1 <+>
+suc
+
+> <+> 1
+λ _7 ⇒ _7 <+> 1
+
+> 1 <+> 1
+suc 1
+
+> 2 <+>
+λ _5 ⇒ suc (suc _5)
+
+> <+> 2
+λ _7 ⇒ _7 <+> 2

When we only need to pattern match on a subset of the parameters, we can use the elim keyword:

example def infixl [+] (a n : Nat) : Nat elim a
+| 0 ⇒ n
+| suc msuc (m [+] n)
+

Type-level programming

In Haskell:

haskell
id :: a -> a
+id x = x

In Aya:

def id {A : Type} (x : A) ⇒ x
+

Observations:

  • Type parameters have to be explicitly qualified using curly braces.
  • Curly braces denote parameters that are omitted (and will be inferred by type checker) in the pattern matching and invocations. So, parentheses denote parameters that are not omitted.
  • Apart from Type, we also have Set, and ISet. For now, don't use the others.

Type constructors are like {F : Type -> Type} (and yes, the -> denotes function types, works for both values and types), very obvious. Definition of Maybe in Aya:

open inductive Maybe (A : Type)
+| nothing
+| just A
+

Here, (A : Type) is an explicit parameter, because you write Maybe Nat, not just Maybe.

There is a way to automagically insert the implicit parameters -- the variable keyword.

variable A : Type
+
+// Now, since you are using A, so Aya inserts {A : Type}
+example def id (x : A) ⇒ x
+

Aya supports type aliases as functions. For example, we may define the type of binary operators as a function:

def BinOp (A : Type) ⇒ AAA
+

Then, we can define <+> as:

example def infixl <+> : BinOp Nat
+| 0, nn
+| suc m, nsuc (m <+> n)
+

Type families

In Aya, type families are functions. Consider the following code (they are using the variable A defined above):

// Unit type
+open inductive Unit | unit
+
+// A type family
+def FromJust (x : Maybe A) : Type
+| just aA
+| nothingUnit
+
+// A function that uses the type family
+def fromJust (x : Maybe A) : FromJust x
+| just aa
+| nothingunit
+

And fromJust (just a) will evaluate to a. In Haskell, you need to use some language extensions alongside some scary keywords. These functions are available in constructors, too:

inductive Example (A : Type)
+| cons (x : Maybe A) (FromJust x)
+

It is recommended to play with it in the REPL to get a feel of it.

There is a famous example of dependent types in Haskell -- the sized vector type:

haskell
{-# LANGUAGE GADTs #-}
+{-# LANGUAGE DataKinds #-}
+-- Maybe you need more, I don't remember exactly
+
+data Vec :: Nat -> Type -> Type where
+  Nil :: Vec Zero a
+  (:<) :: a -> Vec n a -> Vec (Suc n) a
+infixr :<

In Aya, we have a better syntax:

open inductive Vec (n : Nat) (A : Type)
+| 0, Anil
+| suc n, Ainfixr :< A (Vec n A)
+

The :< constructor is defined as a right-associative infix operator. And yes, you can define like vector append painlessly:

variable m n : Nat
+
+def infixr ++ (Vec n A) (Vec m A) : Vec (n <+> m) A
+| nil, ysys
+| x :< xs, ysx :< xs ++ ys
+tighter :<
+

Imagine how much work this is in Haskell.

Overlapping patterns

There is one more bonus: in Aya, you may modify the definition of <+> to be:

overlap def infixl <+> Nat Nat : Nat
+| 0, n => n
+| n, 0 => n
+| suc m, n => suc (m <+> n)

It says we not only compute 0 + n = n, but when the first parameter is neither 0 nor suc, we may take a look at the second parameter and seek for other potential computations. This is completely useless at runtime, but very good for type checking. For instance, we may want a Vec of size n, and what we have is some Vec of size n + 0. Then having n + 0 to directly reduce to n is very useful, otherwise we will need to write a conversion function that does nothing but changes the type, or use unsafeCoerce.

With n + 0 = n judgmentally, we now have more possibilities. For instance, we can make xs ++ nil = xs. This involves in two steps: we first turni ++ into a overlap def, then we add the following clause to ++:

| xs, nil => xs

This makes ++ compute on more cases too.

For more information about this feature, checkout the tutorial for proof assistant users.

+ + + + \ No newline at end of file diff --git a/guide/index.html b/guide/index.html new file mode 100644 index 0000000..af49994 --- /dev/null +++ b/guide/index.html @@ -0,0 +1,28 @@ + + + + + + The Aya Prover | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

The Aya Prover

Aya is a programming language and an interactive proof assistant designed for type-directed programming and formalizing math.

The type system of Aya has the following highlights:

  • Set-level cubical features so funExt and quotients are available without axioms (like Agda, redtt, and Arend but not higher-dimensional),
  • Overlapping and order-independent pattern matching makes simple functions compute better,
  • Practical functional programming features similar to Haskell and Idris: dependent pattern matching, typed holes, enchanted synthesis of implicit arguments.

The implementation of the Aya compiler has the following highlights:

  • Efficient type checking by JIT-compiling well-typed definitions to JVM higher-order abstract syntax, so substitution does not traverse terms,
  • Convenient interactive tools such as a language server for VSCode, a REPL, and hyperlinked document generation (demo),
  • Pre-compiled binary release.
+ + + + \ No newline at end of file diff --git a/guide/install.html b/guide/install.html new file mode 100644 index 0000000..2513bfc --- /dev/null +++ b/guide/install.html @@ -0,0 +1,53 @@ + + + + + + Install Aya | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Install Aya

At this stage of development, we recommend using the nightly version of Aya. Go to GitHub Release, there will be a plenty of files. It's updated per-commit in the main branch, but the release date displayed is very old and is an issue of GitHub itself.

Checking the section below that fits your platform. After the installation, run aya --help for general instructions and aya -i to start an interactive REPL. If you chose the jlink version, the bin folder contains the executable scripts.

Download from GitHub Release

Aya is available for Windows, Linux, and macOS, as listed below.

x64aarch64
Windowszipzip
Linuxzipzip
macOSzipzip

Here's a hands-on script I wrote to (re)install Aya to $AYA_PREFIX (define the variable somewhere or replace with your preferred prefix, e.g. /opt/aya) on Linux x64:

bash
#!/bin/bash
+sudo mkdir -p ${AYA_PREFIX:-/tmp}
+sudo chown $USER ${AYA_PREFIX:-/tmp}
+rm -rf ${AYA_PREFIX:-/tmp}/*
+cd ${AYA_PREFIX:-/tmp}
+wget https://github.com/aya-prover/aya-dev/releases/download/nightly-build/aya-prover_jlink_linux-x64.zip
+unzip aya-prover_jlink_linux-x64.zip
+rm aya-prover_jlink_linux-x64.zip
+cd -

If it's the first time you install Aya, you may want to do (or replace ~/.bashrc with your shell's rc file):

bash
echo 'export PATH="$AYA_PREFIX/bin:$PATH"' >> ~/.bashrc
+source ~/.bashrc

Use Aya in GitHub Actions

If you want to use Aya in your GitHub Actions workflow, you can use aya-prover/setup-aya like

yaml
- name: Setup Aya
+  uses: aya-prover/setup-aya@latest
+  with:
+    version: 'nightly-build'

The step above will install the latest version of Aya to PATH. You can find the complete example here.

If you already have Java runtime...

Very cool! Now you can try the prebuilt jars (much smaller and platform-independent) or build Aya from source.

We will (hopefully) always be using the latest release of Java, rather than LTS, unless there are breaking changes on the byte code format.

Prebuilt binary

Download the jar version of cli (for using command line) and lsp (for using VSCode) and run it with java --enable-preview -jar [file name].jar.

Build from source

Clone the repository. Then, run build with ./gradlew followed by a task name. If you have problems downloading dependencies (like you are in China), check out how to let gradle use a proxy.

bash
# build Aya and its language server as applications to `ide-lsp/build/image/current`
+# the image is usable in Java-free environments 
+./gradlew jlinkAya --rerun-tasks
+# build Aya and its language server as executable
+# jars to <project>/build/libs/<project>-<version>-fat.jar
+./gradlew fatJar
+# build a platform-dependent installer for Aya and its language
+# server with the jlink artifacts to ide-lsp/build/jpackage
+# requires https://wixtoolset.org/releases on Windows
+./gradlew jpackage
+# run tests and generate coverage report to build/reports
+./gradlew testCodeCoverageReport
+# (Windows only) show the coverage report in your default browser
+./gradlew showCCR

Gradle supports short-handed task names, so you can run ./gradlew fJ to invoke fatJar, tCCR to invoke testCodeCoverageReport, and so on.

+ + + + \ No newline at end of file diff --git a/guide/project-tutorial.html b/guide/project-tutorial.html new file mode 100644 index 0000000..c2a75c7 --- /dev/null +++ b/guide/project-tutorial.html @@ -0,0 +1,44 @@ + + + + + + Aya Package | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Aya Package

An Aya project consists of a directory with a aya.json file (project metadata) and a src directory for source code. Here's a sample aya.json:

json
{
+  "ayaVersion": "0.31",
+  // ^ The version of Aya you are using -- for compatibility checks
+  "name": "<project name>",
+  "version": "<project version>",
+  "group": "<project group>",
+  // ^ The group is used to distinguish different projects with the same modules
+
+  "dependency": {
+    "<name of dependency>": {
+      "file": "<directory to your dependency>"
+    },
+    // We plan to support other sources of dependencies,
+    // but we do not have money to
+    // host a package repository for now.
+  }
+}

To build a project, run aya --make <parent dir of aya.json> (incremental). For force-rebuilding, replace --make with --remake. For jar users, run java --enable-preview -jar cli-fatjar.jar --make <parent dir of aya.json>.

+ + + + \ No newline at end of file diff --git a/guide/prover-tutorial.html b/guide/prover-tutorial.html new file mode 100644 index 0000000..b5f68cb --- /dev/null +++ b/guide/prover-tutorial.html @@ -0,0 +1,125 @@ + + + + + + Proof assistants' user tutorial | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Proof assistants' user tutorial

Great. I expect you to have basic experience with interactive theorem proving. This is another Aya tutorial for interactive theorem prover users. If you find a bug, open an issue on GitHub!

This tutorial will use some basic Aya syntax. I hope those are sufficiently intuitive, or you can look up this tutorial.

Here's a little prelude, which you do not need to understand now.

prim I
+prim coe (r s : I) (A : IType) : A rA s
+prim Path
+variable A B : Type
+def infix = (a b : A) ⇒ Path (\iA) a b
+
+open inductive Nat
+| zero
+| suc Nat
+

Function extensionality

Consider the following code:

open inductive Bool | true | false
+def not Bool : Bool
+| truefalse
+| falsetrue
+
+def id (x : Bool) ⇒ x
+
+def Goalid = (fn xnot (not x))
+
+// {??} is the syntax for typed holes in Aya:
+// def question : Goal => {??}
+

There is no way to prove it in Martin-Löf type theory or Calculus of Constructions. However, you are very smart and realized you can instead show the following:

def Goal' (x : Bool) ⇒ id x = not (not x)
+

This is pretty much the same theorem!

Now, suppose we need to show a propositional equality between two records. This means we have to show they're memberwise equal. One record has a member \ p0not (not p0), and the other has id. This time, you cannot cheat by changing the goal type. You post the question on some mailing list and people are telling you that the alternative version of the theorem you have shown does not imply the original, unless "function extensionality" is a theorem in your type theory.

To have function extensionality as a theorem, you came across two distinct type theories: observational type theory and cubical type theory. Aya chose the latter.

Cubical

Here's the proof of function extensionality in Aya:

def funExt (f g : AB) (p :  af a = g a) : f = g
+   ⇒ fn i ap a i
+

Aya has a "cubical" equality type that is not inductively defined. An equality a = b for a, b : A is really just a function IA (as we can see from the proof construction, for f = g we prove it by a lambda abstraction) where:

  • I is a special type that has two closed instances 0 and 1, and we think of there being a propositional equality between 0 and 1, and there is no pattern matching operation that distinguishes them. So, every function that maps out of I must preserve this judgmental equality.
  • For f : I -> A, the corresponding equality type is f 0 = f 1. Hypothetically, let f be the identity function, and we get a propositional equality between 0 and 1, but for technical reasons we don't talk about equality between 0 and 1 directly.

By this definition, we can "prove" reflexivity by creating a constant function:

def refl {a : A} : a = afn ia
+

For f = fn i => a, we need to verify if f 0 equals the left-hand side of the equality and f 1 equals the right-hand side, which are both true.

And to show that f = g, it suffices to construct a function q : I -> (A -> B) such that q 0 = f and q 1 = g. This is true for the proof above:

  (fn i a => p a i) 0    β-reduce
+= fn a => p a 0          p a : f a = g a
+= fn a => f a            η-reduce
+= f

We may also prove the action-on-path theorem, commonly known as cong, but renamed to pmap to avoid a potential future naming clash:

def pmap (f : AB) {a b : A} (p : a = b) : f a = f b
+   ⇒ fn if (p i)
+

Checking the above definition is left as an exercise.

However, we cannot yet define transitivity/symmetry of equality because we do not have the traditional elimination rule of the equality type -- the J rule. This will need some advanced proving techniques that are beyond the scope of this simple tutorial, so I'll skim them.

We may define the type-safe coercion using it, and this will help us prove the two lemmas about equality:

def cast (p : A  = B) : AB coe 0 1 (fn ip i)
+

Then, from p : a = b we construct the equivalence (a = a) = (b = a) and coerce along this equivalence:

def pinv {a b : A} (p : a = b) : b = acast (\ip i = a) refl
+

From q : b = c we construct the equivalence (a = b) = (a = c) and coerce along this equivalence:

def concat {a b c : A} (p : a = b) (q : b = c) : a = c ⇒
+  cast (\ia = q i) p
+

Note that at this point you can already do a bunch of familiar proofs about some simple types such as natural numbers or sized vectors. These are left as exercises, and you are encouraged to try yourself if you are not very sure about how it feels to prove things in Aya.

Overlapping and Order-independent Pattern Matching

Remember the +-comm proof that you need two lemmas? It is standard to define + in the following way:

example def infix + Nat Nat : Nat
+| 0, nn
+| suc m, nsuc (m + n)
+

And then you prove that a + 0 = a and a + suc b = suc (a + b). It is tempting to have | n, 0 => n as a computation rule as well, but this is incompatible with the usual semantics of pattern matching, which is compiled to elimination principles during type checking. However, you can do that in Aya. You may also add the other lemma as well.

overlap def infix + Nat Nat : Nat
+| 0, nn
+| n, 0 ⇒ n
+| suc m, nsuc (m + n)
+| m, suc nsuc (m + n)
+tighter =
+

This makes all of them definitional equality. So, +-comm can be simplified to just one pattern matching:

def +-comm (a b : Nat) : a + b = b + a elim a
+| 0 ⇒ refl
+| suc _ ⇒ pmap suc (+-comm _ _)
+

Note that we are using the elim keyword, which describes the variables that the function body is pattern matching on.

Heterogeneous equality

When working with indexed families, you may want to have heterogeneous equality to avoid having mysterious coercions. For example, consider the associativity of sized vector appends. We first need to define sized vectors and the append operation:

variable n m o : Nat
+// Definitions
+open inductive Vec (n : Nat) (A : Type)
+| 0, Anil
+| suc n, Ainfixr :< A (Vec n A)
+overlap def infixr ++ (Vec n A) (Vec m A) : Vec (n + m) A
+| nil, ysys
+| ys, nilys
+| x :< xs, ysx :< xs ++ ys
+tighter :< =
+

It is tempting to use the below definition:

overlap def ++-assoc (xs : Vec n A) (ys : Vec m A) (zs : Vec o A)
+  : (xs ++ ys) ++ zs = xs ++ (ys ++ zs) elim xs
+| nil => refl
+| x :< xs => pmap (x :<) (++-assoc xs ys zs)

However, this definition is not well-typed:

  • (xs ++ ys) ++ zs is of type Vec ((n + m) + o) A
  • xs ++ (ys ++ zs) is of type Vec (n + (m + o)) A.

They are not the same! Fortunately, we can prove that they are propositionally equal. We need to show that natural number addition is associative, which is the key lemma of this propositional equality:

def +-assoc {a b c : Nat} : (a + b) + c = a + (b + c) elim a
+| 0 ⇒ refl
+| suc _ ⇒ pmap suc +-assoc
+

Now we can work on the proof of ++-assoc. Here's a lame definition that is well-typed in pre-cubical type theory, and is also hard to prove -- we cast one side of the equation to be other side. So instead of:

xs ++ (ys ++ zs) = (xs ++ ys) ++ zs

We show:

f (xs ++ (ys ++ zs)) = (xs ++ ys) ++ zs

Where f is a function that changes the type of the vector, implemented using cast. The definition looks like this:

example def ++-assoc-ty (xs : Vec n A) (ys : Vec m A) (zs : Vec o A)
+  ⇒ cast (pmap (fn nVec n A) +-assoc) ((xs ++ ys) ++ zs) = xs ++ (ys ++ zs)
+

It is harder to prove because in the induction step, one need to show that cast (pmap (\ p0Vec p0 A) +-assoc) is equivalent to the identity function in order to use the induction hypothesis. For the record, here's the proof:

def castRefl (a : A) : cast  refl a = afn icoe i 1 (fn jA) a
+

But still, with this lemma it is still hard. Cubical provides a pleasant way of working with heterogeneous equality:

def Path' (A : IType) (a : A 0) (b : A 1) ⇒ Path A a b
+

So if we have X : A = B and a : A, b : B, then Path (\i => X i) a b expresses the heterogeneous equality between a and b nicely.

We may then use the following type signature:

def ++-assoc-type (xs : Vec n A) (ys : Vec m A) (zs : Vec o A)
+  ⇒ Path (fn iVec (+-assoc i) A) ((xs ++ ys) ++ zs) (xs ++ (ys ++ zs))
+

The proof is omitted (try yourself!).

Quotient inductive types

Quotient types are types that equates their instances in a non-trivial way. In Aya, they are defined using the following syntax:

open inductive Interval
+| left
+| right
+| line : left = right
+

This is an uninteresting quotient type, that is basically Bool but saying its two values are equal, so it's really just a unit type, with its unique element being the equivalence class of left and right.

If you're familiar with a proof assistant with an intensional equality like Coq/Agda/Lean/etc., you might find this surprising because a unit type shall not have two distinct elements, and an equality shall not be stated between two distinct constructors. How does this work in Aya?

Actually, in these systems, the equality is defined inductively, and it only has one constructor -- refl. This is not how equality is defined in Aya, so we can cook some interesting equality proofs into it, which includes these equality-looking constructors.

  1. The type of line will be translated into IInterval together with the judgmental equality that line 0 is left and line 1 is right, basically a desugaring of the equality with additional features. This makes line a valid constructor in normal type theory: it takes some parameters and returns Interval.
  2. These judgmental equalities need to be preserved by the elimination rule of Interval. Here is an example elimination:
example def Interval-elim {a b : A} {p : a = b} (i : Interval) : A elim i
+| lefta
+| rightb
+| line jp j
+

Note that the term pmap Interval-elim line, which reduces to p, has type Interval-elim left = Interval-elim right, so we need to check if p 0 equals Interval-elim left, and p 1 equals Interval-elim right. This is a confluence check that ensures the elimination is well-defined.

What's interesting about this type, is that its elimination implies function extensionality:

private def lemma
+  (f g : AB) (p :  xf x = g x)
+  (i : Interval) (a : A) : B elim i
+| leftf a
+| rightg a
+| line jp a j
+
+example def funExt' (f g : AB) (p :  af a = g a) : f = g ⇒
+  pmap (lemma f g p) (fn iline i)
+

Note that even though we are using equation combinators like pmap which are implemented using path application and abstraction, it is not considered cheating because these are already theorems in MLTT anyway.

We can define other interesting quotients such as a symmetric integer:

open inductive Int
+| pos Nat | neg Nat
+| zro : pos 0 = neg 0
+

Some operations on Int:

def succ Int : Int
+| pos npos (suc n)
+| neg 0 ⇒ pos 1
+| neg (suc n) ⇒ neg n
+| zro ipos 1
+
+def abs Int : Nat
+| pos nn
+| neg nn
+| zro _ ⇒ 0
+

The succ operator has the first three clauses straightforward, and the last one is a proof of succ (neg 0) equals succ (pos 0), as we should preserve the judgmental equality in the type of zro. We need to do the same for abs.

+ + + + \ No newline at end of file diff --git a/guide/readings.html b/guide/readings.html new file mode 100644 index 0000000..2b6e301 --- /dev/null +++ b/guide/readings.html @@ -0,0 +1,28 @@ + + + + + + Recommended Reading | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Recommended Reading

This is a list of documents that are helpful or simply related to the design & implementation of Aya, randomly ordered.

Beware that you are encouraged to suggest changes to this page! Just go to the bottom of this page and there will be a link. Apart from this list, Jon Sterling's cubical bibliography is also a good source of information.

Universes

Equality and Higher/Quotient Inductive Types

Cubical Type Theory

Compilation and Code Generation

Unification, Implicits, and Constraints

Pattern Matching

Miscellaneous

  • Coq's Vibrant Ecosystem for Verification Engineering, by Andrew W. Appel
    CPP 2022
  • The End of History? Using a Proof Assistant to Replace Language Design with Library Design, by Adam Chlipala, Benjamin Delaware, Samuel Duchovni, Jason Gross, Clément Pit-Claudel, Sorawit Suriyakarn, Peng Wang, Katherine Ye
    SNAPL 2017
+ + + + \ No newline at end of file diff --git a/guide/vscode-tutorial.html b/guide/vscode-tutorial.html new file mode 100644 index 0000000..d0000c0 --- /dev/null +++ b/guide/vscode-tutorial.html @@ -0,0 +1,28 @@ + + + + + + So you are using VSCode | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

So you are using VSCode

Go to GitHub Releases, click the latest successful run, scroll down to the bottom of the page, download the "aya-prover-vscode-extension", and unzip it. Then, follow VSCode docs to install the extension.

It remains to configure the Aya language server. There are two ways to use the server. First, open settings, search for "Aya path", you should see a text box. Then, you have a choice:

  1. Use a jar file. Put your lsp-fatjar.jar file path there. Make sure you have a java executable in the Path (recommended) or in java.home key in the settings json.
  2. Use the jlink version of Aya. Put the aya-lsp (or aya-lsp.bat if you are on Windows) file path there, which is under the bin folder of the jlink distribution. In this case, you don't need to have a java executable in the Path.

Then, open a directory that is an Aya project (see project-tutorial). Open any .aya file, you should see some basic highlight (keywords, comments, etc.). Wait for VSCode to activate the extension, and hit Ctrl+L Ctrl+L to load the file. At this point, you should see advanced highlight (type names, constructors, etc.), with clickable definitions.

The rest of the features should be quite discoverable for regular programmers, such as hovering a red or a yellow wavy line to see the error message, etc. Please create issues and discuss ideas on how to improve the error reports.

+ + + + \ No newline at end of file diff --git a/hashmap.json b/hashmap.json new file mode 100644 index 0000000..f816643 --- /dev/null +++ b/hashmap.json @@ -0,0 +1 @@ +{"blog_binops.md":"CdTTQPUm","blog_bye-hott.md":"BrkJeJl8","blog_class-defeq.md":"B5iu-E0L","blog_extended-pruning.md":"CVuBUw6d","blog_ind-prop.md":"gSiorRXd","blog_index-unification.md":"8JIbTjsd","blog_index.md":"DFYRtLrm","blog_lang-exts.md":"DfBlE6eJ","blog_path-elab.md":"DMxfi4CO","blog_pathcon-elab.md":"qxT9XSmx","blog_redirect.md":"dnCf5fLC","blog_tt-in-tt-qiit.md":"DGl7KXmS","guide_fake-literate.md":"wKOOxSKp","guide_haskeller-tutorial.md":"CwlnPH1m","guide_index.md":"CiHHc-gO","guide_install.md":"NmQ5a4E1","guide_project-tutorial.md":"Brh1y7za","guide_prover-tutorial.md":"DBob0Be6","guide_readings.md":"zYAL6Jj9","guide_vscode-tutorial.md":"DiZyYf9h","index.md":"CMxZ7gZj","pubs_index.md":"D4yWMioC"} diff --git a/header.jpg b/header.jpg new file mode 100644 index 0000000..8894855 Binary files /dev/null and b/header.jpg differ diff --git a/index.html b/index.html new file mode 100644 index 0000000..7939d7b --- /dev/null +++ b/index.html @@ -0,0 +1,28 @@ + + + + + + Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Aya Prover

A proof assistant designed for formalizing math and type-directed programming.

+ + + + \ No newline at end of file diff --git a/logo.svg b/logo.svg new file mode 100644 index 0000000..1a723c9 --- /dev/null +++ b/logo.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/pubs/index.html b/pubs/index.html new file mode 100644 index 0000000..537ad6f --- /dev/null +++ b/pubs/index.html @@ -0,0 +1,28 @@ + + + + + + Publications | Aya Prover + + + + + + + + + + + + + + + + + +
Skip to content

Publications

This is a list of publications related to Aya by the Aya developers.

Papers

Notes

+ + + + \ No newline at end of file diff --git a/vp-icons.css b/vp-icons.css new file mode 100644 index 0000000..ddc5bd8 --- /dev/null +++ b/vp-icons.css @@ -0,0 +1 @@ +.vpi-social-github{--icon:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M12 .297c-6.63 0-12 5.373-12 12c0 5.303 3.438 9.8 8.205 11.385c.6.113.82-.258.82-.577c0-.285-.01-1.04-.015-2.04c-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729c1.205.084 1.838 1.236 1.838 1.236c1.07 1.835 2.809 1.305 3.495.998c.108-.776.417-1.305.76-1.605c-2.665-.3-5.466-1.332-5.466-5.93c0-1.31.465-2.38 1.235-3.22c-.135-.303-.54-1.523.105-3.176c0 0 1.005-.322 3.3 1.23c.96-.267 1.98-.399 3-.405c1.02.006 2.04.138 3 .405c2.28-1.552 3.285-1.23 3.285-1.23c.645 1.653.24 2.873.12 3.176c.765.84 1.23 1.91 1.23 3.22c0 4.61-2.805 5.625-5.475 5.92c.42.36.81 1.096.81 2.22c0 1.606-.015 2.896-.015 3.286c0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12'/%3E%3C/svg%3E")} \ No newline at end of file