Trying to learn sequent calculus and so I am trying to work thru some examples to get a better grip/understanding but the following question is not answered at the back of the book. I wrote my guess in the blue writing in the attached picture, however I am unsure of my answer because phi appears in the consequent under the first line. So I am wondering if it should look like my second guess which is written in red. The book I took this from is Mathematical Logic, by Hodges. Hope somebody can explain what is correct and why, please!!!


Neither.
The sequent proved is :
It is the last formula and the only assumption of the derivation : $\phi$, has been discharged (it is crossed with the "dandah").
The derivation is correct; see the discussion in :
or see the relevant parts quoted into this post.
The approach followed by Chiswell & Hodeges into this example simply amounts to :
The intuition behind it is quite simple : let's start assuming $\phi$, and derive $\phi$.
Having preformed this obviuos derivation of $\phi$ from some assumptions, it is harmless to assert that we have derived it from "those" assumption plus some extra-one.
Conclusion : we can always add "unnecessary" assumptions in a derivation.