Catuṣkoṭi or tretralemma is mostly made up by intellectuals who commented on what they thought was the dhamma, and they tried to push their sloppy reasoning as the dhamma too, like Nagarjuna, so it is mostly in Mahayana. None of that stuff is strongly buddhist. The intellectual works like Upanishads use it too and the jains also, to sustain exactly the same claim like Nagarjuna, ie ''you can't talk about reality'', ie the absolute truth cannot be said. Buddhist intellectuals are not really rigorous logicians, even more so when compared to today logicians.
Plenty of people have tried to formalize the tretralemma like here https://scholarworks.sjsu.edu/cgi/viewcontent.cgi?article=1032&context=comparativephilosophy
https://plato.stanford.edu/entries/contradiction/#LNCBudTet
In the sutras, the tetralemma is just rejecting a claim and also rejecting the negation of the claim. This is from the claim being ill-defined, completely out of topic. But intellectuals prefer to view it has a deep thing about reality.