Zulip Chat Archive

Stream: mathlib4

Topic: FindFacts drill down facets


Johan Commelin (Aug 01 2024 at 14:50):

I just learned about Isabelle's FindFacts. It has this "drill down facets". That seems like a very useful feature. Would that be something for mathlib docs search as well?

Example: https://search.isabelle.in.tum.de/#search/default_Isabelle2024_AFP2024?q=%7B%22term%22%3A%22bigo%22%2C%22facets%22%3A%7B%22Kind%22%3A%5B%22Constant%22%5D%7D%7D

E.g. we might want to be able to "drill down" into one top-level folder.

Maybe not just mathlib-docs. Other search tools could have this as well.

Jireh Loreaux (Aug 01 2024 at 15:15):

I'm not sure I understand what's going on here. Can you give a brief explanation?

Johan Commelin (Aug 01 2024 at 15:24):

Well, you search for something on mathlib docs, or moogle, or whatever, and then maybe you want to apply extra filters on top of the search results. For example: n1n_1 results in Algebra/ and n2n_2 results in Topology/ etc... and you want to filter for only the results in a certain folder, once you know how many results there are in each folder.

Jireh Loreaux (Aug 01 2024 at 16:07):

okay, so basically it's just query filters. Yes, that would be lovely. Even just filtering out theorem vs def vs structure vs class etc. would be nice.

Joachim Breitner (Aug 01 2024 at 17:15):

Loogle inherently supports filtering by theorem or lemma, using |- (?a : Prop) resp. |- (?a : Type _). Nicer syntax to be added eventually. (https://github.com/nomeata/loogle/issues/9)

Joachim Breitner (Aug 01 2024 at 17:17):

Using something like "List." you can approximate filtering by namespace rather well.

Something similar to filter by defining module might be useful. As usual, the syntax design is the hardest part :-)

Mario Carneiro (Aug 03 2024 at 15:23):

I wonder whether loogle could take some design inspiration from coq's Search tactic? It seems most structurally similar to that tactic (indeed the original #find was based on it), but it has a more expressive syntax than loogle currently supports

Johan Commelin (Aug 12 2024 at 07:22):

Joachim Breitner said:

Loogle inherently supports filtering by theorem or lemma, using |- (?a : Prop) resp. |- (?a : Type _). Nicer syntax to be added eventually. (https://github.com/nomeata/loogle/issues/9)

That's nice!

Johan Commelin (Aug 12 2024 at 07:23):

One benefit of the "drill down" feature in FindFacts is discoverability. It gives suggestions of which filters you can apply. And it already tells you how many results satisfy a certain filter. So you can guesstimate whether it is useful to "drill down" in that direction.


Last updated: May 02 2025 at 03:31 UTC