hans / puddle-world

1 stars 1 forks source link

Custom PyCCG-driven enumeration for Dreamcoder. #12

Closed CatherineWong closed 5 years ago

CatherineWong commented 5 years ago

Implements ECLanguageLearner, a custom driver that uses PyCCG for timed enumeration (and falls back to blind multicore enumeration).

Relies on https://github.com/ellisk42/ec/pull/50, which allows passing custom 'wake_generative' functions for custom enumeration to Dreamcoder.

This is a nearly-complete version of a PyCCG driven enumeration function that should:

  1. Use a PyCCG WordLearner to enumerate semantics for a batch of tasks;
  2. Use blind enumeration to enumerate semantics for the unsolved tasks;
  3. Update the WordLearner with supervision from the blind enumerator;
  4. Return all of the frontiers to continue in Dreamcoder as usual.

Importantly, currently we do not actually update the PyCCG WordLearner with supervision from the frontiers discovered via blind enumeration. https://github.com/hans/pyccg/issues/5 should implement this.