Open adam-hurwitz opened 5 years ago
Did YouTube API v3 pull test as a function of number of OR Boolean operators. The number of search hits increase with 1st and 2nd uses of OR (hit results: text1 < text1 OR text2 < text1 OR text2 OR text3), but using three or more OR statements, the hits begin to tail off as more OR operators are used for a given pull. Thus, in my analysis, using two OR operators gives max (non-duplicate) results for each pull. Curious why YT does this.
On Jan 4, 2022 3:23 PM, iteGH @.***> wrote: Did YouTube API v3 pull test as a function of number of OR Boolean operators. The number of search hits increase with 1st and 2nd uses of OR (hit results: text1 < text1 OR text2 < text1 OR text2 OR text3), but using three or more OR statements, the hits begin to tail off as more OR operators are used for a given pull. Thus, in my analysis, using two OR operators gives max (non-duplicate) results for each pull. Curious why YT does this.
—Reply to this email directly, view it on GitHub, or unsubscribe.Triage notifications on the go with GitHub Mobile for iOS or Android. You are receiving this because you are subscribed to this thread.Message ID: @.***>
Expected
Adding a keyword phrase with the OR operator
|
in the YouTube API v3 search list request should return more results than without a keyword phrase because OR is inclusive.ie:
cryptocurrency|DigitalCash|digital+cash|dash
is passed via theq
parameter, and is expected to return at least the same or larger size JSON response of videos compared to the search without the keyword phrase such ascryptocurrency|DigitalCash|dash
.Documentation
The YouTube Search: list documentation does not mention keyword phrases explicitly for the
q
parameter.Implementation: Search Requests documentation mentions keyword phrases with the
skateboarding+dog
example, which is the syntax followed below using+
in between keyword phrases' words.Observed
No Keyword Phrases
Results in 40 - 43 videos after multiple tests.
Request where
q
parameter equals:Cryptocurrency|crypto|blockchain|digitalcurrency|bitcoin|BTC|ethereum|ETH|Dash|DashNews|DigitalCash|LLMQs|ChainLocks|DAPI|MakerDao|MKR|DAI|Tezos|XTZ|ETC|Ripple|XRP|BCH|EOS|Stellar|XLM|Litecoin|LTC|Cardano|ADA|IOTA|Monero|XMR|Zcash|Tether|USDT|ChanLink|LINK|BAT|0x|ZRX|omisego|OMG|Tron|TRX|Coinbase|Binance
Request:
https://www.googleapis.com/youtube/v3/search?part=snippet&maxResults=50&order=viewCount&publishedAfter=2019-05-22T23%3A30%3A04.334000000Z&q=Cryptocurrency%7Ccrypto%7Cblockchain%7Cdigitalcurrency%7Cbitcoin%7CBTC%7Cethereum%7CETH%7CDash%7CDashNews%7CDigitalCash%7CLLMQs%7CChainLocks%7CDAPI%7CMakerDao%7CMKR%7CDAI%7CTezos%7CXTZ%7CETC%7CRipple%7CXRP%7CBCH%7CEOS%7CStellar%7CXLM%7CLitecoin%7CLTC%7CCardano%7CADA%7CIOTA%7CMonero%7CXMR%7CZcash%7CTether%7CUSDT%7CChanLink%7CLINK%7CBAT%7C0x%7CZRX%7Comisego%7COMG%7CTron%7CTRX%7CCoinbase%7CBinance&safeSearch=none&type=video&pageToken=&key={yourApiKey}
Keyword Phrases
Results in 8 videos after multiple tests.
Request where
q
parameter equals:Cryptocurrency|crypto|blockchain|DigitalCurrency|digital+currency|bitcoin|BTC|ethereum|ETH|Dash|DashNews|Dash+News|DigitalCash|Digital+Cash|LLMQs|ChainLock|DAPI|MakerDao|MKR|DAI|Tezos|XTZ|ETC|Ripple|XRP|BCH|EOS|Stellar|XLM|Litecoin|LTC|Cardano|ADA|IOTA|Monero|XMR|Zcash|Tether|USDT|ChainLink|LINK|BAT|0x|ZRX|omisego|OMG|Tron|TRX|Coinbase|Binance
Request:
https://www.googleapis.com/youtube/v3/search?part=snippet&maxResults=50&order=viewCount&publishedAfter=2019-05-23T00%3A02%3A57.853000000Z&q=Cryptocurrency%7Ccrypto%7Cblockchain%7CDigitalCurrency%7Cdigital%2Bcurrency%7Cbitcoin%7CBTC%7Cethereum%7CETH%7CDash%7CDashNews%7CDash%2BNews%7CDigitalCash%7CDigital%2BCash%7CLLMQs%7CChainLock%7CDAPI%7CMakerDao%7CMKR%7CDAI%7CTezos%7CXTZ%7CETC%7CRipple%7CXRP%7CBCH%7CEOS%7CStellar%7CXLM%7CLitecoin%7CLTC%7CCardano%7CADA%7CIOTA%7CMonero%7CXMR%7CZcash%7CTether%7CUSDT%7CChainLink%7CLINK%7CBAT%7C0x%7CZRX%7Comisego%7COMG%7CTron%7CTRX%7CCoinbase%7CBinance&safeSearch=none&type=video&pageToken=&key={yourApiKey}