Preheat oven to 375 degrees F (190 degrees C). Grease baking sheets, or line with parchment paper.
In a large bowl, cream together the butter and sugar until smooth. Beat in the eggs one at a time, then stir in the vanilla. Combine the flour, cocoa and baking powder; stir into the creamed mixture until well blended. Dough will be stiff, so mix in the last bit by hand. Mix in the chocolate chips and walnuts.
Divide dough into two equal parts. Shape into 9x2x1 inch loaves. Place onto baking sheet 4 inches apart. Brush with mixture of water and yolk.
Bake for 20 to 25 minutes in the preheated oven, or until firm. Cool on baking sheet for 30 minutes.
Using a serrated knife, slice the loaves diagonally into 1 inch slices. Return the slices to the baking sheet, placing them on their sides. Bake for 10 to 15 minutes on each side, or until dry. Cool completely and store in an airtight container.