There is no easy calculation for addition of flavorings. Your best bet is to look at a number of recipes which use vanilla and/or coffee, read about how they are using and where they are adding it.
I have not done anything with coffee so far, but I have used vanilla in a number of recipes. Generally, I will start with beans and add split vanilla beans into the fermenter after fermentation is finished and then top off with some vanilla extract at bottling to get a slightly stronger flavor than I want, as it will mellow with age. The amounts I add are specific to the recipe, beer style, and effect which I want to achieve.