I'll probably do something very similarly to this, with the adjustment of the size. Unfortunately, I'll need pellet launchers 4 blocks away because ghasts are 4x4x4. There's the (very) small chance of a ghast dodging both, but they float around so I should be okay. Thank you for your help!
I let it run for quite a while. and I didn't see any ghast dodging the bullets so to say. Thing is. there is always bullets bouncing around in there, and even at tier 5 the spawn rate is not all that high tbh. you can't even place the shard in the cage until it is at tier 4, so there are some kind of nerfbat type of rule going on with the soul shard mod in regards to mobs like ghasts. don't add too many pellet launchers tho. they do make lag if there are many of them at once. but 3 or 4 should generally be fine i think, just don't cross the beams, it makes for extra noise you don't want.
Making the entire thing a 5x5x5 room only reduced troughput by around 25-35%, since most of the time, despite the large spawn room, you only got one ghast spawn at a time, with 2 or 3 being less common. I think this has to do with the spawner looking for suitable locations within it's 8x8 spawn area centered on it's lowest coordinate corner. there is only room for a max of 4 inside that area, and only if all the ghasts spawn in a corner area, (something they would rarely do). I made it a bit higher, so that it would use the entire spawn height of the spawner. one layer below the top edge of the spawner, and 2 above it, so adding 3 to the 5x5x5 requirement on height, and an extra one for the layer of water. a total of 9. This does help the spawn rate a bit, since it tries all 3 layers, and if one is blocked, by say water, then you will loose a potential spawn.
I made it as wide as I did because i erroneously believed that it would potentially be spawning the center block of the ghast all the way on the edge of the spawn volume, but that seems to be wrong. it appears to want to fit the entirety of the ghast inside the spawner volume, (allowing parts of the ghast to be above the 3 layers of spawn volume ofc. all the spawners allows that).
So 3 blocks of air are wasted in both cardinal directions in the latest setup. the first one was just as good for spawning as this one was. (it was a 9x9 centered on the spawning block. (I like odd numbers for looks). the beta version i posted earlier was not as good at the killing tho.
The optimal size i think is a 8x8x10 room with the spawner sitting 2 blocks above the floor, then a ring of water source blocks beneath the lower edge of the spawner protecting the floor from fireballs, and pushing items into the transposers or obsidian pipes. An important note on obsidian pipes. ghasts will fire at you if you move below the collection system. they seem to be able to see you trough it, so expect to get some damage down there during maintenance unless the machine is turned off. They can even see you when you use transposers, altho not as reliably as when using obsidian pipes. i think they go transparent when activated, and that is all it takes. a split second, and a fireball is on it's way to the floor.