leanprover-community / leanprover-community/mathlib4
RFC: Standardise naming for instances
Nobody has claimed this yet.
- Dominant language
- Lean
- Stars
- 4.1k
- Forks
- 1.7k
- PR merge metrics
- No merged PRs in 30d
Description
Currently, we have 300+ instances with a manual name like instance instCommGroup : CommGroup _, and 700+ instances with a manual name that does not contain inst.
I think not having a standardised policy for these names can create confusion, so I urge the community to decide on one standard for the future.
Arguments for inst:
- Kenny (the author) thinks that this is more consistent with the automatically generated names, which reduces the burden on the user when trying to guess the name, as it is inefficient to first try
Rat.commRingand thenRat.instCommRing.
Arguments against inst:
- Andrew Yang thinks that the automatically generated names are intentionally different to discourage people from mentioning them.
There also seem to be people with the opinion that we should not have explicit instance names at all, which is also one possible option.
Zulip: mathlib4 > naming convention: "inst" in instance names
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the linked instance-name search results and the Zulip discussion on the naming convention. The work is done when the community reaches a documented decision on a standard for explicit instance names and the issue records that decision.
Written by the indexing model from the issue text.
Assessment
- Domain
- developer-experience
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100