The AI caravan arrives with a list of 100 logs that it wants from you and offers a fixed quantity of goods. If it offer it one log then it will offer you only 1% of all the goods that it has on offer. If you offer 100 logs then you get to walk away with the entire caravan.
This is an overly clumsy way of trading. They need to re-evaluate all of their trading once they arrive and get an updated true list of what you own. Otherwise they would likely be giving themselves a bad deal for no good reason.
For instance, if the trade partner has more logs than they thought, and thus the partner values logs less than expected, then they would likely demand more logs than they expected to demand for the entire caravan.
Or if there are NO logs, then it would usually be dumb to just leave without trading, since in most cases, there's probably something else they have instead that you'd be still willing to trade for, just not quite as profitably as logs (depending on your whole network of other trade partners, etc. All of which get taken into account).
Basically, the moment your caravan arrives, you re-calculate your civilization's trade strategy, using the new information you just got updated with, and constrained to what you have on hand, and then make up new demand curves and THEN trade based on that.
For much less? Much less of what?
Value. It is an intangible equatable measurement that spans across all goods. It is what the Y axis basically measures in both supply and demand curves.
Value in dwarf fortress is measured in "dorfbucks" which does not correspond to any coins or anything in particular. It's just wanting something X versus Y amount.
If you do happen to have a currency, then you can map people's values to a certain amount of currency just to make it easier to talk about, but it's not necessary. The true measurement is just psychological value.
Cool as those ideas may be, I think the existing trade system is already time consuming enough and does need to be made worse. In my system the AI's demands, the list of items, each item's accepted minimum quality and the amount of each item that they will accept can be easily be neatly lined up say on top of the screen. On the left of the screen are the items that the AI is offering for sale and on the right of the screen are the items that you are offering to sell.
I agree with goblincookie here that for player-NPC trading, it would be really annoying and unnecessary to have the guy suggest random sets of things. That's not how people actually trade.
However, items don't just have fixed values either, as goblin is suggesting -- the value depends on the quantity being traded, so you can't have fixed advertised values. Instead, they dynamically update.
Let's say I want to sell logs for breastplates. On each side of the trade screen, I click a quantity of items that I'm proposing to buy and sell, respectively. It initially displays the price that it would be to add the first one of that item to your current deal.
As I click higher numbers of breastplates I want to buy, the "price" (measured in intangible dorfbucks) may or may not change for them, depending on the NPC's supply curve. If it does change, it will go up with higher numbers.
As I click higher numbers of logs, the price the NPC is willing to pay will go down (or not change), according to his demand curve.
At any point where the sum of prices is acceptable, you can hit trade and have it go through. (this doesn't reset the prices back. They continue to act dynamically as if it were all done in one trade. You can't trick them by just doing 10 small trades, obviously).
"Acceptable" means different things, depending on how much strategy we are coding in. If the NPC wants to buy friendliness from you, for instance, he might be willing to take a slight loss early in your relationship (for example if you are militarily much stronger than them).
In a zero strategy situation, "acceptable" would just mean "equal prices on both sides, or a better deal for him, only" is accepted.
One major reason for this is that governments are non-profit entitities, private entities pursue profits because they can hand these over to their owners and governments have no owners.
No, governments are for-profit as well in an economic sense. Everybody is always for-profit, there is no such thing as non-profit entities, except maybe literally insane or dumb people.
When you hear "not-for-profit" what it really means is "not for maximum capital dividends to shareholders" which is very different than "not for maximizing economic utility." Governments still want to maximize utility, but it's just that they have different values and utilities than a corporation does. For instance, a government places economic value on security of its citizens, often even if that comes at a currency deficit.
That doesn't mean that they aren't maximizing value profit. It just means that the non-currency value for them may outweight the role of currency value.