It’s tricky to know because technology has changed the nature of these jobs significantly, and Star Trek has tended to map to roles as they are, despite projecting further technology.
In the 60s, 70s & 80s, a Yeoman would have held the encryption keys and would have been responsible for interactions with command. (The Comms officer would have had communications engineering and codes, but not necessarily access to the highest command codes.)
Likewise, responsibility for personnel assessment and promotion recommendations among ratings was a senior NCO responsibility that interlinked with the responsibilities of the XO.
It’s easy to portray a lot of these jobs as ‘merely clerical’ and it can be a kind of erasure of the people of colour and women who were in these ratings.
It brings to mind the work of the WW2 Wrens who did all the naval gaming in the UK and in Halifax, modeling, innovating and teaching tactics to UK and allied navies, but who got no credit. Or the women ‘computers’ and code breakers at Bletchley. Their commanding officers got all the credit and they were erased.
Understood. I suspect that Roddenberry was just trying to find a role for another woman after having such pushback on a Lieutenant Commander.