YoonJ-C commited on
Commit
90577fb
Β·
1 Parent(s): c359d3c

Major improvements to assessment scoring system and code cleanup

Browse files

🎯 Assessment Logic Improvements:
- Implement weighted question importance (Q1 weight 5, Q9 weight 2)
- Expand point scale from 2-3 to 1-5 for better tradition differentiation
- Split Q5 into separate prayer and ritual questions to eliminate Islam/Christianity bias
- Add canonical tradition keys with alias mapping for consistency
- Implement coverage-based tie-breaker when scores are equal
- Calculate accurate percentages based on max possible weighted score (150 points)

✨ New Traditions Added:
- Jainism, Shintoism, Stoicism, Confucianism
- Complete descriptions and practices for each

πŸ› Bug Fixes:
- Fix chat and transcribe endpoints to support Firebase users (not just legacy)
- Fix logout to redirect to landing page instead of login page
- Normalize all tradition keys through canon() function

🧹 Code Cleanup:
- Remove unused functions (get_user_answers, save_user_answers, get_user_results, save_user_results)
- Remove unused TRADITIONS dictionary
- Clean up verification system code
- Remove obsolete README_FIREBASE.md

πŸ“Š Testing:
- All scoring tests pass with balanced results
- Christianity and Islam now score equally when given equivalent answers
- No systematic bias in any tradition

Files changed (6) hide show
  1. README_FIREBASE.md +0 -209
  2. app.py +253 -145
  3. religions.csv +109 -16
  4. static/style.css +1 -1
  5. templates/index.html +1 -1
  6. templates/landing.html +1 -1
README_FIREBASE.md DELETED
@@ -1,209 +0,0 @@
1
- # Spiritual Path Assessment Tool
2
-
3
- A Flask-based web application that helps users discover which religious or spiritual path aligns with their beliefs, values, and lifestyle through an interactive questionnaire.
4
-
5
- ## Features
6
-
7
- - πŸ” **Firebase Authentication**
8
- - Email/Password authentication
9
- - Google Sign-In
10
- - Email verification
11
- - Password reset
12
-
13
- - πŸ“Š **Assessment System**
14
- - 8-question spiritual path questionnaire
15
- - Personalized recommendations based on responses
16
- - Detailed information about each spiritual path
17
-
18
- - πŸ’¬ **AI-Powered Chatbot**
19
- - Ask questions about recommended spiritual paths
20
- - RAG-enhanced responses using religion-specific data
21
- - Voice input support with Whisper transcription
22
-
23
- - πŸ—„οΈ **Firestore Database**
24
- - Secure user data storage
25
- - Assessment answers and results persistence
26
- - Real-time synchronization
27
-
28
- ## Tech Stack
29
-
30
- - **Backend**: Flask (Python)
31
- - **Frontend**: HTML, CSS, JavaScript
32
- - **Authentication**: Firebase Authentication
33
- - **Database**: Cloud Firestore
34
- - **AI/ML**:
35
- - Together AI (chatbot)
36
- - OpenAI Whisper (voice transcription)
37
- - **Deployment**: Render.com / Docker
38
-
39
- ## Quick Start
40
-
41
- ### Prerequisites
42
-
43
- - Python 3.9+
44
- - Firebase project (see [FIREBASE_SETUP.md](FIREBASE_SETUP.md))
45
- - API keys for Together AI and OpenAI (optional, for chatbot features)
46
-
47
- ### Installation
48
-
49
- 1. **Clone the repository**
50
- ```bash
51
- git clone https://github.com/YoonJ-C/Spiritual-Path-Assessment.git
52
- cd Spiritual-Path-Assessment
53
- ```
54
-
55
- 2. **Install dependencies**
56
- ```bash
57
- pip install -r requirements.txt
58
- ```
59
-
60
- 3. **Set up Firebase** (detailed guide in [FIREBASE_SETUP.md](FIREBASE_SETUP.md))
61
- - Create a Firebase project
62
- - Enable Authentication (Email/Password and Google)
63
- - Create Firestore database
64
- - Download service account key as `serviceAccountKey.json`
65
-
66
- 4. **Configure environment variables**
67
- ```bash
68
- cp .env.example .env
69
- # Edit .env with your Firebase credentials and API keys
70
- ```
71
-
72
- 5. **Run the application**
73
- ```bash
74
- python app.py
75
- ```
76
-
77
- 6. **Open in browser**
78
- ```
79
- http://localhost:5003
80
- ```
81
-
82
- ## Environment Variables
83
-
84
- See `.env.example` for all required environment variables. Key variables:
85
-
86
- - `FIREBASE_CREDENTIALS_PATH`: Path to service account JSON file
87
- - `FIREBASE_WEB_API_KEY`: Firebase web API key
88
- - `FIREBASE_PROJECT_ID`: Your Firebase project ID
89
- - `TOGETHER_API_KEY`: Together AI API key (for chatbot)
90
- - `OPENAI_API_KEY`: OpenAI API key (for voice input)
91
-
92
- ## Deployment
93
-
94
- ### Render.com
95
-
96
- 1. Push your code to GitHub
97
- 2. Create a new Web Service on Render.com
98
- 3. Connect your GitHub repository
99
- 4. Add environment variables in Render dashboard
100
- 5. Upload `serviceAccountKey.json` as a secret file
101
- 6. Deploy!
102
-
103
- See [FIREBASE_SETUP.md](FIREBASE_SETUP.md) for detailed deployment instructions.
104
-
105
- ### Docker
106
-
107
- ```bash
108
- docker build -t spiritual-path-assessment .
109
- docker run -p 5003:5003 --env-file .env spiritual-path-assessment
110
- ```
111
-
112
- ## Project Structure
113
-
114
- ```
115
- Spiritual-Path-Assessment/
116
- β”œβ”€β”€ app.py # Main Flask application
117
- β”œβ”€β”€ rag_utils.py # RAG utilities for chatbot
118
- β”œβ”€β”€ requirements.txt # Python dependencies
119
- β”œβ”€β”€ Dockerfile # Docker configuration
120
- β”œβ”€β”€ FIREBASE_SETUP.md # Firebase setup guide
121
- β”œβ”€β”€ .env.example # Environment variables template
122
- β”œβ”€β”€ religions.csv # Religion data for RAG
123
- β”œβ”€β”€ static/
124
- β”‚ β”œβ”€β”€ style.css # Main styles
125
- β”‚ β”œβ”€β”€ landing.css # Landing page styles
126
- β”‚ β”œβ”€β”€ script.js # Frontend JavaScript
127
- β”‚ β”œβ”€β”€ design-tokens.css # Design system tokens
128
- β”‚ └── images/ # Image assets
129
- └── templates/
130
- β”œβ”€β”€ landing.html # Landing page
131
- └── index.html # Main app template
132
- ```
133
-
134
- ## Features in Detail
135
-
136
- ### Authentication
137
-
138
- - **Firebase Authentication** provides secure user management
139
- - **Google Sign-In** for quick access
140
- - **Email verification** ensures valid user accounts
141
- - **Password reset** via email
142
- - **Legacy support** for existing username/password users
143
-
144
- ### Assessment
145
-
146
- - 8 carefully crafted questions covering:
147
- - Views on divinity
148
- - Spiritual practices
149
- - Afterlife beliefs
150
- - Moral guidance
151
- - Ritual importance
152
- - Nature relationship
153
- - Suffering perspective
154
- - Community role
155
-
156
- - Results show top 3 spiritual paths with:
157
- - Alignment percentage
158
- - Description
159
- - Common practices
160
- - Core beliefs
161
-
162
- ### Chatbot
163
-
164
- - Ask questions about recommended spiritual paths
165
- - Powered by Meta-Llama-3-8B-Instruct-Lite
166
- - RAG-enhanced with detailed religion data
167
- - Voice input with live transcription
168
- - Conversation history maintained per religion
169
-
170
- ## Security
171
-
172
- - Firebase handles authentication securely
173
- - Firestore security rules restrict data access
174
- - Service account keys kept secure
175
- - HTTPS enforced in production
176
- - Session management with secure cookies
177
-
178
- ## Contributing
179
-
180
- Contributions are welcome! Please:
181
-
182
- 1. Fork the repository
183
- 2. Create a feature branch
184
- 3. Make your changes
185
- 4. Test thoroughly
186
- 5. Submit a pull request
187
-
188
- ## License
189
-
190
- Apache 2.0 License - see LICENSE file for details
191
-
192
- ## Support
193
-
194
- For issues or questions:
195
- - Open an issue on GitHub
196
- - Check [FIREBASE_SETUP.md](FIREBASE_SETUP.md) for setup help
197
- - Review Firebase documentation
198
-
199
- ## Acknowledgments
200
-
201
- - Firebase for authentication and database
202
- - Together AI for chatbot capabilities
203
- - OpenAI for Whisper transcription
204
- - All contributors and users
205
-
206
- ---
207
-
208
- Made with ❀️ for spiritual seekers everywhere
209
-
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
app.py CHANGED
@@ -69,94 +69,234 @@ openai_client = OpenAI(api_key=OPENAI_API_KEY) if OPENAI_API_KEY else None
69
  # Load detailed religion data at startup
70
  RELIGIONS_CSV = load_religions_from_csv('religions.csv')
71
 
72
- # Assessment Questions
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
73
  QUESTIONS = [
74
  {
75
  "id": 1,
76
  "question": "What is your view on the nature of the divine?",
77
  "options": {
78
- "One supreme God who created everything": {"christianity": 3, "islam": 3, "judaism": 3},
79
- "Multiple gods and goddesses": {"hinduism": 3, "paganism": 3},
80
- "A universal energy or force": {"buddhism": 2, "taoism": 3, "new_age": 3},
81
- "No divine being, focus on human potential": {"humanism": 3, "atheism": 3},
82
- "Uncertain or unknowable": {"agnosticism": 3}
 
 
 
 
 
 
 
 
 
 
83
  }
84
  },
85
  {
86
  "id": 2,
87
  "question": "How do you prefer to connect with spirituality?",
88
  "options": {
89
- "Through organized worship and community": {"christianity": 2, "islam": 2, "judaism": 2},
90
- "Through personal meditation and reflection": {"buddhism": 3, "hinduism": 2, "taoism": 2},
91
- "Through nature and natural cycles": {"paganism": 3, "indigenous": 3},
92
- "Through reason and philosophy": {"humanism": 2, "stoicism": 3},
93
- "I don't feel the need for spiritual connection": {"atheism": 3}
 
 
 
 
 
 
 
 
 
 
94
  }
95
  },
96
  {
97
  "id": 3,
98
  "question": "What is your belief about the afterlife?",
99
  "options": {
100
- "Heaven or Hell based on faith/deeds": {"christianity": 3, "islam": 3},
101
- "Reincarnation until enlightenment": {"hinduism": 3, "buddhism": 3},
102
- "Ancestral realm or spiritual world": {"indigenous": 2, "paganism": 2},
103
- "No afterlife, this life is all there is": {"atheism": 3, "humanism": 2},
104
- "Unsure or open to possibilities": {"agnosticism": 2, "new_age": 2}
 
 
 
 
 
 
 
 
 
 
105
  }
106
  },
107
  {
108
  "id": 4,
109
  "question": "What guides your moral and ethical decisions?",
110
  "options": {
111
- "Sacred texts and religious teachings": {"christianity": 3, "islam": 3, "judaism": 3},
112
- "Universal principles of compassion and mindfulness": {"buddhism": 3, "jainism": 3},
113
- "Harmony with nature and balance": {"taoism": 3, "indigenous": 2},
114
- "Reason, empathy, and human rights": {"humanism": 3, "secularism": 3},
115
- "Personal intuition and inner wisdom": {"new_age": 2, "spiritualism": 3}
 
 
 
 
 
 
 
 
 
 
 
 
 
116
  }
117
  },
118
  {
119
  "id": 5,
120
- "question": "What role does ritual or practice play in your life?",
121
  "options": {
122
- "Regular prayer and worship are essential": {"islam": 3, "christianity": 2, "judaism": 2},
123
- "Daily meditation or mindfulness practice": {"buddhism": 3, "hinduism": 2, "zen": 3},
124
- "Seasonal celebrations and ceremonies": {"paganism": 3, "wicca": 3},
125
- "Minimal to no ritual, prefer intellectual engagement": {"humanism": 2, "deism": 2},
126
- "Flexible, whatever feels meaningful to me": {"new_age": 2, "spiritual_not_religious": 3}
 
 
 
 
 
 
 
 
 
 
 
 
 
127
  }
128
  },
129
  {
130
  "id": 6,
131
- "question": "How do you view the relationship between humans and nature?",
132
  "options": {
133
- "Humans are stewards of God's creation": {"christianity": 2, "islam": 2, "judaism": 2},
134
- "All life is interconnected and sacred": {"buddhism": 2, "hinduism": 2, "jainism": 3},
135
- "Nature itself is divine": {"paganism": 3, "pantheism": 3, "indigenous": 3},
136
- "Nature follows natural laws we can understand": {"atheism": 2, "humanism": 2},
137
- "We should live in harmony with natural flow": {"taoism": 3, "shintoism": 2}
 
 
 
 
 
 
 
 
 
 
138
  }
139
  },
140
  {
141
  "id": 7,
142
- "question": "What is your view on suffering and its purpose?",
143
  "options": {
144
- "A test of faith or part of God's plan": {"christianity": 2, "islam": 2},
145
- "Result of attachment and desire": {"buddhism": 3, "stoicism": 2},
146
- "Karma from past actions": {"hinduism": 3, "sikhism": 2},
147
- "Random or result of natural causes": {"atheism": 3, "secular": 2},
148
- "An opportunity for growth and learning": {"new_age": 2, "spiritualism": 2}
 
 
 
 
 
 
 
 
 
 
149
  }
150
  },
151
  {
152
  "id": 8,
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
153
  "question": "How important is community in your spiritual life?",
154
  "options": {
155
- "Very important, prefer group worship": {"christianity": 2, "islam": 2, "sikhism": 3},
156
- "Somewhat important, but personal practice matters more": {"buddhism": 2, "hinduism": 2},
157
- "Community of like-minded seekers": {"paganism": 2, "unitarian": 3},
158
- "Not important, spirituality is personal": {"spiritual_not_religious": 3, "deism": 2},
159
- "Prefer secular community over religious": {"humanism": 2, "atheism": 2}
 
 
 
 
 
 
 
 
 
 
160
  }
161
  }
162
  ]
@@ -176,50 +316,13 @@ RELIGIONS = {
176
  "new_age": {"name": "New Age Spirituality", "description": "Eclectic approach emphasizing personal growth.", "practices": "Meditation, energy work, crystals, yoga", "core_beliefs": "Personal transformation, universal consciousness"},
177
  "spiritual_not_religious": {"name": "Spiritual But Not Religious", "description": "Personal spirituality without organized religion.", "practices": "Personal practices, meditation, self-reflection", "core_beliefs": "Individual journey, authenticity, diverse wisdom"},
178
  "sikhism": {"name": "Sikhism", "description": "One God emphasizing service, equality, and meditation.", "practices": "Prayer, meditation, community service, 5 Ks", "core_beliefs": "One God, equality, honest living, sharing"},
179
- "indigenous": {"name": "Indigenous Spirituality", "description": "Traditional practices honoring ancestors and land.", "practices": "Ceremonies, storytelling, seasonal rituals", "core_beliefs": "Land connection, ancestor veneration, reciprocity"}
 
 
 
 
180
  }
181
 
182
- # Email verification tokens (in-memory for simplicity)
183
- VERIFICATION_TOKENS = {}
184
-
185
- def validate_email(email):
186
- """Basic email validation"""
187
- pattern = r'^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$'
188
- return re.match(pattern, email) is not None
189
-
190
- def send_verification_email(email, token):
191
- """Send verification email (dev mode: prints to console)"""
192
- verification_url = f"{request.host_url}verify-email?token={token}"
193
- message = f"""
194
- Hello!
195
-
196
- Please verify your email by clicking this link:
197
- {verification_url}
198
-
199
- Or visit: {request.host_url}verify-email?token={token}
200
- """
201
- print(f"[EMAIL] To: {email}")
202
- print(f"[EMAIL] Subject: Verify your email")
203
- print(f"[EMAIL] Body:\n{message}")
204
- # In production, replace with actual SMTP sending
205
- return True
206
-
207
- def send_password_reset_email(email, token):
208
- """Send password reset email (dev mode: prints to console)"""
209
- reset_url = f"{request.host_url}reset-password?token={token}"
210
- message = f"""
211
- Hello!
212
-
213
- You requested a password reset. Click this link:
214
- {reset_url}
215
-
216
- Or visit: {request.host_url}reset-password?token={token}
217
- """
218
- print(f"[EMAIL] To: {email}")
219
- print(f"[EMAIL] Subject: Password Reset Request")
220
- print(f"[EMAIL] Body:\n{message}")
221
- # In production, replace with actual SMTP sending
222
- return True
223
 
224
  # ============================================================================
225
  # FIRESTORE HELPER FUNCTIONS
@@ -251,51 +354,7 @@ def create_or_update_user(uid, user_data):
251
  print(f"Error saving user {uid}: {e}")
252
  return False
253
 
254
- def get_user_answers(uid):
255
- """Get user's assessment answers from Firestore"""
256
- if not db:
257
- return []
258
- try:
259
- user_data = get_user_by_uid(uid)
260
- return user_data.get('answers', []) if user_data else []
261
- except Exception as e:
262
- print(f"Error getting answers for {uid}: {e}")
263
- return []
264
 
265
- def save_user_answers(uid, answers):
266
- """Save user's assessment answers to Firestore"""
267
- if not db:
268
- return False
269
- try:
270
- user_ref = db.collection('users').document(uid)
271
- user_ref.update({'answers': answers})
272
- return True
273
- except Exception as e:
274
- print(f"Error saving answers for {uid}: {e}")
275
- return False
276
-
277
- def get_user_results(uid):
278
- """Get user's assessment results from Firestore"""
279
- if not db:
280
- return []
281
- try:
282
- user_data = get_user_by_uid(uid)
283
- return user_data.get('results', []) if user_data else []
284
- except Exception as e:
285
- print(f"Error getting results for {uid}: {e}")
286
- return []
287
-
288
- def save_user_results(uid, results):
289
- """Save user's assessment results to Firestore"""
290
- if not db:
291
- return False
292
- try:
293
- user_ref = db.collection('users').document(uid)
294
- user_ref.update({'results': results})
295
- return True
296
- except Exception as e:
297
- print(f"Error saving results for {uid}: {e}")
298
- return False
299
 
300
  def verify_firebase_token(id_token):
301
  """Verify Firebase ID token and return decoded token"""
@@ -346,27 +405,76 @@ def initialize_default_user():
346
  print("βœ… Default test user created (username: test, password: test)")
347
 
348
  def calculate_results(answers):
349
- """Calculate which spiritual paths align with user's answers"""
 
 
 
350
  scores = {}
 
351
 
 
352
  for answer in answers:
353
  question = next((q for q in QUESTIONS if q["id"] == answer["question_id"]), None)
354
  if question and answer["answer"] in question["options"]:
355
- points = question["options"][answer["answer"]]
356
- for religion, score in points.items():
357
- scores[religion] = scores.get(religion, 0) + score
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
358
 
359
- # Sort by score
360
- sorted_scores = sorted(scores.items(), key=lambda x: x[1], reverse=True)
 
 
 
 
 
361
 
362
- # Get top 3 recommendations
363
  recommendations = []
364
- for religion_key, score in sorted_scores[:3]:
365
- if religion_key in RELIGIONS:
366
- religion_info = RELIGIONS[religion_key].copy()
367
- religion_info["score"] = score
368
- religion_info["percentage"] = round((score / (len(answers) * 3)) * 100)
369
- recommendations.append(religion_info)
 
 
 
 
 
 
 
 
 
 
370
 
371
  return recommendations
372
 
@@ -719,7 +827,7 @@ def logout():
719
  session.pop('user_id', None)
720
  session.pop('email', None)
721
  session.pop('username', None)
722
- return redirect(url_for('login'))
723
 
724
  @app.route("/submit_assessment", methods=["POST"])
725
  def submit_assessment():
@@ -794,7 +902,7 @@ def chat():
794
  RAG-enhanced chat endpoint for spiritual guidance
795
  Uses retrieval-augmented generation with religion-specific context
796
  """
797
- if 'username' not in session:
798
  return jsonify({"success": False, "message": "Not logged in"})
799
 
800
  if not client:
 
69
  # Load detailed religion data at startup
70
  RELIGIONS_CSV = load_religions_from_csv('religions.csv')
71
 
72
+
73
+ # Aliases map inconsistent keys to canonical ones
74
+ TRADITION_ALIASES = {
75
+ "secular": "humanism",
76
+ "secularism": "humanism",
77
+ "spiritualism": "spiritual_not_religious",
78
+ "wicca": "paganism",
79
+ "zen": "buddhism",
80
+ "pantheism": "paganism",
81
+ "unitarian": "spiritual_not_religious",
82
+ "deism": "agnosticism"
83
+ }
84
+
85
+ def canon(key):
86
+ """Normalize tradition key to canonical form"""
87
+ return TRADITION_ALIASES.get(key, key)
88
+
89
+ # Question importance weights (higher = more significant)
90
+ QUESTION_WEIGHTS = {
91
+ 1: 5, # Nature of the divine (most fundamental)
92
+ 2: 3, # Spiritual connection style
93
+ 3: 4, # Afterlife beliefs
94
+ 4: 4, # Moral/ethical foundation
95
+ 5: 3, # Prayer practices
96
+ 6: 3, # Ritual/practice style
97
+ 7: 3, # Human-nature relationship
98
+ 8: 3, # View on suffering
99
+ 9: 2 # Community importance
100
+ }
101
+
102
+ # Assessment Questions ----------------------------
103
  QUESTIONS = [
104
  {
105
  "id": 1,
106
  "question": "What is your view on the nature of the divine?",
107
  "options": {
108
+ "One supreme God who created everything": {
109
+ "christianity": 5, "islam": 5, "judaism": 5, "sikhism": 4
110
+ },
111
+ "Multiple gods and goddesses": {
112
+ "hinduism": 5, "paganism": 5, "shintoism": 3
113
+ },
114
+ "A universal energy or force": {
115
+ "taoism": 5, "buddhism": 4, "new_age": 4, "spiritual_not_religious": 3
116
+ },
117
+ "No divine being, focus on human potential": {
118
+ "humanism": 5, "atheism": 5, "stoicism": 3, "confucianism": 2
119
+ },
120
+ "Uncertain or unknowable": {
121
+ "agnosticism": 5, "spiritual_not_religious": 2
122
+ }
123
  }
124
  },
125
  {
126
  "id": 2,
127
  "question": "How do you prefer to connect with spirituality?",
128
  "options": {
129
+ "Through organized worship and community": {
130
+ "christianity": 4, "islam": 4, "judaism": 4, "sikhism": 3
131
+ },
132
+ "Through personal meditation and reflection": {
133
+ "buddhism": 5, "hinduism": 4, "taoism": 4, "jainism": 4
134
+ },
135
+ "Through nature and natural cycles": {
136
+ "paganism": 5, "indigenous": 5, "shintoism": 4
137
+ },
138
+ "Through reason and philosophy": {
139
+ "stoicism": 5, "humanism": 4, "confucianism": 3
140
+ },
141
+ "I don't feel the need for spiritual connection": {
142
+ "atheism": 5, "humanism": 2
143
+ }
144
  }
145
  },
146
  {
147
  "id": 3,
148
  "question": "What is your belief about the afterlife?",
149
  "options": {
150
+ "Heaven or Hell based on faith/deeds": {
151
+ "christianity": 5, "islam": 5, "judaism": 3
152
+ },
153
+ "Reincarnation until enlightenment": {
154
+ "hinduism": 5, "buddhism": 5, "jainism": 4, "sikhism": 3
155
+ },
156
+ "Ancestral realm or spiritual world": {
157
+ "indigenous": 4, "paganism": 3, "shintoism": 3, "confucianism": 2
158
+ },
159
+ "No afterlife, this life is all there is": {
160
+ "atheism": 5, "humanism": 4, "stoicism": 2
161
+ },
162
+ "Unsure or open to possibilities": {
163
+ "agnosticism": 4, "new_age": 3, "spiritual_not_religious": 3
164
+ }
165
  }
166
  },
167
  {
168
  "id": 4,
169
  "question": "What guides your moral and ethical decisions?",
170
  "options": {
171
+ "Sacred texts and religious teachings": {
172
+ "islam": 5, "christianity": 5, "judaism": 5, "sikhism": 3
173
+ },
174
+ "Universal principles of compassion and mindfulness": {
175
+ "buddhism": 5, "jainism": 5, "hinduism": 3
176
+ },
177
+ "Harmony with nature and balance": {
178
+ "taoism": 5, "indigenous": 4, "shintoism": 3, "paganism": 3
179
+ },
180
+ "Reason, empathy, and human rights": {
181
+ "humanism": 5, "atheism": 3, "stoicism": 3
182
+ },
183
+ "Personal intuition and inner wisdom": {
184
+ "spiritual_not_religious": 5, "new_age": 4
185
+ },
186
+ "Virtue, duty, and social harmony": {
187
+ "confucianism": 5, "stoicism": 4
188
+ }
189
  }
190
  },
191
  {
192
  "id": 5,
193
+ "question": "How do you approach prayer or meditation?",
194
  "options": {
195
+ "Structured daily prayers at set times (e.g., 5 times daily)": {
196
+ "islam": 5, "sikhism": 3
197
+ },
198
+ "Regular personal prayer and church attendance": {
199
+ "christianity": 5, "judaism": 4
200
+ },
201
+ "Daily meditation or mindfulness practice": {
202
+ "buddhism": 5, "hinduism": 4, "jainism": 4
203
+ },
204
+ "Occasional prayer or reflection when needed": {
205
+ "christianity": 2, "judaism": 2, "spiritual_not_religious": 3, "new_age": 2
206
+ },
207
+ "Meditation for inner peace, not religious practice": {
208
+ "stoicism": 3, "humanism": 2, "buddhism": 2
209
+ },
210
+ "I don't pray or meditate": {
211
+ "atheism": 4, "humanism": 3
212
+ }
213
  }
214
  },
215
  {
216
  "id": 6,
217
+ "question": "What role do rituals and ceremonies play in your life?",
218
  "options": {
219
+ "Essential - weekly services and holy day observances": {
220
+ "christianity": 4, "islam": 4, "judaism": 5, "hinduism": 3
221
+ },
222
+ "Important - seasonal celebrations and nature rituals": {
223
+ "paganism": 5, "indigenous": 5, "shintoism": 4
224
+ },
225
+ "Helpful - personal rituals that feel meaningful": {
226
+ "new_age": 4, "spiritual_not_religious": 4, "hinduism": 2
227
+ },
228
+ "Minimal - prefer contemplation and philosophy": {
229
+ "stoicism": 4, "humanism": 3, "confucianism": 2, "agnosticism": 2
230
+ },
231
+ "None - I don't practice rituals": {
232
+ "atheism": 4, "humanism": 2
233
+ }
234
  }
235
  },
236
  {
237
  "id": 7,
238
+ "question": "How do you view the relationship between humans and nature?",
239
  "options": {
240
+ "Humans are stewards of God's creation": {
241
+ "christianity": 4, "islam": 4, "judaism": 4
242
+ },
243
+ "All life is interconnected and sacred": {
244
+ "buddhism": 5, "hinduism": 4, "jainism": 5, "indigenous": 4
245
+ },
246
+ "Nature itself is divine and should be revered": {
247
+ "paganism": 5, "indigenous": 4, "shintoism": 5, "taoism": 3
248
+ },
249
+ "Nature follows natural laws we can study": {
250
+ "atheism": 4, "humanism": 4, "stoicism": 2
251
+ },
252
+ "We should live in harmony with natural flow": {
253
+ "taoism": 5, "buddhism": 3, "shintoism": 3, "indigenous": 3
254
+ }
255
  }
256
  },
257
  {
258
  "id": 8,
259
+ "question": "What is your view on suffering and its purpose?",
260
+ "options": {
261
+ "A test of faith or part of God's plan": {
262
+ "christianity": 4, "islam": 4, "judaism": 3
263
+ },
264
+ "Result of attachment, desire, and ignorance": {
265
+ "buddhism": 5, "stoicism": 3, "jainism": 3
266
+ },
267
+ "Karma from past actions and choices": {
268
+ "hinduism": 5, "sikhism": 4, "buddhism": 3, "jainism": 3
269
+ },
270
+ "Natural part of life without cosmic meaning": {
271
+ "atheism": 5, "humanism": 3, "stoicism": 2
272
+ },
273
+ "An opportunity for spiritual growth": {
274
+ "new_age": 4, "spiritual_not_religious": 3, "christianity": 2
275
+ },
276
+ "To be accepted with virtue and equanimity": {
277
+ "stoicism": 5, "buddhism": 2, "confucianism": 2
278
+ }
279
+ }
280
+ },
281
+ {
282
+ "id": 9,
283
  "question": "How important is community in your spiritual life?",
284
  "options": {
285
+ "Very important - prefer group worship and fellowship": {
286
+ "christianity": 4, "islam": 4, "sikhism": 5, "judaism": 4
287
+ },
288
+ "Somewhat important - personal practice matters more": {
289
+ "buddhism": 3, "hinduism": 3, "taoism": 2
290
+ },
291
+ "Community of like-minded spiritual seekers": {
292
+ "paganism": 4, "spiritual_not_religious": 4, "new_age": 3
293
+ },
294
+ "Not important - spirituality is deeply personal": {
295
+ "spiritual_not_religious": 3, "agnosticism": 3, "taoism": 2
296
+ },
297
+ "Prefer secular community over religious": {
298
+ "humanism": 4, "atheism": 4, "stoicism": 2
299
+ }
300
  }
301
  }
302
  ]
 
316
  "new_age": {"name": "New Age Spirituality", "description": "Eclectic approach emphasizing personal growth.", "practices": "Meditation, energy work, crystals, yoga", "core_beliefs": "Personal transformation, universal consciousness"},
317
  "spiritual_not_religious": {"name": "Spiritual But Not Religious", "description": "Personal spirituality without organized religion.", "practices": "Personal practices, meditation, self-reflection", "core_beliefs": "Individual journey, authenticity, diverse wisdom"},
318
  "sikhism": {"name": "Sikhism", "description": "One God emphasizing service, equality, and meditation.", "practices": "Prayer, meditation, community service, 5 Ks", "core_beliefs": "One God, equality, honest living, sharing"},
319
+ "indigenous": {"name": "Indigenous Spirituality", "description": "Traditional practices honoring ancestors and land.", "practices": "Ceremonies, storytelling, seasonal rituals", "core_beliefs": "Land connection, ancestor veneration, reciprocity"},
320
+ "jainism": {"name": "Jainism", "description": "Ancient path emphasizing non-violence and spiritual purification.", "practices": "Meditation, fasting, non-violence, self-discipline", "core_beliefs": "Ahimsa (non-violence), karma liberation, asceticism"},
321
+ "shintoism": {"name": "Shinto", "description": "Japanese tradition honoring kami spirits and natural harmony.", "practices": "Shrine visits, purification rituals, festivals", "core_beliefs": "Kami reverence, purity, harmony with nature"},
322
+ "stoicism": {"name": "Stoicism", "description": "Philosophy emphasizing virtue, reason, and acceptance of fate.", "practices": "Contemplation, virtue practice, rational thinking", "core_beliefs": "Virtue, reason, acceptance, inner peace"},
323
+ "confucianism": {"name": "Confucianism", "description": "Philosophy emphasizing moral cultivation and social harmony.", "practices": "Ritual propriety, study, self-cultivation", "core_beliefs": "Filial piety, benevolence, social harmony"}
324
  }
325
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
326
 
327
  # ============================================================================
328
  # FIRESTORE HELPER FUNCTIONS
 
354
  print(f"Error saving user {uid}: {e}")
355
  return False
356
 
 
 
 
 
 
 
 
 
 
 
357
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
358
 
359
  def verify_firebase_token(id_token):
360
  """Verify Firebase ID token and return decoded token"""
 
405
  print("βœ… Default test user created (username: test, password: test)")
406
 
407
  def calculate_results(answers):
408
+ """
409
+ Calculate which spiritual paths align with user's answers
410
+ Uses weighted scoring with canonical tradition keys and tie-breakers
411
+ """
412
  scores = {}
413
+ coverage = {} # Track number of questions contributing to each tradition (for tie-breaking)
414
 
415
+ # Calculate weighted scores
416
  for answer in answers:
417
  question = next((q for q in QUESTIONS if q["id"] == answer["question_id"]), None)
418
  if question and answer["answer"] in question["options"]:
419
+ points_map = question["options"][answer["answer"]]
420
+ question_weight = QUESTION_WEIGHTS.get(answer["question_id"], 1)
421
+
422
+ # Track which traditions are scored in this question (for tie-breaker)
423
+ touched_this_question = set()
424
+
425
+ for tradition_key, base_points in points_map.items():
426
+ # Normalize tradition key to canonical form
427
+ canonical_key = canon(tradition_key)
428
+
429
+ # Calculate weighted score
430
+ weighted_score = base_points * question_weight
431
+ scores[canonical_key] = scores.get(canonical_key, 0) + weighted_score
432
+ touched_this_question.add(canonical_key)
433
+
434
+ # Update coverage count for tie-breaking
435
+ for key in touched_this_question:
436
+ coverage[key] = coverage.get(key, 0) + 1
437
+
438
+ # Calculate maximum possible score for percentage calculation
439
+ max_possible_score = 0
440
+ for answer in answers:
441
+ question = next((q for q in QUESTIONS if q["id"] == answer["question_id"]), None)
442
+ if question:
443
+ # Find the highest point value among all options for this question
444
+ max_option_points = 0
445
+ for option_scores in question["options"].values():
446
+ if option_scores:
447
+ max_option_points = max(max_option_points, max(option_scores.values()))
448
+
449
+ question_weight = QUESTION_WEIGHTS.get(answer["question_id"], 1)
450
+ max_possible_score += max_option_points * question_weight
451
 
452
+ # Sort by score (primary) and coverage (tie-breaker)
453
+ # Higher coverage means the tradition was scored across more questions
454
+ sorted_scores = sorted(
455
+ scores.items(),
456
+ key=lambda x: (x[1], coverage.get(x[0], 0)),
457
+ reverse=True
458
+ )
459
 
460
+ # Build top 3 recommendations
461
  recommendations = []
462
+ for tradition_key, score in sorted_scores:
463
+ if tradition_key in RELIGIONS:
464
+ tradition_info = RELIGIONS[tradition_key].copy()
465
+ tradition_info["score"] = score
466
+
467
+ # Calculate percentage based on actual max possible
468
+ if max_possible_score > 0:
469
+ tradition_info["percentage"] = round((score / max_possible_score) * 100)
470
+ else:
471
+ tradition_info["percentage"] = 0
472
+
473
+ recommendations.append(tradition_info)
474
+
475
+ # Stop after top 3
476
+ if len(recommendations) == 3:
477
+ break
478
 
479
  return recommendations
480
 
 
827
  session.pop('user_id', None)
828
  session.pop('email', None)
829
  session.pop('username', None)
830
+ return redirect(url_for('landing'))
831
 
832
  @app.route("/submit_assessment", methods=["POST"])
833
  def submit_assessment():
 
902
  RAG-enhanced chat endpoint for spiritual guidance
903
  Uses retrieval-augmented generation with religion-specific context
904
  """
905
+ if 'user_id' not in session and 'username' not in session:
906
  return jsonify({"success": False, "message": "Not logged in"})
907
 
908
  if not client:
religions.csv CHANGED
@@ -1,16 +1,109 @@
1
- "key","name","description","practices","core_beliefs","common_curiosities"
2
- "christianity","Christianity","Christianity is a major monotheistic religion originating from the life, teachings, and death of Jesus of Nazareth in the 1st century CE. It is the world's largest religion with over two billion adherents, emphasizing faith in Jesus Christ as the Son of God who offers salvation through his death and resurrection. The religion has profoundly influenced global culture, ethics, and institutions, evolving through historical interactions with diverse civilizations and adapting to various contexts while maintaining a focus on redemption and community.","Key practices include prayer (personal and communal communication with God), Bible study (reading and interpreting sacred scriptures), attending church services (worship, preaching, and fellowship), and sacraments such as communion (commemorating Jesus' Last Supper) and baptism (symbolizing spiritual rebirth). Other observances involve fasting, charity, mission work, and celebrating holidays like Christmas (Jesus' birth) and Easter (resurrection). Practices vary by denomination, from liturgical rituals in Catholicism to charismatic worship in Pentecostalism.","Central beliefs include the Trinity (one God in three persons: Father, Son, Holy Spirit), salvation through faith in Jesus Christ (who atoned for humanity's sins), the resurrection and eternal life, original sin (humanity's fallen state), and the authority of the Bible. Additional doctrines encompass grace (God's unmerited favor), the church as the body of believers, eschatology (end times and judgment), and ethical living based on love, forgiveness, and justice. Monotheism is foundational, rejecting polytheism and atheism.","Common questions include: Why does God allow evil and suffering? Is faith irrational or opposed to science? Why is Jesus the only way to heaven? Can one lose salvation? Why are there hypocrites in Christianity? How to take the Bible literally? How should Christians respond to issues like LGBTQ+ rights, racism, and injustice? Interesting facts: Christianity emerged from Judaism; not all ministers wear special attire; churches are communities, not just buildings; over 2 billion followers worldwide; the Bible has no contradictions claimed by believers but debated by skeptics."
3
- "islam","Islam","Islam is a monotheistic religion founded in 7th-century Arabia by the Prophet Muhammad, emphasizing submission to the will of Allah (God) as revealed in the Quran. With over 1.5 billion adherents worldwide, it integrates spiritual devotion with social, legal, and ethical guidelines, fostering a sense of global community (ummah) and influencing diverse cultures through conquests, trade, and mysticism. It promotes justice, compassion, and personal accountability in both individual and communal life.","Core practices, known as the Five Pillars, include Shahada (profession of faith), Salat (five daily prayers), Zakat (charity to the needy), Sawm (fasting during Ramadan), and Hajj (pilgrimage to Mecca). Additional observances involve Halal dietary laws, ethical business conduct, community service, and Sufi mysticism (meditation, dhikr remembrance of God). Practices emphasize discipline, social equity, and spiritual purification, varying between Sunni and Shia traditions.","Fundamental beliefs are Tawhid (oneness of Allah), prophethood (Muhammad as the final prophet completing revelations from Adam to Jesus), angels, holy books (Quran as ultimate scripture), Day of Judgment (accountability for deeds), and predestination (Allah's will). Sources include Quran, Sunnah (Prophet's traditions), Ijma (consensus), and Ijtihad (reasoned interpretation). Ethics stress justice, mercy, and community, with variations in Sunni (Hadith-focused) and Shia (Imam-guided) interpretations.","Common questions: Why is Islam perceived as violent? What are the Five Pillars? Who was Muhammad? Do Muslims believe in Jesus? What is the difference between Sunni and Shia? Why do Muslims fast during Ramadan? What is Jihad? Interesting facts: Islam recognizes previous prophets like Abraham and Jesus; the Quran contains scientific facts ahead of its time; Muslims believe in one God without partners; major festivals include Eid al-Fitr and Eid al-Adha; over 1.8 billion followers worldwide; emphasizes charity and community."
4
- "buddhism","Buddhism","Buddhism is a philosophy and religion founded by Siddhartha Gautama (the Buddha) in northeastern India between the 6th and 4th centuries BCE, focusing on overcoming suffering through enlightenment. With global influence in Asia and beyond, it emphasizes ethical living, meditation, and wisdom, adapting to diverse cultures while promoting compassion and mindfulness as paths to nirvana (liberation from rebirth).","Core practices include meditation (vipassana for insight, samatha for calm), mindfulness (awareness in daily life), following the Eightfold Path (right view, intention, speech, action, livelihood, effort, mindfulness, concentration), and observing precepts (ethical guidelines like non-violence). Rituals vary: Theravada focuses on monastic discipline, Mahayana on bodhisattva vows and chants, Vajrayana on tantric rituals and mantras. Lay practices involve offerings, festivals, and pilgrimage.","Key beliefs are the Four Noble Truths (suffering, its cause in desire, cessation through detachment, path to end it), Three Jewels (Buddha, Dharma teachings, Sangha community), karma (actions' consequences), samsara (cycle of rebirth), nirvana (enlightenment), and impermanence (anicca). Variations: Theravada emphasizes individual liberation, Mahayana universal salvation via bodhisattvas, Vajrayana rapid enlightenment through esoteric methods. Rejects a creator god, focusing on self-reliance.","Common questions: Who was the Buddha? Is Buddhism a religion or philosophy? Do Buddhists believe in God? What is karma and reincarnation? How does one achieve enlightenment? Why is suffering central? Interesting facts: Originated 2,500 years ago in India; about 535 million followers; no creator god; focuses on ending suffering; diverse schools like Theravada, Mahayana; mindfulness practices influence modern psychology; Buddha means 'awakened one'; no single holy book but many scriptures."
5
- "hinduism","Hinduism","Hinduism is an ancient, diverse tradition originating in the Indian subcontinent around the 2nd millennium BCE, encompassing varied philosophies, rituals, and beliefs aimed at spiritual realization. As the world's oldest living religion with nearly one billion adherents, it adapts regionally and emphasizes dharma (duty), karma (actions' effects), and moksha (liberation), influencing art, ethics, and society globally through texts and practices.","Practices include yoga (physical and meditative disciplines), meditation (for inner peace), puja (worship with offerings), festivals (Diwali, Holi), pilgrimage (to sacred sites like Varanasi), and rites of passage (samskaras like marriage). Daily routines involve mantra chanting, vegetarianism for some, and community service. Variations span devotional bhakti, philosophical jnana, and action-oriented karma paths.","Core beliefs include dharma (cosmic order and duty), karma (cause and effect across lives), samsara (rebirth cycle), moksha (liberation), and Brahman (ultimate reality). Deities represent aspects of the divine (e.g., Vishnu, Shiva, Devi), with paths like bhakti (devotion), jnana (knowledge), and yoga. Scriptures: Vedas, Upanishads, epics like Ramayana. Emphasizes pluralism, with regional variations in worship and philosophy.","Common questions: Why so many gods? Do Hindus believe in reincarnation? What is karma? Why worship cows? Is Hinduism a religion or way of life? Interesting facts: Oldest religion, over 1.1 billion followers mostly in India; no single founder; diverse schools of philosophy; Vedas are ancient scriptures; emphasizes ahimsa (non-violence); multiple paths to truth; polytheistic yet monistic; festivals like Diwali celebrate light over darkness."
6
- "judaism","Judaism","Judaism is a monotheistic religion developed among ancient Hebrews, centered on a covenant with God revealed through prophets like Abraham and Moses. With about 14 million adherents, it integrates theology, law, and culture, emphasizing ethical living and community while adapting through history, influencing Western civilization profoundly.","Practices include Shabbat observance (weekly rest and prayer), Torah study (scriptural learning), daily prayer (three times), kosher dietary laws, and life-cycle events (bar/bat mitzvah, circumcision). Holidays: Passover, Rosh Hashanah, Yom Kippur. Community involvement via synagogue services and charity (tzedakah). Variations in Orthodox (strict), Conservative (balanced), Reform (modern).","Beliefs include one transcendent God, Torah as divine law, covenant with Israel, ethical monotheism, messianic hope, resurrection, and free will. Prophets guide moral response; history reveals God's purpose. Emphasizes justice, peace, and human responsibility. Denominations differ in interpretation but share core ethical-historical monotheism.","Common questions: Why write G-d? What is the Wailing Wall? Is Judaism a religion or ethnicity? Why kosher laws? What are the branches (Orthodox, Reform)? Interesting facts: Based on Torah; one God; 613 mitzvot; emerged 4,000 years ago; Jews, Israelites, Hebrews same; no proselytizing; emphasis on deeds over beliefs; guardian angels in tradition; diverse customs like not climbing trees on Shabbat."
7
- "taoism","Taoism","Taoism (Daoism) is an indigenous Chinese tradition over 2,000 years old, emphasizing harmony with the Tao (the Way), a fundamental force underlying reality. It balances yielding, joyful attitudes with metaphysical exploration, influencing Asian cultures through philosophy, religion, and folk practices.","Practices include meditation (for inner harmony), tai chi (movement for energy flow), wu wei (effortless action), simplicity in living, and rituals like Tao worship or alchemy. Religious aspects involve priestly ceremonies; philosophical focus on contemplation. Blends with Confucianism and Buddhism in folk traditions.","Core beliefs: Tao as the natural order, yin-yang balance (complementary forces), harmony with nature, metaphysical engagement. Texts: Tao Te Ching, Zhuangzi. Variations: philosophical (mystical ideas) vs. religious (ritual worship). Rejects ego-dissolution, affirms reality's nature.","Common questions: What is the Tao? Who was Lao Tzu? Is Taoism a religion or philosophy? What is wu wei? How to apply Taoism daily? Interesting facts: Over 2,000 years old; influences Chinese medicine; yin-yang symbol; no absolutes; monasteries called Gong and Guan; ethics based on charity, thrift; Tao indefinable; self-cultivation goal."
8
- "paganism","Modern Paganism","Modern Paganism (Neopaganism) is a contemporary revival of pre-Christian, nature-based spiritualities, emerging in the 20th century amid environmental and feminist movements. It honors ancient traditions while adapting to modern contexts, emphasizing sacredness in nature and personal empowerment, with diverse, decentralized communities worldwide.","Practices include seasonal celebrations (solstices, equinoxes), rituals (circle casting, offerings), nature work (environmental activism, herbalism), divination (tarot, runes), and meditation. Group covens or solitary paths; festivals like Beltane. Eclectic, drawing from Celtic, Norse, or Wiccan traditions.","Beliefs: Nature as sacred, polytheism or pantheism (multiple deities or divine in all), cycles of life/death/rebirth, personal responsibility, magic as natural force. Rejects dogma; emphasizes harmony, diversity, and ethical living. Variations: Wicca (witchcraft-focused), Druidry (Celtic-inspired), Heathenry (Norse).","Common questions: What is Paganism? Is it witchcraft? Do Pagans worship Satan? How does it differ from ancient paganism? Interesting facts: Umbrella term for non-mainstream religions; revival, not continuous; includes Wicca, Druidry; nature-centric; no central authority; eclectic practices; influenced by 19th-20th century movements; celebrates Wheel of the Year; rejects dogma; modern invention with ancient inspirations."
9
- "humanism","Secular Humanism","Secular Humanism is a modern ethical philosophy emphasizing human reason, values, and dignity without supernatural beliefs, rooted in Renaissance humanism but distinct in its non-theistic focus. It promotes rational inquiry, science, and social justice as paths to fulfillment and societal improvement.","Practices include critical thinking (evidence-based decision-making), ethical living (compassion, justice), community service (volunteering, activism), and secular ceremonies (humanist weddings, namings). Education and dialogue foster personal growth; no rituals, but celebrations of life milestones.","Beliefs: Human dignity and potential, reason and science as guides, secular ethics (morality from empathy, not divine command), rejection of supernaturalism. Anthropocentric focus on this life; variations like pragmatic or Christian humanism, but secular emphasizes autonomy and progress.","Common questions: Is humanism a religion? What is secularism? Why focus on reason? Can humanists have morals without God? Interesting facts: Man-centered ethics; no supernatural; based on naturalism; promotes science; history from Renaissance; emphasizes human agency; not anti-religion but non-theistic; goal is self-remediation; positive worldview."
10
- "atheism","Atheism","Atheism is the absence of belief in gods or spiritual beings, emphasizing empirical evidence and rational critique of metaphysical claims. It promotes a naturalistic worldview focused on human experience and ethics, often in opposition to religious doctrines, with historical roots in philosophy and science.","Practices involve evidence-based thinking (scientific inquiry, skepticism), secular community (atheist groups, discussions), and ethical activism (human rights, separation of church/state). No rituals; focus on rational discourse, education, and living meaningfully without faith.","Beliefs: No gods exist (or low probability), natural explanations for phenomena, focus on this life. Rejects spiritual beings; variations: fallibilistic (open to evidence), incoherence-based (God concepts illogical). Emphasizes burden of proof on theists, empirical reliability.","Common questions: Why no God? Where does morality come from? Do atheists have faith? What about afterlife? Why be moral? Interesting facts: Not a religion, lack of belief; mostly men and young in U.S.; 98% say religion unimportant; doubled in popularity; face discrimination; symbol is atomic whirl; no founder; can pray (meditate); smarter on average per some studies."
11
- "agnosticism","Agnosticism","Agnosticism holds that the existence of gods or ultimate realities is unknowable, prioritizing evidence and reason while suspending judgment on metaphysical claims. Coined by T.H. Huxley in 1869, it fosters intellectual humility amid scientific and philosophical debates.","Practices include rigorous inquiry (following evidence, Clifford's ethics against insufficient belief), critical reflection (questioning claims), and openness to data. No formal rituals; involves ethical living based on reason, potentially contemplative for personal growth.","Beliefs: Unknowability of gods/transcendent realities, method over creed (pursue reason, recognize limits). Variations: secular (nonreligious skepticism), religious (minimal doctrine with evidence), philosophical (Hume/Kant unknowables). Distinguishes from atheism by not denying, but suspending belief.","Common questions: How differs from atheism? Can agnostics be religious? Is it a middle ground? What after death? Interesting facts: Absence of knowledge about gods; coined 1869; honest approach to big questions; can overlap with atheism; views existence as unknowable; promotes humility; no certain evidence for gods; kids' view: 'not sure' about big questions."
12
- "new_age","New Age Spirituality","New Age Spirituality is an eclectic movement from the 1970s-80s, blending esotericism, theosophy, and mysticism to anticipate an era of peace through personal transformation. Rooted in 19th-century theosophy, it promotes holistic growth and global awakening, influencing wellness and alternative therapies.","Practices include meditation (energy work, channeling), energy healing (crystals, reiki), yoga, astrology, and rituals (affirmations, vision boards). Eclectic: tarot, shamanism, nature communion. Focus on self-transformation and sharing divine energy.","Beliefs: Imminent New Age of enlightenment (Aquarian shift), personal spiritual transformation (sadhana path), interconnectedness, reincarnation, Ascended Masters. Variations: theosophical (Maitreya focus), psychedelic-influenced. Emphasizes active manifestation over passive waiting.","Common questions: What is channeling? Why use crystals? Is yoga New Age? Do they believe in reincarnation? What is the Aquarian Age? Interesting facts: Umbrella for contemporary movement; not organized religion; planetary transformation; integrates astrology, tarot; spiritual healing; influenced by Western esotericism; emblematic universities like Naropa; focuses on human potential."
13
- "spiritual_not_religious","Spiritual But Not Religious","Spiritual But Not Religious (SBNR) is a stance prioritizing personal spirituality over organized religion, focusing on individual well-being and exploration. Emerging in the 1960s-2000s amid deinstitutionalization, it appeals to unaffiliated seekers valuing autonomy and eclecticism.","Practices include meditation (mindfulness, TM), nature connection, eclectic rituals (Tarot, I Ching), and self-reflection. Therapeutic: yoga, journaling for emotional support. Avoids communal worship; experimental and as-needed.","Beliefs: Spirituality as private empowerment, anti-dogmatic (religion as rigid), focus on mind-body-spirit harmony. Variations: dissenters (reject religion), explorers (wanderlust), seekers (looking for home). Emphasizes curiosity, intellectual freedom, personal path.","Common questions: What does SBNR mean? Do they believe in God? Why reject religion? What practices? Interesting facts: Connected to true self; most Americans spiritual; addresses evil/misery; values ethical values; personal divine experience; anti-dogma; hunger for ritual without structure; integrates with other beliefs."
14
- "sikhism","Sikhism","Sikhism is a monotheistic faith founded by Guru Nanak in 15th-century Punjab, emphasizing equality, service, and devotion. With 25 million adherents, it follows 10 Gurus' teachings, now in the Guru Granth Sahib, promoting ethical living and community amid historical independence from Hinduism.","Practices include daily prayer/meditation (Nitnem), community service (seva), langar (free meals), wearing 5 Ks (kesh, kangha, kara, kachera, kirpan), and gurdwara attendance. Festivals: Vaisakhi, Diwali. Focus on honest living and sharing.","Beliefs: One formless God, equality of all, Gurmat (Guru's way), liberation via devotion, rejection of caste/rituals. Scriptures: Guru Granth Sahib. Influences: Sant (nirgun devotion), Nath (meditation ascent). Emphasizes ethical monotheism, service.","Common questions: What do Sikhs teach about other religions? Who are the Gurus? Why wear turbans/5 Ks? What is langar? Interesting facts: Founded 1469 by Guru Nanak; 27 million followers; originated in Punjab; equality of men/women; no caste; daily prayer; emblem Khanda; greets with Sat Sri Akal; emphasizes humanity and charity."
15
- "indigenous","Indigenous Spirituality","Indigenous Spirituality encompasses diverse traditional beliefs of native peoples worldwide, deeply connected to land, ancestors, and nature. Rooted in ancient oral histories, it emphasizes holistic well-being, resilience, and reciprocity, varying by community but sharing themes of interconnectedness and cultural identity.","Practices include ceremonies (sweat lodges, vision quests), storytelling, seasonal rituals (harvest dances), and healing (herbal medicine, shamanic journeys). Community-focused: elder guidance, sacred sites pilgrimage. Emphasizes respect for nature and ancestors.","Beliefs: Interconnectedness of all (humans, animals, spirits), land as sacred, ancestor veneration, balance/harmony. Variations: Native American (Great Spirit, totemism), Aboriginal (Dreamtime, kinship). Holistic: mind-body-spirit integration; resilience through cultural practices.","Common questions: What is Indigenous spirituality? Do they have a Great Spirit? How linked to land? Myths about 'having it easy'? Interesting facts: Diverse, no single belief; spirituality in daily life; no division spiritual/secular; kinship with nature; ceremonies vary by tribe; addresses appropriation; hunger for rituals; combined with other faiths sometimes."
16
-
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ id,religion,category,topic,content,keywords,question_relevance
2
+ 1,christianity,core_belief,nature_of_divine,"Christianity is a monotheistic religion centered on belief in one God who exists as three persons: Father, Son (Jesus Christ), and Holy Spirit. Christians believe God is loving, just, and personal, actively involved in human affairs.","monotheism,trinity,personal god,jesus christ",q1_q4
3
+ 2,christianity,practice,spiritual_connection,"Christians connect with God through personal prayer, communal worship, reading the Bible, and participating in sacraments like communion and baptism. Church community is central to faith practice.","prayer,worship,bible,communion,church",q2_q5
4
+ 3,christianity,belief,afterlife,Christianity teaches that faith in Jesus Christ leads to eternal life in Heaven with God. Those who reject Christ face separation from God (Hell). Salvation is through grace and faith.,"heaven,hell,salvation,eternal life,grace",q3
5
+ 4,christianity,ethics,moral_guidance,"Christian ethics are based on Biblical teachings, especially Jesus' commands to love God and love others. The Ten Commandments and Jesus' Sermon on the Mount provide moral framework.","bible,ten commandments,love,scripture,jesus teaching",q4
6
+ 5,christianity,practice,nature_relationship,"Christians view humans as stewards of God's creation, called to care for the Earth responsibly. Nature reveals God's glory but is distinct from God.","stewardship,creation care,dominion",q6
7
+ 6,christianity,belief,suffering,"Suffering is often seen as a test of faith, opportunity for spiritual growth, or part of God's mysterious plan. Jesus' suffering on the cross gives meaning to human suffering.","test of faith,cross,redemptive suffering,gods plan",q7
8
+ 7,islam,core_belief,nature_of_divine,"Islam is strictly monotheistic, believing in one God (Allah) who is merciful, compassionate, and transcendent. Allah is the creator and sustainer of all existence, revealed through Prophet Muhammad.","monotheism,allah,tawhid,prophet muhammad",q1_q4
9
+ 8,islam,practice,spiritual_connection,"Muslims connect with Allah through five daily prayers (salat), reciting Quran, and following the Five Pillars. Prayer involves physical prostration showing submission to Allah.","five pillars,salat,prayer,quran,submission",q2_q5
10
+ 9,islam,belief,afterlife,Muslims believe in Day of Judgment where all are resurrected and judged by Allah. Paradise (Jannah) awaits the righteous; Hell (Jahannam) for those who reject faith and do evil.,"judgment day,jannah,paradise,hell,resurrection",q3
11
+ 10,islam,ethics,moral_guidance,"Islamic ethics come from Quran and Hadith (Prophet's teachings). Core values include justice, compassion, honesty, modesty, and following Shariah (Islamic law).","quran,hadith,shariah,justice,compassion",q4
12
+ 11,islam,practice,nature_relationship,"Muslims see humans as Allah's khalifah (stewards) on Earth, responsible for protecting and using resources justly. Nature is a sign of Allah's power and mercy.","khalifah,stewardship,creation,signs of allah",q6
13
+ 12,islam,belief,suffering,Suffering is a test from Allah to strengthen faith and purify the soul. Patience (sabr) during hardship is highly valued and rewarded by Allah.,"test,sabr,patience,purification,trial",q7
14
+ 13,buddhism,core_belief,nature_of_divine,"Buddhism generally doesn't focus on a creator god. Instead, it teaches about the nature of reality, suffering, and the path to enlightenment (Nirvana). Some schools venerate Buddha and bodhisattvas.","non-theistic,enlightenment,nirvana,buddha,no creator",q1
15
+ 14,buddhism,practice,spiritual_connection,"Buddhists practice meditation (especially mindfulness and concentration), follow the Eightfold Path, and cultivate wisdom and compassion. Personal practice is emphasized over communal worship.","meditation,mindfulness,eightfold path,personal practice",q2_q5
16
+ 15,buddhism,belief,afterlife,Buddhism teaches rebirth (samsara) driven by karma. The goal is to achieve Nirvana - liberation from the cycle of rebirth and suffering. Rebirth isn't eternal soul but continuation of consciousness.,"rebirth,samsara,karma,nirvana,liberation",q3
17
+ 16,buddhism,ethics,moral_guidance,"Buddhist ethics center on the Four Noble Truths and Eightfold Path. Core principles include non-harm (ahimsa), compassion (karuna), and mindful awareness. Actions create karma.","four noble truths,ahimsa,compassion,karma,mindfulness",q4
18
+ 17,buddhism,belief,interconnection,Buddhism teaches dependent origination - all phenomena are interconnected. Harming nature harms oneself. All sentient beings deserve compassion and should be treated with respect.,"interconnection,dependent origination,sentient beings,compassion",q6
19
+ 18,buddhism,belief,suffering,"Suffering (dukkha) is caused by attachment, craving, and ignorance of reality's true nature. The path to end suffering is through understanding, letting go of attachment, and following the Eightfold Path.","dukkha,attachment,craving,four noble truths,cessation",q7
20
+ 19,hinduism,core_belief,nature_of_divine,"Hinduism embraces diverse views: one supreme reality (Brahman) manifesting as many deities, or devotion to personal gods like Vishnu, Shiva, or Devi. Ultimate reality is beyond form.","brahman,polytheism,monotheism,vishnu,shiva,multiple paths",q1
21
+ 20,hinduism,practice,spiritual_connection,"Hindus practice yoga, meditation, puja (worship), temple visits, and festivals. Multiple paths exist: devotion (bhakti), knowledge (jnana), action (karma yoga), meditation (raja yoga).","yoga,meditation,puja,bhakti,multiple paths",q2_q5
22
+ 21,hinduism,belief,afterlife,"Hindus believe in reincarnation (samsara) based on karma. The soul (atman) is reborn until achieving moksha (liberation) - union with Brahman, ending the cycle of rebirth.","reincarnation,karma,moksha,atman,samsara,liberation",q3
23
+ 22,hinduism,ethics,moral_guidance,"Hindu ethics center on dharma (righteous duty), which varies by role, age, and circumstance. Universal principles include non-violence (ahimsa), truthfulness, and compassion.","dharma,ahimsa,karma,righteous duty",q4
24
+ 23,hinduism,belief,interconnection,"Hinduism teaches all life contains the divine essence (atman/Brahman). Ahimsa (non-violence) extends to all creatures. Many Hindus are vegetarian, viewing cows and other animals as sacred.","atman,brahman,sacred,ahimsa,interconnected",q6
25
+ 24,hinduism,belief,suffering,Suffering results from karma - consequences of past actions in this or previous lives. It's an opportunity to work through karmic debt and progress spiritually toward moksha.,"karma,past lives,spiritual progress,moksha",q7
26
+ 25,judaism,core_belief,nature_of_divine,"Judaism is strictly monotheistic, believing in one God (YHWH/Adonai) who is eternal, creator, and enters into covenant with the Jewish people. God is both transcendent and involved in history.","monotheism,yhwh,covenant,ethical monotheism",q1_q4
27
+ 26,judaism,practice,spiritual_connection,"Jews connect with God through prayer (especially Shabbat and holidays), Torah study, following mitzvot (commandments), and community participation in synagogue.","prayer,torah,mitzvot,shabbat,synagogue",q2_q5
28
+ 27,judaism,belief,afterlife,"Jewish views on afterlife vary. Traditional belief includes resurrection of the dead in messianic age. Some emphasize this-world focus, others believe in Olam Ha-Ba (World to Come).","resurrection,messianic age,olam haba,varied views",q3
29
+ 28,judaism,ethics,moral_guidance,"Jewish ethics come from Torah and Talmud, emphasizing justice (tzedakah), ethical behavior, study, and repair of the world (tikkun olam). The 613 mitzvot guide daily life.","torah,talmud,tzedakah,tikkun olam,justice",q4
30
+ 29,judaism,practice,nature_relationship,Jews are stewards (bal tashchit - don't destroy) of God's creation. Environmental care is a religious duty. Laws like kosher and sabbatical years reflect respect for creation.,"stewardship,bal tashchit,creation care",q6
31
+ 30,judaism,belief,suffering,"Suffering raises theological questions addressed differently across Jewish thought. Some see it as test, punishment, mystery, or call to action for justice. Holocaust deeply shaped modern Jewish theology.","test,mystery,justice,theological question",q7
32
+ 31,taoism,core_belief,nature_of_divine,"Taoism centers on the Tao - the ineffable, eternal source and pattern of all existence. It's not a personal god but the natural way of the universe, beyond words or concepts.","tao,natural way,non-theistic,universal force",q1
33
+ 32,taoism,practice,spiritual_connection,"Taoists practice meditation, tai chi, qigong, and wu wei (effortless action). The focus is aligning with natural rhythms and simplicity rather than forceful striving.","meditation,tai chi,wu wei,simplicity,natural flow",q2_q5
34
+ 33,taoism,belief,afterlife,Traditional Taoism includes beliefs in immortality through spiritual cultivation and alchemy. Philosophical Taoism focuses more on living well in harmony with Tao than afterlife concerns.,"immortality,spiritual cultivation,harmony,this-life focus",q3
35
+ 34,taoism,ethics,moral_guidance,"Taoist ethics emphasize naturalness, spontaneity, simplicity, and compassion. Rather than rigid rules, guidance comes from understanding natural balance (yin-yang) and wu wei.","naturalness,wu wei,yin-yang,balance,spontaneity",q4
36
+ 35,taoism,belief,interconnection,"Taoism sees humans as integral part of nature, not separate or superior. Living in harmony with natural cycles and respecting all life reflects the Tao. Nature is the primary teacher.","harmony with nature,natural cycles,interconnection,nature teacher",q6
37
+ 36,taoism,belief,suffering,"Suffering arises from resistance to natural flow and clinging to desires. By accepting change, practicing wu wei, and aligning with Tao, one reduces suffering and finds peace.","resistance,acceptance,wu wei,natural flow",q7
38
+ 37,paganism,core_belief,nature_of_divine,Modern Paganism typically honors multiple deities (polytheism) or sees divinity in nature itself (pantheism). Gods/goddesses often represent natural forces and archetypal energies.,"polytheism,pantheism,nature deities,goddess,god",q1
39
+ 38,paganism,practice,spiritual_connection,"Pagans celebrate seasonal festivals (solstices, equinoxes), perform rituals, work with natural elements, and often practice magic. Connection with nature is central to practice.","sabbats,rituals,nature connection,magic,seasonal celebrations",q2_q5
40
+ 39,paganism,belief,afterlife,"Pagan views vary widely: some believe in reincarnation, others in ancestral realms or otherworlds, some in merging with nature. Many focus on honoring this life fully.","reincarnation,otherworld,ancestral realm,varied views",q3
41
+ 40,paganism,ethics,moral_guidance,"Pagan ethics often center on personal responsibility and the Wiccan Rede ('harm none'). Values include balance, reciprocity with nature, and authentic personal experience.","harm none,reciprocity,personal responsibility,balance",q4
42
+ 41,paganism,belief,interconnection,"Pagans view nature as sacred and divine. All life is interconnected. Humans are part of nature's web, not separate or superior. Environmental stewardship is spiritual duty.","nature sacred,divine nature,interconnected,sacred earth",q6
43
+ 42,paganism,belief,suffering,Suffering is part of natural cycles of death and rebirth. It can be transformative and teach important lessons. Balance between light and dark is natural and necessary.,"cycles,transformation,balance,death and rebirth",q7
44
+ 43,humanism,core_belief,nature_of_divine,"Humanism is non-religious, rejecting supernatural beliefs. Focus is on human potential, reason, ethics, and science without gods or divine intervention.","atheistic,secular,non-religious,reason,human potential",q1
45
+ 44,humanism,practice,spiritual_connection,"Humanists connect through reason, critical thinking, community service, art, philosophy, and building meaningful relationships. Fulfillment comes from human connection and contribution.","reason,community,philosophy,critical thinking,service",q2_q5
46
+ 45,humanism,belief,afterlife,"Humanists generally don't believe in afterlife. This life is all there is, making it precious. Legacy lives through impact on others and contributions to human progress.","no afterlife,this life only,legacy,naturalistic",q3
47
+ 46,humanism,ethics,moral_guidance,"Humanist ethics are based on reason, empathy, human rights, and wellbeing. Morality comes from human needs and social context, not divine command. Science informs ethical decisions.","reason,empathy,human rights,secular ethics,evidence-based",q4
48
+ 47,humanism,belief,interconnection,"Humanists view humans as part of natural world, subject to natural laws. Environmental protection is important for human wellbeing and future generations, based on scientific understanding.","naturalism,science,environmentalism,evolution",q6
49
+ 48,humanism,belief,suffering,"Suffering has natural causes, not divine purpose. Humans can reduce suffering through science, medicine, social progress, and compassionate action. Focus on solving problems, not accepting fate.","natural causes,problem-solving,progress,compassion",q7
50
+ 49,atheism,core_belief,nature_of_divine,"Atheism is lack of belief in gods or deities. Atheists rely on naturalistic explanations, viewing universe as product of natural processes without supernatural intervention.","no god,naturalistic,non-theistic,skepticism",q1
51
+ 50,atheism,practice,spiritual_connection,"Atheists typically don't seek spiritual connection in traditional sense. Meaning comes from relationships, experiences, learning, creativity, and contributing to society. Some find awe in nature/science.","secular,community,science,meaning-making,non-spiritual",q2_q5
52
+ 51,atheism,belief,afterlife,Atheists don't believe in afterlife. Consciousness ends at death. This makes life precious and motivates living fully and ethically now.,"no afterlife,materialism,this life only,consciousness ends",q3
53
+ 52,atheism,ethics,moral_guidance,"Atheist morality is based on empathy, reason, wellbeing, and social cooperation. Ethics evolved to help humans live together successfully, not from divine command.","secular ethics,empathy,reason,evolution,wellbeing",q4
54
+ 53,atheism,belief,interconnection,"Atheists understand humans as evolved animals, part of natural world. Environmental concern comes from understanding ecology and protecting our only home, based on scientific evidence.","naturalism,evolution,science,ecology,evidence-based",q6
55
+ 54,atheism,belief,suffering,"Suffering has natural causes - disease, accidents, natural disasters, human actions. No divine purpose or test. We reduce suffering through medicine, technology, social justice, and compassion.","natural causes,randomness,problem-solving,no divine plan",q7
56
+ 55,agnosticism,core_belief,nature_of_divine,Agnostics hold that existence/nature of divine is unknown or unknowable. Some lack belief but remain open; others actively believe we cannot know. Focus on uncertainty rather than conviction.,"unknowable,uncertainty,open-minded,skeptical inquiry",q1
57
+ 56,agnosticism,practice,spiritual_connection,"Agnostics may explore various practices or none at all. Often value philosophical inquiry, ethical living, and intellectual honesty over religious ritual. Open to diverse perspectives.","inquiry,philosophical,eclectic,ethical living,exploration",q2_q5
58
+ 57,agnosticism,belief,afterlife,"Agnostics are uncertain about afterlife. Some lean toward no afterlife, others remain completely open. Emphasis on living well now given the uncertainty about what follows.","uncertain,unknown,open possibilities,this-life focus",q3
59
+ 58,agnosticism,ethics,moral_guidance,"Agnostic ethics often based on reason, empathy, and human wellbeing without certainty about divine command. Questions and inquiry are valued over absolute answers.","reason,empathy,inquiry,questioning,open ethics",q4
60
+ 59,agnosticism,belief,interconnection,Agnostics may appreciate scientific understanding of interconnection or remain open to spiritual interpretations. Often value environmental care based on practical concerns.,"scientific understanding,open interpretation,practical ethics",q6
61
+ 60,agnosticism,belief,suffering,Agnostics are uncertain whether suffering has purpose or is random. May see it as natural phenomenon while remaining open to other interpretations. Focus on responding compassionately.,"uncertainty,natural and/or meaningful,compassionate response",q7
62
+ 61,new_age,core_belief,nature_of_divine,"New Age spirituality sees divine as universal consciousness or energy pervading all existence. Often blends ideas from Eastern religions, Western esotericism, and modern psychology.","universal consciousness,divine energy,holistic,eclectic",q1
63
+ 62,new_age,practice,spiritual_connection,"New Age practitioners use meditation, energy healing, crystals, yoga, tarot, astrology, and visualization. Emphasis on personal experience and whatever resonates individually.","meditation,crystals,energy work,personal practice,eclectic",q2_q5
64
+ 63,new_age,belief,afterlife,"New Age views often include reincarnation, spiritual evolution across lifetimes, and eventual unity with higher consciousness. Some believe in creating own reality even after death.","reincarnation,spiritual evolution,higher consciousness,varied beliefs",q3
65
+ 64,new_age,ethics,moral_guidance,"New Age ethics emphasize personal growth, positive thinking, manifesting desires, and universal love. 'What you put out returns to you' (Law of Attraction). Follow inner guidance.","law of attraction,personal growth,inner guidance,positive energy",q4
66
+ 65,new_age,belief,interconnection,"New Age teaches all is one - humans, nature, cosmos connected through universal energy. Harming environment harms collective consciousness. Earth (Gaia) may be seen as living being.","oneness,universal energy,gaia,interconnected consciousness",q6
67
+ 66,new_age,belief,suffering,Suffering provides growth opportunities and spiritual lessons. Often seen as self-created for soul evolution. Positive thinking and raising vibration can transform suffering.,"growth opportunity,spiritual lesson,soul evolution,transformation",q7
68
+ 67,spiritual_not_religious,core_belief,nature_of_divine,"SBNR individuals have personal spiritual beliefs outside organized religion. Views vary widely - some believe in higher power, universal energy, or remain undefined. Value personal experience over doctrine.","personal spirituality,no organized religion,individual path,authentic",q1
69
+ 68,spiritual_not_religious,practice,spiritual_connection,"SBNR people create personal practices - may include meditation, nature connection, journaling, yoga, or borrowing from various traditions. Emphasis on what feels authentic and meaningful.","personal practice,eclectic,authentic,self-directed,meaningful",q2_q5
70
+ 69,spiritual_not_religious,belief,afterlife,"SBNR views on afterlife vary widely. Some believe in reincarnation, others in energy continuation, some remain open and uncertain. Focus on present spiritual experience over afterlife doctrine.","varied beliefs,open-minded,present-focused,personal interpretation",q3
71
+ 70,spiritual_not_religious,ethics,moral_guidance,"SBNR ethics based on personal intuition, inner wisdom, and values like compassion and authenticity. Draw from various sources - philosophy, psychology, wisdom traditions - without dogma.","intuition,inner wisdom,authenticity,compassion,non-dogmatic",q4
72
+ 71,spiritual_not_religious,belief,interconnection,SBNR individuals often feel deep connection to nature and all life. May see nature as sacred teacher without formal religious framework. Environmental care is spiritual practice.,"nature connection,sacred nature,interconnection,personal meaning",q6
73
+ 72,spiritual_not_religious,belief,suffering,SBNR views on suffering are personal and varied. Many see it as growth opportunity or natural part of life's journey. Focus on finding personal meaning rather than accepting religious explanation.,"personal meaning,growth,varied interpretation,authentic response",q7
74
+ 73,sikhism,core_belief,nature_of_divine,"Sikhism is monotheistic, believing in one formless God (Waheguru) who is creator, sustainer, and destroyer. God is timeless, without gender, and accessible to all through devotion and service.","monotheism,waheguru,one god,formless,universal access",q1_q4
75
+ 74,sikhism,practice,spiritual_connection,"Sikhs connect with God through meditation on God's name (Naam Japna), selfless service (Seva), honest living (Kirat Karni), and sharing (Vand Chakna). Community worship at Gurdwara is important.","naam japna,seva,kirat karni,gurdwara,community",q2_q5_q8
76
+ 75,sikhism,belief,afterlife,Sikhs believe in reincarnation based on karma until union with God is achieved. The goal is to escape reincarnation cycle and merge with divine light through righteous living.,"reincarnation,karma,union with god,liberation,mukti",q3
77
+ 76,sikhism,ethics,moral_guidance,"Sikh ethics emphasize equality, justice, service, honest work, and devotion. The five virtues are truth, contentment, compassion, humility, and love. Fight against injustice is duty.","equality,justice,five virtues,honest living,service",q4
78
+ 77,sikhism,belief,interconnection,"Sikhs see all creation as manifestation of one God. All humans are equal regardless of caste, gender, or religion. Environmental care is duty as God's creation must be respected.","equality,gods creation,stewardship,respect for all",q6
79
+ 78,sikhism,belief,suffering,"Suffering is result of separation from God and ego (Haumai). It's also karma from past lives. Through devotion, service, and God's grace, one can transcend suffering.","karma,separation from god,ego,grace,transcendence",q7
80
+ 79,indigenous,core_belief,nature_of_divine,"Indigenous spiritualities vary greatly but often include Great Spirit, creator beings, and/or spirits in all things (animism). Divine is immanent in nature, ancestors, and the land itself.","great spirit,animism,spirits,ancestors,varied traditions",q1
81
+ 80,indigenous,practice,spiritual_connection,"Indigenous practices include ceremonies, storytelling, seasonal rituals, vision quests, and maintaining relationship with land and ancestors. Community and tradition are central.","ceremonies,storytelling,seasonal rituals,land connection,ancestral",q2_q5
82
+ 81,indigenous,belief,afterlife,"Indigenous beliefs often include journey to spirit world or ancestral realm after death. Ancestors remain present and active. Death is transformation, not end. Varies by tradition.","spirit world,ancestors,transformation,varied beliefs,continuity",q3
83
+ 82,indigenous,ethics,moral_guidance,"Indigenous ethics center on reciprocity with nature and community, respect for elders and ancestors, seven generations thinking, and living in balance. Wisdom comes from tradition and land.","reciprocity,respect,balance,traditional wisdom,seven generations",q4
84
+ 83,indigenous,belief,interconnection,"Indigenous worldviews see all beings as relatives - plants, animals, rocks, rivers all have spirit. Humans are part of nature's web with responsibilities. Land is sacred, not property.","all my relations,sacred land,interconnection,reciprocity,kinship",q6
85
+ 84,indigenous,belief,suffering,"Suffering may be seen as imbalance, result of not honoring relationships, or spiritual lesson. Healing comes through ceremony, community support, and restoring harmony.","imbalance,ceremony,healing,restoration,community",q7
86
+ 85,jainism,core_belief,nature_of_divine,"Jainism is non-theistic, focusing on individual spiritual liberation rather than god-worship. The universe is eternal, uncreated. Tirthankaras (enlightened teachers) show the path but aren't gods.","non-theistic,tirthankaras,eternal universe,self-liberation",q1
87
+ 86,jainism,practice,spiritual_connection,"Jains practice strict non-violence (ahimsa), meditation, fasting, self-discipline, and study. Monks/nuns follow intense ascetic practices. Lay people support monastics and follow modified vows.","ahimsa,meditation,fasting,asceticism,non-violence",q2_q5
88
+ 87,jainism,belief,afterlife,"Jains believe in reincarnation based on karma. Liberation (moksha) comes through eliminating all karma through right conduct, non-violence, and asceticism, freeing soul from rebirth cycle.","reincarnation,karma,moksha,liberation,soul purification",q3
89
+ 88,jainism,ethics,moral_guidance,"Jain ethics center on ahimsa (non-violence) to all living beings. Five main vows: non-violence, truth, non-stealing, celibacy/chastity, non-attachment. Compassion extends to smallest creatures.","ahimsa,non-violence,five vows,compassion,universal",q4
90
+ 89,jainism,belief,interconnection,"Jainism teaches all beings have souls (jiva) and deserve absolute respect. Even plants, water, and air contain souls. Strict vegetarianism and extreme care not to harm any life.","jiva,all beings sacred,extreme non-violence,vegetarianism,reverence for life",q6
91
+ 90,jainism,belief,suffering,"Suffering results from karma accumulated through violence and attachment. Liberation comes through eliminating karma via strict non-violence, asceticism, and detachment from worldly concerns.","karma,non-violence,asceticism,detachment,purification",q7
92
+ 91,shintoism,core_belief,nature_of_divine,"Shinto honors kami - spirits in nature, ancestors, and sacred places. Kami are not all-powerful gods but spiritual essences deserving respect. No single creator deity or canonical texts.","kami,nature spirits,ancestors,polytheistic,japanese tradition",q1
93
+ 92,shintoism,practice,spiritual_connection,"Shinto practices include shrine visits, purification rituals (misogi), festivals (matsuri), offerings to kami, and maintaining harmony with nature. Ritual purity is important.","shrines,purification,matsuri,offerings,rituals",q2_q5
94
+ 93,shintoism,belief,afterlife,"Shinto has no clear afterlife doctrine. Ancestors become kami and are venerated. Focus is on this life, purity, and harmony rather than afterlife rewards/punishments.","ancestors become kami,this-life focus,veneration,unclear afterlife",q3
95
+ 94,shintoism,ethics,moral_guidance,"Shinto ethics emphasize purity, harmony with nature and community, gratitude, and living naturally. Morality comes from innate goodness and maintaining balance, not divine commandments.","purity,harmony,gratitude,natural living,balance",q4
96
+ 95,shintoism,belief,interconnection,"Shinto sees nature as sacred - mountains, rivers, trees, rocks can all house kami. Humans are part of nature, not separate. Living in harmony with natural world is spiritual imperative.","nature sacred,kami in nature,harmony,sacred places,reverence",q6
97
+ 96,shintoism,belief,suffering,Shinto doesn't have elaborate suffering theology. Misfortune may come from spiritual impurity or disharmony. Purification rituals and harmonious living restore balance and wellbeing.,"purification,impurity,balance,harmony,restoration",q7
98
+ 97,stoicism,core_belief,nature_of_divine,"Stoicism is philosophical tradition, not religion. Some ancient Stoics believed in divine reason (logos) pervading cosmos; modern Stoics may be theistic, atheistic, or agnostic. Focus is on virtue.","philosophy,logos,reason,virtue,varied divine views",q1
99
+ 98,stoicism,practice,spiritual_connection,"Stoics practice contemplation, journaling, virtue cultivation, and accepting what can't be controlled. Philosophical study and rational reflection replace religious ritual.","contemplation,journaling,virtue practice,rational reflection,philosophy",q2_q5
100
+ 99,stoicism,belief,afterlife,Ancient Stoics had varied views; many modern Stoics don't focus on afterlife. Emphasis is on living virtuously now. Some believed in soul's continuation; others focused solely on this life.,"varied views,this-life focus,virtue,unclear afterlife",q3
101
+ 100,stoicism,ethics,moral_guidance,"Stoic ethics center on four cardinal virtues: wisdom, justice, courage, temperance. Live according to reason and nature. Focus on what you can control; accept what you cannot.","four virtues,reason,acceptance,control,wisdom",q4
102
+ 101,stoicism,belief,interconnection,"Stoics see humans as part of rational, ordered cosmos. We're social beings with duties to others. Living according to nature means recognizing our place in larger whole.","cosmic order,social duty,rational nature,interconnection",q6
103
+ 102,stoicism,belief,suffering,"Suffering comes from mistaken judgments and desire for control over externals. By accepting fate (amor fati), focusing on virtue, and distinguishing what we control, we achieve tranquility.","acceptance,amor fati,control,judgment,tranquility",q7
104
+ 103,confucianism,core_belief,nature_of_divine,"Confucianism is philosophical/ethical system more than religion. Focus is on human relationships and moral cultivation, not supernatural. Some reverence for Heaven (Tian) as moral force.","philosophy,ethics,tian,human relationships,moral cultivation",q1
105
+ 104,confucianism,practice,spiritual_connection,"Confucian practice emphasizes ritual propriety (li), ancestor veneration, study of classics, self-cultivation, and fulfilling social roles properly. Education and moral development are central.","ritual propriety,ancestor veneration,study,self-cultivation,li",q2_q5
106
+ 105,confucianism,belief,afterlife,"Confucianism focuses on this life and proper conduct, not afterlife speculation. Ancestors are honored and remembered, continuing influence through descendants.","this-life focus,ancestor honor,unclear afterlife,legacy",q3
107
+ 106,confucianism,ethics,moral_guidance,"Confucian ethics emphasize five relationships, filial piety, benevolence (ren), righteousness (yi), and proper ritual conduct. Moral cultivation through education and self-reflection.","five relationships,filial piety,ren,yi,moral cultivation",q4
108
+ 107,confucianism,belief,interconnection,Confucianism sees humans as inherently social beings in web of relationships. Harmony in family and society reflects cosmic order. Proper human conduct maintains balance.,"social harmony,relationships,cosmic order,balance,interconnection",q6
109
+ 108,confucianism,belief,suffering,"Suffering often results from social disorder, improper relationships, or lack of virtue. Remedy through moral cultivation, proper conduct, education, and restoring harmonious relationships.","moral cultivation,harmony,proper conduct,social order",q7
static/style.css CHANGED
@@ -411,7 +411,7 @@ button:disabled {
411
  /* ===== RESULTS ===== */
412
  .results-explanation {
413
  max-width: 400px; /* Adjust this value as needed */
414
- margin: 0 auto var(--space-lg);
415
  text-align: center;
416
  color: var(--text-secondary);
417
  font-size: var(--font-size-sm);
 
411
  /* ===== RESULTS ===== */
412
  .results-explanation {
413
  max-width: 400px; /* Adjust this value as needed */
414
+ margin: 0 auto var(--space-sm);
415
  text-align: center;
416
  color: var(--text-secondary);
417
  font-size: var(--font-size-sm);
templates/index.html CHANGED
@@ -169,7 +169,7 @@
169
  Based on your responses, here are the spiritual paths that align most closely with your values and beliefs:
170
  </p>
171
  <div class="results-explanation">
172
- * Percentages reflect alignment strength based on your answers (max 24 points(=100%) per path).
173
  </div>
174
 
175
  <div id="resultsContainer" class="results-spacing">
 
169
  Based on your responses, here are the spiritual paths that align most closely with your values and beliefs:
170
  </p>
171
  <div class="results-explanation">
172
+ * Percentages reflect how strongly your answers align with each path, using weighted scoring where more fundamental beliefs count more.
173
  </div>
174
 
175
  <div id="resultsContainer" class="results-spacing">
templates/landing.html CHANGED
@@ -34,7 +34,7 @@
34
  </h1>
35
  <p class="hero-subtitle">
36
  Discover the spiritual or religious path that resonates with your unique beliefs, values, and lifestyle.
37
- Answer 8 thoughtful questions to gain deep insights into your worldview.
38
  </p>
39
 
40
  <div class="cta-buttons">
 
34
  </h1>
35
  <p class="hero-subtitle">
36
  Discover the spiritual or religious path that resonates with your unique beliefs, values, and lifestyle.
37
+ Answer 9 thoughtful questions to gain deep insights into your worldview.
38
  </p>
39
 
40
  <div class="cta-buttons">