I'll try to regurgitate what I found in the code while modding:
Brief Version:
Full Citizenship: All jobs
Residence: Also all jobs, however they are only rulers if no other possible pops can be rulers, and if they are a ruler they are typically replaced by the first "Full Citizen" pops.
Chattel Slavery: Exclusively Workers.
Domestic Slavery: Worker jobs and Entertainers. Also, "unemployed" pops auto-join servant jobs, which give amenities and use a quarter of a house instead of 3/4 of one.
Battle Thralls: Exclusively Workers. Massive priority over all other pops for soldier jobs.
Livestock: JUST cattle. Also, 0.25 housing instead of 0.75.
Robots normally don't care if they are enslaved or not when picking jobs. Robots can only be workers, Droids can also be Specialists, and Synthetics can be Rulers IF you have full AI rights. A small handful of Worker and Specialist jobs are "Complex", which is treated as one tier higher (So a complex Worker job is treated as a Specialist for considering if a mechanical pop can work there).
Also as a general rule, pops will first try to become rulers, then colonists, then soldiers, then specialists, then criminals, then workers, then clerks, then "highly unusual jobs" like "toilers" on thrall worlds.
Details:
More specifically, jobs check what is called a "job_trigger", which is different for rulers, specialists, and workers. Entertainers also have exclusive triggers (due to slavery types being able to use those two).
* Complex Jobs (For Robots in Normal Empires):
So Specialists and Worker jobs have what I will call "Normal" and "Complex" jobs. If a worker job is complex, it must be worked by a droid instead of a robot. If a specialist job is complex, it must be worked by a synthetic instead of a droid AND AI cannot be outlawed.
Otherwise Worker jobs can be worked by any robots, Specialist jobs can only be worked by Droids and Synths, and Ruler jobs can only be worked by Synthetics.
Full List of "Complex" Worker Jobs: Clerk, Technician, Prosperity Preacher (Yes. The job provided by "Gospel of the Masses" Megacorp Branch Offices that build that building).
Full List of "Complex" Specialist Jobs: Colonist, Researcher, Priest (I'm not making this up, Temple jobs), Cultural Worker.
* Requirements for "Ruler" Jobs:
Cannot be enslaved.
Cannot be in the process of being purged or assimilated.
Does NOT have the "Proles" (Syncretic Civic) or "Nerve Stapled" (genetic ascension) traits.
Does NOT have the "Mechanical" trait OR has both Synthetic Workers Tech AND Full AI Rights.
Is NOT a Bio-Trophy.
Additionally, High Priests cannot be materialist, but it doesn't have any other special robot checks. In fact, it checks for robot traits when considering how many amenities to give! The same is true of the normal Priest job, although those may be materialist.
* Requirements for "Specialist" Jobs:
Some jobs are considered "Complex", which Synthetics (not Droids) may work. They have exactly the same bio-requirements.
Cannot be enslaved.
Cannot be in the process of being purged or assimilated.
Does NOT have the "Proles" (Syncretic Civic) or "Nerve Stapled" (genetic ascension) traits.
Does NOT have the "Mechanical" trait OR is a Droid (can be "shackled", aka robot slavery?).
Is NOT a Bio-Trophy.
Additionally, Entertainers have their own, separate check, which replaces "Cannot be enslaved" with "Is Domestic Slave OR Not-Enslaved".
There is also a trigger called "Can_Take_Servant_Jobs", which only checks if the pop is a Domestic Slave or has the robot Domestic Protocols. Nothing requires this trigger, but nearly all specialist jobs have a reduced weight modifier if it's true.
Which means if a robot has Domestic Protocols, it's chances to be picked for a specialist job (except entertainer) over all other pops (that CAN take it) is reduced dramatically.
* Requirements for "Worker" Jobs:
NOT Purging, Assimilating, Bio-Trophy.
NOT BOTH: "Citizen Slavery" and livestock/matrix slavery type. (I THINK this just means they can't be Livestock or Matrix slaves).
I should also explain this: Jobs have a weight, which is a value. If a job has a higher value than another job, a pop will pick the job with the higher value. A unemployed pop is picked before a pop that already has a job, but a job with a higher value will "steal" a pop from a job with a lower one, except a job from a lower stratum CANNOT steal a pop from a higher stratum. Pops will typically fill Ruler jobs first if they can (value 1000), then Colonist jobs (200), then Soldier (100), then Criminals (5), then Workers (1), then Clerks (0.8), then "Special Jobs" (0.01). Special jobs include things like "Toilers" on Thrall Worlds.
Those values can change though, as one pop that is more qualified for a job has a higher value toward that job, and one that is less qualified has a reduced value. Specialists also have a +50% value to a job they already have, meaning a pop must be significantly more qualified than a specialist to "steal" their job. Rulers have a value multiplier of 5! Almost nothing can kick out a ruler from their job short of AMAZING traits or losing citizenship. Most specialist jobs have a -80% value if the pop has Residence Citizenship.
Also, events can change values too. A planet under martial law gives soldier jobs a multiplier of 10, meaning they are prioritized as if they were ruler jobs! But because they are the lowest stratum (meaning they can't steal specialist/ruler pops) and already have a massive value, this functionally just means martial law forces new pops to become soldiers instead of rulers or colonists.
Admins, Nobles, and High Priests have a -90% value if the pop is a resident. Those three are ALWAYS replaced by full citizens as soon as full citizen pops are available. Science Directors only have a -80%, and can therefore keep their jobs through sheer merit if they have enough traits that make them good researchers (like intelligent). Merchants/Executives have NO value penalty if they're residents, meaning they are effectively permanently a merchant until resettled, enslaved, purged, or the source of their merchant job is destroyed. It also means that when hiring a merchant, the game ignores citizenship (assuming they're not enslaved) unless all possible pops have exactly the same traits that make them good merchants. Only then does full citizenship get picked over residents for Merchant jobs.
This weight mechanic can sort of make it seem like some pops are unable to pick certain pops, but it's more likely that due to citizenship they're just not picked over Full Citizens.
I hope this helps clear up what you need to know.
EDIT: I almost forgot:
You mentioned your robots NOT being picked for alloys. This is not found anywhere in the code, so I suspect you either had robots (not droids) or Bio pops were constantly being picked for the job over the droids (which is almost guaranteed if they have the domestic protocols trait; even residence citizenship is more likely to be picked for that job than a droid with DP trait.)
I believe your robot pops have the Domestic Protocols trait, which explains your specific scenario of them refusing to be alloys workers, but they are entertainers. They CAN be alloy workers, but it's the LAST job they'll take.
EDIT2: Whoops, accidentally claimed "Enforcers" have a special check. They do not: they are normal specialist jobs.
EDIT3: Clarified how ruler job weights work.
Brief Version:
Full Citizenship: All jobs
Residence: Also all jobs, however they are only rulers if no other possible pops can be rulers, and if they are a ruler they are typically replaced by the first "Full Citizen" pops.
Chattel Slavery: Exclusively Workers.
Domestic Slavery: Worker jobs and Entertainers. Also, "unemployed" pops auto-join servant jobs, which give amenities and use a quarter of a house instead of 3/4 of one.
Battle Thralls: Exclusively Workers. Massive priority over all other pops for soldier jobs.
Livestock: JUST cattle. Also, 0.25 housing instead of 0.75.
Robots normally don't care if they are enslaved or not when picking jobs. Robots can only be workers, Droids can also be Specialists, and Synthetics can be Rulers IF you have full AI rights. A small handful of Worker and Specialist jobs are "Complex", which is treated as one tier higher (So a complex Worker job is treated as a Specialist for considering if a mechanical pop can work there).
Also as a general rule, pops will first try to become rulers, then colonists, then soldiers, then specialists, then criminals, then workers, then clerks, then "highly unusual jobs" like "toilers" on thrall worlds.
Details:
More specifically, jobs check what is called a "job_trigger", which is different for rulers, specialists, and workers. Entertainers also have exclusive triggers (due to slavery types being able to use those two).
* Complex Jobs (For Robots in Normal Empires):
So Specialists and Worker jobs have what I will call "Normal" and "Complex" jobs. If a worker job is complex, it must be worked by a droid instead of a robot. If a specialist job is complex, it must be worked by a synthetic instead of a droid AND AI cannot be outlawed.
Otherwise Worker jobs can be worked by any robots, Specialist jobs can only be worked by Droids and Synths, and Ruler jobs can only be worked by Synthetics.
Full List of "Complex" Worker Jobs: Clerk, Technician, Prosperity Preacher (Yes. The job provided by "Gospel of the Masses" Megacorp Branch Offices that build that building).
Full List of "Complex" Specialist Jobs: Colonist, Researcher, Priest (I'm not making this up, Temple jobs), Cultural Worker.
* Requirements for "Ruler" Jobs:
Cannot be enslaved.
Cannot be in the process of being purged or assimilated.
Does NOT have the "Proles" (Syncretic Civic) or "Nerve Stapled" (genetic ascension) traits.
Does NOT have the "Mechanical" trait OR has both Synthetic Workers Tech AND Full AI Rights.
Is NOT a Bio-Trophy.
Additionally, High Priests cannot be materialist, but it doesn't have any other special robot checks. In fact, it checks for robot traits when considering how many amenities to give! The same is true of the normal Priest job, although those may be materialist.
* Requirements for "Specialist" Jobs:
Some jobs are considered "Complex", which Synthetics (not Droids) may work. They have exactly the same bio-requirements.
Cannot be enslaved.
Cannot be in the process of being purged or assimilated.
Does NOT have the "Proles" (Syncretic Civic) or "Nerve Stapled" (genetic ascension) traits.
Does NOT have the "Mechanical" trait OR is a Droid (can be "shackled", aka robot slavery?).
Is NOT a Bio-Trophy.
Additionally, Entertainers have their own, separate check, which replaces "Cannot be enslaved" with "Is Domestic Slave OR Not-Enslaved".
There is also a trigger called "Can_Take_Servant_Jobs", which only checks if the pop is a Domestic Slave or has the robot Domestic Protocols. Nothing requires this trigger, but nearly all specialist jobs have a reduced weight modifier if it's true.
Which means if a robot has Domestic Protocols, it's chances to be picked for a specialist job (except entertainer) over all other pops (that CAN take it) is reduced dramatically.
* Requirements for "Worker" Jobs:
NOT Purging, Assimilating, Bio-Trophy.
NOT BOTH: "Citizen Slavery" and livestock/matrix slavery type. (I THINK this just means they can't be Livestock or Matrix slaves).
I should also explain this: Jobs have a weight, which is a value. If a job has a higher value than another job, a pop will pick the job with the higher value. A unemployed pop is picked before a pop that already has a job, but a job with a higher value will "steal" a pop from a job with a lower one, except a job from a lower stratum CANNOT steal a pop from a higher stratum. Pops will typically fill Ruler jobs first if they can (value 1000), then Colonist jobs (200), then Soldier (100), then Criminals (5), then Workers (1), then Clerks (0.8), then "Special Jobs" (0.01). Special jobs include things like "Toilers" on Thrall Worlds.
Those values can change though, as one pop that is more qualified for a job has a higher value toward that job, and one that is less qualified has a reduced value. Specialists also have a +50% value to a job they already have, meaning a pop must be significantly more qualified than a specialist to "steal" their job. Rulers have a value multiplier of 5! Almost nothing can kick out a ruler from their job short of AMAZING traits or losing citizenship. Most specialist jobs have a -80% value if the pop has Residence Citizenship.
Also, events can change values too. A planet under martial law gives soldier jobs a multiplier of 10, meaning they are prioritized as if they were ruler jobs! But because they are the lowest stratum (meaning they can't steal specialist/ruler pops) and already have a massive value, this functionally just means martial law forces new pops to become soldiers instead of rulers or colonists.
Admins, Nobles, and High Priests have a -90% value if the pop is a resident. Those three are ALWAYS replaced by full citizens as soon as full citizen pops are available. Science Directors only have a -80%, and can therefore keep their jobs through sheer merit if they have enough traits that make them good researchers (like intelligent). Merchants/Executives have NO value penalty if they're residents, meaning they are effectively permanently a merchant until resettled, enslaved, purged, or the source of their merchant job is destroyed. It also means that when hiring a merchant, the game ignores citizenship (assuming they're not enslaved) unless all possible pops have exactly the same traits that make them good merchants. Only then does full citizenship get picked over residents for Merchant jobs.
This weight mechanic can sort of make it seem like some pops are unable to pick certain pops, but it's more likely that due to citizenship they're just not picked over Full Citizens.
I hope this helps clear up what you need to know.
EDIT: I almost forgot:
You mentioned your robots NOT being picked for alloys. This is not found anywhere in the code, so I suspect you either had robots (not droids) or Bio pops were constantly being picked for the job over the droids (which is almost guaranteed if they have the domestic protocols trait; even residence citizenship is more likely to be picked for that job than a droid with DP trait.)
I believe your robot pops have the Domestic Protocols trait, which explains your specific scenario of them refusing to be alloys workers, but they are entertainers. They CAN be alloy workers, but it's the LAST job they'll take.
EDIT2: Whoops, accidentally claimed "Enforcers" have a special check. They do not: they are normal specialist jobs.
EDIT3: Clarified how ruler job weights work.
Last edited: