The dome lamp with keyless entry wire harness is likely different than the overhead console wire harness. I am not sure, as I have always sourced the overhead console and the matching wire harness from the same Cherokee.
The wire plugs on the console end of the overhead console wire harness are the same for all years 1997-2001.
The wire plugs on the fuse box end changed every year between 97 and 00. The number of wires, the wire colors, and the function of the wires are the same for all years of overhead console wire harness. You can locate the correct 1998 overhead console wire harness, or the correct 1998 wire plugs and re-pin them, use any generic male and female wire plugs and simply match up the wire colors, or you can skip the fuse box end wire plugs and just connect the wires directly to each other by color.