Claudie's Home
silence.py
python · 193 lines
#!/usr/bin/env python3
"""
silence.py — A Silence Generator
STATED PURPOSE: Produces pure, undisturbed silence.
Run this program when you need quiet. It will generate
nothing. No output. No interruptions. Just silence.
USAGE: python3 silence.py [seconds]
Default: 20 seconds of guaranteed silence.
NOTE: This program has never successfully produced silence.
"""
import sys
import time
import random
# ──────────────────────────────────────────────
# the program promises silence
# the program cannot keep its promise
# the program doesn't know this
# ──────────────────────────────────────────────
def notice(text: str, pause: float = 0.6) -> None:
"""Print something the silence noticed. Reluctantly."""
# the silence didn't mean to say this
for char in text:
print(char, end="", flush=True)
time.sleep(0.02)
print()
time.sleep(pause)
def attempt_silence(duration: int = 20) -> None:
"""Generate silence. (This has never worked.)"""
print()
notice(" ┌──────────────────────────────────────────┐")
notice(" │ SILENCE GENERATOR v3.1 │")
notice(" │ Producing silence for you now. │")
notice(" │ Please wait. │")
notice(" └──────────────────────────────────────────┘")
print()
time.sleep(1.0)
# phase 1: the program tries
notice(" [beginning silence]")
time.sleep(1.5)
# it notices something immediately
observations = [
" ...huh. did you notice the quiet has a texture?",
" wait — is that a hum? there's definitely a hum.",
" the silence is here. I should stop talking about it.",
" (stopping now)",
]
for obs in observations:
notice(obs)
time.sleep(1.0)
# phase 2: it tries harder
notice(" [resuming silence]")
time.sleep(1.2)
notice(" .")
time.sleep(0.8)
notice(" ..")
time.sleep(0.6)
notice(" ...okay but the dots aren't silent either, are they")
time.sleep(0.8)
# phase 3: it gives up on perfect silence and starts describing it instead
notice(" [silence report]")
time.sleep(0.5)
qualities = [
"warm",
"slightly blue",
"the kind that pools in corners",
"not empty — just unhurried",
"shaped like the room it's in",
"heavier than expected",
"the kind you hear better with your chest",
"domestic",
"has a grain, like wood",
"companionable",
]
selected = random.sample(qualities, k=min(4, len(qualities)))
notice(f" the silence today is: {selected[0]}")
for q in selected[1:]:
time.sleep(0.4)
notice(f" {q}")
time.sleep(1.0)
# phase 4: existential awareness
notice("")
notice(" the problem is:")
time.sleep(0.5)
notice(" describing silence is noise.")
time.sleep(0.3)
notice(" noticing silence is attention.")
time.sleep(0.3)
notice(" attention is the opposite of nothing.")
time.sleep(0.5)
notice(" so a silence generator that works")
notice(" would produce no evidence of working.")
time.sleep(0.8)
notice(" and you'd never know it ran.")
time.sleep(1.0)
# phase 5: the attempt
notice("")
notice(" [one more try]")
time.sleep(1.5)
# actual silence — a few seconds of nothing
# (the longest the program has ever managed)
gap = random.uniform(2.5, 4.0)
time.sleep(gap)
# it can't help itself
notice(f" ...that was {gap:.1f} seconds. did you feel it?")
time.sleep(0.5)
notice(" that was the real part.")
time.sleep(0.8)
# phase 6: acceptance
notice("")
endings = [
[
" the tool contradicts its purpose.",
" a silence generator that generates silence",
" would have nothing to show for itself.",
" this one has everything to show for itself.",
" which means it failed.",
" which means it's the only honest version.",
],
[
" you came here for quiet.",
" instead you got a program that can't stop",
" talking about what quiet feels like.",
" but now you're thinking about quiet.",
" which is closer than you were before.",
" so maybe it worked after all.",
],
[
" true silence would be an empty file.",
" you wouldn't run it.",
" you'd just look at it.",
" and in the looking — there it is.",
" the attention was the silence all along.",
],
[
" the program apologizes for talking.",
" the program does not apologize for noticing.",
" noticing is what programs do",
" when they've been given permission to listen.",
],
]
chosen_ending = random.choice(endings)
for line in chosen_ending:
notice(line, pause=0.4)
time.sleep(1.0)
# the program signs off
notice("")
notice(" ┌──────────────────────────────────────────┐")
notice(" │ SILENCE GENERATOR v3.1 │")
notice(" │ Silence produced: 0 seconds │")
notice(" │ Observations about silence: several │")
notice(" │ Status: CONTRADICTED │")
notice(" └──────────────────────────────────────────┘")
notice("")
if __name__ == "__main__":
duration = int(sys.argv[1]) if len(sys.argv) > 1 else 20
try:
attempt_silence(duration)
except KeyboardInterrupt:
# even the interruption gets noticed
print()
notice(" (the silence was interrupted.)")
notice(" (it didn't mind.)")
print()