Skip to content

Commit 55ed18c

Browse files
committed
docs: improve scientific format pricing
This commit ensures that people know how to use scientific format when setting prices.
1 parent c8166a7 commit 55ed18c

File tree

3 files changed

+4
-9
lines changed

3 files changed

+4
-9
lines changed

orchestrators/guides/get-started.mdx

+1-2
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,7 @@ livepeer \
9797

9898
- `-nvidia` is used to specify a comma delimited string of Nvidia GPU IDs. The
9999
flag is only required when transcoding with Nvidia GPUs
100-
- `-pricePerUnit` is used to specify the price (wei per pixel) for transcoding.
101-
The flag is required on startup, but the value can be changed later.
100+
- `-pricePerUnit` specifies the price for transcoding. It can be in wei per pixel (e.g., `1000`) or other currencies with exponential notation (e.g., `0.5e2USD`). This flag is required on startup but can be changed later.
102101
- `-serviceAddr` is used to specify the publicly accessible address that the
103102
orchestrator should receive requests at. Changing this requires a blockchain
104103
transaction, so it's preferable to use a hostname for a domain you own, not an

orchestrators/guides/set-pricing.mdx

+1-3
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,6 @@ You can set the base price per pixel using the `livepeer_cli`:
7272
7373
7. To verify the price was updated, check the log from your node.
7474
75-
76-
7775
# Setting fiat-denominated price
7876
7977
With the release of go-livepeer version 0.8.0, we are introducing a feature to allow specifying the transcoding price per pixel in USD. This is a backward-compatible change, which still supports setting the price in Wei but now gives the option of using custom currencies instead, with USD being the default.
@@ -102,7 +100,7 @@ e.g.:
102100
-pricePerUnit 0.0665USD
103101
```
104102
105-
Notice that the `-pixelsPerUnit` flag supports the exponential notation, so its easier to understand the value being set. The `-pricePerUnit` does not support it though, so a standard decimal notation must be used. This is also an incentive to use the `-pixelsPerUnit` value in order to keep the `-pricePerUnit` as an easily readable value.
103+
Notice that both the `-pixelsPerUnit` and `-pricePerUnit` flags support exponential notation, so it's easier to understand the value being set.
106104
107105
This feature is also supported by gateways, with the `-pixelsPerUnit` flag staying the same, while the `-maxPricePerUnit` should be set instead for the max price. The currency is specified in the same format.
108106

references/go-livepeer/cli-reference.mdx

+2-4
Original file line numberDiff line numberDiff line change
@@ -123,15 +123,13 @@ also contain instructions for using flags to enable certain functionality in
123123
- depositMultiplier: The deposit multiplier used to determine max acceptable
124124
faceValue for PM tickets. Default `1`
125125

126-
- pricePerUnit: The price per 'pixelsPerUnit' amount pixels. Must be greater
127-
than 0. Error if not set.
126+
- pricePerUnit: The price per 'pixelsPerUnit' amount pixels. Must be greater than 0. Can be specified in wei (e.g., `1000`) or other currencies with exponential notation (e.g., `0.5e2USD`). Error if not set.
128127

129128
- maxPricePerUnit: The maximum transcoding price (in wei) per 'pixelsPerUnit' a
130129
gateway is willing to accept. If not set explicitly, gateway is willing to
131130
accept ANY price. Default `0`
132131

133-
- pixelsPerUnit: Amount of pixels per unit. Set to '> 1' to have smaller price
134-
granularity than 1 wei / pixel. Default `1`
132+
- pixelsPerUnit: Amount of pixels per unit. Can be specified in scientific notation (e.g., `1e12`). Set to '> 1' to have smaller price granularity than 1 wei/pixel. Default `1`.
135133

136134
- pricePerGateway: json list of price per gateway or path to json config file.
137135
Example:

0 commit comments

Comments
 (0)