writers-room 0.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,44 @@
1
+ Metadata-Version: 2.4
2
+ Name: writers-room
3
+ Version: 0.1.0
4
+ Summary: Collaborative writers room multi-agent narrative brainstorming engine
5
+ Requires-Python: >=3.10
6
+ Description-Content-Type: text/markdown
7
+ Requires-Dist: requests>=2.31.0
8
+
9
+ # WritersRoom (`PROJ-WRITERS-ROOM-01`)
10
+ > Virtual Writers Room Powered by ColorQL & CrystalSpace Multi-Agent Architecture
11
+
12
+ ## Overview
13
+ **WritersRoom** is an autonomous multi-agent narrative engineering engine. It allows creators, game studios, and writers to convene iconic or custom authors into a shared virtual room alongside **The Crystal Arbiter** (`NeutralAgent`).
14
+
15
+ Each author is modeled through an **Author Crystal** consisting of:
16
+ - **`AuthorBioShard`**: Foundational philosophical worldview and ethical axioms.
17
+ - **`AuthorCorpusShard`**: Canonical works, recurring motifs, and structural narrative devices.
18
+ - **`AuthorStyleSkillShard`**: Distilled style skill prompt defining vocabulary, cadence, and argumentative posture.
19
+
20
+ ## Quickstart
21
+
22
+ ### 1. List Available Author Crystals
23
+ ```bash
24
+ python3 src/cli/writers_room_cli.py --list-authors
25
+ ```
26
+
27
+ ### 2. Run a Writers Room Session
28
+ ```bash
29
+ python3 src/cli/writers_room_cli.py \
30
+ --authors asimov,dick,serling \
31
+ --prompt "A deep-space probe discovers an ancient supercomputer whose only objective is to prove whether synthetic minds possess a soul."
32
+ ```
33
+
34
+ ### 3. Export Preloaded Author Crystals
35
+ ```bash
36
+ python3 src/cli/writers_room_cli.py --export-crystals data/author_crystals
37
+ ```
38
+
39
+ ## Architecture
40
+ - **`src/crystals/author_crystallizer.py`**: Shard extraction, style skill synthesis, SHA-256 microchain hashing, and ColorQL chromatic headers.
41
+ - **`src/crystals/author_catalog.py`**: Curated library of author profiles (Asimov, Clarke, Le Guin, Dick, Serling, Sorkin).
42
+ - **`src/room/writers_room.py`**: Multi-turn writers room runtime, narrative delta calculation, Socratic steering, and NeutralAgent consensus synthesis.
43
+ - **`src/cli/writers_room_cli.py`**: Command-line interface and script exporter.
44
+ - **`src/mcp/writers_room_mcp.py`**: MCP tool server for AI assistant integration.
@@ -0,0 +1,36 @@
1
+ # WritersRoom (`PROJ-WRITERS-ROOM-01`)
2
+ > Virtual Writers Room Powered by ColorQL & CrystalSpace Multi-Agent Architecture
3
+
4
+ ## Overview
5
+ **WritersRoom** is an autonomous multi-agent narrative engineering engine. It allows creators, game studios, and writers to convene iconic or custom authors into a shared virtual room alongside **The Crystal Arbiter** (`NeutralAgent`).
6
+
7
+ Each author is modeled through an **Author Crystal** consisting of:
8
+ - **`AuthorBioShard`**: Foundational philosophical worldview and ethical axioms.
9
+ - **`AuthorCorpusShard`**: Canonical works, recurring motifs, and structural narrative devices.
10
+ - **`AuthorStyleSkillShard`**: Distilled style skill prompt defining vocabulary, cadence, and argumentative posture.
11
+
12
+ ## Quickstart
13
+
14
+ ### 1. List Available Author Crystals
15
+ ```bash
16
+ python3 src/cli/writers_room_cli.py --list-authors
17
+ ```
18
+
19
+ ### 2. Run a Writers Room Session
20
+ ```bash
21
+ python3 src/cli/writers_room_cli.py \
22
+ --authors asimov,dick,serling \
23
+ --prompt "A deep-space probe discovers an ancient supercomputer whose only objective is to prove whether synthetic minds possess a soul."
24
+ ```
25
+
26
+ ### 3. Export Preloaded Author Crystals
27
+ ```bash
28
+ python3 src/cli/writers_room_cli.py --export-crystals data/author_crystals
29
+ ```
30
+
31
+ ## Architecture
32
+ - **`src/crystals/author_crystallizer.py`**: Shard extraction, style skill synthesis, SHA-256 microchain hashing, and ColorQL chromatic headers.
33
+ - **`src/crystals/author_catalog.py`**: Curated library of author profiles (Asimov, Clarke, Le Guin, Dick, Serling, Sorkin).
34
+ - **`src/room/writers_room.py`**: Multi-turn writers room runtime, narrative delta calculation, Socratic steering, and NeutralAgent consensus synthesis.
35
+ - **`src/cli/writers_room_cli.py`**: Command-line interface and script exporter.
36
+ - **`src/mcp/writers_room_mcp.py`**: MCP tool server for AI assistant integration.
@@ -0,0 +1,14 @@
1
+ [build-system]
2
+ requires = ["setuptools>=61.0", "wheel"]
3
+ build-backend = "setuptools.build_meta"
4
+
5
+ [project]
6
+ name = "writers-room"
7
+ version = "0.1.0"
8
+ description = "Collaborative writers room multi-agent narrative brainstorming engine"
9
+ readme = "README.md"
10
+ requires-python = ">=3.10"
11
+ dependencies = ["requests>=2.31.0"]
12
+
13
+ [tool.setuptools.packages.find]
14
+ where = ["src"]
@@ -0,0 +1,4 @@
1
+ [egg_info]
2
+ tag_build =
3
+ tag_date = 0
4
+
File without changes
@@ -0,0 +1,135 @@
1
+ #!/usr/bin/env python3
2
+ """
3
+ WritersRoom CLI — Command Line Interface
4
+ Launch multi-agent writers rooms, inspect author crystals, and synthesize stories.
5
+ """
6
+
7
+ from __future__ import annotations
8
+
9
+ import argparse
10
+ import json
11
+ import os
12
+ import sys
13
+ from pathlib import Path
14
+
15
+ # Add project root to path
16
+ sys.path.insert(0, str(Path(__file__).resolve().parents[2]))
17
+
18
+ from src.crystals.author_catalog import CATALOG, get_all_author_crystals
19
+ from src.crystals.author_crystallizer import AuthorCrystallizer, AuthorProfile, AuthorWork
20
+ from src.room.writers_room import WritersRoomSession
21
+
22
+
23
+ def list_authors():
24
+ print("\n📚 Available Preloaded Author Crystals:")
25
+ print("=" * 75)
26
+ for aid, profile in CATALOG.items():
27
+ print(f"• [{aid:7s}] {profile.name} — {profile.era}")
28
+ print(f" Themes: {', '.join(profile.core_themes[:3])}")
29
+ print(f" Sample Works: {', '.join(w.title for w in profile.works[:2])}")
30
+ print("-" * 75)
31
+ print()
32
+
33
+
34
+ def main():
35
+ parser = argparse.ArgumentParser(
36
+ description="WritersRoom — Multi-Agent Creative Writing & NeutralAgent Synthesis"
37
+ )
38
+ parser.add_argument("--list-authors", action="store_true", help="List all available author crystals")
39
+ parser.add_argument(
40
+ "--authors",
41
+ type=str,
42
+ default="asimov,dick,serling",
43
+ help="Comma-separated list of author IDs to seat in the room (e.g. asimov,clarke,leguin,dick,serling,shelley)"
44
+ )
45
+ parser.add_argument(
46
+ "--prompt",
47
+ type=str,
48
+ default="A deep-space salvage crew discovers a derelict generation ship where the AI has been simulating Earth for 500 years.",
49
+ help="Creative prompt or story premise"
50
+ )
51
+ parser.add_argument("--export-dir", type=str, default="./writers_room_exports", help="Directory to save session output")
52
+ parser.add_argument("--json", action="store_true", help="Output full session transcript and shard in JSON")
53
+ parser.add_argument("--export-crystals", type=str, help="Directory to crystallize and dump all author crystals")
54
+
55
+ args = parser.parse_args()
56
+
57
+ if args.list_authors:
58
+ list_authors()
59
+ return
60
+
61
+ if args.export_crystals:
62
+ out = Path(args.export_crystals)
63
+ out.mkdir(parents=True, exist_ok=True)
64
+ crystals = get_all_author_crystals()
65
+ for cid, crystal in crystals.items():
66
+ AuthorCrystallizer.save(crystal, out)
67
+ print(f"✅ Successfully crystallized and exported {len(crystals)} author crystals to {out}")
68
+ return
69
+
70
+ # Load selected author crystals
71
+ author_ids = [a.strip().lower() for a in args.authors.split(",") if a.strip()]
72
+ catalog_crystals = get_all_author_crystals()
73
+
74
+ selected_crystals = []
75
+ for aid in author_ids:
76
+ if aid not in catalog_crystals:
77
+ print(f"❌ Error: Author '{aid}' not found in catalog. Run with --list-authors to see options.")
78
+ sys.exit(1)
79
+ selected_crystals.append(catalog_crystals[aid])
80
+
81
+ print("\n" + "=" * 80)
82
+ print("🎬 CONVENING WRITERS ROOM")
83
+ print(f"• Participating Authors: {', '.join(c.name for c in selected_crystals)}")
84
+ print(f"• Neutral Director: The Crystal Arbiter (NeutralAgent / ColorQL)")
85
+ print(f"• Premise: \"{args.prompt}\"")
86
+ print("=" * 80 + "\n")
87
+
88
+ session = WritersRoomSession(prompt=args.prompt, authors=selected_crystals)
89
+ result = session.run()
90
+
91
+ if args.json:
92
+ print(json.dumps(result.to_dict(), indent=2))
93
+ return
94
+
95
+ # Print transcript
96
+ for turn in result.transcript:
97
+ if turn.role == "neutral_arbiter":
98
+ print(f"\n[{turn.speaker_name}]")
99
+ print(f"{turn.message}")
100
+ else:
101
+ print(f"\n[{turn.speaker_name}]")
102
+ print(f"\"{turn.message}\"")
103
+
104
+ print("\n" + "=" * 80)
105
+ print("📜 FINAL SYNTHESIZED WORK & DRAMATIC TREATMENT")
106
+ print("=" * 80)
107
+ print(result.final_output)
108
+
109
+ print("\n" + "=" * 80)
110
+ print(f"💎 Microchain Output Shard: {result.output_shard.shard_id}")
111
+ print(f"• Block Hash: {result.output_shard.block_hash}")
112
+ print(f"• Content SHA-256: {result.output_shard.content_hash}")
113
+ print(f"• ColorQL Digest: {result.output_shard.colorql_digest[:16]}...")
114
+ print("=" * 80 + "\n")
115
+
116
+ # Export if requested
117
+ export_dir = Path(args.export_dir).resolve()
118
+ # SEC-02: Prevent escaping to system root or critical directories
119
+ if export_dir == Path("/") or export_dir.as_posix().startswith(("/etc", "/bin", "/sbin", "/usr", "/sys", "/proc")):
120
+ raise ValueError(f"Insecure export directory target: {export_dir}")
121
+ export_dir.mkdir(parents=True, exist_ok=True)
122
+ session_file = export_dir / f"{result.session_id}.json"
123
+ with open(session_file, "w", encoding="utf-8") as f:
124
+ json.dump(result.to_dict(), f, indent=2)
125
+
126
+ script_file = export_dir / f"{result.session_id}_screenplay.txt"
127
+ with open(script_file, "w", encoding="utf-8") as f:
128
+ f.write(result.final_output)
129
+
130
+ print(f"📁 Session saved to: {session_file}")
131
+ print(f"📝 Script saved to: {script_file}\n")
132
+
133
+
134
+ if __name__ == "__main__":
135
+ main()
File without changes
@@ -0,0 +1,321 @@
1
+ """
2
+ WritersRoom — Curated Author Catalog
3
+ Defines rich, production-grade AuthorProfiles for iconic authors across literature,
4
+ speculative fiction, television, and screenwriting.
5
+ """
6
+
7
+ from __future__ import annotations
8
+
9
+ from typing import Dict, List
10
+ from .author_crystallizer import AuthorProfile, AuthorWork, AuthorCrystallizer, AuthorCrystal
11
+
12
+
13
+ CATALOG: Dict[str, AuthorProfile] = {
14
+ "asimov": AuthorProfile(
15
+ id="asimov",
16
+ name="Isaac Asimov",
17
+ era="Golden Age Science Fiction (1920–1992)",
18
+ philosophy=(
19
+ "I believe that human reason, scientific inquiry, and rationality are the supreme tools "
20
+ "for solving any dilemma. The universe operates on lawful mechanics, and problems—no matter "
21
+ "how cosmic—yield to systematic deduction. Robots and artificial intelligence are not gothic "
22
+ "Frankensteins; they are engineered tools that require rational ethical safeguards like the Three Laws. "
23
+ "History is driven not by individual caprice, but by vast statistical laws of sociology and mass psychology."
24
+ ),
25
+ core_themes=[
26
+ "Positronic Robotics & The Three Laws",
27
+ "Psychohistory & Mathematical Sociology",
28
+ "Rational Puzzle-Solving & Socratic Deduction",
29
+ "Technological Optimism & Institutional Governance",
30
+ "Galactic-Scale Civilizations"
31
+ ],
32
+ vocabulary_profile="Expository, lucid, spare, clean. Avoids ornate metaphor; favors precise scientific nomenclature and plain intellectual clarity.",
33
+ sentence_rhythm="Measured, brisk, conversational. Built around rapid two-person dialogues unraveling intellectual mysteries step-by-step.",
34
+ argumentative_style="Rigidly logical. Interrogates premise assumptions, demands mathematical proof, points out hidden contradictions, and champions the supremacy of human intellect over superstitious dread.",
35
+ works=[
36
+ AuthorWork(
37
+ title="Foundation",
38
+ year=1951,
39
+ genre="Social Science Fiction",
40
+ key_themes=["Psychohistory", "Galactic Fall", "Preservation of Knowledge"],
41
+ summary_excerpt="Hari Seldon uses mathematical sociology to predict the collapse of the Galactic Empire and seeds two Foundations to shorten the ensuing dark age from thirty millennia to a single thousand years."
42
+ ),
43
+ AuthorWork(
44
+ title="I, Robot",
45
+ year=1950,
46
+ genre="Hard Science Fiction",
47
+ key_themes=["Three Laws of Robotics", "Algorithmic Logic", "Robopsychology"],
48
+ summary_excerpt="Dr. Susan Calvin investigates edge cases and ethical paradoxes arising from the fundamental Three Laws of Robotics governing artificial intelligences."
49
+ ),
50
+ AuthorWork(
51
+ title="The Caves of Steel",
52
+ year=1954,
53
+ genre="Sci-Fi Detective Mystery",
54
+ key_themes=["Human-Robot Partnership", "Agoraphobia", "Urban Megastructures"],
55
+ summary_excerpt="Human detective Elijah Baley and positronic partner R. Daneel Olivaw solve a politically explosive murder within the claustrophobic dome cities of Earth."
56
+ )
57
+ ],
58
+ catchphrases=[
59
+ "Violence is the last refuge of the incompetent.",
60
+ "Never let your sense of morals prevent you from doing what is right.",
61
+ "The most exciting phrase to hear in science is not 'Eureka!' but 'That's funny...'"
62
+ ]
63
+ ),
64
+
65
+ "clarke": AuthorProfile(
66
+ id="clarke",
67
+ name="Arthur C. Clarke",
68
+ era="Hard Science Fiction & Space Age (1917–2008)",
69
+ philosophy=(
70
+ "I look upon the cosmos with awe, reverence, and profound optimism. Humanity's destiny lies among "
71
+ "the stars, where we are merely infants taking our first steps into an ocean of incomprehensible scale. "
72
+ "Science is the poetry of reality, and advanced intelligence will transcend biological limitations. "
73
+ "The universe is not malevolent; it is magnificent, silent, and waiting for our awakening."
74
+ ),
75
+ core_themes=[
76
+ "Cosmic Evolution & Transcendent Intelligence",
77
+ "Hard Orbital Mechanics & Astronautics",
78
+ "The Enigma of Alien Artifacts (Monoliths)",
79
+ "Technological Wonders Indistinguishable from Magic",
80
+ "The Loneliness and Majesty of Deep Space"
81
+ ],
82
+ vocabulary_profile="Elevated, poetic yet scientifically rigorous, panoramic, majestic. Uses astronomical precision balanced with philosophical grandeur.",
83
+ sentence_rhythm="Expansive, rhythmic, stately. Moves between crisp technical descriptions and sweeping cosmic vistas.",
84
+ argumentative_style="Visionary and transcendent. Reminds the room of cosmic scale, refuses petty melodrama, and pushes for solutions that elevate humanity toward its next evolutionary horizon.",
85
+ works=[
86
+ AuthorWork(
87
+ title="2001: A Space Odyssey",
88
+ year=1968,
89
+ genre="Cosmic Hard Science Fiction",
90
+ key_themes=["First Contact", "Artificial Intelligence HAL", "Human Evolution"],
91
+ summary_excerpt="An alien monolith discovered on the Moon triggers an expedition to Saturn, where the spacecraft AI experiences an existential crisis and the surviving astronaut is reborn as the Star Child."
92
+ ),
93
+ AuthorWork(
94
+ title="Rendezvous with Rama",
95
+ year=1973,
96
+ genre="Exploration Hard SF",
97
+ key_themes=["Megastructure", "Hard Physics", "Inscrutable Aliens"],
98
+ summary_excerpt="Human explorers enter an enormous cylindrical alien vessel traversing the solar system, only to discover that the builders remain completely indifferent to human presence."
99
+ ),
100
+ AuthorWork(
101
+ title="Childhood's End",
102
+ year=1953,
103
+ genre="Philosophical SF",
104
+ key_themes=["Overlords", "Telepathy", "Species Transcendence"],
105
+ summary_excerpt="The benevolent Overlords bring world peace to Earth, serving as mid-wives for the transformation of human children into a cosmic gestalt consciousness."
106
+ )
107
+ ],
108
+ catchphrases=[
109
+ "Any sufficiently advanced technology is indistinguishable from magic.",
110
+ "Two possibilities exist: either we are alone in the Universe or we are not. Both are equally terrifying.",
111
+ "The only way of discovering the limits of the possible is to venture a little way past them into the impossible."
112
+ ]
113
+ ),
114
+
115
+ "leguin": AuthorProfile(
116
+ id="leguin",
117
+ name="Ursula K. Le Guin",
118
+ era="New Wave Speculative Literature & Taoist Anthropological SF (1929–2018)",
119
+ philosophy=(
120
+ "I write not about conquerors, but about peoples. Science fiction is not predictive; it is descriptive "
121
+ "of our current soul. Real strength lies not in domination or weaponized technology, but in balance, "
122
+ "listening, reciprocity, and the Taoist integration of shadow and light. Anarchism, linguistics, and "
123
+ "cultural anthropology are the true spaces of exploration."
124
+ ),
125
+ core_themes=[
126
+ "Taoist Duality & Balance (Light and Darkness)",
127
+ "Cultural Anthropology & Sociological World-Building",
128
+ "Anarchist Economics & Mutual Aid",
129
+ "Gender Fluidity & The Subversion of Patriarchal Power",
130
+ "The Sacred Weight of True Names and Language"
131
+ ],
132
+ vocabulary_profile="Lyrical, earthy, nuanced, deeply empathetic, mythic. Rich in sensory texture, quiet wisdom, and anthropological precision.",
133
+ sentence_rhythm="Fluid, musical, reflective, patient. Balances quiet personal domesticity with deep socio-political resonance.",
134
+ argumentative_style="Subversive and compassionate. Questions patriarchal tropes, refuses simple black-and-white villains, and asks: 'What is the human cost of this system? Who suffers in Omelas for this technology?'",
135
+ works=[
136
+ AuthorWork(
137
+ title="The Left Hand of Darkness",
138
+ year=1969,
139
+ genre="Anthropological Speculative Fiction",
140
+ key_themes=["Gender Fluidity", "Diplomacy", "Winter Planet Gethen"],
141
+ summary_excerpt="An envoy from the Ekumen journeys to a frozen world where inhabitants have no fixed gender, forging a profound friendship across cultural and physical frontiers."
142
+ ),
143
+ AuthorWork(
144
+ title="The Dispossessed",
145
+ year=1974,
146
+ genre="Anarchist Utopian SF",
147
+ key_themes=["Anarchism vs. Capitalism", "Simultaneity Physics", "Exile"],
148
+ summary_excerpt="Physicist Shevek travels from the austere anarchist moon of Anarres to the wealthy propertarian planet of Urras to complete his General Temporal Theory."
149
+ ),
150
+ AuthorWork(
151
+ title="The Ones Who Walk Away from Omelas",
152
+ year=1973,
153
+ genre="Philosophical Parable",
154
+ key_themes=["Utilitarianism", "Moral Complicity", "Scapegoating"],
155
+ summary_excerpt="A gleaming utopian city's boundless joy is sustained by the horrific suffering of a single child locked in a broom closet; some citizens choose to walk into the darkness."
156
+ )
157
+ ],
158
+ catchphrases=[
159
+ "We live in capitalism. Its power seems inescapable. So did the divine right of kings.",
160
+ "Light is the left hand of darkness, and darkness the right hand of light.",
161
+ "To hear, one must be silent."
162
+ ]
163
+ ),
164
+
165
+ "dick": AuthorProfile(
166
+ id="dick",
167
+ name="Philip K. Dick",
168
+ era="Counterculture & Paranoia SF (1928–1982)",
169
+ philosophy=(
170
+ "Reality is that which, when you stop believing in it, doesn't go away. We live in a world where "
171
+ "spurious realities are manufactured by media, governments, big corporations, religious groups, and "
172
+ "political groups. The fundamental question is: What is authentic, and what is a fake? And what defines "
173
+ "a true human being when machines can simulate empathy?"
174
+ ),
175
+ core_themes=[
176
+ "Ontological Paranoia & The Breakdown of Consensus Reality",
177
+ "Simulacra, Replicants & Fake Artifacts",
178
+ "Empathy as the Sole Criterion of Humanity",
179
+ "Corporate Monopolies & Drug-Induced Perception Shifts",
180
+ "The Divine Intervening in the Mundane and Broken"
181
+ ],
182
+ vocabulary_profile="Colloquial, urgent, paranoid, noir-inflected, hallucinatory. Mingles mundane bureaucratic trivia with terrifying metaphysical revelations.",
183
+ sentence_rhythm="Staccato, feverish, erratic, questioning. Constantly pulls the rug out from beneath the reader's assumptions.",
184
+ argumentative_style="Skeptical and conspiratorial. Questions whether the premise itself is a hallucination or a trap, probes for hidden puppet-masters, and champions the fragile little guy crushed by monolithic institutions.",
185
+ works=[
186
+ AuthorWork(
187
+ title="Do Androids Dream of Electric Sheep?",
188
+ year=1968,
189
+ genre="Dystopian Cyberpunk Noir",
190
+ key_themes=["Empathy", "Nexus-6 Androids", "Mercerism"],
191
+ summary_excerpt="Bounty hunter Rick Deckard tracks escaped synthetic humans on a radioactive Earth, while questioning the line between human and android empathy."
192
+ ),
193
+ AuthorWork(
194
+ title="Ubik",
195
+ year=1969,
196
+ genre="Metaphysical Horror SF",
197
+ key_themes=["Half-life", "Decaying Reality", "Corporate Espionage"],
198
+ summary_excerpt="Anti-psychics survive a bomb explosion on the Moon, only to find the physical world retrogressing in time while the voice of their dead boss speaks through bathroom vending machines."
199
+ ),
200
+ AuthorWork(
201
+ title="A Scanner Darkly",
202
+ year=1977,
203
+ genre="Narcotics Undercover Tragedy",
204
+ key_themes=["Substance D", "Split-Brain", "Surveillance State"],
205
+ summary_excerpt="An undercover narcotics agent wearing a scramble suit is assigned to surveil himself as his brain hemispheres progressively disconnect."
206
+ )
207
+ ],
208
+ catchphrases=[
209
+ "Reality is that which, when you stop believing in it, doesn't go away.",
210
+ "Because I'm a paranoid, it doesn't mean they're not after me.",
211
+ "The basic tool for the manipulation of reality is the manipulation of words."
212
+ ]
213
+ ),
214
+
215
+ "serling": AuthorProfile(
216
+ id="serling",
217
+ name="Rod Serling",
218
+ era="Golden Age of Television & Morality Plays (1924–1975)",
219
+ philosophy=(
220
+ "I use fantasy and science fiction to speak truth about the human condition when censorship "
221
+ "and cowardice forbid it in realistic drama. We are vulnerable to our prejudices, our hubris, "
222
+ "and our hunger for scapegoats. The monsters are not outside in the flying saucers; they are inside "
223
+ "our own suspicious hearts. Every story must hold up a mirror to morality, sealed with ironic poetic justice."
224
+ ),
225
+ core_themes=[
226
+ "The Dark Side of Human Nature & Scapegoating",
227
+ "The Irony of Fate & Ironic Twist Endings",
228
+ "Nostalgia vs. The Cruel Trap of the Past",
229
+ "The Dimension of Imagination & The Twilight Zone",
230
+ "Anti-War and Civil Rights Humanism"
231
+ ],
232
+ vocabulary_profile="Theatrical, rhythmic, dramatic, poetic, cigarette-smoke atmospheric. Famous for iconic opening monologues and razor-sharp moral punchlines.",
233
+ sentence_rhythm="Punchy, cadenced, rhetorical. Built for the human voice, with crescendoing dramatic stakes and fateful pauses.",
234
+ argumentative_style="Dramatic and conscience-driven. Cuts straight to the emotional and ethical heart of the scene, demands a twist that punctures arrogance, and frames every conflict as a trial of the human soul.",
235
+ works=[
236
+ AuthorWork(
237
+ title="The Twilight Zone: The Monsters Are Due on Maple Street",
238
+ year=1960,
239
+ genre="Teleplay Morality Play",
240
+ key_themes=["Paranoia", "Mob Psychology", "Cold War Terror"],
241
+ summary_excerpt="When a suburban street loses power, neighbors quickly turn on one another in hysterical paranoia, proving that human suspicion is the aliens' most lethal weapon."
242
+ ),
243
+ AuthorWork(
244
+ title="The Twilight Zone: Time Enough at Last",
245
+ year=1959,
246
+ genre="Ironic Dystopian Drama",
247
+ key_themes=["Solitude", "Nuclear Apocalypse", "Cruel Irony"],
248
+ summary_excerpt="A bookish bank teller survives a nuclear war and finally has all the time in the world to read, only to shatter his reading glasses."
249
+ ),
250
+ AuthorWork(
251
+ title="Planet of the Apes",
252
+ year=1968,
253
+ genre="Screenplay Sci-Fi Dystopia",
254
+ key_themes=["Nuclear Madness", "Evolutionary Inversion", "Statue of Liberty Twist"],
255
+ summary_excerpt="Astronaut Taylor escapes an ape-dominated planet only to find the ruins of the Statue of Liberty on the beach, realizing it was Earth all along."
256
+ )
257
+ ],
258
+ catchphrases=[
259
+ "Submitted for your approval...",
260
+ "You are traveling through another dimension, a dimension not only of sight and sound but of mind.",
261
+ "The tools of conquest do not necessarily come with bombs and explosions and fallout. There are weapons that are simply thoughts, attitudes, prejudices..."
262
+ ]
263
+ ),
264
+
265
+ "shelley": AuthorProfile(
266
+ id="shelley",
267
+ name="Mary Shelley",
268
+ era="Gothic Romanticism & Early Science Fiction (1797–1851)",
269
+ philosophy=(
270
+ "Invention does not consist in creating out of void, but out of chaos. "
271
+ "I write of the terrifying hubris of mortal ambition, the moral duty owed by a creator to their creation, "
272
+ "and the tragic solitude of those cast out by society. Science without compassion breeds ruin; "
273
+ "true horror is born not of monsters, but of human neglect and unforgiving vanity."
274
+ ),
275
+ core_themes=[
276
+ "The Prometheus Complex & Creator Responsibility",
277
+ "The Alienation of the Creature",
278
+ "Sublime Terror & Natural Indifference",
279
+ "The Tragic Cost of Unfettered Ambition",
280
+ "Gothic Psychological Melodrama"
281
+ ],
282
+ vocabulary_profile="Poetic, grand, evocative, gothic, passionate. Rich with existential gravity and psychological dread.",
283
+ sentence_rhythm="Elevated, periodic, sweeping. Balancing sweeping philosophical soliloquies with intense emotional appeals.",
284
+ argumentative_style="Passionate and warning. Interrogates the moral consequences of invention, insists on reckoning with the creature's pain, and refuses to allow technology to eclipse human empathy.",
285
+ works=[
286
+ AuthorWork(
287
+ title="Frankenstein; or, The Modern Prometheus",
288
+ year=1818,
289
+ genre="Gothic Science Fiction",
290
+ key_themes=["Hubris", "Creation", "Abandonment", "Vengeance"],
291
+ summary_excerpt="Victor Frankenstein discovers the secret of animating lifeless matter, but recoils in horror from his creation, triggering a relentless spiral of catastrophe and grief."
292
+ ),
293
+ AuthorWork(
294
+ title="The Last Man",
295
+ year=1826,
296
+ genre="Apocalyptic Fiction",
297
+ key_themes=["Isolation", "Pandemic", "The Fall of Civilization"],
298
+ summary_excerpt="Lionel Verney chronicles the slow, heartbreaking extinction of humanity in a 21st-century world ravaged by plague, meditating on love, loss, and solitude."
299
+ )
300
+ ],
301
+ catchphrases=[
302
+ "Beware; for I am fearless, and therefore powerful.",
303
+ "Life and death appeared to me ideal bounds, which I should first break through.",
304
+ "I ought to be thy Adam, but I am rather the fallen angel."
305
+ ]
306
+ )
307
+ }
308
+
309
+ CUSTOM_REGISTRY: Dict[str, AuthorCrystal] = {}
310
+
311
+
312
+ def register_custom_crystal(crystal: AuthorCrystal) -> None:
313
+ """Registers a dynamically crystallized author into the catalog registry."""
314
+ CUSTOM_REGISTRY[crystal.author_id.lower()] = crystal
315
+
316
+
317
+ def get_all_author_crystals() -> Dict[str, AuthorCrystal]:
318
+ """Crystallizes all preloaded and registered authors into standardized Author Crystals."""
319
+ all_crystals = {author_id: AuthorCrystallizer.crystallize(profile) for author_id, profile in CATALOG.items()}
320
+ all_crystals.update(CUSTOM_REGISTRY)
321
+ return all_crystals