Each commit message should follow this structure:
<type>(<scope>): <short summary>
<optional body>
- feat: A new definition, theorem, or structure
- fix: A bug fix or correction to an existing proof/definition
- refactor: Restructuring code without changing behavior (e.g. renaming, reorganizing modules)
- style: Formatting, whitespace, universe annotations, namespace organization
- docs: Documentation changes (README, comments, docstrings)
- build: Changes to lakefile.toml, lean-toolchain, CI configuration
- chore: Maintenance tasks (updating dependencies, cleaning up imports)
The scope should identify the area of the library affected, typically a module path:
Possible— thePossibletypeclass and instancesTuringMachine— multi-tape Turing machine definitionsModels— the models aggregation layerproject— project-level configuration
feat(TuringMachine): add multi-tape monadic Turing machine
Define MultiTapeTM parameterized over a monad M with Possible typeclass,
along with step relation, reachability, and output predicates.
refactor(Possible): add universe polymorphism to Possible class
build(project): bump Mathlib to v4.28.0
- Keep the summary line under 72 characters.
- Use imperative mood ("add", "fix", "remove", not "added", "fixes", "removed").
- The body is optional but encouraged for non-trivial changes. Explain why, not what.
- Reference related issues or discussions if applicable.
- Follow Mathlib conventions for naming:
camelCasefor definitions,PascalCasefor types and Prop-valued definitions. - Use universe polymorphism where appropriate.
- Keep
opendeclarations scoped to sections or namespaces rather than at module level. - Use
variableinsidesectionblocks to organize implicit parameters. - Avoid unused variable warnings — use
_for genuinely unused binders. - Prefer Mathlib's existing types and lemmas over custom ones.
lake buildEnsure the project builds cleanly with no warnings before submitting changes.