(CFACT-59) Add id and gid facts

Also, I'm fine with some reasonable static limit.