10. A system comprising: one or more computers and one or more storage devices storing instructions that are operable, when executed by the one or more computers, to cause the one or more computers to perform operations comprising: obtaining an image of a rendered document that includes text; determining a two dimensional geometric shape based at least on a first location in the image of the rendered document of a first space between a first pair of consecutive words, a second location in the image of the rendered document of a second space between a second pair of consecutive words, and a third location in the image of the rendered document of a third space between a third pair of consecutive words, wherein the first space, the second space, and the third space are not all included on a same line of text in the rendered document; generating a document signature based on the two dimensional geometric shape; and generating a query for an electronic document that is a counterpart to the rendered document, based at least on the document signature.
10. A system comprising: one or more computers and one or more storage devices storing instructions that are operable, when executed by the one or more computers, to cause the one or more computers to perform operations comprising: obtaining an image of a rendered document that includes text; determining a two dimensional geometric shape based at least on a first location in the image of the rendered document of a first space between a first pair of consecutive words, a second location in the image of the rendered document of a second space between a second pair of consecutive words, and a third location in the image of the rendered document of a third space between a third pair of consecutive words, wherein the first space, the second space, and the third space are not all included on a same line of text in the rendered document; generating a document signature based on the two dimensional geometric shape; and generating a query for an electronic document that is a counterpart to the rendered document, based at least on the document signature. 11. The system of claim 10 , wherein the first location, the second location, and the third location each comprise an absolute location in the image and determining the two dimensional geometric shape comprises determining the two dimensional geometric shape using the absolute locations.