Python Tutorial, Release 3.9.5 And the last uses all three calling conventions in the same function definition: Finally, consider this function definition which has a potential collision between the positional argument$_{name}$and **kwds which has name as a key: There is no possible call that will make it return$_{True}$ as the keyword$_{'name'}$ will always bind to the first parameter. For example: But using$_{/}$(positional only arguments), it is possible since it allows$_{name}$as a positional argument and$_{'name'}$ as a key in the keyword arguments: In other words, the names of positional-only parameters can be used in$_{**kwds}$ without ambiguity. The use case will determine which parameters to use in the function definition: As guidance: Recap • Use positional-only if you want the name of the parameters to not be available to the user. This is useful when parameter names have no real meaning, if you want to enforce the order of the arguments when the function is called or if you need to take some positional parameters and arbitrary keywords. • Use keyword-only when names have meaning and the function definition is more understandable by being explicit with names or you want to prevent users relying on the position of the argument being passed. • For an API, use positional-only to prevent breaking API changes if the parameter’s name is modified in the future. Chapter 4. More Control Flow Tools 26 def foo(name,/,**kwds): return 'name' in kwds >> >foo(1,**{ 'name':2}) True >>> foo(1,**{ 'name':2}) Traceback (most recent call last): File "<stdin>" , line1, in <module> TypeError: foo() got multiple values for argument 'name' >>> >>> combined_example( 1,2,3) Traceback (most recent call last): File "<stdin>" , line1, in <module> TypeError: combined_example() takes 2 positional arguments but 3 were given >>> combined_example( 1,2, kwd_only =3) 1 2 3 >>> combined_example( 1, standard =2, kwd_only =3) 1 2 3 >>> combined_example(pos_only =1, standard =2, kwd_only =3) Traceback (most recent call last): File "<stdin>" , line1, in <module> TypeError: combined_example() got an unexpected keyword argument 'pos_only' def foo(name,**kwds): return 'name' in kwds def f(pos1, pos2, /, pos_or_kwd, *, kwd1, kwd2):