Lxml alone does not work here, but using BeautifulSoup works fine!
s1="This is a text with mathjax like $1<2$, let's see if this works till here $2>1$!"
import lxml.html.soupparser as sp
from lxml import html
soup1 = sp.fromstring(s1)
print sp.unescape(html.tostring(soup1, encoding='unicode'))
gives
<html>This is a text with mathjax like $1<2$, let's see if this works till here $2>1$!</html>