make max_gram configurable
refine installation instructions