In a small bowl combine the vanilla and espresso powder. Set aside.
In a medium mixing bowl lightly whisk the eggs yolks. Set aside. Set a large sieve over a large bowl and set aside.
In a large saucepan combine the sugar, cocoa, salt and cornstarch. Stir milk in gradually with a wooden spoon. Cook over medium heat, stirring constantly until mixture thickens and boils. Boil 1 minute, stirring constantly. Remove from heat and add the chopped chocolate. Stir until melted taking care to get into the corners of the pan.
Slowly drizzle half the chocolate mixture into the yolks while whisking the eggs constantly. This slowly warms the eggs without cooking them into scrambled eggs. Blend the chocolate and egg mixture back into the saucepan with the remaining hot mixture and mix well. Return to the heat and boil 1 minute more, stirring constantly. Remove from the heat and add the butter and vanilla/espresso mixture.
Pour the pudding through a strainer into the prepared bowl, if desired, to remove any lumps of egg or cornstarch. Immediately press a piece of lightly greased (vegetable spray) parchment, plastic wrap or wax paper directly onto the surface of the pudding. Refrigerate for 4 hours. When ready to serve, spoon into serving glasses and top with lightly sweetened whipped cream and chocolate shavings or curls if desired.
If you prefer to serve slightly warm pudding, pour into individual serving dishes instead of the large bowl and allow to cool slightly. Top with lightly sweetened whipped cream before serving, if desired.