Open umangahuja1 opened 6 years ago
If it's just randomly selecting quotes from a bag of quotes, then I agree it needs improvement. I have quite a good experience with scrapy, I think I can work on this. Do you know any publically available API to get quotes?
Hey, I found two APIs for quotes: https://quotesondesign.com/api-v4-0/ & http://forismatic.com/en/api From my point of view, it's unnecessary to scrape the quotes we get by the APIs and save them. We can simply request a quote when the user does so similar to the movie or music modules.
This is great. We can pick one of them or both, and start the work. I think I will take this up. @KonstantinBork thanks, man. Will let you know.
If you need any help, I'll be available.
@KonstantinBork I was thinking of introducing a class that will help us to call above API's, and more in future, which will basically have attributes to set request method type, query param, headers (if any) etc. And then randomly selecting the available API resources and calling it using the above class. Sounds good? Or if you have anything better please let me know.
This should be the way to go. I think there already exists a util folder where you can put the class into.
@KonstantinBork I was also thinking, rather than being completely dependent on random selection, we should incorporate a system that checks for repetition of quotes based on what was generated previously. But to implement this we then also have to consider the various active chat session, which will make the system bit complicated.
You should keep it as simple as possible at first. Implement a first working draft and when this is merged with the main code, you can think about improving the system. Just my two cents.
How about scraping quote of the day from https://www.brainyquote.com/quote_of_the_day?
Is this issue still open? I am ready to take this.
I have raised a PR. Still not merged.
I saw that quote feature provide quotes from one of the few listed. How about using this to provide quote of the day by web scraping?