Part of Val Town Semantic Search.

Generates OpenAI embeddings for all public vals, and stores them in Neon, using the pg_vector extension.

  • Create the vals_embeddings table in Neon if it doesn't already exist.
  • Get all val names from the database of public vals, made by Achille Lacoin.
  • Get all val names from the vals_embeddings table and compute the difference (which ones are missing).
  • Iterate through all missing vals, get their code, get embeddings from OpenAI, and store the result in Neon.
  • Can now be searched using janpaul123/semanticSearchNeon.

Migrated from folder: semanticSearchPrototype/indexValsNeon