How are you planning on winning? You technically have enough land to win from here, but it would be a good idea to start planning ahead. In my opinion, you started with an early rush and have a lot of units left, so military victory is the natural progression from here.
Slavery here is correct. Production is much more important for the time being, and you need a lot more workers to improve the land you've got. You're working quite a bit of unimproved land, so whipping more workers would not only put your population to use but help you get back on track. There's also quite a bit of good land still left to settle, so you can whip some settlers too. Even if your plan is to go military, I would say your priority for now is to get at least one worker for each of your cities. The sooner you get your land in good shape, the more you will snowball when you start pumping out military, and you will need the workers to road up your land.
Go ahead and take the gold from tech trades. The AI is so backwards they're never going to keep up with you from this point on. It's better to get 20g for now instead of nothing for the rest of the game. It also helps your diplomacy because giving them discounts will give you up to +4 in relations. It may be kind of counterintuitive, but the faster the AI researches, the faster your research gets. The more techs the AI researches, the more they will be able to offer you, assuming you didn't research the exact same techs as them. Just try not to give them military techs unless you're even further ahead in military, or they're fighting someone you're going to try to take out soon.
Civil Service is really good, as it unlocks Bureaucracy, but to be honest, your capital isn't in very good shape, so it wouldn't benefit you a lot right away. You should finish cottaging up all the land around it and work cottages instead of scientists. You already got your academy, so the next great scientist goals, Philosophy and Education aren't as important at this moment. Bureaucracy is super expensive at this point in the game, as it's twice as expensive as a lot of the techs that you could really benefit from right now. Since you're already mostly done, you might as well finish, but the next games try to keep in mind that getting more cheaper techs sooner will help you more.
In particular at this point, you could have already researched something like Monarchy for Hereditary Rule civic, Metal Casting for forges, or Literature for Heroic and National Epic, and be benefiting from it immediately.
If you're going for war, you should go for Construction as soon as bureaucracy is finished so you can start building Catapults. Just glancing at what I can see right now, it might even be possible to win the game right now with just Horse Archers if you're focused on chopping and whipping your army, but catapults will make it a lot easier. Construction will also unlock War Elephants, which you will be able to get from that barb city you're about to take. You can definitely win with just War Elephants and catapults given the pitiful state of the AI.
Just a few notes on your cities. As a general observation, you need to improve your tiles, but building and whipping workers will cut down on the "waste" for now.
Your capital as I noted earlier is in bad shape. Caste system scientists is a cute trick, but I would recommend doing that in a city that *isn't* your capital, unless you have a lot of helper cities that can work cottages for you. Any city with a lot of food will do fine for great person production (Turfan seems like your best option here, as it has a lot of food and no hills or rivers, so it won't be a particularly great commerce or production city without the whip. You don't need to be in caste, just whip up a library and run the two scientists). If you're going science victory, you should start working cottages ASAP as there will be a lot of tech to finish. If you're going military, it's probably too late for cottages. It would be better to use all that food to whip up as much stuff as possible.
Karakorum doesn't need a lighthouse, as the water tiles aren't that useful at only 2 food, 2 commerce. It will be better to take advantage of all those grassy hills and the horse to really pump out units. I would build your Heroic Epic here.
In general, you don't need a lot of libraries now, as you don't have really strong commerce cities yet. More workers to improve your tiles will give you a greater payoff now. If going military, more units. It's hard to say exactly how much commerce you need for the library to be worth it, but even if you're focusing on research, building wealth is better than building a library up to a certain point, because it lets you run the slider at 100% longer. You want to find the right balance, and build the library just when it starts becoming worth it.
In the north, the most important improvement is actually the road to Agra. This will allow you to get trade routes to Gilgamesh for a pretty large boost in commerce. I'm not actually sure why you aren't getting trade routes to Hammurabi already to be honest, as you look definitely connected by coast to me...
On a side note, gifting AI's techs is perfectly acceptable because it gives you a diplomacy boost (up to +4). Even if you can't even get gold, it will help you get to "Friendly" relations with them, and you will be able to use your techs to bribe the AI into wars. If you can get them to at least "Pleased" you can usually bribe them into wars that you've already started (which may push you into friendly because of the extra bonus for being military partners). On higher difficulties "Friendly" is very important because the AI will start trading almost all of their techs with you, regardless of how many techs you traded for or how many other AI's have the tech.
You have this game in the bag. You should be able to play at a quicker pace and not worry about waiting for more help. Just try your best to stabilize your economy and then whip up an army of elephants as quickly as possible and a few catapults, and go ahead and share your progress if you want. My guess is you only need an initial stack of like 10 elephants and 4 catapults (maybe even less), and then constant reinforcements from there to roll through the AI. After that, you should play some games by yourself and work on applying what you've already learned, or come back with another game at a higher difficulty.