whatever generative ai is up to now -- week 1
i cloned the ml5.js repository (git clone https://github.com/ml5js/ml5-library.git) to understand how a machine learning library designed for creative coding is structured under the hood. ml5 sits on top of TensorFlow.js but wraps complex machine learning workflows into simpler JavaScript functions that artists and designers can use in the browser. looking through the repo, the src/ folder contains the core library code, where different model interfaces are defined, while dist/ contains the compiled version that people actually load in their sketches. the examples/ folder was especially helpful because it shows how models like image classifiers or pose detection are typically used in practice with p5.js. one thing that became clear while exploring the code is that most of the heavy computation is handled by pretrained TensorFlow models, while ml5 focuses on simplifying how those models are loaded and how predictions are returned to the user. using Claude to walk through the structure helped me trace how a model gets initialized, how input data is passed into it, and how results are returned to the sketch. this made the library feel less like a black box and more like a set of organized abstractions sitting on top of existing machine learning tools.
i used Claude to help map the structure of the repository and explain how the model-loading process works. the most useful prompts were ones that asked it to walk through the execution flow of the code rather than just summarize the project.
here are some writing samples: speech recognition piece, gaza interview reflection, halim el-dabh