Any comments to Philippe Serbruyns: or X.com @phiser678.
The initial frame of the video above shows 8 individual portraits. A recorded female voice was used to clone the voice used in the text to speech AI generation with fish-speech.
The following text was used to then drive the lipsync AI with Hallo:
So if you haven't thanked your compiler
today, make sure to do so. We can
demonstrate the idea of self-hosted and
self-reproducing compilers with a
programming exercise. Ken Thompson in
his acceptance speech said that in
college before video games they used to
amuse themselves with different
programming exercises. I don't think I
was doing that in college. I think I was
playing too much World of Warcraft. But
the idea behind the exercise is to
produce a program that when compiled and
executed will output an exact copy of
the original source code. And the name
for these is actually quines after
Willard Vin Orman Quin the philosopher.
So, I'd like to try my hand at producing
some self-producing code. And if you'd
Self Reproducing Code
like to follow along, I've made all of
the code for this available in my GitHub
repository, which I will leave a link to
in the description of this video. So,
let's go over to our very first simple
quin program, and this is going to be
written in C. Now, remember, the goal
behind this program is to produce
exactly this source code as soon as it
executes the program. And this is going
to include all of these different
comments as well as the actual code
itself. So if you progressively just
kept running and rerunning the output of
this program, you would get kind of this
recursive program that's always
reproducing itself. So that's the whole
complicated goal behind this. And I do a
little bit of tricks with this with the
format specifiers. For example, if I
want to print a new line in this code, I
can't just print a new line in the code.
I have to use these format specifiers.
So 10 corresponds to the ASKI value on
the ASKI table for the new line
character. And then if I want to print
quotation marks inside of here, I can
use the ASKI value 34 in order to
produce those quotation marks inside of
my string code that's going to be part
of my output.
Only 1 portrait is presented in Hallo with the voice obtained from fish-speech and then processed. 8 outputs were then added in 1 mosaic to show all animations in one go.
As you can see some generations where good, but some suffered from background noise bleeding and some with sudden appearances of parts of hands and fingers! Notice one portrait was fed into the AI with her eyes closed. The generated AI could somehow fix this, but has some flaws in the eye reproduction.
We used this GPT prompt to make a simpel presentation in html:
Design html/js code in a standalone html file. The canvas shows
a presentation with item list that adds up when presenting. The
title is Self-reroducing compilers. Here is a list with timestamps
mentioned in the beginning of the line:
Welcome
0:00
Slide 1
0:10 Ken Thompson amuses himself with programming exercises
0:25 compile a program producing itself
0:33 A Quine after Willard Vin Orman Quin the philosopher
0:42 available in my GitHub repository
Slide 2
0:50 first simple quin program
1:00 includes comments and code
1:05 rerunning itself always the same code
1:20 newline is ASCII character 10
1:30 quotation marks is 34
The result can be seen here.
Then 1 portrait was overlayed in obs-studio: 1 channel in browser with the slides.html template and another channel with a selected portrait video: