However, much to my dismay, I found it almost impossible to keep track of the literally thousands of if-then scenarios that were rapidly analysed by both amateur and professional astrologers. I soon realised that good astrologers, like good card or chess players, have an intuitive sense of the totality of the situation, whereas I was an algorithmic person who could follow rules. So I decided that I would create a program -- immensely complicated if necessary -- to crunch through the immense number of conditions.
Accordingly, sometime in the year 1998 or 1999, I embarked on a grand project to convert the immense number of conditions given by Harihar Majumder in Falit Jyotish into a corpus of XBasic code. But after struggling with it for almost a year, I gave up. It was way too complex to try to enumerate all possible combinations. I realised that I would need some kind of generic inference engine to crunch through an ever-expanding set of conditions. Moreover, I would need a generic way to store conditions -- like aspects and conjuncts of both planets and lords -- that could be processed in the hypothetical inference engine.
This is where I thought my considerable knowledge of relational databases would help. I devised a very clever way of codifying significant text fragments -- like planet names, lord numbers, and situations such as aspects and conjuncts -- as numeric codes. These could then be concatenated to create meaningful descriptions of significant states; for example, “Saturn aspected by Third Lord.” In retrospect, this was no different from the key-value approach that is widely used today, but I had arrived at it quite independently and was immensely proud of the fact.
I discussed this with my IIT friend A. Raghuram Hebbar, who himself was adept in this field, and he was very impressed with this and encouraged me to explore it further. I plunged into the field with renewed vigour and learnt about the Swiss Ephemeris program, with which horoscopes could be cast with great accuracy. Hebbar told me that the Swiss Ephemeris programs -- written largely in C -- would be too difficult for normal astrologers to use, so I created a wonderful Excel-based front end for it. This was a very clever program in which the C executable was run inside an Excel macro, the results brought back into Excel, and then converted into horoscope charts in all three formats -- North Indian, South Indian, and East Indian (Bengali). I doubt if anyone anywhere in the world had ever used Excel in this way.
While the system was ingenious, it was rather clumsy. Astrology knowledge first had to be codified into key-value pairs, concatenated into meaningful sentences, inserted into a relational database like MySQL, and accessed through a front end consisting of an Excel spreadsheet. The system was a marvel of system integration -- but would it be of any real use? Frankly, no. It was a programmer’s pride and an astrologer’s nightmare. So I was left scratching my head on how to make it more useful.
At this point, let me take a little break and detour to explore the rationale and raison d'ĂȘtre of astrology.
Traditional scientists, of course, hesitate to view astrology as a science because they are trained to interpret phenomena through the prism of cause and effect. Naive astrologers also fall into the trap of trying to justify astrology by invoking gravitational, electromagnetic, and even undiscovered, unheard-of “rays” that emanate from astronomical bodies and influence human destiny. Both are wrong because they are searching for causation, whereas the underlying principle is one of correlation. Astrology is interested in predicting an outcome based on some correlation -- an event, say an accident, happens not because a certain planet was at a particular location and caused the event, but because it has been historically observed that the presence of a planet at a particular position is associated or strongly correlated with the occurrence of that specific event.
But is correlation an acceptable way to analyse situations and predict outcomes? Certainly, if we consider...
The world of data science, of which artificial intelligence (AI) is a specific example, is largely based on the study of correlations. In all such cases, the system is presented with a set, or pattern, of input data, and it generates some output that can be interpreted as predictions. What happens inside the system -- almost like a black box -- is not very clear. Some parameters, also known as weights, are assigned numeric values, but it’s not possible to explain why those specific values were chosen. All that is known is that changing these values leads to a change in the accuracy of the prediction. Once the values have been set correctly -- the system has been “trained” -- the subsequent predictions are almost always correct.
Viewed from this perspective, astrology can be freed from its dependence on thousands of if-then conditions and seen as a machine learning exercise. With this new thought in mind, I decided to approach my goal from a very different perspective. I threw out everything that I had done with Excel and MySQL and rebuilt the entire system -- Parashar21 -- with Python, using the new-fangled NoSQL tool, MongoDB, as a backend database. In this new system, I used K.N. Rao's book on the introduction to Hindu Astrology as the basis for all calculations.
In fact, MongoDB was a game changer because it made the storage of horoscope charts very simple. Perhaps not exactly simple, but much more logical and surely far less clunky than the concatenations of key-value pairs that were required in SQL systems. Now I had everything in place -- except the data! For any machine learning system to work, it must first be trained with actual data. I needed the horoscopes of thousands of people, along with some information about their lives. Professional astrologers would have some data, and Hebbar suggested that I contact K.N. Rao's team. Unfortunately, astrologers are very possessive of their data, and they simply ignored my request. I also tried to contact U.S. astrologers like James Braha and the founder of Astrosage, Punit Pandey, who politely acknowledged my overtures but did not take it any further. Perhaps they did not understand; perhaps they did not want to collaborate.
In desperation, I turned to the web and discovered that there existed an Astro Database Wiki Project. This database contains the basic birth date, time, and location of nearly 40,000 people, along with six additional fields containing information about their vocation (or profession). Using the profession tag to identify people connected to medicine and equating them to doctors, I asked my colleague Subhasis Das Gupta to carry out a classification exercise to see if we could predict who all could become doctors on the basis of their horoscope. Unfortunately, our results did not show any statistical significance and cannot be quoted any further. I realised that the tagging was perhaps very inaccurate.
If we had more -- and better -- data about (a) independent variables like date and time of birth, and (b) dependent variables like life events, I am confident that machine learning tools could be used effectively in astrology. What we need is a database of 'tagged' horoscopes. The current Astro Bank database has six descriptive fields with information about vocation and vocation details for up to three vocations. We would need to generalise this by tagging horoscopes with additional information like education, wealth, fame, health, etc. Creating such a database would be the first step towards discovering and validating patterns of data that are correlated to life outcomes.
The astronomical observations that were made with the naked eye and recorded in a vast database by Tycho Brahe and his sister Sophia were the basis for the formulation of Kepler's Laws of Planetary Motion, which in turn led to Newton's laws of gravitation and the emergence of European science in the eighteenth century. Today, the same laws can be deduced very easily and quickly from NASA data.
Similarly, a database built on these lines could surely lead to a resurgence of Hindu astrology in the twenty-first century. That was the goal of Parashar21. However, given my limited resources, and the apathy of the professional astrologers in this regard, Parashar21 will possibly remain "A Bridge Too Far."