You ask a question to which there is no simple answer based on your requirements:
no python - this limits any automation and implies a lot of work
with anti aliasing - this is something cycles cannot do yet on masks
The anti-aliasing issue of ID masks (first render, second without, last with):
The perfect solution would be to render the scene with each ...
Here's how you do it:
Select all the objects you want to change
For the active object (last one selected), change the Pass Index to the Index ID you want.
Right click on the Pass Index field and select "Copy to Selected" from the menu
All the objects should now be updated to the same index ID.
Similar to @Carlo's answer you can set this up within a single blendfile (and within the same scene) by making use of the Render Layers 'material override' setting. Set up each object with a pass index relating to the type of material in use. For example, we could have :
0 = Black diffuse (obscures mask)
1 = Emissive (the thing we want the mask for)
2 = ...
I don't think it's possible to utilize material (or object) index behind a refractive material as it is.
Blender is correctly showing the mask of the object that form the camera point of view truly has the material assigned. The squared piece is made of glass, the fact that is somehow showing what's behind doesn't change the material which is made of.
You could use a 'binary encoding' technique to allow you to assign each object to a limited number of groups.
To achieve this, allocate each group a power of 2 :
Group 1 = 2^0 = 1
Group 2 = 2^1 = 2
Group 3 = 2^2 = 4
Group 4 = 2^3 = 8
Group 5 = 2^4 = 16
You can combine these 'groups' by simply adding them together :
Groups(1,3,4) = 1 + 4 + 8 = 13
This is pretty weird. I can think of three possible workarouds:
Render the eye as a separate object, then use Object Index.
Render the eye on a separate RenderLayer.
As the eye seems to be pretty much an emission material, you could separate the emission pass.
I don't think there is any decent way. That is why cryptomatte became "game changer" (with some issues as well, as you can see in your screen). You can play with edge in compositor, but it always brings some artefacts (inaccuracy) in final comp.
Short pixel "steps" can be disolved quite easily, but long pixel "steps" can't (as you can see on vertical edge). ...
I have posted answers both here and here related to finally getting rid of the nasty edge colors when using mattes and compositing, but would like to add to this post relating to the OP's question about edge anti-aliasing. If you use the methods described by vklidu, but also by this YouTube video by CG Cookie using Inpaint nodes and inverse masking etc, you ...
Each material can have it's own Pass Index set up in the Properties Window > Material > Settings > Pass Index
If you set them up correctly after rendering, using a Compositor you can use an ID Mask node to mask out each part of the image according to material.
It can be directly from the Render Layers node or from an Image node through a multi layer file ...