Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Show HN: Simple Bhagavad Gita Search Web App (searchgita.com)
103 points by cvaidya1986 on Aug 6, 2017 | hide | past | favorite | 32 comments


Hey this is excellent! I just finished a survey philosophy course which started off with the Gita and continually returned to it, I was super disappointed when I found most online editions plastered with ads and barely readable (by modern standards).

I agree with the other commenter, I expected clicking on a verse would jump me that position in the whole body of text, but I'm sure this is just your starting point. Well done OP


So thankful! The whole body of text as in you can see below and above quotes or how do you envision the UI when you click on the quote? Would you also like this for other types of philosophy too? Shiva Sutras? Buddha? Zen?


Shantideva, and commentaries on his work.

Yes, anything would be great.


Typing two words results in the second word being matched with non-contiguous letters. For instance, 'Krishna and' will match with

^Krishna) ^am the source of the origi^n as well as the ^dissolution of the entire universe. (7.06)

Not sure if this was intended


Yea point taken! Will improve search!


When I type "entitled" I get matches for "entities", "There", "Divine" and lot of others. Does it search for every single letter of the search term? That doesn't seem very useful.


It's a basic fuzzy search, are you looking for a more cognitive search where it tries to find the meaning of entitled and returns a response?


I am looking for matches that contain the word "entitled". Nothing else. This search seems way too fuzzy.


So if the word does not exist in the verses, it should show up zero matches instead of something close?


In what way is "there" even close to "entitled"?

Yes, the default should be not to show verses that don't contain the search word. At least to me the current implementation is not useful.


Similar to this: when I type "Bhima" it also gets me "Bhisma". That means it does not recognize the structure of a word.


Hmm you're right. I will definitely look into improving the search.


Hey! Excellent Work! Just found a typo in following sentence: "I am the wind among the purifiers and Lord Rama among the warriors. I am the crocodile among the fishes and the holy Gariga among the rivers. (10.31)"

I think it should be Ganga. :)


Of course you're right! I shall correct it when I get a chance! Any more suggestions welcome!


Is there a way to click on the results to bring up the surrounding text?


Ah you mean jumping to the place in the Gita? Or show the sequential quotes below and above?


Yes to both, if possible. I read the Gita first when given a free copy by the ISKC (Hare Krishnas) in Brooklyn back in 1978. Then I read all sorts of texts after taking a comparative religion class in high school. I'd love to have this to study it better.


Does this only search the English translation? I tried the famous 'yada yada hi dharmasya' but it was showing some random results.


Ah yes only English translation for now. Ok I will add it!


I feel like the transliteration issues may be pretty complex! Someone using the site might choose to search for any of

यदा यदा हि धर्मस्य (in Unicode)

yadā-yadā hi dharmasya

yadā yadā hi dharmasya

yadaa yadaa hi dhamasya

yada yada hi dharmasya

If you want to allow search using transliteration, there are a number of interesting algorithmic and non-algorithmic questions about the range of different transliteration mechanisms that people may use.

Also, for a reason that I don't quite understand, people transliterating Sanskrit can be very inconsistent about where they do and don't transcribe spaces. Are the spaces perhaps not present in the original? For example ग्लानिर्भवति might be transcribed as "glānir bhavati" or "glānirbhavati", which may also be treated differently for search purposes.

(I don't actually know any Sanskrit; I'm just interested in linguistics and writing systems.)


Thats fast. Can you comment on the architecture?


Less than 1000 verses. You could naively linearly search the whole Gita as a single string.


Looking at the source. All the text is loaded with the HTML (in a <script> tag), which is filtered using a fuzzy search implementation.

Very simple and fast considering the text doesn't change ;)


I'm planning to add share buttons for twitter and FB. Let me kno if you'd like other features or a mobile app?


Ability to annotate? That's obviously a lot of work though. It could provide context or scholarly opinion/analysis.

Maybe "navigation" buttons so if you find a passage you can click next or previous to see the preceding or subsequent passages.


Added navigation!


Nice work. It would be nice if the citation were logically and visually separated from the body of each verse.


Like verse then Chapter name and verse number at the bottom right?


Can I help implement a full text search?


What I like about fuzzy search is that if I search something like 'Constant Remembrance' which is a spiritual concept but it doesn't exist in those exact words in the Gita, fuzzy search comes up with a quote quite close to the concept simply because it is fuzzy. How would full text search work? Would it come up with zero results if the search was not precise?


Exactly. That's how it should work. I searched "love" and got passages "Lord Krishna [...] grieve" which the search included because of LO (from LOrd) and VE (from grieVE) - no mention at all of "love," so not what I was looking for. Just go with standard search.


Point taken!




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: