vikramvasudevan commited on
Commit
921acf8
·
verified ·
1 Parent(s): a338ef5

Upload folder using huggingface_hub

Browse files
modules/config/vishnu_sahasranamam.py CHANGED
@@ -117,4 +117,9 @@ vishnu_sahasranamam_config = {
117
  ],
118
  "video": [],
119
  },
 
 
 
 
 
120
  }
 
117
  ],
118
  "video": [],
119
  },
120
+ "audio_modes" : {
121
+ "recitation": "Recitation",
122
+ "recitation namavali": "Recitation Namavali",
123
+ "santhai": "Santhai",
124
+ }
125
  }
server.py CHANGED
@@ -245,8 +245,7 @@ async def get_scripture_configs():
245
  f_copy["lov"] = []
246
  metadata_fields.append(f_copy)
247
 
248
- scriptures.append(
249
- {
250
  "name": s["name"], # e.g. "bhagavad_gita"
251
  "title": s["title"], # e.g. "Bhagavad Gita"
252
  "banner_url": s.get("banner_url", None),
@@ -262,7 +261,12 @@ async def get_scripture_configs():
262
  "metadata_fields": metadata_fields,
263
  "field_mapping": config.remove_callables(s.get("field_mapping", {})),
264
  }
265
- )
 
 
 
 
 
266
 
267
  return {"scriptures": sorted(scriptures, key=lambda s: s["title"])}
268
 
 
245
  f_copy["lov"] = []
246
  metadata_fields.append(f_copy)
247
 
248
+ entry = {
 
249
  "name": s["name"], # e.g. "bhagavad_gita"
250
  "title": s["title"], # e.g. "Bhagavad Gita"
251
  "banner_url": s.get("banner_url", None),
 
261
  "metadata_fields": metadata_fields,
262
  "field_mapping": config.remove_callables(s.get("field_mapping", {})),
263
  }
264
+
265
+ # Add ONLY if present in scripture definition
266
+ if "audio_modes" in s:
267
+ entry["audio_modes"] = s["audio_modes"]
268
+
269
+ scriptures.append(entry)
270
 
271
  return {"scriptures": sorted(scriptures, key=lambda s: s["title"])}
272