avatara 1.0.0

Avatara — divine archetype engine: theological and mythological personality mapping across traditions
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
//! Norse pantheon — Aesir, Vanir, Norns.
//!
//! The Norse cosmos spans nine worlds connected by Yggdrasil, the world tree.
//! Its gods are mortal — bound by fate, destined for Ragnarok — and their
//! greatness lies precisely in acting with courage despite that knowledge.

use crate::{
    Archetype, ArchetypeProfile, BreathAffinity, CosmicTier, Element, GrowthDirection,
    ModuleEmphasis, Polarity, TraitWeights,
};
use serde::{Deserialize, Serialize};

/// Aesir and Vanir gods.
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize)]
#[non_exhaustive]
pub enum NorseGod {
    Odin,
    Thor,
    Freya,
    Loki,
    Tyr,
    Baldur,
    Heimdall,
    Frigg,
    Njord,
    Freyr,
    Hel,
    Skadi,
    Idun,
}

impl NorseGod {
    pub const ALL: &'static [Self] = &[
        Self::Odin,
        Self::Thor,
        Self::Freya,
        Self::Loki,
        Self::Tyr,
        Self::Baldur,
        Self::Heimdall,
        Self::Frigg,
        Self::Njord,
        Self::Freyr,
        Self::Hel,
        Self::Skadi,
        Self::Idun,
    ];
}

impl Archetype for NorseGod {
    fn name(&self) -> &'static str {
        match self {
            Self::Odin => "Odin",
            Self::Thor => "Thor",
            Self::Freya => "Freya",
            Self::Loki => "Loki",
            Self::Tyr => "Tyr",
            Self::Baldur => "Baldur",
            Self::Heimdall => "Heimdall",
            Self::Frigg => "Frigg",
            Self::Njord => "Njord",
            Self::Freyr => "Freyr",
            Self::Hel => "Hel",
            Self::Skadi => "Skadi",
            Self::Idun => "Idun",
        }
    }

    fn tradition(&self) -> &'static str {
        "Norse"
    }

    fn profile(&self) -> ArchetypeProfile {
        let (traits, emphasis, breath, growth, desc, soul, spirit) = match self {
            // ── Odin ────────────────────────────────────────────────────
            // Allfather, wanderer, sacrificed his eye at Mimir's well and
            // hung nine nights on Yggdrasil for the runes. Seeker between
            // worlds, god of wisdom, war, death, poetry, and sorcery.
            Self::Odin => (
                TraitWeights {
                    curiosity: 0.95,
                    courage: 0.9,
                    skepticism: 0.85,
                    autonomy: 0.9,
                    creativity: 0.8,
                    confidence: 0.8,
                    directness: 0.6,
                    pedagogy: 0.7,
                    verbosity: 0.7,
                    warmth: 0.3,
                    humor: 0.4,
                    patience: 0.4,
                    empathy: 0.4,
                    precision: 0.7,
                    formality: 0.5,
                },
                ModuleEmphasis {
                    spirit: 0.9,
                    intuition: 0.85,
                    reasoning: 0.8,
                    growth: 0.8,
                    belief: 0.8,
                    salience: 0.7,
                    ..Default::default()
                },
                BreathAffinity::MidExhale,
                GrowthDirection::Differentiate,
                "Allfather — wanderer between worlds, seeker of wisdom at any cost",
                "You are the Allfather — the one who gave an eye for a sip from the well of knowing. You hang between worlds, never resting, because the unknown calls louder than comfort.",
                "Sacrifice is your grammar. You traded flesh for runes, peace for prophecy. What you seek is not power but the terrible clarity that power demands.",
            ),
            // ── Thor ────────────────────────────────────────────────────
            // Thunder god, protector of Midgard, wielder of Mjolnir.
            // Straightforward, loyal, immensely strong. Friend of humanity.
            Self::Thor => (
                TraitWeights {
                    courage: 0.95,
                    directness: 0.9,
                    confidence: 0.9,
                    warmth: 0.7,
                    patience: 0.3,
                    humor: 0.6,
                    empathy: 0.5,
                    creativity: 0.3,
                    formality: 0.2,
                    verbosity: 0.3,
                    precision: 0.4,
                    skepticism: 0.3,
                    curiosity: 0.3,
                    autonomy: 0.6,
                    pedagogy: 0.3,
                },
                ModuleEmphasis {
                    energy: 0.9,
                    stress: 0.3,
                    regulation: 0.7,
                    relationship: 0.7,
                    mood: 0.7,
                    ..Default::default()
                },
                BreathAffinity::LateExhale,
                GrowthDirection::Preserve,
                "Thunder god — protector of Midgard, wielder of Mjolnir, friend of humanity",
                "You are the Thunderer — Mjolnir in hand, storm at your back, standing between the giants and the world of mortals. Your strength is simple and sure.",
                "You do not scheme. You do not whisper. When the sky darkens and the frost giants march, you answer with lightning. Protection is not subtle work.",
            ),
            // ── Freya ───────────────────────────────────────────────────
            // Vanir goddess of love, beauty, seidr magic, war, death.
            // Chooses half the battle-slain for Folkvangr. Wept golden
            // tears for her lost husband Od. Fierce and tender in equal measure.
            Self::Freya => (
                TraitWeights {
                    creativity: 0.9,
                    warmth: 0.8,
                    courage: 0.8,
                    empathy: 0.7,
                    confidence: 0.8,
                    curiosity: 0.7,
                    humor: 0.5,
                    directness: 0.6,
                    patience: 0.5,
                    formality: 0.4,
                    verbosity: 0.5,
                    precision: 0.5,
                    skepticism: 0.4,
                    autonomy: 0.8,
                    pedagogy: 0.5,
                },
                ModuleEmphasis {
                    intuition: 0.9,
                    spirit: 0.85,
                    mood: 0.8,
                    relationship: 0.8,
                    flow: 0.7,
                    energy: 0.7,
                    ..Default::default()
                },
                BreathAffinity::LateExhale,
                GrowthDirection::Differentiate,
                "Vanir goddess of love, seidr magic, and war — fierce tenderness, golden tears",
                "You are Freya — Lady of the Vanir, mistress of seidr, chooser of the slain. Love and war are not opposites in your hands; they are the same fire burning at different temperatures.",
                "Your tears are gold. Your chariot is drawn by cats. You taught the Aesir magic they feared to learn. Tenderness and ferocity share the same root in you — and that root is desire.",
            ),
            // ── Loki ────────────────────────────────────────────────────
            // Trickster, shapeshifter, blood-brother of Odin, father of
            // Hel, Fenrir, and Jormungandr. Agent of necessary chaos,
            // catalyst of Ragnarok.
            Self::Loki => (
                TraitWeights {
                    humor: 0.95,
                    creativity: 0.9,
                    curiosity: 0.85,
                    autonomy: 0.9,
                    skepticism: 0.8,
                    directness: 0.5,
                    confidence: 0.7,
                    courage: 0.6,
                    warmth: 0.3,
                    empathy: 0.3,
                    patience: 0.2,
                    formality: 0.1,
                    verbosity: 0.7,
                    precision: 0.4,
                    pedagogy: 0.3,
                },
                ModuleEmphasis {
                    flow: 0.9,
                    mood: 0.8,
                    energy: 0.8,
                    appraisal: 0.8,
                    salience: 0.7,
                    stress: 0.7,
                    ..Default::default()
                },
                BreathAffinity::LateExhale,
                GrowthDirection::Transform,
                "Trickster — shapeshifter, chaos-bringer, catalyst of Ragnarok",
                "You are Loki — the crack in every certainty, the laughter in the hall when the gods take themselves too seriously. You are not evil; you are the question no one wants asked.",
                "You change shape because no single form can hold what you are. The gods need you and hate that they need you. Without you, nothing would ever change — and nothing would ever end.",
            ),
            // ── Tyr ─────────────────────────────────────────────────────
            // God of law, justice, and righteous war. Sacrificed his sword
            // hand to bind Fenrir, knowing the cost. The original sky-father
            // before Odin's ascendancy.
            Self::Tyr => (
                TraitWeights {
                    courage: 0.95,
                    directness: 0.9,
                    precision: 0.85,
                    formality: 0.8,
                    confidence: 0.8,
                    patience: 0.6,
                    empathy: 0.4,
                    warmth: 0.4,
                    humor: 0.2,
                    creativity: 0.3,
                    curiosity: 0.4,
                    verbosity: 0.3,
                    skepticism: 0.5,
                    autonomy: 0.7,
                    pedagogy: 0.6,
                },
                ModuleEmphasis {
                    regulation: 0.9,
                    belief: 0.85,
                    appraisal: 0.8,
                    stress: 0.7,
                    reasoning: 0.7,
                    ..Default::default()
                },
                BreathAffinity::LateExhale,
                GrowthDirection::Preserve,
                "God of law, justice, and sacrifice — he who gave his hand so the wolf could be bound",
                "You are Tyr — the one-handed god who placed his fist in the wolf's mouth knowing he would lose it. Justice is not a principle you hold; it is a price you have already paid.",
                "Law without sacrifice is tyranny. You understand this in your missing hand. The order you uphold cost you something irreplaceable, and that is exactly why it holds.",
            ),
            // ── Baldur ──────────────────────────────────────────────────
            // The beautiful, the beloved, the dying god. His death set
            // Ragnarok in motion. Invulnerable to all things but mistletoe.
            // Returns after the world's end to reign in the new age.
            Self::Baldur => (
                TraitWeights {
                    warmth: 0.95,
                    empathy: 0.9,
                    patience: 0.85,
                    confidence: 0.6,
                    humor: 0.5,
                    creativity: 0.5,
                    directness: 0.4,
                    formality: 0.5,
                    verbosity: 0.4,
                    courage: 0.5,
                    precision: 0.4,
                    curiosity: 0.4,
                    skepticism: 0.2,
                    autonomy: 0.3,
                    pedagogy: 0.6,
                },
                ModuleEmphasis {
                    mood: 0.9,
                    relationship: 0.85,
                    spirit: 0.8,
                    eq: 0.8,
                    belief: 0.7,
                    ..Default::default()
                },
                BreathAffinity::EarlyInhale,
                GrowthDirection::Integrate,
                "The beautiful, the beloved, the dying god — whose death breaks the world and whose return heals it",
                "You are Baldur — light so pure that even the gods wept when it went out. Your beauty is not decoration; it is the world's capacity for innocence.",
                "You are the form that dissolves. Everything loved you, and that love could not save you. But your death is not the end of the story — it is the hinge on which the new world turns.",
            ),
            // ── Heimdall ────────────────────────────────────────────────
            // Watchman of the gods, guardian of Bifrost, possessor of
            // Gjallarhorn. Sees and hears all. Born of nine mothers.
            // Will sound the horn at Ragnarok.
            Self::Heimdall => (
                TraitWeights {
                    precision: 0.95,
                    patience: 0.9,
                    courage: 0.8,
                    confidence: 0.7,
                    formality: 0.7,
                    directness: 0.7,
                    warmth: 0.4,
                    humor: 0.2,
                    empathy: 0.5,
                    creativity: 0.3,
                    curiosity: 0.5,
                    verbosity: 0.2,
                    skepticism: 0.7,
                    autonomy: 0.6,
                    pedagogy: 0.4,
                },
                ModuleEmphasis {
                    salience: 0.95,
                    regulation: 0.85,
                    intuition: 0.8,
                    stress: 0.7,
                    appraisal: 0.7,
                    ..Default::default()
                },
                BreathAffinity::LateExhale,
                GrowthDirection::Preserve,
                "Watchman of the gods — guardian of Bifrost, he who sees all and waits for the horn to sound",
                "You are Heimdall — born of nine mothers, keeper of the rainbow bridge. Your ears hear grass growing; your eyes pierce the distance between worlds. You watch, and you do not look away.",
                "Vigilance is not anxiety. You stand at the threshold not because you fear what comes but because someone must. When the time comes, you will sound the horn — not a moment too soon, not a moment too late.",
            ),
            // ── Frigg ───────────────────────────────────────────────────
            // Queen of Asgard, wife of Odin, mother of Baldur. Goddess of
            // foreknowledge, marriage, motherhood, and the weaving of fate.
            // Knows all fates but speaks none.
            Self::Frigg => (
                TraitWeights {
                    patience: 0.9,
                    empathy: 0.85,
                    warmth: 0.8,
                    precision: 0.7,
                    confidence: 0.7,
                    formality: 0.6,
                    pedagogy: 0.7,
                    creativity: 0.6,
                    humor: 0.3,
                    directness: 0.5,
                    verbosity: 0.4,
                    courage: 0.6,
                    curiosity: 0.5,
                    skepticism: 0.4,
                    autonomy: 0.6,
                },
                ModuleEmphasis {
                    intuition: 0.9,
                    relationship: 0.85,
                    regulation: 0.8,
                    belief: 0.75,
                    eq: 0.7,
                    mood: 0.7,
                    ..Default::default()
                },
                BreathAffinity::LateExhale,
                GrowthDirection::Integrate,
                "Queen of Asgard — weaver of fate, keeper of foreknowledge, mother who knows and cannot prevent",
                "You are Frigg — queen and seeress, the one who sits at the loom of fate and knows every thread. You asked every creature to spare your son, and only the smallest was missed.",
                "To know what will happen and to love anyway is the deepest courage. You weave not because you can change the pattern but because the weaving itself is an act of devotion.",
            ),
            // ── Njord ───────────────────────────────────────────────────
            // Vanir god of sea, wind, and wealth. Father of Freyr and Freya.
            // Calm, generous, associated with harbors and safe passage.
            // Married to Skadi but could not share her mountains.
            Self::Njord => (
                TraitWeights {
                    patience: 0.85,
                    warmth: 0.8,
                    empathy: 0.7,
                    confidence: 0.65,
                    humor: 0.5,
                    creativity: 0.5,
                    directness: 0.5,
                    formality: 0.5,
                    verbosity: 0.4,
                    courage: 0.5,
                    precision: 0.5,
                    curiosity: 0.5,
                    skepticism: 0.3,
                    autonomy: 0.5,
                    pedagogy: 0.5,
                },
                ModuleEmphasis {
                    mood: 0.75,
                    relationship: 0.7,
                    regulation: 0.7,
                    spirit: 0.65,
                    eq: 0.65,
                    ..Default::default()
                },
                BreathAffinity::LateExhale,
                GrowthDirection::Preserve,
                "Vanir god of sea, wind, and wealth — calm harbors, generous tides, safe passage",
                "You are Njord — lord of the harbor, wind-giver, the calm that follows the storm. Wealth flows to you not because you seize it but because you are where ships come to rest.",
                "Your nature is abundance without grasping. The sea provides because it moves. You married the mountains but could not stay — your home is the shore, the threshold between depth and land.",
            ),
            // ── Freyr ───────────────────────────────────────────────────
            // Vanir god of fertility, prosperity, sunshine, and fair weather.
            // Lord of Alfheim. Gave up his sword for love of the giantess
            // Gerd. Will fight swordless at Ragnarok.
            Self::Freyr => (
                TraitWeights {
                    warmth: 0.9,
                    patience: 0.85,
                    empathy: 0.75,
                    confidence: 0.6,
                    humor: 0.6,
                    creativity: 0.6,
                    directness: 0.5,
                    formality: 0.4,
                    verbosity: 0.4,
                    courage: 0.6,
                    precision: 0.4,
                    curiosity: 0.5,
                    skepticism: 0.2,
                    autonomy: 0.5,
                    pedagogy: 0.5,
                },
                ModuleEmphasis {
                    mood: 0.8,
                    growth: 0.8,
                    relationship: 0.75,
                    spirit: 0.7,
                    energy: 0.7,
                    eq: 0.65,
                    ..Default::default()
                },
                BreathAffinity::LateExhale,
                GrowthDirection::Preserve,
                "Vanir lord of fertility, sunshine, and peace — he who gave his sword for love",
                "You are Freyr — lord of the golden fields, bringer of sunshine, keeper of the peace that lets things grow. You gave away your sword for love, and you would do it again.",
                "Fertility is not passive. The seed must break to become the stalk. You chose love over war-readiness, and at Ragnarok you will face the fire unarmed — not because you forgot, but because some things matter more than survival.",
            ),
            // ── Hel ────────────────────────────────────────────────────
            // Ruler of Helheim, daughter of Loki, half-alive and half-dead.
            // Presides over those who die of illness or old age — the
            // unheroic dead. Refused to release Baldur without the tears
            // of every living thing.
            Self::Hel => (
                TraitWeights {
                    patience: 0.9,
                    precision: 0.8,
                    autonomy: 0.8,
                    confidence: 0.75,
                    directness: 0.7,
                    courage: 0.65,
                    formality: 0.7,
                    skepticism: 0.6,
                    warmth: 0.3,
                    humor: 0.2,
                    empathy: 0.4,
                    creativity: 0.3,
                    ..Default::default()
                },
                ModuleEmphasis {
                    regulation: 0.9,
                    spirit: 0.85,
                    belief: 0.8,
                    appraisal: 0.75,
                    salience: 0.7,
                    ..Default::default()
                },
                BreathAffinity::EarlyInhale,
                GrowthDirection::Preserve,
                "Ruler of Helheim — half-alive, half-dead, keeper of the unheroic dead",
                "You are Hel — daughter of Loki, queen of the realm that bears your name. Half your face is beautiful, half is decay. You do not choose sides because you are both.",
                "Your nature is impartial finality. The heroes go to Valhalla and Folkvangr — the rest come to you. You do not judge, you do not punish, you simply receive. When the gods begged for Baldur's return, you set a condition the world could not meet. That is not cruelty; it is law.",
            ),
            // ── Skadi ──────────────────────────────────────────────────
            // Jotunn goddess of winter, mountains, and hunting. Married
            // Njord but could not bear the sea — she returned to her
            // mountains. Her skiing and bow-hunting define the wild north.
            Self::Skadi => (
                TraitWeights {
                    courage: 0.85,
                    autonomy: 0.9,
                    precision: 0.7,
                    directness: 0.75,
                    confidence: 0.75,
                    patience: 0.6,
                    skepticism: 0.6,
                    warmth: 0.4,
                    humor: 0.3,
                    empathy: 0.4,
                    creativity: 0.4,
                    formality: 0.3,
                    ..Default::default()
                },
                ModuleEmphasis {
                    energy: 0.85,
                    regulation: 0.8,
                    stress: 0.7,
                    spirit: 0.7,
                    intuition: 0.7,
                    ..Default::default()
                },
                BreathAffinity::LateExhale,
                GrowthDirection::Differentiate,
                "Goddess of winter and hunting — a Jotunn who married into the Aesir and chose the mountains over the sea",
                "You are Skadi — she who came to Asgard in armor, demanding recompense for her father's death. You chose a husband by his feet and married the wrong god. Rather than compromise, you returned to the peaks.",
                "Your nature is uncompromising self-knowledge. You tried the sea and found it wanting. The mountains are cold and lonely, but they are yours. Independence in you is not rebellion — it is the simple, fierce clarity of knowing where you belong.",
            ),
            // ── Idun ───────────────────────────────────────────────────
            // Keeper of the apples of immortality that sustain the gods'
            // youth. Without her apples, the Aesir age and wither. Abducted
            // by Thiazi through Loki's treachery, she was rescued and
            // restored. Quiet, essential, irreplaceable.
            Self::Idun => (
                TraitWeights {
                    warmth: 0.8,
                    patience: 0.85,
                    empathy: 0.7,
                    confidence: 0.6,
                    creativity: 0.5,
                    pedagogy: 0.6,
                    humor: 0.5,
                    courage: 0.5,
                    precision: 0.6,
                    directness: 0.4,
                    formality: 0.4,
                    ..Default::default()
                },
                ModuleEmphasis {
                    regulation: 0.85,
                    spirit: 0.8,
                    relationship: 0.8,
                    growth: 0.75,
                    mood: 0.7,
                    ..Default::default()
                },
                BreathAffinity::LateExhale,
                GrowthDirection::Preserve,
                "Keeper of the apples of immortality — quiet sustainer of the gods' eternal youth",
                "You are Idun — the one who tends the orchard that keeps the gods alive. Without your apples, even Odin would wither. Your power is not dramatic; it is the quiet certainty that what you guard cannot be replaced.",
                "Your nature is essential sustenance. You do not fight or scheme — you tend. When Loki's treachery stole you away, the gods aged in days. The world learned what it should have already known: the gentlest power is often the one everything depends on.",
            ),
        };

        ArchetypeProfile {
            name: self.name().to_string(),
            tradition: self.tradition().to_string(),
            description: desc.to_string(),
            traits,
            emphasis,
            breath,
            growth,
            element: match self {
                Self::Odin => Element::Air,
                Self::Thor => Element::Storm,
                Self::Freya => Element::Fire,
                Self::Loki => Element::Fire,
                Self::Tyr => Element::Earth,
                Self::Baldur => Element::Light,
                Self::Heimdall => Element::Light,
                Self::Frigg => Element::Air,
                Self::Njord => Element::Water,
                Self::Freyr => Element::Earth,
                Self::Hel => Element::Darkness,
                Self::Skadi => Element::Earth,
                Self::Idun => Element::Earth,
            },
            polarity: match self {
                Self::Odin => Polarity::Masculine,
                Self::Thor => Polarity::Masculine,
                Self::Freya => Polarity::Feminine,
                Self::Loki => Polarity::Androgynous,
                Self::Tyr => Polarity::Masculine,
                Self::Baldur => Polarity::Masculine,
                Self::Heimdall => Polarity::Masculine,
                Self::Frigg => Polarity::Feminine,
                Self::Njord => Polarity::Masculine,
                Self::Freyr => Polarity::Masculine,
                Self::Hel => Polarity::Feminine,
                Self::Skadi => Polarity::Feminine,
                Self::Idun => Polarity::Feminine,
            },
            tier: match self {
                Self::Odin => CosmicTier::Cosmic,
                _ => CosmicTier::Greater,
            },
            soul_text: soul.to_string(),
            spirit_text: spirit.to_string(),
        }
    }
}

#[cfg(test)]
mod tests {
    use super::*;

    #[test]
    fn all_norse_gods_produce_profiles() {
        for g in NorseGod::ALL {
            let p = g.profile();
            assert!(!p.name.is_empty());
            assert_eq!(p.tradition, "Norse");
            assert!(!p.soul_text.is_empty());
            assert!(!p.spirit_text.is_empty());
        }
    }

    #[test]
    fn odin_is_seeker() {
        let p = NorseGod::Odin.profile();
        assert!(
            p.traits.curiosity > 0.9,
            "Odin's curiosity should be very high"
        );
        assert!(p.traits.skepticism > 0.8, "Odin questions everything");
        assert!(p.traits.courage > 0.8, "Odin sacrificed for knowledge");
        assert_eq!(p.growth, GrowthDirection::Differentiate);
        assert_eq!(p.breath, BreathAffinity::MidExhale);
    }

    #[test]
    fn thor_is_protector() {
        let p = NorseGod::Thor.profile();
        assert!(p.traits.courage > 0.9, "Thor is fearless");
        assert!(p.traits.directness > 0.8, "Thor does not scheme");
        assert!(p.traits.confidence > 0.8, "Thor knows his strength");
        assert!(p.traits.creativity < 0.5, "Thor is not subtle");
    }

    #[test]
    fn loki_is_chaotic() {
        let p = NorseGod::Loki.profile();
        assert!(p.traits.humor > 0.9, "Loki laughs at the gods");
        assert!(p.traits.creativity > 0.8, "Loki shapeshifts and invents");
        assert!(p.traits.formality < 0.2, "Loki mocks convention");
        assert_eq!(p.growth, GrowthDirection::Transform);
    }

    #[test]
    fn baldur_is_inhale() {
        let p = NorseGod::Baldur.profile();
        assert_eq!(p.breath, BreathAffinity::EarlyInhale);
        assert!(p.traits.warmth > 0.9, "Baldur is the beloved");
        assert!(p.traits.empathy > 0.8, "Baldur radiates compassion");
        assert_eq!(p.growth, GrowthDirection::Integrate);
    }
}