Module unique := fc_unique wf subst.

(* Specifications: *)
Lemma AnnTyping_regularity : (forall G a A, AnnTyping G a A -> AnnTyping G A a_Star).
Lemma AnnPropWff_regularity : forall G A B A1, AnnPropWff G (Eq A B A1) -> exists B1 g, AnnTyping G A A1 /\ AnnTyping G B B1 /\ AnnDefEq G empty g A1 B1.
Lemma erase_pi : forall G AB0 rho A B S, erase AB0 = (a_Pi rho A B) -> AnnTyping G AB0 S -> exists A1 B0, erase AB0 = erase (a_Pi rho A1 B0) /\ erase A1 = A /\ erase B0 = B /\ AnnTyping G (a_Pi rho A1 B0) a_Star.
Lemma erase_cpi : forall AB0 A B G S, erase AB0 = (a_CPi A B) -> AnnTyping G AB0 S -> exists A1 B0, erase AB0 = erase (a_CPi A1 B0) /\ erase_constraint A1 = A /\ erase B0 = B /\ AnnTyping G (a_CPi A1 B0) a_Star.
Lemma erase_app_Rel : forall AB0 A B C G, erase AB0 = (a_App A Rel B) -> AnnTyping G AB0 C -> exists A1 B0 g D, erase AB0 = erase (a_App A1 Rel B0) /\ erase A1 = A /\ erase B0 = B /\ AnnTyping G (a_App A1 Rel B0) D /\ AnnDefEq G (dom G) g C D.
Lemma erase_app_Irrel : forall AB0 A C G, erase AB0 = (a_App A Irrel a_Bullet) -> AnnTyping G AB0 C -> exists A1 B0 g D, erase AB0 = erase (a_App A1 Irrel B0) /\ erase A1 = A /\ AnnTyping G (a_App A1 Irrel B0) D /\ AnnDefEq G (dom G) g C D.
Lemma erasure_compatible : forall G a A (H1 :AnnTyping G a A), forall b B (H2 : AnnTyping G b B) (E : erase a = erase b) (F : erase A = erase B), exists g1, AnnDefEq G (dom G) g1 a b.
Lemma AnnDefEqAnnIso_regularity : (forall G0 a A, AnnTyping G0 a A -> True ) /\ (forall G0 phi, AnnPropWff G0 phi -> True ) /\ (forall G D g p1 p2, AnnIso G D g p1 p2 -> AnnPropWff G p1 /\ AnnPropWff G p2) /\ (forall G D g A B, AnnDefEq G D g A B -> exists C1 C2 g', AnnTyping G A C1 /\ AnnTyping G B C2 /\ AnnDefEq G (dom G) g' C1 C2) /\ (forall G0, AnnCtx G0 -> True).