- Core calculations (Life Path, Expression, Soul Urge, Birthday) - Advanced numbers (Maturity, Personality, Hidden Passion, Karmic Lessons) - Timing cycles and optimal days finder - Compatibility analysis and name optimizer - Telos integration for personal development - Professional PDF report generation - Profile management system - Security fix: Add .claude/ to .gitignore 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
124 lines
4.1 KiB
Python
Executable file
124 lines
4.1 KiB
Python
Executable file
# Numerology
|
|
# Core Personality
|
|
|
|
import meanings
|
|
|
|
# Functions
|
|
|
|
# Reduces down to one digit or notifies of master number
|
|
def reduce(n, context=""):
|
|
master_nums = [11, 22, 33]
|
|
if n in master_nums:
|
|
if context:
|
|
print(f'Master number found in {context}:', n)
|
|
return n
|
|
total = sum(int(digit) for digit in str(n))
|
|
return total if total < 10 else reduce(total, context)
|
|
|
|
# Changes characters in name to digits and reduces
|
|
def name_num(name):
|
|
total = 0
|
|
for char in name:
|
|
x = ord(char) - 96
|
|
total += x if x < 10 else sum(int(digit) for digit in str(x))
|
|
return total
|
|
|
|
# Checks for master number, then reduces further as necessary
|
|
def master_check(total, context=""):
|
|
master_nums = [11, 22, 33]
|
|
if total in master_nums:
|
|
if context:
|
|
print(f'Master number found in {context}:', total)
|
|
return total
|
|
total = sum(int(digit) for digit in str(total))
|
|
return total if total < 10 else sum(int(digit) for digit in str(total))
|
|
|
|
def pull_vowels(name):
|
|
return [letter for letter in name if letter in 'aeiou']
|
|
|
|
# Asks for the person's full name
|
|
name_raw = input("Please enter the person's Full Name: \n").strip()
|
|
|
|
# Validate name input
|
|
while not name_raw or name_raw.isnumeric():
|
|
print('Error: Please enter a valid name (letters only).')
|
|
name_raw = input("Please enter the person's Full Name: \n").strip()
|
|
|
|
name = name_raw.lower()
|
|
name_split = name.split()
|
|
|
|
# Ensure the full name has at least first and last name
|
|
while len(name_split) < 2:
|
|
print('Error: More information needed. Please use at least your First and Last name.')
|
|
name_raw = input("Please enter the person's Full Name [First, Middle, Last]: \n").strip()
|
|
name = name_raw.lower()
|
|
name_split = name.split()
|
|
|
|
# Asks user for their birthdate
|
|
birth_raw = input('What is your full Date of Birth? (mm/dd/yyyy) [eg. 5/13/1982] \n').strip()
|
|
|
|
# Validate birth date input
|
|
while not birth_raw:
|
|
print('Error: Birth date cannot be blank.')
|
|
birth_raw = input('What is your full Date of Birth? (mm/dd/yyyy) [eg. 5/13/1982] \n').strip()
|
|
|
|
# Calculations
|
|
|
|
# Birthday
|
|
pieces = birth_raw.split('/')
|
|
month = reduce(int(pieces[0]), context="Month")
|
|
day = reduce(int(pieces[1]), context="Day")
|
|
year = reduce(int(pieces[2]), context="Year")
|
|
birth_date = month + day + year
|
|
|
|
# Life Path
|
|
life_path = reduce(birth_date, context="Life Path")
|
|
|
|
# Birthday
|
|
birthday = reduce(day, context="Birthday")
|
|
|
|
# Name
|
|
|
|
# Expression (Name)
|
|
subname_value = list()
|
|
|
|
# If name is longer than four subnames, only use first and last name
|
|
if len(name_split) > 4:
|
|
subname_value.append(reduce(master_check(name_num(name_split[0]), context="First Name"), context="First Name"))
|
|
subname_value.append(reduce(master_check(name_num(name_split[-1]), context="Last Name"), context="Last Name"))
|
|
else:
|
|
for subname in name_split:
|
|
subname_value.append(reduce(master_check(name_num(subname), context=f"Subname: {subname}"), context=f"Subname: {subname}"))
|
|
|
|
expression = master_check(reduce(sum(subname_value)), context="Expression")
|
|
|
|
# Soul Urge (Vowels)
|
|
subname_vowels = list()
|
|
for subname in name_split:
|
|
subname_vowels.append(master_check(name_num(pull_vowels(subname)), context=f"Vowels in {subname}"))
|
|
|
|
soul_urge = master_check(reduce(sum(subname_vowels)), context="Soul Urge")
|
|
|
|
# Core Output
|
|
|
|
print('\nCore for', name_raw,'\n')
|
|
# Core 1: Life Path (Birth Date)
|
|
print('1: Life Path:', life_path)
|
|
# Core 2: Expression (Name)
|
|
print('2: Expression:', expression)
|
|
# Core 3: Soul Urge (Vowels)
|
|
print("3: Soul Urge:", soul_urge)
|
|
# Core 4: Birthday
|
|
print('4: Birthday:', birthday)
|
|
|
|
# Detailed output
|
|
|
|
print('\nDetailed Meanings:\n')
|
|
# Life Path meaning
|
|
print(f'Life Path {life_path}:\n{meanings.life_path[life_path]}\n')
|
|
# Expression meaning
|
|
print(f'Expression {expression}:\n{meanings.expression[expression]}\n')
|
|
# Soul Urge meaning
|
|
print(f'Soul Urge {soul_urge}:\n{meanings.soul_urge[soul_urge]}\n')
|
|
# Birthday meaning
|
|
print(f'Birthday {birthday}:\n{meanings.birthday[birthday]}\n')
|