Local vs global nilpotence class (Lazard correspondence) The Lazard Correspondence is often phrased (for simplicity) for $p$-groups of nilpotence class $c < p$, but it works more generally whenever every 3-generated subgroup has nilpotence class $< p$, and I'm wondering how big a difference this is. (And under some additional conditions on a specific case I'm working on, the same but for 2-generated subgroups.)
Towards that end, let's say a (finite) group $G$ is $k$-locally nilpotent* of class $\leq c$ if every subgroup generated by $k$ elements  has nilpotency class $\leq c$, and let us call the smallest such $c$ the $k$-local nilpotence class of $G$.

For finite $p$-groups of 2-local (resp. 3-local) nilpotence class $c$, is there an upper bound on the (global) nilpotency class? What are examples achieving the largest known gap between the 2-local (resp. 3-local) nilpotency class and the (global) nilpotency class?

I'd also be interested in the same question for $p$-Lie algebras.
I've found it quite hard to search for — there seems to be a lot of literature about groups satisfying Engel conditions, but these aren't quite the same. A group of 2-local nilpotence class $c$ is $c$-Engel, but I believe the converse isn't true in general. And there's a lot of literature about locally nilpotent groups, but that is usually in the setting of infinite groups (where every finitely generated subgroup is nilpotent, or even where every f.g. subgroup is finite nilpotent). And of course "2-local" and "3-local" have their own meanings in finite group theory, so the overlapping/non-standard nomenclature really gets in the way.
While of course an answer would be great, because of the difficulty of searching, I'd also be happy with better keywords, authors, pointers to the literature, etc.
* Maybe not the best name, but I don't know a better one - if you do please let me know in the comments!
 A: This is not a complete answer (only gives the answer for p=2,3,5) but it is also too long to add as a comment!
Known results concerning similar questions as yours suggest that the nilpotency class of the whole group is a function depending on both the number of generators of the whole group as well as the prime p. For example there is a group of exponent 5 in which every 2-generated subgroup is nilpotent of class at most 6 and every 3-generator subgroup is of nilpotent class at most 8 and for m>3, every m-generated subgroup is of nilpotent class at most 2m. see the following
Newman, M. F. (5-ANUM); Vaughan-Lee, Michael (4-OXCH)
Engel-4 groups of exponent 5. II. Orders.
Proc. London Math. Soc. (3) 79 (1999), no. 2, 283–317.
Of course you are asking of the nilpotency class of a finite p-group in which every 3-generator (2-generator) subgroup is at most p-1, so the above example does not apparently answer your question.
The case 2-generator has been studied extensively but not for the nilpotency $p-1$ as you mentioned. The case $p=2$ implies the abelian and $p=3$ implies the nilpotency class 3 (as the group will be 2-Engel). The first non-trivial case is $p=5$ in which the group will be 4-Engel. If we assume 3-local assumption (that is every 3-generator subgroup is nilpotent of class $5-1=4$, then answer is positive and the nilpotency class of the whole group is at most 6. It follows from Corollary of
H. Heineken, Bounds for the nilpotency class of a group, J. London Math. Soc. 37 (1962), 456–458.
There is a related question. One may look at the following:
Abdollahi, Alireza,
Certain locally nilpotent varieties of groups,
Bull. Austral. Math. Soc. 67 (2003), no. 1, 115–119.

Added in 25/May/2021

As I mentioned above, one may consider the case $p>5$. It follows from part (a) of Theorem 2.4 of
A. Abdollahi and G. Traustason,
[On locally finite $p$-groups satisfying an Engel condition]
(https://doi.org/10.1090/S0002-9939-02-06421-3),
Proc. Amer. Math. Soc. 130 (2002) 2827-2836.
if $G$ is a finite $p$-group in which every 2-generator subgroup is nilpotent of class at most $p-1$, then $G^p:=\langle g^p \;|\; g\in G\rangle$ is nilpotent of class bounded by a function depending only on $p$. Now one may study $G/G^p$ having the same condition as $G$ (corresponding 2-local or 3-local as $G$).
Hence, if there is a universal bound, we must have a universal bound on the nilpotency class of finite $p$-groups of exponent $p$ in which every $3$-generator subgroup is nilpotent of class at most $p-1$.
