    (s/optional-key :lvl) s/Int
    (s/optional-key :bonded) (s/eq true)
    (s/optional-key :prerequisites) Prerequisite
-   (s/optional-key :bonuses) #{Bonus}
+   (s/optional-key :effects) #{Effect}
    (s/optional-key :heft) (s/enum :heavy :light)
    (s/optional-key :time-to-equip) GameTime
    :cost {:value s/Int :unit s/Str}})

          :Sense
          :Charm))

(s/defschema Check (s/enum
                     :Push :Pull :Jump :Catch :Throw :Run :Climb :Grab :Hold :Block :Melee-Attack
                     :Balance :Tumble :Dodge :Parry :Range-Attack :Hide
                     :Resist :Heal-Self
                     :Find :Recall :Learn :Triage :Cure
                     :Look :Smell :Taste :Touch :Hear :Detect-Psychic
                     :Inspire :Sway :Mock :Tame :Lie))

(s/defschema Stats {Stat Score})

(s/defschema Prerequisite
  (s/constrained

   :skills #{Skill-Id}
   :items #{Item-Id}})

(s/defschema Solution
  {:check All-Checks
   :mark s/Int
   (s/enum :succeed :fail) Effect})

(s/defschema Obstacle
  {:id Obstacle-Id
   :name s/Str
   :description s/Str
   :effects #{Effect}
   :solutions #{Solution}})

(s/defschema Context
  (s/constrained
    {:checks {Check-Id Custom-Check}
     :damage-types {Damage-Id Damage-Type}
     :conditions {Condition-Id Condition}
     :kin {Kin-Id Kin}
     :castes {Caste-Id Caste}
     :items {Item-Id Item}
     :skills {Skill-Id Skill}
     :skill-sets {Skill-Set-Id Skill-Set}
     :characters {Char-Id Character}
     :obstacles {Obstacle-Id Obstacle}}
    v/validate-compendium
    'Compendium))

(s/defschema Answer
  {:text s/Str
   :next #{Question-Id}})

(s/defschema Question-Node
{:id Question-Id
 :question s/Str
 :answer (s/cond-pre
           Answer
           {:checks #{{:check All-Checks
                       :mark s/Int}}
            :fail Answer
            :succeed Answer})})

(s/defschema NPC
  {:character Char-Id
   :questions {Question-Id Question-Node}
   :base-line #{Question-Id}})

(s/defschema Position {:x s/Int :y s/Int})

(s/defschema Door
  {:label s/Str
   :description s/Str
   :to Room-Id})

(s/defschema Room
  {:id Room-Id
   :name s/Str
   :description s/Str
   :shape (s/cond-pre
            {:width s/Int :height s/Int}
            {:points [Position]})
   (s/optional-key :doors) #{Door}
   (s/optional-key :contents){Position (s/cond-pre Char-Id NPC-Id Obstacle-Id Item-Id)}})

(s/defschema Maze
  {:rooms {Room-Id Room}
   :entrance Room-Id
   :exit Room-Id})

(s/defschema Chapter
  {:intro s/Str
   :outro s/Str
   :maze Maze-Id})

(s/defschema Story
  {:title s/Str
   :prologue s/Str
   :epilogue s/Str
   :chapters [Chapter]})

(s/defschema Adventure
  {:context Context
   :story Story
   :mazes {Maze-Id Maze}
   :NPCs {NPC-Id NPC}})