Lignin valorization for carbon based materials