add simple demo and some fixes