Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 4 5 [6] 7

Author Topic: Uristonomics: Dynamic Item Value  (Read 15835 times)

Scruiser

  • Bay Watcher
    • View Profile
Re: Uristonomics: Dynamic Item Value
« Reply #75 on: September 23, 2014, 09:07:34 am »

Hardcoding is specifically what this whole project is about getting away from...

What is the "inherent value" of a log, outside of it's practical usefulness (i.e. site needs) and one's personal preferences for it (happy thoughts)? Nothing, there isn't anything else left beyond those things. The remaining value is zero after that for everything, i.e. not actually a variable.

Gold is only valuable for people's personal preferences for it. Steel is only valuable for site needs for it if/when they are actually expecting war and need more armament or upgraded armament. Etc.
     Yeah, but you can consistently predict before any world-gen has happened that copper<iron<bronze<steel<admantine when it comes to edged weapons.  The actual price will change according to weapon production, which in turn changes according to the state of warfare, but the underlying "value" placed on it is constant.  For another example asethtically speaking, silver~gold~platinum but gold>iron and platinum>iron by most any standard of aesthetics.  You give gold/silver/platinum a higher underlying aesthetic value over iron, and then you let civ preferences and demand for weapons/armor versus demand for jewelry/artistic items the shape the demand for the metals.
  So yeah, I am saying some underlying values can be hard coded to help calculate utility in order to calculate demand which is then used to calculate a dynamic price.
Logged
Things I have never done in Dwarf Fortress;

- Won.

Dirst

  • Bay Watcher
  • [EASILY_DISTRA
    • View Profile
Re: Uristonomics: Dynamic Item Value
« Reply #76 on: September 23, 2014, 09:41:40 am »

Hardcoding is specifically what this whole project is about getting away from...

What is the "inherent value" of a log, outside of it's practical usefulness (i.e. site needs) and one's personal preferences for it (happy thoughts)? Nothing, there isn't anything else left beyond those things. The remaining value is zero after that for everything, i.e. not actually a variable.

Gold is only valuable for people's personal preferences for it. Steel is only valuable for site needs for it if/when they are actually expecting war and need more armament or upgraded armament. Etc.
     Yeah, but you can consistently predict before any world-gen has happened that copper<iron<bronze<steel<admantine when it comes to edged weapons.  The actual price will change according to weapon production, which in turn changes according to the state of warfare, but the underlying "value" placed on it is constant.  For another example asethtically speaking, silver~gold~platinum but gold>iron and platinum>iron by most any standard of aesthetics.  You give gold/silver/platinum a higher underlying aesthetic value over iron, and then you let civ preferences and demand for weapons/armor versus demand for jewelry/artistic items the shape the demand for the metals.
  So yeah, I am saying some underlying values can be hard coded to help calculate utility in order to calculate demand which is then used to calculate a dynamic price.
I think the algorithm might need a little help, since the game doesn't seem to understand material properties very well (certain civs just use certain metals because reasons).  I'd recommend these as starting points rather than fixed values, though.  Whether starting point ends up meaning "value in year 1" or "seed for the first round of optimization" depends on implementation details.
Logged
Just got back, updating:
(0.42 & 0.43) The Earth Strikes Back! v2.15 - Pay attention...  It's a mine!  It's-a not yours!
(0.42 & 0.43) Appearance Tweaks v1.03 - Tease those hippies about their pointy ears.
(0.42 & 0.43) Accessibility Utility v1.04 - Console tools to navigate the map

GavJ

  • Bay Watcher
    • View Profile
Re: Uristonomics: Dynamic Item Value
« Reply #77 on: September 23, 2014, 09:44:36 am »

Yes we can do that. We also can just hard code everything and have no economy at all. By doing nothing...

Why are you suddenly, randomly backpedaling and intending to do a half assed job of removing hard code? Gold isn't even slightly difficult -- we already have a preferences system in the game that already has to get folded into the dynamic economy. We don't need another redundant preferences system... especially not one that could easily piggyback on dynamics but then doesnt! All you have to do is make nearly all dwarves (but not all) like gold, etc.  To avoid spamminess, the character description would need to be tweaked, but not the algorithms.

Weapons are slightly more complicated, but not much. It would be sufficient to make their value based on a simple rock paper scissors sort of things, given their current situation of neighbors (potential enemies), enemies, and wildlife/zombies locally. Whatever their current intel is on those things, they place value on weapons that can beat them, and not any value on ones that won't (or very little value comparatively - resale value only pretty much). AND only if not already armed and stockpiled. But still needs to be entirely dynamic to make sense.

If you put inherent value in steel for edged weapons, then you get people infinitely buying steel weapons even when they need adamtine to beat their foes, not steel, and even when they already have steel for every dwarf and a stockpile on top of that, just because there's this magical hardcoded baseline value.  And other silliness. No no no. Again, avoiding that is the WHOLE POINT of the project.
Logged
Cauliflower Labs – Geologically realistic world generator devblog

Dwarf fortress in 50 words: You start with seven alcoholic, manic-depressive dwarves. You build a fortress in the wilderness where EVERYTHING tries to kill you, including your own dwarves. Usually, your chief imports are immigrants, beer, and optimism. Your chief exports are misery, limestone violins, forest fires, elf tallow soap, and carved kitten bone.

Scruiser

  • Bay Watcher
    • View Profile
Re: Uristonomics: Dynamic Item Value
« Reply #78 on: September 23, 2014, 11:12:00 am »

I think the algorithm might need a little help, since the game doesn't seem to understand material properties very well (certain civs just use certain metals because reasons).  I'd recommend these as starting points rather than fixed values, though.  Whether starting point ends up meaning "value in year 1" or "seed for the first round of optimization" depends on implementation details.
You use the RAW values as initializations/starting points for individual/site/civ AIs and the economic algorithms.   Dirst gets the direction I am coming from.

Weapons are slightly more complicated, but not much. It would be sufficient to make their value based on a simple rock paper scissors sort of things, given their current situation of neighbors (potential enemies), enemies, and wildlife/zombies locally. Whatever their current intel is on those things, they place value on weapons that can beat them, and not any value on ones that won't (or very little value comparatively - resale value only pretty much). AND only if not already armed and stockpiled. But still needs to be entirely dynamic to make sense.
    Theoretically, you could have the game procedurally work out the value of all the metals from basic realistic properties, but this would require a major materials rewrite and an entire AI for determining which metals are better for which weapons. 
    For weapons materials, right now, human players have to go through extensive arena testing just to get a general idea which metals are better for edged weapons, blunt weapons, and armor.  How do you expect Toady to program an entire AI to work this out when human players are still unsure on iron versus bronze for edged weapons?  The [VALUE_EDGED_WEAPONS:##] and [VALUE_BLUNT_WEAPONS:##] tokens would give the AI a starting place to work from.  These numeric values could be based on data collected by the players with arena testing.
    For jewelry/furniture, it you would need to add a whole list of properties if you want to procedurally work out the aesthetic value.  Luster, malleability, and resistance to corrosion are all major characteristics that make gold valuable for instance.  If you added material tokens for these properties then had world gen add in various cultural preferences then yeah, you could generate an entirely procedural value.  It would be easier in the short term though, to just have a VALUE_AESTHETIC token which acts as a place holder for properties like luster, malleability, resistance to corrosion, and other such properties.  The world gen civ preferences could still act as a modifier on top of this.

If you put inherent value in steel for edged weapons, then you get people infinitely buying steel weapons even when they need adamtine to beat their foes, not steel, and even when they already have steel for every dwarf and a stockpile on top of that, just because there's this magical hardcoded baseline value.  And other silliness. No no no. Again, avoiding that is the WHOLE POINT of the project.
Okay, now you are definitely  straw-manning me...
   To have the dwarfs determine that they need only adamantine for a decisive advantage is going to require an entire AI addition, that may or may not come before the economic rewrite.  Also, if the RAW values are set reasonably, then this case is exactly what it will help.  The RAW values will serve to let the AI know that adamantine>steel>iron when it comes to edged weapons.  Right now, the AI wouldn't even know not to use adamantine for blunt weapons, and to make its iron into steel whenever possible.  An entire AI to evaluate materials for weapons would be nice, but in the short term, RAW values could indicate to the AI which ones to prefer.
   Again, the baseline value serves as an initialization.  Even given that adamantine and steel are better for armor than bronze and copper, the AI and economic algorithms could determine that it needs its steel and adamantine for edged weapons. It then checks the next available materials and it determines that it should alloy its copper into bronze because bronze is more valuable for armor.
Logged
Things I have never done in Dwarf Fortress;

- Won.

GavJ

  • Bay Watcher
    • View Profile
Re: Uristonomics: Dynamic Item Value
« Reply #79 on: September 23, 2014, 11:24:17 am »

Quote
To have the dwarfs determine that they need only adamantine for a decisive advantage is going to require an entire AI addition, that may or may not come before the economic rewrite.  Also, if the RAW values are set reasonably, then this case is exactly what it will help.  The RAW values will serve to let the AI know that adamantine>steel>iron when it comes to edged weapons.  Right now, the AI wouldn't even know not to use adamantine for blunt weapons, and to make its iron into steel whenever possible.  An entire AI to evaluate materials for weapons would be nice, but in the short term, RAW values could indicate to the AI which ones to prefer.
So we don't have time to do an AI rewrite, and instead in the meantime, we should do an AI rewrite?

The proper version is about equally complicated as the raw system you're suggesting. It's really just filling out a table of "who wins in each instance?" for blunt, sharp, ammo, and armor versus each type. Then looking up the table based on a list of nearby threats. Use some simple rule to combine across threats (most threatening one drives it all, probably).

It's ~ a 2 hour coding project either way.

Quote
Theoretically, you could have the game procedurally work out the value of all the metals from basic realistic properties
No that's unnecessary. You can just tell it with hardcode which ones win in which fights (a table). Not a numeric value, just an inequality, that the civ uses to decide which one they need, and then just treat that one like any other need, and re-calculate every once in awhile (mainly, whenever you get new info updates about your neighbors and whether they exist and what armor they have)

Quote
For jewelry/furniture, it you would need to add a whole list of properties if you want to procedurally work out the aesthetic value.
What??

Urist likes gold.  Urista likes gold. Tom likes gold. ...etc.

That is all you need to do. This system already exists and already needs to be coded into the economy engine anyway. Why would metals have a weird, separate, detailed system when likeing puppies or whatever doesn't? Luster and malleability and stuff would be fine if there's time, but is by no means necessary.
Logged
Cauliflower Labs – Geologically realistic world generator devblog

Dwarf fortress in 50 words: You start with seven alcoholic, manic-depressive dwarves. You build a fortress in the wilderness where EVERYTHING tries to kill you, including your own dwarves. Usually, your chief imports are immigrants, beer, and optimism. Your chief exports are misery, limestone violins, forest fires, elf tallow soap, and carved kitten bone.

Scruiser

  • Bay Watcher
    • View Profile
Re: Uristonomics: Dynamic Item Value
« Reply #80 on: September 23, 2014, 11:40:41 am »

The proper version is about equally complicated as the raw system you're suggesting. It's really just filling out a table of "who wins in each instance?" for blunt, sharp, ammo, and armor versus each type. Then looking up the table based on a list of nearby threats. Use some simple rule to combine across threats (most threatening one drives it all, probably).

It's ~ a 2 hour coding project either way.
I get what you are saying now.  This sounds better than my idea in some ways, because then you could have your dwarf civ determine that it is fighting kobolds, and thus copper weapons and leather armor is sufficient.  It might be slightly trickier to maintain because each additional materials is an entire new row and an entire new column, but still doable.  There are still some cases it might have more or less issues with, let me think on it.

Quote
For jewelry/furniture, it you would need to add a whole list of properties if you want to procedurally work out the aesthetic value.
What??

Urist likes gold.  Urista likes gold. Tom likes gold. ...etc.

That is all you need to do. This system already exists and already needs to be coded into the economy engine anyway. Why would metals have a weird, separate, detailed system when likeing puppies or whatever doesn't? Luster and malleability and stuff would be fine if there's time, but is by no means necessary.
IRL, rarity definitely is a factor in gold's price, along with culture precedent.  Even so, it has a bunch of properties that make it valuable even without the cultural precedent.  Higher supplies would reduce the price, and thus it would be less of a luxury item, but people would still value it for its luster, malleability, and corrosion resistance.  Aluminium was really expensive and treated like a luxury until it was mass produced.  Now that it is mass produced, its price is less, but its light weight, malleability and corrosion resistance still make it fundamentally useful.  The demand curve is overall greater for its properties. 
Logged
Things I have never done in Dwarf Fortress;

- Won.

Dirst

  • Bay Watcher
  • [EASILY_DISTRA
    • View Profile
Re: Uristonomics: Dynamic Item Value
« Reply #81 on: September 23, 2014, 02:16:12 pm »

Reminds me of an exchange from Stargate SG-1.

Alien: "What is this?  It's divine!  I must have more!"
General Landry: "It's a rare delicacy called... chicken."
Logged
Just got back, updating:
(0.42 & 0.43) The Earth Strikes Back! v2.15 - Pay attention...  It's a mine!  It's-a not yours!
(0.42 & 0.43) Appearance Tweaks v1.03 - Tease those hippies about their pointy ears.
(0.42 & 0.43) Accessibility Utility v1.04 - Console tools to navigate the map

GoblinCookie

  • Bay Watcher
    • View Profile
Re: Uristonomics: Dynamic Item Value
« Reply #82 on: September 24, 2014, 08:56:37 am »

Okay, so you picture the caravan showing up with a strict shopping list.  Offering them anything not on their list would be of 0% value to them, which seems a bit weird.

It is not weird if you consider that you are not dealing directly with the administrators running the settlement but you are dealing with traders that do not have authorisation to spend what they are bringing to trade on anything but the shopping list. 

This is for a good reason too otherwise the people making a trade deals begin to usurp power from the people supposed to be running the settlement because they decide what is available based upon their own subjective preferences. 

Sorry, I don't see what in my post you are referring to.

I was asking a question about the fundermental problem with the concept of basing the economy on dynamic values rather than having dynamic values emerge from a system based upon something else that is fixed as in my model.

There is a trick used in economic modeling called a numéraire.  It is some tradeable good that has a fixed price, and everything else is priced relative to that.  The only items that MUST be present in the game are the 19 hard-coded materials including water, magma, and ash.  I think raw green glass would make a decent numéraire, and with an internal fixed price of 100 there would be plenty of range for prices while staying with integers.

(Edit: Note that the player doesn't need to see things in numéraire units.  Maybe at some point in time a silver coin can buy 8.7 chunks of raw green glass.  It would be simple to display all prices in "silver coins" by dividing the internal prices by 8.7.  Hell, you could even let the player choose the units. "The Overseer has decreed that our new unit of currency is the *obsidian bracelet*.  No, I don't know why.  By the way, does anybody have change for a +steel breastplate+?")

My system in relation to the human player is using labour as this essentially but not completely. 

This wasn't clear from your previous post, but I got that from what you said above.  I still think the inability to go "off-script" is unnecessarily limiting.

There is still communication going on.  You can inform the caravan precisely what it is you wish to offer them in future and what you demand that they are not giving you.  The word then gets around and there is not even any guarantee that you will actually end up getting the goods from the same party that you informed that you needed the goods. 

It just does not change anything immediately there and then. 

It can't be worse than the current system, because it gives you all the options you have now plus an additional "broker's suggestion" available to the player to take some of the tedium out of balancing out a thirty-seven item trade.

Your system would be intuitive if the caravan's shopping list is visible to the player, but it restricts trade to just what the caravan wants.  When it comes down to a choice of making the player happy or the caravan happy, it's better to side with the player.  For one thing, caravans never donate to Bay12! :)

This contributing player is rather annoyed by the way that the game produces a whole raft of utterly irrational trades and how you can concievably sell vast quanties of superabundant goods that noone would ever buy simply because the value of those goods is fixed. 

If this is not a problem then the Status Quo can simply be mantained and Toady One can get on with say actually giving siegers miners to dig through or having Legends mode invasions actually fail sometimes after World-Gen.

An actor is considered rational if it is maximizing an objective function.  For a firm, the objective function is profits.  For an individual, the objective function is utility (roughly DF's "happiness" metric plus some measure of wealth).  For a government, the ideal objective function is called "social welfare" which is the sum of all profits and utilities under that government's jurisdiction.  Real governments are not ideal, though up to this point we've been carrying around the idea of an ideal government as an implicit assumption.  By the way, real firms aren't ideal profit-maximizers either because the managers within them are maximizing their own utilities.

A site within DF is fairly close to an ideal government because the site basically owns all of the capital and employs all of the creatures.  This varies from a "firm" in that the site cares about individuals' utility as well.  We can model selfish nobles by overweighting their personal utility in the "social welfare" calculation, and to a lesser extent the utility of the noble's friends and family.  We'll get something a bit more nuanced than a production mandate and an export ban, which makes for a more interesting game.

That is the point.  The objective function of profits is unbounded and measured in a single value (money) but the objective function of social welfare is broken down into numerous competing but limited values. 

This means that in bartering the profit-making entity behaves differently and in a more destructive manner than a non-profit making entity.  For the profit-making entity 'objectively' surplus items always have a value, they will only reluctantly part with the minimum quantity of goods because those goods could instead be handed over (or their cash value) to the person or people who own the entity.  It does not actually matter if those people actually need or want the value, the whole thing is essentially a mechanical process.

I also like the idea of overweighting the demands of powerful individuals.  This is done easily in my model because people's demands are modified by profession (how capital/raw material demands are dealt with).  Powerful individuals (defined as anyone with a title) can demand goods normally found higher up the 'list' earlier. 

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.

Normally they demand more than logs GavJ.  They normally arrive with a whole list of items that they demand and they think you should have the ability to produce.  In my example for all they want is logs and all the items that they have brought are inherantly what they have already calculated they can 'afford' to spend on logs.

Afford in this context means that if they part with those goods they will not deprive themselves of their desired stockpile of that good.  Another complication is that they also seek to maximise quality, meaning that a lot of the time they will buy high quality goods and thus end up with stockpiles of basic low-quality goods that have been 'replaced. 

These goods could probably be acquired at a low 'price' because they are surplus goods available in great quantity relative to a relatively small quantity of high-quality goods, thus we have simply through programming the computer to seek the highest quality goods of a given level represented the difference in price between higher quality goods of the same function and lower quality without having to hard code it. 

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.

Dorfbucks are actually why the present economic system is both broken and unrealistic.  Because people will actually sell valuable goods for vast quantities of junk and at no point does each item or junk even lose a simply dwarfbuck of relative value. 

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.

The total Social Welfare value (read earlier post by Dirst) of the items is actually the sole fixed basis of my system, the exchange value of the items is dynamic.  Prices are not directly used at all, instead value % is what is used.  The value % is the total amount of labour that would be invested by the buyer (not the seller) in producing those goods out of the total of the goods on the 'shopping list'. Strictly speaking this is not necceserily fixed, but for the most part it would generally be once World Gen is complete. 

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.

That could be correct but only if you stretch the definition of profit to the point that it is meaningless.  What profit is generally understood to mean is the total amount that is earned by a selling party on top of the value of all goods and services being exchanged; that is what profit means in the game at the moment.

The shareholder thing is not an afterthought; the reason why a trading entity trades at a profit is because it has an owner entity that helps itself to the profits at the end of the day.  As I have already explained earlier, the process is essentially mechanical and it does not take into account whether the owner entity actually has any use for or actually places any value on the profits he recieved.

What happens if instead you are a communist utopia like a dwarf fortress settlement?  While we have both production, costs, finite capital and finite resources (including labour), profit now just means something that just rots on a stockpile; worse it actually takes up finite space and finite labour to haul.  This is because there are costs and profits; these are opposing things and if everything surplus to costs is worthless than trades between dwarf fortress societies will end up being conducted on as close to a zero-profit basis as possible.
Logged

GavJ

  • Bay Watcher
    • View Profile
Re: Uristonomics: Dynamic Item Value
« Reply #83 on: September 24, 2014, 09:37:47 am »

Quote
It is not weird if you consider that you are not dealing directly with the administrators running the settlement but you are dealing with traders that do not have authorisation to spend what they are bringing to trade on anything but the shopping list.
Competent administrators delegate. This would be extremely poor management.

Quote
Normally they demand more than logs GavJ.  They normally arrive with a whole list of items that they demand and they think you should have the ability to produce.  In my example for all they want is logs and all the items that they have brought are inherantly what they have already calculated they can 'afford' to spend on logs.
A calculation which is incorrect and needs to be updated with the new information

Quote
Dorfbucks are actually why the present economic system is both broken and unrealistic.  Because people will actually sell valuable goods for vast quantities of junk and at no point does each item or junk even lose a simply dwarfbuck of relative value.
The HARDCODED dorfbuck values are why it is borken in those ways. Not the existence of value, which would instead be dynamically assigned here.  Are you suggesting value is not a real thing.....

Quote
That could be correct but only if you stretch the definition of profit to the point that it is meaningless.  What profit is generally understood to mean is the total amount that is earned by a selling party on top of the value of all goods and services being exchanged; that is what profit means in the game at the moment.
Profit in classical economics is and has always been total utility. Including the money and its usefulness to you AND the rush you get AND the promises you fulfill to your constituents AND blah blah everything else you benefit from entirely, monetary or otherwise. That's not stretching anything. That's how economics works. it's not the study of exchange of money, it's the study of exchange of all value.
Logged
Cauliflower Labs – Geologically realistic world generator devblog

Dwarf fortress in 50 words: You start with seven alcoholic, manic-depressive dwarves. You build a fortress in the wilderness where EVERYTHING tries to kill you, including your own dwarves. Usually, your chief imports are immigrants, beer, and optimism. Your chief exports are misery, limestone violins, forest fires, elf tallow soap, and carved kitten bone.

Scruiser

  • Bay Watcher
    • View Profile
Re: Uristonomics: Dynamic Item Value
« Reply #84 on: September 24, 2014, 10:51:05 am »

Quote
Dorfbucks are actually why the present economic system is both broken and unrealistic.  Because people will actually sell valuable goods for vast quantities of junk and at no point does each item or junk even lose a simply dwarfbuck of relative value.
The HARDCODED dorfbuck values are why it is borken in those ways. Not the existence of value, which would instead be dynamically assigned here.  Are you suggesting value is not a real thing.....
I think we really need to distinguish value  and final market price.  It is the "price" in particular that needs to be dynamic in a way the fits with economics.  On the other hand, some of the major components of "value" can be determined in the RAWs (i.e. for a metal, its basic properties give it value). 
    To use the example of aluminium, it has high demand because of all of its good properties (light weight, resistant to corrosion, luster, methods of working it).  When it was rare, it was exceptionally expensive and valuable as a symbol of luxury, now that it is mass produced, it still has the same high demand curve, it is simply that the supply is greater that it costs less.  Gold should theoretically be the same way.  Its properties should give it a high demand curve.  At rare quantities, it is a symbol of wealth.  Were gold to hypothetically be super abundant (could happen in world gen) it would be like aluminum, and used for everything.
   I think the best way to model this (at least for materials used in goods valued for their appearance) would be to have either more material properties which the game uses to get an underlying aesthetic value, or to simply have a RAW token for aesthetic value.  This value then results in a higher demand curve overall (which can still change due to civ/site preferences and world gen events).  Demand curve and supply curve then determine actual final market price.
    For materials used in weapons and armor this is slightly trickier.  My proposal is to just have additional RAW tokens for value in edged weapons, blunt weapons, and armor.  This is simplistic and it extends the system of RAW token by category I proposed for materials used in aesthetic goods.  It does however have cases that it would be less than accurate.  GavJ has a more complicated but precise solution:
The proper version is about equally complicated as the raw system you're suggesting. It's really just filling out a table of "who wins in each instance?" for blunt, sharp, ammo, and armor versus each type. Then looking up the table based on a list of nearby threats. Use some simple rule to combine across threats (most threatening one drives it all, probably).

It's ~ a 2 hour coding project either way.
I get what you are saying now.  This sounds better than my idea in some ways, because then you could have your dwarf civ determine that it is fighting kobolds, and thus copper weapons and leather armor is sufficient.  It might be slightly trickier to maintain because each additional materials is an entire new row and an entire new column, but still doable.  There are still some cases it might have more or less issues with, let me think on it.
   Anyway, I thought some more on this.  For this to properly work (as in actually be better than my suggestion of value of categories), you need three table, or one table with three times as many rows as materials, because materials can be very different in blunt or edged weapons or ammo(extreme case: adamantine swords are very good because of its high strength and sharpness, adamantine hammer are extremely crappy, adamantine bolts are crappy because of light weight).  Rigid and flexible armor will also need two categories in cases were a material can be used in both (adamantine cloth versus adamantine chain mail versus adamantine breast plate, or leather clothes versus leather armor)   
   So you have a huge table, the columns are labeled by armor material, the rows by weapon/ammo material (iron in blunt weapons and iron in edged weapons would have two separate rows.)  A simple binary value would be insufficient, instead it would be some kind of rating.  Using a scale of 0-5, if rate the weapons against the armor, 0 might be for worthless (wooden edged weapons against any kind of decent armor), 1 really crappy, 3 moderate (decent weapon material against decent armor), 5 (adamantine swords against cloth clothes). 
  This still doesn't quite cover some weird edged cases that can occur in mods, like a race with no armor but skin naturally as strong as iron armor.  To make the table really complete, an entry for each civilized race naked in armor and in weapons would be needed (a naked dwarf can still punch, which would be 2-3 in effectiveness against cloth clothes, and 0 against steel armor)
   Anyway, once all this is in place it should be pretty straight forward for site and military AIs to make choices because they have all the information.  They compare what they are up against in weapon/armor materials, then try to do as best they can against it with the materials available.  Could lead to some interesting arms race scenarios.

If you half-ass the table, it won't really be much better than the value by category I proposed.  If the weapon and armor values are set so that they can be compared to each other, you get pretty much the same benefits as the table if it only had two or three values allowed.

Anyway the overall point I want to reemphasize is that "value" is separate from "price"  and "value" can be partly determined directly by RAWs and then used to dynamically determine price.
Logged
Things I have never done in Dwarf Fortress;

- Won.

GavJ

  • Bay Watcher
    • View Profile
Re: Uristonomics: Dynamic Item Value
« Reply #85 on: September 24, 2014, 11:42:52 am »

I'm not confusing value and price. I'm just disagreeing with you that value doesn't need to be dynamic. They BOTH need to be dynamic I think.

Price obviously does, I don't think anybody objects to that.

Value also does, though. Your aluminum example--it has certain properties than can make it useful, but ONLY if you need something with low weight, corrosion resistance, or whatever, or really like those properties. I'll step through your examples:

Corrosion resistance: There is no corrosion in DF, so this is meaningless. In real life, it is good, but even then still dynamically so, because it only matters if the metal already has other useful properties that make you want to make things out of it such that you need to consider corrosion.

Light weight: Useful for almost nothing in DF. In modern earth, we have airplanes, which MAKES this (situationally, dynamically) valuable. Prior to having airplanes and things, this feature didn't matter as much.

Luster: Unless you're making a really shitty mirror, this doesn't really have any utility. It might be aesthetically pleasing to some people, but that is a situational, dynamic thing based on each individual's personal preferences.

Rarity: This by itself only matters for value due to personal preference for owning "cool" rare things. It is similarly dynamic, therefore, based on individual preference (some people don't care if something is just rare in and of itself).

(All of the above things contribute some lesser value to everybody in the form of resale value. But this too is dynamic and situational: how much resale value depends on how many people have the utility or preference. And whether you care about resale value depends on having customers available to you to resell to. Some guy across the world you will never meet doesn't help you)




For metals in DF, what matters therefore is going to be:

1) Effectiveness in each main war category: sharp and blunt weapons, ammo, armor. You COULD get all hardcore about this and calculate actual tensile blah blah. Or you could just say "Rock beats scissors." Either way, value is totally dynamic, because it depends entirely on WHETHER you have neighbots who might fight you, and if you do, what equipment they have. Steel is almost worthless for instance, if iron will already beat your enemies 99 times out of 100. It being twice as sharp or whatever doesn't matter. It's relative, situational, dynamic.

2) Prettiness. The simplistic way of modeling this is just giving a bunch of dwarves preferences for metals. The probably more elegant way (and not necessarily even harder) would be to go ahead and add luster and maybe one or two other things to metals, and then allow dwarves to have  preferences for QUALITIES. So some dwarves enjoy lustrous things. Some dwarves maybe enjoy things that can hold an edge, etc. Compact and easy to understand, but still spans many metals at once in a sensical way and realistically accounts for the aesthetics of value.

That's about it. Note that neither one needs to be (or should be) hard coded with any numbers at all. Other than the physical properties (or shortcuts to them like a rock paper scissors table). Which are themselves not value, they're just properties.

After all, some weird dwarf might HATE lustrous things and have a value PENALTY on gold... <-- As an extreme illustration of how properties =/= value.


Quote
so you have a huge table...
Sorry, more specifically, I meant:

Table 1: all materials in rows, all materials in columns. Cells are either 1s and 0s or perhaps larger numbers for "how much better." The whole table is just something like "rows as ammunition, columns as armor" etc.

Table 2: Same, but rows as sharp weapons, columns as armor

Table 3: Same, but rows as blunt weapons, columns as armor

Table 4: [if we ever have weapons clashing with one another, then similar and such forth]

For races with exoskeletons and stuff? Just go ahead and include ALL body tissues used in the raws in the armor columns as well. Whatever. This is not important. The whole thing will take up so little RAM that you can basically throw whatever you want in there and not care. And as long as theyre organized in a logical way, it won't take any longer to search (you're just looking up by known index value)
« Last Edit: September 24, 2014, 11:44:23 am by GavJ »
Logged
Cauliflower Labs – Geologically realistic world generator devblog

Dwarf fortress in 50 words: You start with seven alcoholic, manic-depressive dwarves. You build a fortress in the wilderness where EVERYTHING tries to kill you, including your own dwarves. Usually, your chief imports are immigrants, beer, and optimism. Your chief exports are misery, limestone violins, forest fires, elf tallow soap, and carved kitten bone.

Dirst

  • Bay Watcher
  • [EASILY_DISTRA
    • View Profile
Re: Uristonomics: Dynamic Item Value
« Reply #86 on: September 24, 2014, 11:56:11 am »

First, what GavJ said.

I was asking a question about the fundermental problem with the concept of basing the economy on dynamic values rather than having dynamic values emerge from a system based upon something else that is fixed as in my model.
The fixed shopping lists are too limiting because (1) that's not how real long-distance trade has ever worked, and (2) human players are notoriously bad at doing what the AI would expect them to do.  You are basically telling the player to run his or her fort the way the AI would have run it, or be severely handicapped in trade.

Even if they AI eventually learns what to expect from a player fort, it's the early caravans that have a big impact on the game.

There is a trick used in economic modeling called a numéraire.  It is some tradeable good that has a fixed price, and everything else is priced relative to that.  The only items that MUST be present in the game are the 19 hard-coded materials including water, magma, and ash.  I think raw green glass would make a decent numéraire, and with an internal fixed price of 100 there would be plenty of range for prices while staying with integers.

(Edit: Note that the player doesn't need to see things in numéraire units.  Maybe at some point in time a silver coin can buy 8.7 chunks of raw green glass.  It would be simple to display all prices in "silver coins" by dividing the internal prices by 8.7.  Hell, you could even let the player choose the units. "The Overseer has decreed that our new unit of currency is the *obsidian bracelet*.  No, I don't know why.  By the way, does anybody have change for a +steel breastplate+?")

My system in relation to the human player is using labour as this essentially but not completely.
Labor is not completely fungible.  A master armorsmith's labor is more valuable than a novice armorsmith's, even if they both report the same profession in the unit list.  You could set the numéraire as the labor to perform one hauling job (this was the numéraire of the old "broken" DF economy), but (1) strength and distance affect how much time it takes to perform the job which muddies its value as a numéraire and (2) you'd still have to have a system of working out the relative value of other labors.

For NPC sites, we'd probably affix a certain amount of each labor to producing a product (rather than working out exactly how many steps the material needs to be hauled).  The AI will incorrectly assume the player fort has the same costs, but it should be close enough that the error is swamped by noble mandates and player whims.

This wasn't clear from your previous post, but I got that from what you said above.  I still think the inability to go "off-script" is unnecessarily limiting.

There is still communication going on.  You can inform the caravan precisely what it is you wish to offer them in future and what you demand that they are not giving you.  The word then gets around and there is not even any guarantee that you will actually end up getting the goods from the same party that you informed that you needed the goods. 

It just does not change anything immediately there and then.
This would limit the player's options in the first few caravans.  And the player will be severely penalized for being a little sluggish getting the metal industry growing (or whatever).
It can't be worse than the current system, because it gives you all the options you have now plus an additional "broker's suggestion" available to the player to take some of the tedium out of balancing out a thirty-seven item trade.

Your system would be intuitive if the caravan's shopping list is visible to the player, but it restricts trade to just what the caravan wants.  When it comes down to a choice of making the player happy or the caravan happy, it's better to side with the player.  For one thing, caravans never donate to Bay12! :)

This contributing player is rather annoyed by the way that the game produces a whole raft of utterly irrational trades and how you can concievably sell vast quanties of superabundant goods that noone would ever buy simply because the value of those goods is fixed. 

If this is not a problem then the Status Quo can simply be mantained and Toady One can get on with say actually giving siegers miners to dig through or having Legends mode invasions actually fail sometimes after World-Gen.
This is the whole point of dynamic value.  If you flood the market with crap crafts, the price will crash.  Moderately adaptive NPCs will smooth out any arbitrage weirdness, and if the player can corner the market on something (like, say, adamantine) the he or she will benefit.
An actor is considered rational if it is maximizing an objective function.  For a firm, the objective function is profits.  For an individual, the objective function is utility (roughly DF's "happiness" metric plus some measure of wealth).  For a government, the ideal objective function is called "social welfare" which is the sum of all profits and utilities under that government's jurisdiction.  Real governments are not ideal, though up to this point we've been carrying around the idea of an ideal government as an implicit assumption.  By the way, real firms aren't ideal profit-maximizers either because the managers within them are maximizing their own utilities.

A site within DF is fairly close to an ideal government because the site basically owns all of the capital and employs all of the creatures.  This varies from a "firm" in that the site cares about individuals' utility as well.  We can model selfish nobles by overweighting their personal utility in the "social welfare" calculation, and to a lesser extent the utility of the noble's friends and family.  We'll get something a bit more nuanced than a production mandate and an export ban, which makes for a more interesting game.

That is the point.  The objective function of profits is unbounded and measured in a single value (money) but the objective function of social welfare is broken down into numerous competing but limited values. 

This means that in bartering the profit-making entity behaves differently and in a more destructive manner than a non-profit making entity.  For the profit-making entity 'objectively' surplus items always have a value, they will only reluctantly part with the minimum quantity of goods because those goods could instead be handed over (or their cash value) to the person or people who own the entity.  It does not actually matter if those people actually need or want the value, the whole thing is essentially a mechanical process.

I also like the idea of overweighting the demands of powerful individuals.  This is done easily in my model because people's demands are modified by profession (how capital/raw material demands are dealt with).  Powerful individuals (defined as anyone with a title) can demand goods normally found higher up the 'list' earlier. 
GavJ already covered this, but it might make it easier if you think of the objective function measuring "payoffs" without attaching specific labels to what that payoff is.  Publicly-traded firms focus on monetary profits, but even they don't focus on money exclusively.
Normally they demand more than logs GavJ.  They normally arrive with a whole list of items that they demand and they think you should have the ability to produce.  In my example for all they want is logs and all the items that they have brought are inherantly what they have already calculated they can 'afford' to spend on logs.

Afford in this context means that if they part with those goods they will not deprive themselves of their desired stockpile of that good.  Another complication is that they also seek to maximise quality, meaning that a lot of the time they will buy high quality goods and thus end up with stockpiles of basic low-quality goods that have been 'replaced. 

These goods could probably be acquired at a low 'price' because they are surplus goods available in great quantity relative to a relatively small quantity of high-quality goods, thus we have simply through programming the computer to seek the highest quality goods of a given level represented the difference in price between higher quality goods of the same function and lower quality without having to hard code it. 
The system you are describing would work if communication was constant and trade was costless.  The transaction cost of sending a caravan is pretty high, so you'd want to fully inform a trusted broker and delegate trading to him or her.

That full information is represented by the demand curve.  It can answer questions like "Well, if they don't have logs or copper bars or iron bars or buckets or splints or the next seventeen items on our list, what would be the next best thing to get?"
The total Social Welfare value (read earlier post by Dirst) of the items is actually the sole fixed basis of my system, the exchange value of the items is dynamic.  Prices are not directly used at all, instead value % is what is used.  The value % is the total amount of labour that would be invested by the buyer (not the seller) in producing those goods out of the total of the goods on the 'shopping list'. Strictly speaking this is not necceserily fixed, but for the most part it would generally be once World Gen is complete. 
The underlying demand for a site is relatively fixed (at least until enough historical figures accumulate to cause some drifting from the mean), but how satiated those demands are changes radically over time.  The demand hypercurve represents what the actor wants next to make the best improvement in his or her payoff.  You can trace indifference curves along the demand hypercurve that represent different bundles of goods that would equally suitable to meet current demand ("I'd be equally happy with an anvil and a donkey, or six bronze daggers, or two +fire opal cushion-cut gems+, or ... ").  The existing system puts everything in a fixed scale of dorfbucks, but dynamic prices handle site needs more naturally.

Once everyone is fed, and clothed in their favorite color, and sleeping in private beds, trade would naturally swing toward the most "profitable" remaining goods such as pets.
That could be correct but only if you stretch the definition of profit to the point that it is meaningless.  What profit is generally understood to mean is the total amount that is earned by a selling party on top of the value of all goods and services being exchanged; that is what profit means in the game at the moment.
Again, try glossing in the word "payoff" which doesn't have the capitalist overtones.  "Payoff" is synonymous with "surplus," and by the way there is nothing to prevent that from being negative.  The rational actor faced with all negative possibilities is still maximizing, which means going for the smallest loss (as in the earlier example with liquidating excess inventory).
The shareholder thing is not an afterthought; the reason why a trading entity trades at a profit is because it has an owner entity that helps itself to the profits at the end of the day.  As I have already explained earlier, the process is essentially mechanical and it does not take into account whether the owner entity actually has any use for or actually places any value on the profits he recieved.
Firms do not disperse 100% of their profits as dividends.  Microsoft had no dividend whatsoever for the longest time because the largest shareholder (Bill Gates) felt the money was better spent as reinvestment in the company.
What happens if instead you are a communist utopia like a dwarf fortress settlement?  While we have both production, costs, finite capital and finite resources (including labour), profit now just means something that just rots on a stockpile; worse it actually takes up finite space and finite labour to haul.  This is because there are costs and profits; these are opposing things and if everything surplus to costs is worthless than trades between dwarf fortress societies will end up being conducted on as close to a zero-profit basis as possible.
The payoff/surplus for a commonwealth like a DF site incorporates the happiness of the citizens as part of the calculation.  Stuff is accumulated (and stockpiled for a rainy day) that meets the needs of the citizens, then what matches the preferences of the citizens, and finally what realizes the dreams of the citizens.  It would be incredibly odd for a single commodity to remain the best thing to buy, unit after unit and unit, as the site's wants change.  So no, this system will not lead to infinite stockpiling.  It will lead quite naturally to decadence (and then a megabeast attack).
Logged
Just got back, updating:
(0.42 & 0.43) The Earth Strikes Back! v2.15 - Pay attention...  It's a mine!  It's-a not yours!
(0.42 & 0.43) Appearance Tweaks v1.03 - Tease those hippies about their pointy ears.
(0.42 & 0.43) Accessibility Utility v1.04 - Console tools to navigate the map

Scruiser

  • Bay Watcher
    • View Profile
Re: Uristonomics: Dynamic Item Value
« Reply #87 on: September 25, 2014, 12:18:28 am »

The discussion has shifted some, but the OP topic is "Dynamic Item Value" so I will keep developing the ideas I had going for the last couple of posts, if it isn't bothering you all.

A few more comments about the weapons and armor material table:
The materials that can be used in both rigid and flexible armor columns rigid and flexible. 
There is a range between doesn't work at all and beats it, so just binary values wouldn't work that well.
Adding one new material that can be used in weapons and armor will require adding several rows and several, so it could get annoying to maintain for mods.

But overall, yeah it works and it would let the value dynamically vary.

A few more comments about materials used for prettiness:
A few qualities which civs/individuals can have preferences for would be useful in getting a meaningful dynamic value.  It seems unreasonable that worlds could exist were iron is randomly favored over gold in jewelry.  A few extra material property tokens should cover this.
The rest of prettiness "value" could emerge in world gen as a combination of cultural perception.  A rare metal with good properties develops a high price in the early world-gen history, which then adds an additional value to the metal as a symbol of wealth.  Then if the quantity of it increases, it still keeps that bonus value as a symbol for some time.  Like bronze medals.

So I guess my original idea of value categories would only be good as a placeholder.  The values by category in the RAWs could be used up until a more complete system for dynamically calculating underlying values is developed.  The dynamic calculations could then generate the value by category in game, allowing for reuse of the code that originally used the placeholder RAW defined value.

GoblinCookie, I agree with Dirst's comments on your post.  It seems like a lot of issues you bring up get solved if the in game economic system is modeled accurately after real world economics.

Anyway, I think we covered dynamic metal value pretty well, how do you guys think dynamic value of animals should be covered?
I think the quick and dirt way is value by category (PET_VALUE_WAR, PET_VALUE_HUNTING, PET_VALUE_DOMESTIC, for example).  But there is probably a more dynamic and procedural approach.  Maybe checks for egg laying *quantity, war trainable * size + bonus for natural attacks+innate skill level, use as a mount, milk generation * quantify, shearing * hair growth rate, hunting trainable * size + bonus for stealth.  World gen modifiers/bonuses for rarity and cultural preference also seem reasonable.  It seems like most of the key data is directly there in the RAWs, but how should the game get a good estimate of value from it?
Logged
Things I have never done in Dwarf Fortress;

- Won.

GavJ

  • Bay Watcher
    • View Profile
Re: Uristonomics: Dynamic Item Value
« Reply #88 on: September 25, 2014, 12:30:23 am »

animals are just ingredients and products in reactions, like pretty much anything else. They have cool-down timers, but so do lots of things, most notably labor.
Logged
Cauliflower Labs – Geologically realistic world generator devblog

Dwarf fortress in 50 words: You start with seven alcoholic, manic-depressive dwarves. You build a fortress in the wilderness where EVERYTHING tries to kill you, including your own dwarves. Usually, your chief imports are immigrants, beer, and optimism. Your chief exports are misery, limestone violins, forest fires, elf tallow soap, and carved kitten bone.

Scruiser

  • Bay Watcher
    • View Profile
Re: Uristonomics: Dynamic Item Value
« Reply #89 on: September 25, 2014, 08:59:13 am »

animals are just ingredients and products in reactions, like pretty much anything else. They have cool-down timers, but so do lots of things, most notably labor.
For slaughtering the animal for food, yes.
However for milk/egg production they are a form of capital used in food production.  For wool generation they are a form of capital used in cloth production (and other materials in mods).  For war and hunting they are in the same category as weapons and armor.  For pets, they are a source of happiness.
So there are multiple ways of valuing them which leads to multiple ways of pricing them.
Logged
Things I have never done in Dwarf Fortress;

- Won.
Pages: 1 ... 4 5 [6] 7