grep comes really from ed (g/re/p) but sed is the stream editor and is based on qed (quick editor) and ed.

Niels Kobschätzki @nielsk