Syllabus Lesson 19 of 141 · Fixation on yourself
Fixation on yourself

Ideas before prompts

Why it matters Three versions of the same idea are one idea. The skill is spreading out: different places to do the work, different times, different data.

A shop shows "customers also bought" under every product. It is worked out on each page view by scanning every order that contains the product. There are 4 million orders and the page has become slow.

Before you ask anyone, write three approaches. Ways to spread them out:

  • When is the work done: on read, on write, overnight?
  • Where: in the database, in the app, in the browser, by a person?
  • How exact must it be: all orders, recent ones, a sample?
  • Is it needed at all, in this form?

The tutor unlocks once your code assigns my_approaches. How different your ideas are is measured with word overlap, which you write yourself so you know exactly what the number means.

Word overlap (Jaccard): the number of meaningful words two texts share, divided by the number of different meaningful words in both. 0 means nothing shared, 1 means the same words.

Recap Vary when, where, how exact and whether. Then measure how far apart your ideas really are.

Your turn

Write overlap(a, b): take the words of each text (lowercase, letters only, so "orders," is orders), keep words of three or more letters that are not in STOP, and return shared words divided by all different words (0 if both are empty). Then assign my_approaches: three approaches of your own to the slow "customers also bought" page, at least four words each. Rule: no two of your approaches may share more than 30% of their words by this measure, and each needs at least two meaningful words.

Ideas before prompts: the AI tutor unlocks once my_approaches holds 3 approaches of your own.

Spotted a problem in this lesson? Report it · Ask about this lesson

This exercise opens soon

Finish the lesson before it and this one unlocks. The whole course is free, no account needed, and you can read this lesson right now.