(defparameter *ccg-grammar*
'(((KEY 1) (PHON KNOWS) (MORPH V)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL STAR) ((BCAT NP) (FEATS NIL)))
     (DIR FS) (MODAL HARMONIC) ((BCAT NP) (FEATS NIL))))
   (SEM (LAM X (LAM Y (("KNOW" X) Y)))) (PARAM 3.8629303))
  ((KEY 2) (PHON KNOWS) (MORPH V)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL STAR) ((BCAT NP) (FEATS NIL)))
     (DIR FS) (MODAL HARMONIC) ((BCAT S) (FEATS NIL))))
   (SEM (LAM S (LAM X (("KNOW" S) X)))) (PARAM 2.21802))
  ((KEY 3) (PHON KNOWS) (MORPH V)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL STAR) ((BCAT NP) (FEATS NIL)))
     (DIR FS) (MODAL HARMONIC) ((BCAT NP) (FEATS NIL))))
   (SEM (LAM X (LAM Y (("KNOW" Y) X)))) (PARAM -0.4314654))
  ((KEY 4) (PHON KNOWS) (MORPH V)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL STAR) ((BCAT NP) (FEATS NIL)))
     (DIR FS) (MODAL HARMONIC) ((BCAT S) (FEATS NIL))))
   (SEM (LAM S (LAM X (("KNOW" X) S)))) (PARAM -0.7900369))
  ((KEY 5) (PHON LOVES) (MORPH V)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL STAR) ((BCAT NP) (FEATS NIL)))
     (DIR FS) (MODAL HARMONIC) ((BCAT NP) (FEATS NIL))))
   (SEM (LAM X (LAM Y (("LOVE" X) Y)))) (PARAM 4.241246))
  ((KEY 6) (PHON LOVES) (MORPH V)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL STAR) ((BCAT NP) (FEATS NIL)))
     (DIR FS) (MODAL HARMONIC) ((BCAT NP) (FEATS NIL))))
   (SEM (LAM X (LAM Y (("LOVE" Y) X)))) (PARAM -2.2412465))
  ((KEY 7) (PHON JOHN) (MORPH N)
   (SYN
    (((BCAT S) (FEATS NIL)) (DIR FS) (MODAL ALL)
     (((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "JOHN"))) (PARAM 3.2668285))
  ((KEY 8) (PHON JOHN) (MORPH N)
   (SYN
    (((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL)
     (((BCAT S) (FEATS NIL)) (DIR FS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "JOHN"))) (PARAM 1.9911809))
  ((KEY 9) (PHON JOHN) (MORPH N)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
     (DIR BS) (MODAL ALL)
     ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
      (DIR FS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "JOHN"))) (PARAM 2.4334605))
  ((KEY 10) (PHON JOHN) (MORPH N)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
     (DIR BS) (MODAL ALL)
     ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
      (DIR FS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (LAM X (("JOHN" P) X)))) (PARAM -0.17698202))
  ((KEY 11) (PHON MARY) (MORPH N)
   (SYN
    (((BCAT S) (FEATS NIL)) (DIR FS) (MODAL ALL)
     (((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "MARY"))) (PARAM 3.0476155))
  ((KEY 12) (PHON MARY) (MORPH N)
   (SYN
    (((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL)
     (((BCAT S) (FEATS NIL)) (DIR FS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "MARY"))) (PARAM 2.1366656))
  ((KEY 13) (PHON MARY) (MORPH N)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
     (DIR BS) (MODAL ALL)
     ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
      (DIR FS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "MARY"))) (PARAM 2.646367))
  ((KEY 14) (PHON MARY) (MORPH N)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
     (DIR BS) (MODAL ALL)
     ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
      (DIR FS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (LAM X (("MARY" P) X)))) (PARAM -0.3603557))
  ((KEY 15) (PHON JOHN) (MORPH N)
   (SYN
    (((BCAT S) (FEATS NIL)) (DIR FS) (MODAL ALL)
     (((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "DOG"))) (PARAM -1.1742549))
  ((KEY 16) (PHON JOHN) (MORPH N)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
     (DIR BS) (MODAL ALL)
     ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
      (DIR FS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "DOG"))) (PARAM -0.17698202))
  ((KEY 17) (PHON MARY) (MORPH N)
   (SYN
    (((BCAT S) (FEATS NIL)) (DIR FS) (MODAL ALL)
     (((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "CAT"))) (PARAM -1.0884278))
  ((KEY 18) (PHON MARY) (MORPH N)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
     (DIR BS) (MODAL ALL)
     ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
      (DIR FS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "CAT"))) (PARAM -0.3603557))))

(defparameter *ccg-grammar*
'(((KEY 1) (PHON KNOWS) (MORPH V)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL STAR) ((BCAT NP) (FEATS NIL)))
     (DIR FS) (MODAL HARMONIC) ((BCAT NP) (FEATS NIL))))
   (SEM (LAM X (LAM Y (("KNOW" X) Y)))) (PARAM 3.8629303))
  ((KEY 2) (PHON KNOWS) (MORPH V)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL STAR) ((BCAT NP) (FEATS NIL)))
     (DIR FS) (MODAL HARMONIC) ((BCAT S) (FEATS NIL))))
   (SEM (LAM S (LAM X (("KNOW" S) X)))) (PARAM 2.21802))
  ((KEY 3) (PHON KNOWS) (MORPH V)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL STAR) ((BCAT NP) (FEATS NIL)))
     (DIR FS) (MODAL HARMONIC) ((BCAT NP) (FEATS NIL))))
   (SEM (LAM X (LAM Y (("KNOW" Y) X)))) (PARAM -0.4314654))
  ((KEY 4) (PHON KNOWS) (MORPH V)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL STAR) ((BCAT NP) (FEATS NIL)))
     (DIR FS) (MODAL HARMONIC) ((BCAT S) (FEATS NIL))))
   (SEM (LAM S (LAM X (("KNOW" X) S)))) (PARAM -0.7900369))
  ((KEY 5) (PHON LOVES) (MORPH V)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL STAR) ((BCAT NP) (FEATS NIL)))
     (DIR FS) (MODAL HARMONIC) ((BCAT NP) (FEATS NIL))))
   (SEM (LAM X (LAM Y (("LOVE" X) Y)))) (PARAM 4.241246))
  ((KEY 6) (PHON LOVES) (MORPH V)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL STAR) ((BCAT NP) (FEATS NIL)))
     (DIR FS) (MODAL HARMONIC) ((BCAT NP) (FEATS NIL))))
   (SEM (LAM X (LAM Y (("LOVE" Y) X)))) (PARAM -2.2412465))
  ((KEY 7) (PHON JOHN) (MORPH N)
   (SYN
    (((BCAT S) (FEATS NIL)) (DIR FS) (MODAL ALL)
     (((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "JOHN"))) (PARAM 3.2668285))
  ((KEY 8) (PHON JOHN) (MORPH N)
   (SYN
    (((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL)
     (((BCAT S) (FEATS NIL)) (DIR FS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "JOHN"))) (PARAM 1.9911809))
  ((KEY 9) (PHON JOHN) (MORPH N)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
     (DIR BS) (MODAL ALL)
     ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
      (DIR FS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "JOHN"))) (PARAM 2.4334605))
  ((KEY 10) (PHON JOHN) (MORPH N)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
     (DIR BS) (MODAL ALL)
     ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
      (DIR FS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (LAM X (("JOHN" P) X)))) (PARAM -0.17698202))
  ((KEY 11) (PHON MARY) (MORPH N)
   (SYN
    (((BCAT S) (FEATS NIL)) (DIR FS) (MODAL ALL)
     (((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "MARY"))) (PARAM 3.0476155))
  ((KEY 12) (PHON MARY) (MORPH N)
   (SYN
    (((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL)
     (((BCAT S) (FEATS NIL)) (DIR FS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "MARY"))) (PARAM 2.1366656))
  ((KEY 13) (PHON MARY) (MORPH N)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
     (DIR BS) (MODAL ALL)
     ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
      (DIR FS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "MARY"))) (PARAM 2.646367))
  ((KEY 14) (PHON MARY) (MORPH N)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
     (DIR BS) (MODAL ALL)
     ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
      (DIR FS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (LAM X (("MARY" P) X)))) (PARAM -0.3603557))
  ((KEY 15) (PHON JOHN) (MORPH N)
   (SYN
    (((BCAT S) (FEATS NIL)) (DIR FS) (MODAL ALL)
     (((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "DOG"))) (PARAM -1.1742549))
  ((KEY 16) (PHON JOHN) (MORPH N)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
     (DIR BS) (MODAL ALL)
     ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
      (DIR FS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "DOG"))) (PARAM -0.17698202))
  ((KEY 17) (PHON MARY) (MORPH N)
   (SYN
    (((BCAT S) (FEATS NIL)) (DIR FS) (MODAL ALL)
     (((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "CAT"))) (PARAM -1.0884278))
  ((KEY 18) (PHON MARY) (MORPH N)
   (SYN
    ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
     (DIR BS) (MODAL ALL)
     ((((BCAT S) (FEATS NIL)) (DIR BS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))
      (DIR FS) (MODAL ALL) ((BCAT NP) (FEATS NIL)))))
   (SEM (LAM P (P "CAT"))) (PARAM -0.3603557))))
