File size: 5,640 Bytes
2d198f5
7be9035
2d198f5
 
 
 
2a95661
7be9035
 
 
2d198f5
 
 
 
 
 
fac55e5
2d198f5
acfcefc
2d198f5
 
 
 
acfcefc
2d198f5
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
fac55e5
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5f3c368
 
 
 
 
 
 
 
 
 
2d198f5
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5f3c368
2d198f5
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5f3c368
2d198f5
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
0bdc135
 
 
 
2d198f5
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
from modules.config.categories import ScriptureCategoryConstants
from modules.google_drive.google_drive_utils import convert_drive_url_to_direct
import nalayiram_helper

divya_prabandham_taniyans_config = {
    "name": "divya_prabandham_taniyans",
    "title": "4000 Divya Prabandha Taniyans",
    "banner_url": convert_drive_url_to_direct(
        "https://drive.google.com/file/d/1jYdgIXbM3siBOIo3YnQ7JMLv087tRiqL/view?usp=drive_link"
    ),
    "category": ScriptureCategoryConstants.LITERATURE,
    "output_dir": "./output/divya_prabandham_taniyans",
    "collection_name": "divya_prabandham_taniyans",
    "collection_embedding_fn": "openai",
    "unit": "taniyan",
    "unit_field": "verse",
    "chapter_order": lambda: nalayiram_helper.get_prabandham_chapter_order_mapping(),
    "field_mapping": {
        "text": "pasuram_ta",
        "title": lambda doc: f"{doc.get('prabandham_name','')} Taniyan",
        "location": "divya_desams",
        "word_by_word_native": "wbw_ta",
        "unit_index": "verse",
        "transliteration": "pasuram_en",
        "reference_link": "html_url",
        "author": "author",
        "relative_path": lambda doc: "-".join(
            filter(
                None,
                [doc.get("prabandham_name", ""), "Taniyan"],
            )
        ),
    },
    "metadata_fields": [
        {
            "name": "prabandham_name",
            "label": "Prabandham Name",
            "datatype": "str",
            "description": "contains the prabandham name. e.g. `Thiruppallandu`",
            "show_as_filter": True,
            "component": "dropdown",
            "lov": lambda: list(
                set(
                    [
                        p.prabandham_name
                        for p in nalayiram_helper.get_standardized_prabandham_names()
                    ]
                )
            ),
            "is_unique": True,
        },
        {
            "name": "prabandham_code",
            "label": "Prabandham Code",
            "datatype": "str",
            "description": "contains the short prabandham_code. e.g. `TPL` for `Thiruppallandu`",
            "is_unique": True,
        },
        {
            "name": "verse",
            "label": "Absolute Taniyan Number",
            "datatype": "int",
            "is_unique": True,
            "description": (
                "Absolute verse number of the taniyan. Each verse has a unique number."
            ),
        },
        {
            "name": "azhwar_name",
            "label": "Azhwar Name",
            "datatype": "str",
            "description": "contains the azhwar name. e.g. `Thirumangai Azhwar`",
            "show_as_filter": True,
            "component": "dropdown",
            "lov": lambda: [
                azhwar_name
                for azhwar_name in nalayiram_helper.get_standardized_azhwar_names()
            ],
        },
        {
            "name": "divya_desams",
            "label": "Divya Desams",
            "datatype": "str",
            "description": "comma separated list of divya desams. e.g. Thiruneermalai,Thiruvallikkeni.",
            "show_as_filter": True,
            "component": "dropdown",
            "lov": lambda: [
                divya_desam_name
                for divya_desam_name in nalayiram_helper.get_standardized_divya_desam_names()
            ],
        },
        {
            "name": "title",
            "label": "Taniyan Title",
            "datatype": "str",
            "description": ("Exact title of a Taniyan."),
            "show_as_filter": True,
        },
        {
            "name": "pasuram_en",
            "label": "Taniyan Lyrics in English",
            "datatype": "str",
            "description": "Taniyan lyrics in English",
            "show_as_filter": True,
        },
        {
            "name": "pasuram_ta",
            "label": "Taniyan Lyrics in Tamil",
            "datatype": "str",
            "description": "Taniyan lyrics in Tamil",
            "show_as_filter": True,
        },
    ],
    "pdf_path": "./data/divya_prabandham_taniyans.pdf",
    "source": "https://uveda.org",
    "language": "tamil",
    "example_labels": ["Specific taniyan"],
    "examples": [
        "Show me a Taniyan",
    ],
    "llm_hints": [
        "user this collection only when the user asks about a taniyan (not a pasuram)"
    ],
    "credits": {
        "art": [
            {
                "name": "Sri TNCN",
                "url": "https://www.linkedin.com/in/narashiman-chakravarthy-54326111/",
                "role": "Illustrator",
                "notes": "Original artwork used with permission",
                "photo_url": "https://drive.google.com/uc?export=download&id=1D4Vo-Mvkp1RdZR6whUkcjvNBIW1yHSUE",
            }
        ],
        "data": [
            {
                "name": "UVeda",
                "url": "https://uveda.org",
                "role": "Data provider",
                "photo_url": "https://www.uveda.org/_next/image?url=%2Fuveda-logo.png&w=750&q=75",
            }
        ],
        "audio": [
            {
                "name": "Srirangam Vikram Vasudevan",
                "url": "https://www.youtube.com/@onedayoneTaniyan6126",
                "role": "Virutham audio provider",
                "context": [{"start": 1, "end": 4000}],
                "photo_url": "https://yt3.googleusercontent.com/lA5fiJuRDVGxOLkszb6O5DaiR1N7WcRVDHtJSQjO8IxCK-Y3VfMtYZP2Wm1SP0gUx8vj87jA=s160-c-k-c0x00ffffff-no-rj",
            },
        ],
        "video": [],
    },
    "audio_modes": {
        "recitation": "Recitation",
        "virutham" : "Virutham"
    },
}