How to store sparse index in Elasticsearch

I would like to store sparse vectors from my models, but I don't want to use ELSER because I need control over the entire process. How can I store sparse vectors, and how can I execute queries without relying on ELSER?