Importance of Context while using Big Data
There is a catchy phrase in computer science, "garbage in, garbage out". Usually it is used with respect to data. It is equally applicable for setting context while querying data or using GenAI.
I used to work for the Ministry of Corporate Affairs in India, which keeps a registry of all registered companies in the country, among all the other things. For a report at an upcoming conference, the then minister requested total number of companies in India. The person responsible for reporting ran a query, asking for all the companies in the database. They found a number, something like 5,322 companies, and reported to the minister.
During the conference, the minister confidently stated that there were 5,322 active companies in India. The audience pointed out that the number was incorrect. Many of those companies had been struck off the registry or were in the process of striking-off and then there were inactive companies. The actual number of active registered companies was much lower. None of us foresaw the confusion that a simple number could cause. It was only a minor detail in so many other things that were discussed that day.
I've seen mistakes like this happen with GenAI tools since I've been using cursor.ai. If you don't set the context properly, these tools will generate ineffective, buggy code.
Sometimes Claude (or cursor) would generate class components instead of functional ones, or react code instead of preact code.
GenAI tools can hallucinate, but before you blame the tool, maybe check if you set the context wrong.