Guarantee fee = unsecured credit margin − secured credit margin (interest rate differential method, OECD Chapter X §10.160). All other inputs are identical; only the seniority differs.
The expected loss cross-check needs the guarantor’s standalone credit rating. This is separate from the borrower’s rating, which is calculated automatically above.