I suggest morosoph.
Morosoph or morosophist (noun): a learned fool
History and Etymology for morosoph:
morosoph from obsolete French morosophe, from Greek mōrosophos, from mōros dull, stupid + sophos wise; morosophist from obsolete French morosophe + English -ist — M-W
Morosoph: a wise fool
Late 17th century; earliest use found in Thomas Urquhart (1611–1660), author and translator. From Middle French morosophe wise fool (Rabelais, 1546) from post-classical Latin morosophus wise fool from Hellenistic Greek μωρόσοϕος foolishly wise, wise fool (2nd cent. a.d.) from ancient Greek μωρός foolish + σοϕός wise. Cf earlier morosophist — Lexico
Don't expect all your listeners to understand what you mean by 'morosoph'.
From Greybeard's comment:
It’s an interesting word. The OED gives morosoph, n. Brit. /ˈmɔːrəˌsɒf/, U.S. /ˈmɔrəˌsɑf/ Etymology: < Middle French morosophe wise fool (*Rabelais, 1546)... Now rare. (a) A wise fool, a jester. (b) A foolish pedant or would-be philosopher; = morosophist n. ++ For *morosophist, OED gives the same definition and adds “obsolete.rare”. It seems last to have been used seriously in 1835, although there is one use in 1990 in an academic essay about the comparative styles of Grimmelhausen and Rabelais in relation to the original morosophe, Simplicius.