フォーマット済み文字列リテラル
Pythonのf-string
https://docs.python.org/ja/3/reference/lexical_analysis.html#f-strings
変換 '!s' は str() を、 '!r' は repr() を、そして '!a' は ascii() を呼び出します。
Python f-stringの"変換"
These nested fields may include their own conversion fields and format specifiers,
書式指定文字列の文法
The format specifier mini-language is the same as that used by the str.format() method.
書式指定ミニ言語仕様(Python)
参照先
2.4.3. f-strings
PEP 498 – Literal String Interpolation
また関連する文字列フォーマットの仕組みを使っている str.format() も参照してください。
str.format()