In a skillet, melt the butter. Add the onion, cover and cook over moderately low heat, stirring, until softened, 15 minutes. Uncover and cook over moderate heat, stirring, until the onion is caramelized, 20 minutes; add water if necessary to keep the onion from burning. Season with salt and pepper.
In a small bowl, whisk the mayonnaise with the lemon juice, garlic, paprika and cayenne. In a steady stream, whisk in the olive oil and season with salt and pepper. Fold in the cornichons and parsley.
Heat a griddle. In a bowl, mix the Gruyère and cheddar. Season the patties with salt and pepper and cook over high heat for 2 minutes. Flip the burgers and top with the mixed cheeses. Carefully cover the burgers with a large inverted roasting pan and cook for 2 minutes longer, until medium-rare and the cheese is melted.
Spread the paprika mayonnaise on the bottom halves of the buns and stack 2 patties on each. Top with the onions, pickles and lettuce and serve.