Try Pro free

Machine Learning Street Talk · 5 min · Jan 9, 2025

Program synthesis works better as graph search than code generation

François Chollet argues that programs should be represented as graphs of operators, with language models guiding discrete search.

The episode’s best minutes

Full analysis
  1. 10:49Compute amplified ideas more than raw spendingPro pick 5 min
  2. 30:11ARC methods solved different kinds of tasksPro pick 6 min
  3. 41:55Program synthesis works better as graph search than code generationPro pick 5 min
  4. 5 more moments in the full episode
Up next · Training DataDatabricks bet on Spark partnerships, even with competitors4:13
“I think the right way to think about a program is as a graph of operators and program search, program synthesis is basically a tree search process.”
François Cholletat 42:42 · Machine Learning Street Talk
42:42

Takeaways Pro pick

  1. Treat a program as a graph, not a token sequence.
  2. Use models to guide search through program structures.
  3. Task models can narrow the search to a few candidates.

About this segment

François Chollet argues that programs should be represented as graphs of operators, with language models guiding discrete search. That enables targeted edits that token-by-token code generation makes difficult.

François Chollet

François Chollet is an AI researcher and Keras developer.

Created Keras and the ARC-AGI benchmark at Google, then co-founded Ndea with Mike Knoop to pursue AGI through program synthesis.

  • TS

    Tim Scarfe, Host · Host, Machine Learning Street Talk

From “François Chollet on OpenAI o-models and ARC”, Jan 9, 2025. Watch the full episode

Transcript

Transcribed by machine (Whisper) from the episode’s audio, so a word may be off here and there.

  1. 42:07

    So other unexplored avenues of ARC, maybe a better way to ask this is if you yourself spent a year working on ARC, what would you do? I would be doing deep learning guided program synthesis. And, you know, I think the way people are doing the planning-related program studies today is wrong. So everyone is leveraging LLMs, which, of course, makes sense because there are these very powerful tools that contain a lot of useful knowledge that can be replied on any problem.

  2. 42:35

    We've invested billions and billions of dollars into creating these tools. So not using these tools would feel like you're missing out on a lot of power. But I think it is not the right approach to treat program synthesis as just token by token code generation. I think the right way to think about a program is as a graph of operators and program search, program synthesis is basically a tree search process. I think you're better off trying to use deep planning models and in particular LLMs to guide that tree search process. This is not something that many people are trying today, but I think this would be closer to the right approach. Another thing that people are not doing today but should be is that if you look at the way humans solve ARC puzzles, they are not trying many different solution programs in their mind. They are only trying a few. I think humans have

  3. 43:37

    capability to first describe a model with their thing and use this model basically describing like a grid for instance in terms of the objects it contains and their properties and their relationships with other objects with a focus on causal relationships in particular. You can use these descriptive models to constrain the search space when you are finally looking at input-to-output programs, and that's the reason why we only need to consider a handful of programs before finding the correct one.

  4. 44:18

    so in that sense you know it might be possible to do enough modeling of the task to almost make search irrelevant to remove the almost entirely remove the need for search it's so interesting what you just said we should we should meditate on that just for a second so first of all loads of people I've interviewed this week especially in the neural evolution kind of space you know under jeff clune for example many of them are latching on to llms because they say we need to have a measure of interestingness or novelty and llms because they're trained on all of the data in the world they they capture our instincts really really well our intuition and so on so they're a great way of generating programs but but you said though that it's not such a good idea just to generate the program the next step of evolution is guiding the search and i think we're

  5. 45:15

    starting to see this enlightenment in the use of llms in many commercial bits of software so for example the original llm in an app was you just have a chat bot and you just stick it in there now things like cursor for example they're exposing a low level api and they're using you know tool use and so on and the llm is actually guiding the low level you know api interactions in the app and so you're advocating for a similar evolution here where the llm actually guides the discrete search process rather than just generating code. That's right. And the idea being that by creating your program via this iterative discrete search process, you actually have the ability to make targeted modifications to your program graph that would be significantly harder to make if you just treat the program as just a sequence of tokens. And also you're changing the nature of the space

  6. 46:10

    in which you are making addition decisions, right? And CRATs are just the natural data structure to represent programs. Programs are not sequences of tokens. Another thing we're seeing is an intermediate solution.