1. A method performed by a computer having a memory and a processor for encoding information from a document image comprising steps of: receiving a document image; with a processor, parsing the document image into sub-images; with a processor, adding information relating to the sub-images to a codebook; and with a processor, applying a rule-based analysis to content of subdivisions of the sub-images wherein the step of applying includes determining whether three contiguous white columns exist in a subdivision.