Patent attributes
Multiple webpages are used to generate a template that includes portions of webpage code or other instructions common to the webpages, and a view model for each webpage that indicates instructions that may be added to the template to reconstruct the webpage. A first webpage and a second webpage are analyzed to generate a first set of tokens that represent instructions for the first webpage and a second set of tokens that represent instructions for the second webpage. The sets of tokens are compared to determine matching and differing instructions between the webpages. A template is generated that includes the matching portions of instructions and placeholders at locations associated with differences. A view model for each webpage is generated that includes a value for each placeholder, the value being the instructions that may be added to the template at the location of the placeholder to reconstruct the webpage.