In a medium mixing bowl beat butter or margarine and sugar until light and fluffy. Add eggs one at a time, blending constantly until well combined. Mix in melted chocolate, coffee, and rum extract, blending thoroughly. Fold in flour and, if desired, chopped nuts. Pour mixture into pie shell and decorate with walnut halves.
Place in lower third of preheated oven and bake 25 minutes. Let cool one hour before cutting.