feat: Add hypothesis filtering mechanism to only show Prop hypotheses#1226
feat: Add hypothesis filtering mechanism to only show Prop hypotheses#1226KacperFKorban wants to merge 10 commits into
Conversation
|
Thanks! I think the feature is useful, but I wonder if a completely different approach would be feasible. We already plan to put more info in the goal, like unique names to sub terms so to be able to track back where the user clicked. Adding a boolean (the universe) to each hypothesis seems simpler, and the filtering could then be done client side. What do you think? I do like the possibility to replay an event with different options, I do have use cases for the exec event (think at verbose/debug), so the current approach is also acceptable, I'm just exploring alternatives. Maybe I would be more convinced if we could ask to disable a notation (and hence be obliged to re print server side) but we currently lack the notation id in the printed term. Cc @rtetley since we discussed that before |
|
Thanks for the answer! |
86ebd36 to
8407010
Compare
93e371d to
d242057
Compare
|
I really like this feature and would like to use it day to day. Though I also feel it would be better to just augment the data being sent to the client instead of pushing that config option to the server code.
Do we know if this is an expensive operation? |
| export const isVisibleWithPropFilter = (hypothesis: Hypothesis) => { | ||
| // Legacy hypotheses have no universe metadata; keep them visible under the filter. | ||
| return ( | ||
| hypothesis.universe === "" || |
| universe = ""; | ||
| } | ||
|
|
||
| let add_diff_hypotheses_info env sigma hyps = |
There was a problem hiding this comment.
can you add some comment here?
I see the hyps are compacted to display x, y : nat but then I don't get why this extra fiddling.
There was a problem hiding this comment.
Will do, this is basically an attempt to add the universes and ids info to the pre-rendered hypotheses that we get from the Proof_diffs.
|
The I kind of understand moving from manual to continuous mode may be a bit violent if you do that in all tabs. anyway, this change seems orthogonal to the hyp filtering, unless I'm missing something. |
|
I'm not really competent about the client code, the only weird thing to me is that the filter is hardwired. Why can't it be a regex on the sort or the type? (with
I also think a little message like |
|
To be clear, I'm in favor of this change, it just seems to be a bit too ad hoc |
6e715f1 to
6df5b51
Compare
… Proof_diffs more readable
Yes, sorry. That was part of the server-side filtering that I implemented before. I forgot to remove that part of the code by accident. It's not needed for this feature. |


This PR implements a new feature: filtering the displayed hypotheses so that only the Prop-kinded ones are displayed.
Kooha-2026-03-31-11-04-05.webm