However it depends. So if the portrait is a page within the essay itself then "in" is definitely better. But you could also have a set where the set includes the essay and a separate portrait. In that case "with" would be better.
Both are correct but they mean different things. "With" in this context would mean that the portrait was published alongside or at the same time as the essay but was not part of the essay. "In" would mean that the portrait was part of the essay.