mirror of
https://github.com/bitcoinresearchkit/brk.git
synced 2026-06-22 12:23:04 -07:00
Compare commits
17 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| d24f3691cb | |||
| daaaa15483 | |||
| 041652d85d | |||
| 17570e12b8 | |||
| 78172734db | |||
| 19d4a193ff | |||
| 66680368b6 | |||
| b4ded21ea3 | |||
| 7412373d8a | |||
| 259960b80b | |||
| 18bb4186a8 | |||
| 6d3307c0df | |||
| 6eea20b89a | |||
| 5077cefda8 | |||
| 14d7adfdd5 | |||
| 000027fab8 | |||
| ade23795b8 |
Generated
+49
-49
@@ -338,7 +338,7 @@ checksum = "843867be96c8daad0d758b57df9392b6d8d271134fce549de6ce169ff98a92af"
|
||||
|
||||
[[package]]
|
||||
name = "brk"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"brk_bencher",
|
||||
"brk_bindgen",
|
||||
@@ -399,7 +399,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_alloc"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"libmimalloc-sys",
|
||||
"mimalloc",
|
||||
@@ -407,7 +407,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_bencher"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"brk_error",
|
||||
"brk_logger",
|
||||
@@ -417,14 +417,14 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_bencher_visualizer"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"plotters",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "brk_bindgen"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"brk_cohort",
|
||||
"brk_query",
|
||||
@@ -437,7 +437,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_cli"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"brk_alloc",
|
||||
@@ -463,7 +463,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_client"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"brk_cohort",
|
||||
"brk_types",
|
||||
@@ -474,7 +474,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_cohort"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"brk_error",
|
||||
"brk_traversable",
|
||||
@@ -486,7 +486,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_computer"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"bitcoin",
|
||||
"brk_alloc",
|
||||
@@ -517,7 +517,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_error"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"bitcoin",
|
||||
"bitcoincore-rpc",
|
||||
@@ -534,7 +534,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_fetcher"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"brk_error",
|
||||
"brk_logger",
|
||||
@@ -546,7 +546,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_indexer"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"bitcoin",
|
||||
"brk_alloc",
|
||||
@@ -573,7 +573,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_iterator"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"brk_error",
|
||||
"brk_reader",
|
||||
@@ -583,7 +583,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_logger"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"jiff",
|
||||
"owo-colors",
|
||||
@@ -594,7 +594,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_mempool"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"brk_error",
|
||||
"brk_logger",
|
||||
@@ -609,7 +609,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_oracle"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"brk_indexer",
|
||||
"brk_types",
|
||||
@@ -619,7 +619,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_query"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"bitcoin",
|
||||
"brk_computer",
|
||||
@@ -641,7 +641,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_reader"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"bitcoin",
|
||||
"brk_error",
|
||||
@@ -656,7 +656,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_rpc"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"bitcoin",
|
||||
"bitcoincore-rpc",
|
||||
@@ -673,7 +673,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_server"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"aide",
|
||||
"axum",
|
||||
@@ -708,7 +708,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_store"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"brk_error",
|
||||
"brk_types",
|
||||
@@ -719,7 +719,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_traversable"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"brk_traversable_derive",
|
||||
"brk_types",
|
||||
@@ -732,7 +732,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_traversable_derive"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
@@ -741,7 +741,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_types"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"bitcoin",
|
||||
"brk_error",
|
||||
@@ -764,7 +764,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "brk_website"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
dependencies = [
|
||||
"axum",
|
||||
"brk_logger",
|
||||
@@ -2045,9 +2045,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "libredox"
|
||||
version = "0.1.14"
|
||||
version = "0.1.15"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "1744e39d1d6a9948f4f388969627434e31128196de472883b39f148769bfe30a"
|
||||
checksum = "7ddbf48fd451246b1f8c2610bd3b4ac0cc6e149d89832867093ab69a17194f08"
|
||||
dependencies = [
|
||||
"libc",
|
||||
]
|
||||
@@ -2201,9 +2201,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "num-conv"
|
||||
version = "0.2.0"
|
||||
version = "0.2.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "cf97ec579c3c42f953ef76dbf8d55ac91fb219dde70e49aa4a6b7d74e9919050"
|
||||
checksum = "c6673768db2d862beb9b39a78fdcb1a69439615d5794a1be50caa9bc92c81967"
|
||||
|
||||
[[package]]
|
||||
name = "num-traits"
|
||||
@@ -2216,9 +2216,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "oas3"
|
||||
version = "0.20.1"
|
||||
version = "0.21.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "16f67c885c7b19aaf652e84102035258ecb4e0425a4f71037e187798e367bd87"
|
||||
checksum = "05ed0821ab10d7703415a06df039c2493f3a7667999d8b4e104731de0c53796f"
|
||||
dependencies = [
|
||||
"derive_more",
|
||||
"http",
|
||||
@@ -2545,9 +2545,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "rawdb"
|
||||
version = "0.7.2"
|
||||
version = "0.8.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "912a9c6f76a5f141057139d510b969b082ff74f39a72a1c27178d8e1eeec95dc"
|
||||
checksum = "3ebc4ac8e255d001f609b3d3002c7209e1668b9ab0aedf9a6a263e2e7e2c3cdb"
|
||||
dependencies = [
|
||||
"libc",
|
||||
"log",
|
||||
@@ -2916,9 +2916,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "serde_spanned"
|
||||
version = "1.0.4"
|
||||
version = "1.1.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "f8bbf91e5a4d6315eee45e704372590b30e260ee83af6639d64557f51b067776"
|
||||
checksum = "876ac351060d4f882bb1032b6369eb0aef79ad9df1ea8bc404874d8cc3d0cd98"
|
||||
dependencies = [
|
||||
"serde_core",
|
||||
]
|
||||
@@ -3182,9 +3182,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "toml"
|
||||
version = "1.0.7+spec-1.1.0"
|
||||
version = "1.1.0+spec-1.1.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "dd28d57d8a6f6e458bc0b8784f8fdcc4b99a437936056fa122cb234f18656a96"
|
||||
checksum = "f8195ca05e4eb728f4ba94f3e3291661320af739c4e43779cbdfae82ab239fcc"
|
||||
dependencies = [
|
||||
"indexmap",
|
||||
"serde_core",
|
||||
@@ -3197,27 +3197,27 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "toml_datetime"
|
||||
version = "1.0.1+spec-1.1.0"
|
||||
version = "1.1.0+spec-1.1.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "9b320e741db58cac564e26c607d3cc1fdc4a88fd36c879568c07856ed83ff3e9"
|
||||
checksum = "97251a7c317e03ad83774a8752a7e81fb6067740609f75ea2b585b569a59198f"
|
||||
dependencies = [
|
||||
"serde_core",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "toml_parser"
|
||||
version = "1.0.10+spec-1.1.0"
|
||||
version = "1.1.0+spec-1.1.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "7df25b4befd31c4816df190124375d5a20c6b6921e2cad937316de3fccd63420"
|
||||
checksum = "2334f11ee363607eb04df9b8fc8a13ca1715a72ba8662a26ac285c98aabb4011"
|
||||
dependencies = [
|
||||
"winnow",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "toml_writer"
|
||||
version = "1.0.7+spec-1.1.0"
|
||||
version = "1.1.0+spec-1.1.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "f17aaa1c6e3dc22b1da4b6bba97d066e354c7945cac2f7852d4e4e7ca7a6b56d"
|
||||
checksum = "d282ade6016312faf3e41e57ebbba0c073e4056dab1232ab1cb624199648f8ed"
|
||||
|
||||
[[package]]
|
||||
name = "tower"
|
||||
@@ -3352,9 +3352,9 @@ checksum = "e6e4313cd5fcd3dad5cafa179702e2b244f760991f45397d14d4ebf38247da75"
|
||||
|
||||
[[package]]
|
||||
name = "unicode-segmentation"
|
||||
version = "1.12.0"
|
||||
version = "1.13.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "f6ccf251212114b54433ec949fd6a7841275f9ada20dddd2f29e9ceea4501493"
|
||||
checksum = "9629274872b2bfaf8d66f5f15725007f635594914870f65218920345aa11aa8c"
|
||||
|
||||
[[package]]
|
||||
name = "unicode-xid"
|
||||
@@ -3439,9 +3439,9 @@ checksum = "8f54a172d0620933a27a4360d3db3e2ae0dd6cceae9730751a036bbf182c4b23"
|
||||
|
||||
[[package]]
|
||||
name = "vecdb"
|
||||
version = "0.7.2"
|
||||
version = "0.8.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "d6f89be182f86511ee28832cc04039d818564b88c63b14093fcf1871c732c0dd"
|
||||
checksum = "68e0237a44ee8ea6692e815154cc477a8c1936b27dca79bb1b9e093fa55e04a2"
|
||||
dependencies = [
|
||||
"itoa",
|
||||
"libc",
|
||||
@@ -3462,9 +3462,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "vecdb_derive"
|
||||
version = "0.7.2"
|
||||
version = "0.8.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "42915a5ca404d941e3e6d024f794403c481e5aeb96b1867d12d1f1e972d1433f"
|
||||
checksum = "1fef159303d1f54cbb08b8249da70a9e1573145074949a91e9072addde209d65"
|
||||
dependencies = [
|
||||
"quote",
|
||||
"syn",
|
||||
|
||||
+25
-25
@@ -4,7 +4,7 @@ members = ["crates/*"]
|
||||
package.description = "The Bitcoin Research Kit is a suite of tools designed to extract, compute and display data stored on a Bitcoin Core node"
|
||||
package.license = "MIT"
|
||||
package.edition = "2024"
|
||||
package.version = "0.2.1"
|
||||
package.version = "0.2.4"
|
||||
package.homepage = "https://bitcoinresearchkit.org"
|
||||
package.repository = "https://github.com/bitcoinresearchkit/brk"
|
||||
package.readme = "README.md"
|
||||
@@ -40,29 +40,29 @@ aide = { version = "0.16.0-alpha.3", features = ["axum-json", "axum-query"] }
|
||||
axum = { version = "0.8.8", default-features = false, features = ["http1", "json", "query", "tokio", "tracing"] }
|
||||
bitcoin = { version = "0.32.8", features = ["serde"] }
|
||||
bitcoincore-rpc = "0.19.0"
|
||||
brk_alloc = { version = "0.2.1", path = "crates/brk_alloc" }
|
||||
brk_bencher = { version = "0.2.1", path = "crates/brk_bencher" }
|
||||
brk_bindgen = { version = "0.2.1", path = "crates/brk_bindgen" }
|
||||
brk_cli = { version = "0.2.1", path = "crates/brk_cli" }
|
||||
brk_client = { version = "0.2.1", path = "crates/brk_client" }
|
||||
brk_cohort = { version = "0.2.1", path = "crates/brk_cohort" }
|
||||
brk_computer = { version = "0.2.1", path = "crates/brk_computer" }
|
||||
brk_error = { version = "0.2.1", path = "crates/brk_error" }
|
||||
brk_fetcher = { version = "0.2.1", path = "crates/brk_fetcher" }
|
||||
brk_indexer = { version = "0.2.1", path = "crates/brk_indexer" }
|
||||
brk_iterator = { version = "0.2.1", path = "crates/brk_iterator" }
|
||||
brk_logger = { version = "0.2.1", path = "crates/brk_logger" }
|
||||
brk_mempool = { version = "0.2.1", path = "crates/brk_mempool" }
|
||||
brk_oracle = { version = "0.2.1", path = "crates/brk_oracle" }
|
||||
brk_query = { version = "0.2.1", path = "crates/brk_query", features = ["tokio"] }
|
||||
brk_reader = { version = "0.2.1", path = "crates/brk_reader" }
|
||||
brk_rpc = { version = "0.2.1", path = "crates/brk_rpc" }
|
||||
brk_server = { version = "0.2.1", path = "crates/brk_server" }
|
||||
brk_store = { version = "0.2.1", path = "crates/brk_store" }
|
||||
brk_traversable = { version = "0.2.1", path = "crates/brk_traversable", features = ["pco", "derive"] }
|
||||
brk_traversable_derive = { version = "0.2.1", path = "crates/brk_traversable_derive" }
|
||||
brk_types = { version = "0.2.1", path = "crates/brk_types" }
|
||||
brk_website = { version = "0.2.1", path = "crates/brk_website" }
|
||||
brk_alloc = { version = "0.2.4", path = "crates/brk_alloc" }
|
||||
brk_bencher = { version = "0.2.4", path = "crates/brk_bencher" }
|
||||
brk_bindgen = { version = "0.2.4", path = "crates/brk_bindgen" }
|
||||
brk_cli = { version = "0.2.4", path = "crates/brk_cli" }
|
||||
brk_client = { version = "0.2.4", path = "crates/brk_client" }
|
||||
brk_cohort = { version = "0.2.4", path = "crates/brk_cohort" }
|
||||
brk_computer = { version = "0.2.4", path = "crates/brk_computer" }
|
||||
brk_error = { version = "0.2.4", path = "crates/brk_error" }
|
||||
brk_fetcher = { version = "0.2.4", path = "crates/brk_fetcher" }
|
||||
brk_indexer = { version = "0.2.4", path = "crates/brk_indexer" }
|
||||
brk_iterator = { version = "0.2.4", path = "crates/brk_iterator" }
|
||||
brk_logger = { version = "0.2.4", path = "crates/brk_logger" }
|
||||
brk_mempool = { version = "0.2.4", path = "crates/brk_mempool" }
|
||||
brk_oracle = { version = "0.2.4", path = "crates/brk_oracle" }
|
||||
brk_query = { version = "0.2.4", path = "crates/brk_query", features = ["tokio"] }
|
||||
brk_reader = { version = "0.2.4", path = "crates/brk_reader" }
|
||||
brk_rpc = { version = "0.2.4", path = "crates/brk_rpc" }
|
||||
brk_server = { version = "0.2.4", path = "crates/brk_server" }
|
||||
brk_store = { version = "0.2.4", path = "crates/brk_store" }
|
||||
brk_traversable = { version = "0.2.4", path = "crates/brk_traversable", features = ["pco", "derive"] }
|
||||
brk_traversable_derive = { version = "0.2.4", path = "crates/brk_traversable_derive" }
|
||||
brk_types = { version = "0.2.4", path = "crates/brk_types" }
|
||||
brk_website = { version = "0.2.4", path = "crates/brk_website" }
|
||||
byteview = "0.10.1"
|
||||
color-eyre = "0.6.5"
|
||||
corepc-client = { package = "brk-corepc-client", version = "0.11.0", features = ["client-sync"] }
|
||||
@@ -87,7 +87,7 @@ tower-http = { version = "0.6.8", features = ["catch-panic", "compression-br", "
|
||||
tower-layer = "0.3"
|
||||
tracing = { version = "0.1", default-features = false, features = ["std"] }
|
||||
ureq = { version = "3.3.0", features = ["json"] }
|
||||
vecdb = { version = "0.7.2", features = ["derive", "serde_json", "pco", "schemars"] }
|
||||
vecdb = { version = "0.8.0", features = ["derive", "serde_json", "pco", "schemars"] }
|
||||
# vecdb = { path = "../anydb/crates/vecdb", features = ["derive", "serde_json", "pco", "schemars"] }
|
||||
|
||||
[workspace.metadata.release]
|
||||
|
||||
@@ -12,6 +12,6 @@ brk_cohort = { workspace = true }
|
||||
brk_query = { workspace = true }
|
||||
brk_types = { workspace = true }
|
||||
indexmap = { workspace = true }
|
||||
oas3 = "0.20"
|
||||
oas3 = "0.21"
|
||||
serde = { workspace = true }
|
||||
serde_json = { workspace = true }
|
||||
|
||||
@@ -26,7 +26,7 @@ owo-colors = { workspace = true }
|
||||
tracing = { workspace = true }
|
||||
serde = { workspace = true }
|
||||
tokio = { workspace = true }
|
||||
toml = "1.0.7"
|
||||
toml = "1.1.0"
|
||||
vecdb = { workspace = true }
|
||||
|
||||
[[bin]]
|
||||
|
||||
+289
-239
@@ -1247,7 +1247,7 @@ impl GrossInvestedInvestorLossNetNuplProfitSentimentPattern2 {
|
||||
pub struct BpsCentsPercentilesRatioSatsSmaStdUsdPattern {
|
||||
pub bps: SeriesPattern1<BasisPoints32>,
|
||||
pub cents: SeriesPattern1<Cents>,
|
||||
pub percentiles: Pct1Pct2Pct5Pct95Pct98Pct99Pattern,
|
||||
pub percentiles: Pct0Pct1Pct2Pct5Pct95Pct98Pct99Pattern,
|
||||
pub ratio: SeriesPattern1<StoredF32>,
|
||||
pub sats: SeriesPattern1<SatsFract>,
|
||||
pub sma: _1m1w1y2y4yAllPattern,
|
||||
@@ -1255,6 +1255,34 @@ pub struct BpsCentsPercentilesRatioSatsSmaStdUsdPattern {
|
||||
pub usd: SeriesPattern1<Dollars>,
|
||||
}
|
||||
|
||||
/// Pattern struct for repeated tree structure.
|
||||
pub struct Pct0Pct1Pct2Pct5Pct95Pct98Pct99Pattern {
|
||||
pub pct0_5: BpsPriceRatioPattern,
|
||||
pub pct1: BpsPriceRatioPattern,
|
||||
pub pct2: BpsPriceRatioPattern,
|
||||
pub pct5: BpsPriceRatioPattern,
|
||||
pub pct95: BpsPriceRatioPattern,
|
||||
pub pct98: BpsPriceRatioPattern,
|
||||
pub pct99: BpsPriceRatioPattern,
|
||||
pub pct99_5: BpsPriceRatioPattern,
|
||||
}
|
||||
|
||||
impl Pct0Pct1Pct2Pct5Pct95Pct98Pct99Pattern {
|
||||
/// Create a new pattern node with accumulated series name.
|
||||
pub fn new(client: Arc<BrkClientBase>, acc: String) -> Self {
|
||||
Self {
|
||||
pct0_5: BpsPriceRatioPattern::new(client.clone(), acc.clone(), "pct0_5".to_string()),
|
||||
pct1: BpsPriceRatioPattern::new(client.clone(), acc.clone(), "pct1".to_string()),
|
||||
pct2: BpsPriceRatioPattern::new(client.clone(), acc.clone(), "pct2".to_string()),
|
||||
pct5: BpsPriceRatioPattern::new(client.clone(), acc.clone(), "pct5".to_string()),
|
||||
pct95: BpsPriceRatioPattern::new(client.clone(), acc.clone(), "pct95".to_string()),
|
||||
pct98: BpsPriceRatioPattern::new(client.clone(), acc.clone(), "pct98".to_string()),
|
||||
pct99: BpsPriceRatioPattern::new(client.clone(), acc.clone(), "pct99".to_string()),
|
||||
pct99_5: BpsPriceRatioPattern::new(client.clone(), acc.clone(), "pct99_5".to_string()),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Pattern struct for repeated tree structure.
|
||||
pub struct _10y2y3y4y5y6y8yPattern {
|
||||
pub _10y: BpsPercentRatioPattern,
|
||||
@@ -1487,7 +1515,7 @@ impl AverageBlockCumulativeInSumPattern {
|
||||
pub struct BpsCentsPercentilesRatioSatsUsdPattern {
|
||||
pub bps: SeriesPattern1<BasisPoints32>,
|
||||
pub cents: SeriesPattern1<Cents>,
|
||||
pub percentiles: Pct1Pct2Pct5Pct95Pct98Pct99Pattern,
|
||||
pub percentiles: Pct0Pct1Pct2Pct5Pct95Pct98Pct99Pattern,
|
||||
pub ratio: SeriesPattern1<StoredF32>,
|
||||
pub sats: SeriesPattern1<SatsFract>,
|
||||
pub usd: SeriesPattern1<Dollars>,
|
||||
@@ -1499,7 +1527,7 @@ impl BpsCentsPercentilesRatioSatsUsdPattern {
|
||||
Self {
|
||||
bps: SeriesPattern1::new(client.clone(), _m(&acc, "ratio_bps")),
|
||||
cents: SeriesPattern1::new(client.clone(), _m(&acc, "cents")),
|
||||
percentiles: Pct1Pct2Pct5Pct95Pct98Pct99Pattern::new(client.clone(), acc.clone()),
|
||||
percentiles: Pct0Pct1Pct2Pct5Pct95Pct98Pct99Pattern::new(client.clone(), acc.clone()),
|
||||
ratio: SeriesPattern1::new(client.clone(), _m(&acc, "ratio")),
|
||||
sats: SeriesPattern1::new(client.clone(), _m(&acc, "sats")),
|
||||
usd: SeriesPattern1::new(client.clone(), acc.clone()),
|
||||
@@ -1603,30 +1631,6 @@ impl DeltaHalfInToTotalPattern2 {
|
||||
}
|
||||
}
|
||||
|
||||
/// Pattern struct for repeated tree structure.
|
||||
pub struct Pct1Pct2Pct5Pct95Pct98Pct99Pattern {
|
||||
pub pct1: BpsPriceRatioPattern,
|
||||
pub pct2: BpsPriceRatioPattern,
|
||||
pub pct5: BpsPriceRatioPattern,
|
||||
pub pct95: BpsPriceRatioPattern,
|
||||
pub pct98: BpsPriceRatioPattern,
|
||||
pub pct99: BpsPriceRatioPattern,
|
||||
}
|
||||
|
||||
impl Pct1Pct2Pct5Pct95Pct98Pct99Pattern {
|
||||
/// Create a new pattern node with accumulated series name.
|
||||
pub fn new(client: Arc<BrkClientBase>, acc: String) -> Self {
|
||||
Self {
|
||||
pct1: BpsPriceRatioPattern::new(client.clone(), acc.clone(), "pct1".to_string()),
|
||||
pct2: BpsPriceRatioPattern::new(client.clone(), acc.clone(), "pct2".to_string()),
|
||||
pct5: BpsPriceRatioPattern::new(client.clone(), acc.clone(), "pct5".to_string()),
|
||||
pct95: BpsPriceRatioPattern::new(client.clone(), acc.clone(), "pct95".to_string()),
|
||||
pct98: BpsPriceRatioPattern::new(client.clone(), acc.clone(), "pct98".to_string()),
|
||||
pct99: BpsPriceRatioPattern::new(client.clone(), acc.clone(), "pct99".to_string()),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Pattern struct for repeated tree structure.
|
||||
pub struct _1m1w1y24hBlockPattern {
|
||||
pub _1m: SeriesPattern1<StoredF32>,
|
||||
@@ -3126,6 +3130,7 @@ pub struct SeriesTree {
|
||||
pub constants: SeriesTree_Constants,
|
||||
pub indexes: SeriesTree_Indexes,
|
||||
pub indicators: SeriesTree_Indicators,
|
||||
pub investing: SeriesTree_Investing,
|
||||
pub market: SeriesTree_Market,
|
||||
pub pools: SeriesTree_Pools,
|
||||
pub prices: SeriesTree_Prices,
|
||||
@@ -3148,6 +3153,7 @@ impl SeriesTree {
|
||||
constants: SeriesTree_Constants::new(client.clone(), format!("{base_path}_constants")),
|
||||
indexes: SeriesTree_Indexes::new(client.clone(), format!("{base_path}_indexes")),
|
||||
indicators: SeriesTree_Indicators::new(client.clone(), format!("{base_path}_indicators")),
|
||||
investing: SeriesTree_Investing::new(client.clone(), format!("{base_path}_investing")),
|
||||
market: SeriesTree_Market::new(client.clone(), format!("{base_path}_market")),
|
||||
pools: SeriesTree_Pools::new(client.clone(), format!("{base_path}_pools")),
|
||||
prices: SeriesTree_Prices::new(client.clone(), format!("{base_path}_prices")),
|
||||
@@ -3215,17 +3221,13 @@ impl SeriesTree_Blocks_Difficulty {
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Blocks_Time {
|
||||
pub timestamp: SeriesPattern1<Timestamp>,
|
||||
pub date: SeriesPattern18<Date>,
|
||||
pub timestamp_monotonic: SeriesPattern18<Timestamp>,
|
||||
pub timestamp: SeriesPattern18<Timestamp>,
|
||||
}
|
||||
|
||||
impl SeriesTree_Blocks_Time {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
timestamp: SeriesPattern1::new(client.clone(), "timestamp".to_string()),
|
||||
date: SeriesPattern18::new(client.clone(), "date".to_string()),
|
||||
timestamp_monotonic: SeriesPattern18::new(client.clone(), "timestamp_monotonic".to_string()),
|
||||
timestamp: SeriesPattern18::new(client.clone(), "timestamp".to_string()),
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -4562,6 +4564,7 @@ pub struct SeriesTree_Indexes {
|
||||
pub tx_index: SeriesTree_Indexes_TxIndex,
|
||||
pub txin_index: SeriesTree_Indexes_TxinIndex,
|
||||
pub txout_index: SeriesTree_Indexes_TxoutIndex,
|
||||
pub timestamp: SeriesTree_Indexes_Timestamp,
|
||||
}
|
||||
|
||||
impl SeriesTree_Indexes {
|
||||
@@ -4587,6 +4590,7 @@ impl SeriesTree_Indexes {
|
||||
tx_index: SeriesTree_Indexes_TxIndex::new(client.clone(), format!("{base_path}_tx_index")),
|
||||
txin_index: SeriesTree_Indexes_TxinIndex::new(client.clone(), format!("{base_path}_txin_index")),
|
||||
txout_index: SeriesTree_Indexes_TxoutIndex::new(client.clone(), format!("{base_path}_txout_index")),
|
||||
timestamp: SeriesTree_Indexes_Timestamp::new(client.clone(), format!("{base_path}_timestamp")),
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -5129,6 +5133,21 @@ impl SeriesTree_Indexes_TxoutIndex {
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Indexes_Timestamp {
|
||||
pub monotonic: SeriesPattern18<Timestamp>,
|
||||
pub resolutions: SeriesPattern2<Timestamp>,
|
||||
}
|
||||
|
||||
impl SeriesTree_Indexes_Timestamp {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
monotonic: SeriesPattern18::new(client.clone(), "timestamp_monotonic".to_string()),
|
||||
resolutions: SeriesPattern2::new(client.clone(), "timestamp".to_string()),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Indicators {
|
||||
pub puell_multiple: BpsRatioPattern2,
|
||||
@@ -5141,6 +5160,7 @@ pub struct SeriesTree_Indicators {
|
||||
pub dormancy: SeriesTree_Indicators_Dormancy,
|
||||
pub stock_to_flow: SeriesPattern1<StoredF32>,
|
||||
pub seller_exhaustion: SeriesPattern1<StoredF32>,
|
||||
pub realized_envelope: SeriesTree_Indicators_RealizedEnvelope,
|
||||
}
|
||||
|
||||
impl SeriesTree_Indicators {
|
||||
@@ -5156,6 +5176,7 @@ impl SeriesTree_Indicators {
|
||||
dormancy: SeriesTree_Indicators_Dormancy::new(client.clone(), format!("{base_path}_dormancy")),
|
||||
stock_to_flow: SeriesPattern1::new(client.clone(), "stock_to_flow".to_string()),
|
||||
seller_exhaustion: SeriesPattern1::new(client.clone(), "seller_exhaustion".to_string()),
|
||||
realized_envelope: SeriesTree_Indicators_RealizedEnvelope::new(client.clone(), format!("{base_path}_realized_envelope")),
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -5175,6 +5196,234 @@ impl SeriesTree_Indicators_Dormancy {
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Indicators_RealizedEnvelope {
|
||||
pub pct0_5: CentsSatsUsdPattern,
|
||||
pub pct1: CentsSatsUsdPattern,
|
||||
pub pct2: CentsSatsUsdPattern,
|
||||
pub pct5: CentsSatsUsdPattern,
|
||||
pub pct95: CentsSatsUsdPattern,
|
||||
pub pct98: CentsSatsUsdPattern,
|
||||
pub pct99: CentsSatsUsdPattern,
|
||||
pub pct99_5: CentsSatsUsdPattern,
|
||||
pub index: SeriesPattern1<StoredI8>,
|
||||
pub score: SeriesPattern1<StoredI8>,
|
||||
}
|
||||
|
||||
impl SeriesTree_Indicators_RealizedEnvelope {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
pct0_5: CentsSatsUsdPattern::new(client.clone(), "realized_envelope_pct0_5".to_string()),
|
||||
pct1: CentsSatsUsdPattern::new(client.clone(), "realized_envelope_pct01".to_string()),
|
||||
pct2: CentsSatsUsdPattern::new(client.clone(), "realized_envelope_pct02".to_string()),
|
||||
pct5: CentsSatsUsdPattern::new(client.clone(), "realized_envelope_pct05".to_string()),
|
||||
pct95: CentsSatsUsdPattern::new(client.clone(), "realized_envelope_pct95".to_string()),
|
||||
pct98: CentsSatsUsdPattern::new(client.clone(), "realized_envelope_pct98".to_string()),
|
||||
pct99: CentsSatsUsdPattern::new(client.clone(), "realized_envelope_pct99".to_string()),
|
||||
pct99_5: CentsSatsUsdPattern::new(client.clone(), "realized_envelope_pct99_5".to_string()),
|
||||
index: SeriesPattern1::new(client.clone(), "realized_envelope_index".to_string()),
|
||||
score: SeriesPattern1::new(client.clone(), "realized_envelope_score".to_string()),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Investing {
|
||||
pub sats_per_day: SeriesPattern18<Sats>,
|
||||
pub period: SeriesTree_Investing_Period,
|
||||
pub class: SeriesTree_Investing_Class,
|
||||
}
|
||||
|
||||
impl SeriesTree_Investing {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
sats_per_day: SeriesPattern18::new(client.clone(), "dca_sats_per_day".to_string()),
|
||||
period: SeriesTree_Investing_Period::new(client.clone(), format!("{base_path}_period")),
|
||||
class: SeriesTree_Investing_Class::new(client.clone(), format!("{base_path}_class")),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Investing_Period {
|
||||
pub dca_stack: _10y1m1w1y2y3m3y4y5y6m6y8yPattern3,
|
||||
pub dca_cost_basis: SeriesTree_Investing_Period_DcaCostBasis,
|
||||
pub dca_return: _10y1m1w1y2y3m3y4y5y6m6y8yPattern2,
|
||||
pub dca_cagr: _10y2y3y4y5y6y8yPattern,
|
||||
pub lump_sum_stack: _10y1m1w1y2y3m3y4y5y6m6y8yPattern3,
|
||||
pub lump_sum_return: _10y1m1w1y2y3m3y4y5y6m6y8yPattern2,
|
||||
}
|
||||
|
||||
impl SeriesTree_Investing_Period {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
dca_stack: _10y1m1w1y2y3m3y4y5y6m6y8yPattern3::new(client.clone(), "dca_stack".to_string()),
|
||||
dca_cost_basis: SeriesTree_Investing_Period_DcaCostBasis::new(client.clone(), format!("{base_path}_dca_cost_basis")),
|
||||
dca_return: _10y1m1w1y2y3m3y4y5y6m6y8yPattern2::new(client.clone(), "dca_return".to_string()),
|
||||
dca_cagr: _10y2y3y4y5y6y8yPattern::new(client.clone(), "dca_cagr".to_string()),
|
||||
lump_sum_stack: _10y1m1w1y2y3m3y4y5y6m6y8yPattern3::new(client.clone(), "lump_sum_stack".to_string()),
|
||||
lump_sum_return: _10y1m1w1y2y3m3y4y5y6m6y8yPattern2::new(client.clone(), "lump_sum_return".to_string()),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Investing_Period_DcaCostBasis {
|
||||
pub _1w: CentsSatsUsdPattern,
|
||||
pub _1m: CentsSatsUsdPattern,
|
||||
pub _3m: CentsSatsUsdPattern,
|
||||
pub _6m: CentsSatsUsdPattern,
|
||||
pub _1y: CentsSatsUsdPattern,
|
||||
pub _2y: CentsSatsUsdPattern,
|
||||
pub _3y: CentsSatsUsdPattern,
|
||||
pub _4y: CentsSatsUsdPattern,
|
||||
pub _5y: CentsSatsUsdPattern,
|
||||
pub _6y: CentsSatsUsdPattern,
|
||||
pub _8y: CentsSatsUsdPattern,
|
||||
pub _10y: CentsSatsUsdPattern,
|
||||
}
|
||||
|
||||
impl SeriesTree_Investing_Period_DcaCostBasis {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
_1w: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_1w".to_string()),
|
||||
_1m: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_1m".to_string()),
|
||||
_3m: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_3m".to_string()),
|
||||
_6m: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_6m".to_string()),
|
||||
_1y: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_1y".to_string()),
|
||||
_2y: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_2y".to_string()),
|
||||
_3y: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_3y".to_string()),
|
||||
_4y: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_4y".to_string()),
|
||||
_5y: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_5y".to_string()),
|
||||
_6y: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_6y".to_string()),
|
||||
_8y: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_8y".to_string()),
|
||||
_10y: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_10y".to_string()),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Investing_Class {
|
||||
pub dca_stack: SeriesTree_Investing_Class_DcaStack,
|
||||
pub dca_cost_basis: SeriesTree_Investing_Class_DcaCostBasis,
|
||||
pub dca_return: SeriesTree_Investing_Class_DcaReturn,
|
||||
}
|
||||
|
||||
impl SeriesTree_Investing_Class {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
dca_stack: SeriesTree_Investing_Class_DcaStack::new(client.clone(), format!("{base_path}_dca_stack")),
|
||||
dca_cost_basis: SeriesTree_Investing_Class_DcaCostBasis::new(client.clone(), format!("{base_path}_dca_cost_basis")),
|
||||
dca_return: SeriesTree_Investing_Class_DcaReturn::new(client.clone(), format!("{base_path}_dca_return")),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Investing_Class_DcaStack {
|
||||
pub from_2015: BtcCentsSatsUsdPattern3,
|
||||
pub from_2016: BtcCentsSatsUsdPattern3,
|
||||
pub from_2017: BtcCentsSatsUsdPattern3,
|
||||
pub from_2018: BtcCentsSatsUsdPattern3,
|
||||
pub from_2019: BtcCentsSatsUsdPattern3,
|
||||
pub from_2020: BtcCentsSatsUsdPattern3,
|
||||
pub from_2021: BtcCentsSatsUsdPattern3,
|
||||
pub from_2022: BtcCentsSatsUsdPattern3,
|
||||
pub from_2023: BtcCentsSatsUsdPattern3,
|
||||
pub from_2024: BtcCentsSatsUsdPattern3,
|
||||
pub from_2025: BtcCentsSatsUsdPattern3,
|
||||
pub from_2026: BtcCentsSatsUsdPattern3,
|
||||
}
|
||||
|
||||
impl SeriesTree_Investing_Class_DcaStack {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
from_2015: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2015".to_string()),
|
||||
from_2016: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2016".to_string()),
|
||||
from_2017: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2017".to_string()),
|
||||
from_2018: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2018".to_string()),
|
||||
from_2019: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2019".to_string()),
|
||||
from_2020: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2020".to_string()),
|
||||
from_2021: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2021".to_string()),
|
||||
from_2022: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2022".to_string()),
|
||||
from_2023: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2023".to_string()),
|
||||
from_2024: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2024".to_string()),
|
||||
from_2025: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2025".to_string()),
|
||||
from_2026: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2026".to_string()),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Investing_Class_DcaCostBasis {
|
||||
pub from_2015: CentsSatsUsdPattern,
|
||||
pub from_2016: CentsSatsUsdPattern,
|
||||
pub from_2017: CentsSatsUsdPattern,
|
||||
pub from_2018: CentsSatsUsdPattern,
|
||||
pub from_2019: CentsSatsUsdPattern,
|
||||
pub from_2020: CentsSatsUsdPattern,
|
||||
pub from_2021: CentsSatsUsdPattern,
|
||||
pub from_2022: CentsSatsUsdPattern,
|
||||
pub from_2023: CentsSatsUsdPattern,
|
||||
pub from_2024: CentsSatsUsdPattern,
|
||||
pub from_2025: CentsSatsUsdPattern,
|
||||
pub from_2026: CentsSatsUsdPattern,
|
||||
}
|
||||
|
||||
impl SeriesTree_Investing_Class_DcaCostBasis {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
from_2015: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2015".to_string()),
|
||||
from_2016: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2016".to_string()),
|
||||
from_2017: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2017".to_string()),
|
||||
from_2018: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2018".to_string()),
|
||||
from_2019: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2019".to_string()),
|
||||
from_2020: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2020".to_string()),
|
||||
from_2021: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2021".to_string()),
|
||||
from_2022: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2022".to_string()),
|
||||
from_2023: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2023".to_string()),
|
||||
from_2024: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2024".to_string()),
|
||||
from_2025: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2025".to_string()),
|
||||
from_2026: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2026".to_string()),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Investing_Class_DcaReturn {
|
||||
pub from_2015: BpsPercentRatioPattern,
|
||||
pub from_2016: BpsPercentRatioPattern,
|
||||
pub from_2017: BpsPercentRatioPattern,
|
||||
pub from_2018: BpsPercentRatioPattern,
|
||||
pub from_2019: BpsPercentRatioPattern,
|
||||
pub from_2020: BpsPercentRatioPattern,
|
||||
pub from_2021: BpsPercentRatioPattern,
|
||||
pub from_2022: BpsPercentRatioPattern,
|
||||
pub from_2023: BpsPercentRatioPattern,
|
||||
pub from_2024: BpsPercentRatioPattern,
|
||||
pub from_2025: BpsPercentRatioPattern,
|
||||
pub from_2026: BpsPercentRatioPattern,
|
||||
}
|
||||
|
||||
impl SeriesTree_Investing_Class_DcaReturn {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
from_2015: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2015".to_string()),
|
||||
from_2016: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2016".to_string()),
|
||||
from_2017: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2017".to_string()),
|
||||
from_2018: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2018".to_string()),
|
||||
from_2019: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2019".to_string()),
|
||||
from_2020: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2020".to_string()),
|
||||
from_2021: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2021".to_string()),
|
||||
from_2022: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2022".to_string()),
|
||||
from_2023: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2023".to_string()),
|
||||
from_2024: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2024".to_string()),
|
||||
from_2025: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2025".to_string()),
|
||||
from_2026: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2026".to_string()),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Market {
|
||||
pub ath: SeriesTree_Market_Ath,
|
||||
@@ -5183,7 +5432,6 @@ pub struct SeriesTree_Market {
|
||||
pub volatility: _1m1w1y24hPattern<StoredF32>,
|
||||
pub range: SeriesTree_Market_Range,
|
||||
pub moving_average: SeriesTree_Market_MovingAverage,
|
||||
pub dca: SeriesTree_Market_Dca,
|
||||
pub technical: SeriesTree_Market_Technical,
|
||||
}
|
||||
|
||||
@@ -5196,7 +5444,6 @@ impl SeriesTree_Market {
|
||||
volatility: _1m1w1y24hPattern::new(client.clone(), "price_volatility".to_string()),
|
||||
range: SeriesTree_Market_Range::new(client.clone(), format!("{base_path}_range")),
|
||||
moving_average: SeriesTree_Market_MovingAverage::new(client.clone(), format!("{base_path}_moving_average")),
|
||||
dca: SeriesTree_Market_Dca::new(client.clone(), format!("{base_path}_dca")),
|
||||
technical: SeriesTree_Market_Technical::new(client.clone(), format!("{base_path}_technical")),
|
||||
}
|
||||
}
|
||||
@@ -5565,203 +5812,6 @@ impl SeriesTree_Market_MovingAverage_Ema {
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Market_Dca {
|
||||
pub sats_per_day: SeriesPattern18<Sats>,
|
||||
pub period: SeriesTree_Market_Dca_Period,
|
||||
pub class: SeriesTree_Market_Dca_Class,
|
||||
}
|
||||
|
||||
impl SeriesTree_Market_Dca {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
sats_per_day: SeriesPattern18::new(client.clone(), "dca_sats_per_day".to_string()),
|
||||
period: SeriesTree_Market_Dca_Period::new(client.clone(), format!("{base_path}_period")),
|
||||
class: SeriesTree_Market_Dca_Class::new(client.clone(), format!("{base_path}_class")),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Market_Dca_Period {
|
||||
pub stack: _10y1m1w1y2y3m3y4y5y6m6y8yPattern3,
|
||||
pub cost_basis: SeriesTree_Market_Dca_Period_CostBasis,
|
||||
pub return_: _10y1m1w1y2y3m3y4y5y6m6y8yPattern2,
|
||||
pub cagr: _10y2y3y4y5y6y8yPattern,
|
||||
pub lump_sum_stack: _10y1m1w1y2y3m3y4y5y6m6y8yPattern3,
|
||||
pub lump_sum_return: _10y1m1w1y2y3m3y4y5y6m6y8yPattern2,
|
||||
}
|
||||
|
||||
impl SeriesTree_Market_Dca_Period {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
stack: _10y1m1w1y2y3m3y4y5y6m6y8yPattern3::new(client.clone(), "dca_stack".to_string()),
|
||||
cost_basis: SeriesTree_Market_Dca_Period_CostBasis::new(client.clone(), format!("{base_path}_cost_basis")),
|
||||
return_: _10y1m1w1y2y3m3y4y5y6m6y8yPattern2::new(client.clone(), "dca_return".to_string()),
|
||||
cagr: _10y2y3y4y5y6y8yPattern::new(client.clone(), "dca_cagr".to_string()),
|
||||
lump_sum_stack: _10y1m1w1y2y3m3y4y5y6m6y8yPattern3::new(client.clone(), "lump_sum_stack".to_string()),
|
||||
lump_sum_return: _10y1m1w1y2y3m3y4y5y6m6y8yPattern2::new(client.clone(), "lump_sum_return".to_string()),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Market_Dca_Period_CostBasis {
|
||||
pub _1w: CentsSatsUsdPattern,
|
||||
pub _1m: CentsSatsUsdPattern,
|
||||
pub _3m: CentsSatsUsdPattern,
|
||||
pub _6m: CentsSatsUsdPattern,
|
||||
pub _1y: CentsSatsUsdPattern,
|
||||
pub _2y: CentsSatsUsdPattern,
|
||||
pub _3y: CentsSatsUsdPattern,
|
||||
pub _4y: CentsSatsUsdPattern,
|
||||
pub _5y: CentsSatsUsdPattern,
|
||||
pub _6y: CentsSatsUsdPattern,
|
||||
pub _8y: CentsSatsUsdPattern,
|
||||
pub _10y: CentsSatsUsdPattern,
|
||||
}
|
||||
|
||||
impl SeriesTree_Market_Dca_Period_CostBasis {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
_1w: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_1w".to_string()),
|
||||
_1m: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_1m".to_string()),
|
||||
_3m: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_3m".to_string()),
|
||||
_6m: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_6m".to_string()),
|
||||
_1y: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_1y".to_string()),
|
||||
_2y: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_2y".to_string()),
|
||||
_3y: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_3y".to_string()),
|
||||
_4y: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_4y".to_string()),
|
||||
_5y: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_5y".to_string()),
|
||||
_6y: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_6y".to_string()),
|
||||
_8y: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_8y".to_string()),
|
||||
_10y: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_10y".to_string()),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Market_Dca_Class {
|
||||
pub stack: SeriesTree_Market_Dca_Class_Stack,
|
||||
pub cost_basis: SeriesTree_Market_Dca_Class_CostBasis,
|
||||
pub return_: SeriesTree_Market_Dca_Class_Return,
|
||||
}
|
||||
|
||||
impl SeriesTree_Market_Dca_Class {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
stack: SeriesTree_Market_Dca_Class_Stack::new(client.clone(), format!("{base_path}_stack")),
|
||||
cost_basis: SeriesTree_Market_Dca_Class_CostBasis::new(client.clone(), format!("{base_path}_cost_basis")),
|
||||
return_: SeriesTree_Market_Dca_Class_Return::new(client.clone(), format!("{base_path}_return")),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Market_Dca_Class_Stack {
|
||||
pub from_2015: BtcCentsSatsUsdPattern3,
|
||||
pub from_2016: BtcCentsSatsUsdPattern3,
|
||||
pub from_2017: BtcCentsSatsUsdPattern3,
|
||||
pub from_2018: BtcCentsSatsUsdPattern3,
|
||||
pub from_2019: BtcCentsSatsUsdPattern3,
|
||||
pub from_2020: BtcCentsSatsUsdPattern3,
|
||||
pub from_2021: BtcCentsSatsUsdPattern3,
|
||||
pub from_2022: BtcCentsSatsUsdPattern3,
|
||||
pub from_2023: BtcCentsSatsUsdPattern3,
|
||||
pub from_2024: BtcCentsSatsUsdPattern3,
|
||||
pub from_2025: BtcCentsSatsUsdPattern3,
|
||||
pub from_2026: BtcCentsSatsUsdPattern3,
|
||||
}
|
||||
|
||||
impl SeriesTree_Market_Dca_Class_Stack {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
from_2015: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2015".to_string()),
|
||||
from_2016: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2016".to_string()),
|
||||
from_2017: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2017".to_string()),
|
||||
from_2018: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2018".to_string()),
|
||||
from_2019: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2019".to_string()),
|
||||
from_2020: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2020".to_string()),
|
||||
from_2021: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2021".to_string()),
|
||||
from_2022: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2022".to_string()),
|
||||
from_2023: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2023".to_string()),
|
||||
from_2024: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2024".to_string()),
|
||||
from_2025: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2025".to_string()),
|
||||
from_2026: BtcCentsSatsUsdPattern3::new(client.clone(), "dca_stack_from_2026".to_string()),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Market_Dca_Class_CostBasis {
|
||||
pub from_2015: CentsSatsUsdPattern,
|
||||
pub from_2016: CentsSatsUsdPattern,
|
||||
pub from_2017: CentsSatsUsdPattern,
|
||||
pub from_2018: CentsSatsUsdPattern,
|
||||
pub from_2019: CentsSatsUsdPattern,
|
||||
pub from_2020: CentsSatsUsdPattern,
|
||||
pub from_2021: CentsSatsUsdPattern,
|
||||
pub from_2022: CentsSatsUsdPattern,
|
||||
pub from_2023: CentsSatsUsdPattern,
|
||||
pub from_2024: CentsSatsUsdPattern,
|
||||
pub from_2025: CentsSatsUsdPattern,
|
||||
pub from_2026: CentsSatsUsdPattern,
|
||||
}
|
||||
|
||||
impl SeriesTree_Market_Dca_Class_CostBasis {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
from_2015: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2015".to_string()),
|
||||
from_2016: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2016".to_string()),
|
||||
from_2017: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2017".to_string()),
|
||||
from_2018: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2018".to_string()),
|
||||
from_2019: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2019".to_string()),
|
||||
from_2020: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2020".to_string()),
|
||||
from_2021: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2021".to_string()),
|
||||
from_2022: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2022".to_string()),
|
||||
from_2023: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2023".to_string()),
|
||||
from_2024: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2024".to_string()),
|
||||
from_2025: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2025".to_string()),
|
||||
from_2026: CentsSatsUsdPattern::new(client.clone(), "dca_cost_basis_from_2026".to_string()),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Market_Dca_Class_Return {
|
||||
pub from_2015: BpsPercentRatioPattern,
|
||||
pub from_2016: BpsPercentRatioPattern,
|
||||
pub from_2017: BpsPercentRatioPattern,
|
||||
pub from_2018: BpsPercentRatioPattern,
|
||||
pub from_2019: BpsPercentRatioPattern,
|
||||
pub from_2020: BpsPercentRatioPattern,
|
||||
pub from_2021: BpsPercentRatioPattern,
|
||||
pub from_2022: BpsPercentRatioPattern,
|
||||
pub from_2023: BpsPercentRatioPattern,
|
||||
pub from_2024: BpsPercentRatioPattern,
|
||||
pub from_2025: BpsPercentRatioPattern,
|
||||
pub from_2026: BpsPercentRatioPattern,
|
||||
}
|
||||
|
||||
impl SeriesTree_Market_Dca_Class_Return {
|
||||
pub fn new(client: Arc<BrkClientBase>, base_path: String) -> Self {
|
||||
Self {
|
||||
from_2015: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2015".to_string()),
|
||||
from_2016: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2016".to_string()),
|
||||
from_2017: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2017".to_string()),
|
||||
from_2018: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2018".to_string()),
|
||||
from_2019: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2019".to_string()),
|
||||
from_2020: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2020".to_string()),
|
||||
from_2021: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2021".to_string()),
|
||||
from_2022: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2022".to_string()),
|
||||
from_2023: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2023".to_string()),
|
||||
from_2024: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2024".to_string()),
|
||||
from_2025: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2025".to_string()),
|
||||
from_2026: BpsPercentRatioPattern::new(client.clone(), "dca_return_from_2026".to_string()),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Series tree node.
|
||||
pub struct SeriesTree_Market_Technical {
|
||||
pub rsi: SeriesTree_Market_Technical_Rsi,
|
||||
@@ -6527,7 +6577,7 @@ pub struct SeriesTree_Cohorts_Utxo_All_Realized_Price {
|
||||
pub sats: SeriesPattern1<SatsFract>,
|
||||
pub bps: SeriesPattern1<BasisPoints32>,
|
||||
pub ratio: SeriesPattern1<StoredF32>,
|
||||
pub percentiles: Pct1Pct2Pct5Pct95Pct98Pct99Pattern,
|
||||
pub percentiles: Pct0Pct1Pct2Pct5Pct95Pct98Pct99Pattern,
|
||||
pub sma: _1m1w1y2y4yAllPattern,
|
||||
pub std_dev: SeriesTree_Cohorts_Utxo_All_Realized_Price_StdDev,
|
||||
}
|
||||
@@ -6540,7 +6590,7 @@ impl SeriesTree_Cohorts_Utxo_All_Realized_Price {
|
||||
sats: SeriesPattern1::new(client.clone(), "realized_price_sats".to_string()),
|
||||
bps: SeriesPattern1::new(client.clone(), "realized_price_ratio_bps".to_string()),
|
||||
ratio: SeriesPattern1::new(client.clone(), "realized_price_ratio".to_string()),
|
||||
percentiles: Pct1Pct2Pct5Pct95Pct98Pct99Pattern::new(client.clone(), "realized_price".to_string()),
|
||||
percentiles: Pct0Pct1Pct2Pct5Pct95Pct98Pct99Pattern::new(client.clone(), "realized_price".to_string()),
|
||||
sma: _1m1w1y2y4yAllPattern::new(client.clone(), "realized_price_ratio_sma".to_string()),
|
||||
std_dev: SeriesTree_Cohorts_Utxo_All_Realized_Price_StdDev::new(client.clone(), format!("{base_path}_std_dev")),
|
||||
}
|
||||
@@ -6957,7 +7007,7 @@ pub struct SeriesTree_Cohorts_Utxo_Sth_Realized_Price {
|
||||
pub sats: SeriesPattern1<SatsFract>,
|
||||
pub bps: SeriesPattern1<BasisPoints32>,
|
||||
pub ratio: SeriesPattern1<StoredF32>,
|
||||
pub percentiles: Pct1Pct2Pct5Pct95Pct98Pct99Pattern,
|
||||
pub percentiles: Pct0Pct1Pct2Pct5Pct95Pct98Pct99Pattern,
|
||||
pub sma: _1m1w1y2y4yAllPattern,
|
||||
pub std_dev: SeriesTree_Cohorts_Utxo_Sth_Realized_Price_StdDev,
|
||||
}
|
||||
@@ -6970,7 +7020,7 @@ impl SeriesTree_Cohorts_Utxo_Sth_Realized_Price {
|
||||
sats: SeriesPattern1::new(client.clone(), "sth_realized_price_sats".to_string()),
|
||||
bps: SeriesPattern1::new(client.clone(), "sth_realized_price_ratio_bps".to_string()),
|
||||
ratio: SeriesPattern1::new(client.clone(), "sth_realized_price_ratio".to_string()),
|
||||
percentiles: Pct1Pct2Pct5Pct95Pct98Pct99Pattern::new(client.clone(), "sth_realized_price".to_string()),
|
||||
percentiles: Pct0Pct1Pct2Pct5Pct95Pct98Pct99Pattern::new(client.clone(), "sth_realized_price".to_string()),
|
||||
sma: _1m1w1y2y4yAllPattern::new(client.clone(), "sth_realized_price_ratio_sma".to_string()),
|
||||
std_dev: SeriesTree_Cohorts_Utxo_Sth_Realized_Price_StdDev::new(client.clone(), format!("{base_path}_std_dev")),
|
||||
}
|
||||
@@ -7225,7 +7275,7 @@ pub struct SeriesTree_Cohorts_Utxo_Lth_Realized_Price {
|
||||
pub sats: SeriesPattern1<SatsFract>,
|
||||
pub bps: SeriesPattern1<BasisPoints32>,
|
||||
pub ratio: SeriesPattern1<StoredF32>,
|
||||
pub percentiles: Pct1Pct2Pct5Pct95Pct98Pct99Pattern,
|
||||
pub percentiles: Pct0Pct1Pct2Pct5Pct95Pct98Pct99Pattern,
|
||||
pub sma: _1m1w1y2y4yAllPattern,
|
||||
pub std_dev: SeriesTree_Cohorts_Utxo_Lth_Realized_Price_StdDev,
|
||||
}
|
||||
@@ -7238,7 +7288,7 @@ impl SeriesTree_Cohorts_Utxo_Lth_Realized_Price {
|
||||
sats: SeriesPattern1::new(client.clone(), "lth_realized_price_sats".to_string()),
|
||||
bps: SeriesPattern1::new(client.clone(), "lth_realized_price_ratio_bps".to_string()),
|
||||
ratio: SeriesPattern1::new(client.clone(), "lth_realized_price_ratio".to_string()),
|
||||
percentiles: Pct1Pct2Pct5Pct95Pct98Pct99Pattern::new(client.clone(), "lth_realized_price".to_string()),
|
||||
percentiles: Pct0Pct1Pct2Pct5Pct95Pct98Pct99Pattern::new(client.clone(), "lth_realized_price".to_string()),
|
||||
sma: _1m1w1y2y4yAllPattern::new(client.clone(), "lth_realized_price_ratio_sma".to_string()),
|
||||
std_dev: SeriesTree_Cohorts_Utxo_Lth_Realized_Price_StdDev::new(client.clone(), format!("{base_path}_std_dev")),
|
||||
}
|
||||
@@ -8145,7 +8195,7 @@ pub struct BrkClient {
|
||||
|
||||
impl BrkClient {
|
||||
/// Client version.
|
||||
pub const VERSION: &'static str = "v0.1.9";
|
||||
pub const VERSION: &'static str = "v0.2.3";
|
||||
|
||||
/// Create a new client with the given base URL.
|
||||
pub fn new(base_url: impl Into<String>) -> Self {
|
||||
|
||||
@@ -17,12 +17,10 @@ impl Vecs {
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
// Sequential: time → lookback (dependency chain)
|
||||
self.time
|
||||
.timestamp
|
||||
.compute(indexer, indexes, starting_indexes, exit)?;
|
||||
self.lookback
|
||||
.compute(&self.time, starting_indexes, exit)?;
|
||||
self.db.sync_bg_tasks()?;
|
||||
|
||||
// lookback depends on indexes.timestamp.monotonic
|
||||
self.lookback.compute(indexes, starting_indexes, exit)?;
|
||||
|
||||
// Parallel: remaining sub-modules are independent of each other.
|
||||
// size depends on lookback (already computed above).
|
||||
@@ -52,8 +50,11 @@ impl Vecs {
|
||||
Ok(())
|
||||
})?;
|
||||
|
||||
let _lock = exit.lock();
|
||||
self.db.compact()?;
|
||||
let exit = exit.clone();
|
||||
self.db.run_bg(move |db| {
|
||||
let _lock = exit.lock();
|
||||
db.compact()
|
||||
});
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -10,7 +10,7 @@ use crate::{
|
||||
};
|
||||
|
||||
use super::{
|
||||
CountVecs, DifficultyVecs, HalvingVecs, IntervalVecs, LookbackVecs, SizeVecs, TimeVecs, Vecs,
|
||||
CountVecs, DifficultyVecs, HalvingVecs, IntervalVecs, LookbackVecs, SizeVecs, Vecs,
|
||||
WeightVecs,
|
||||
};
|
||||
|
||||
@@ -30,7 +30,6 @@ impl Vecs {
|
||||
let interval = IntervalVecs::forced_import(&db, version, indexes, cached_starts)?;
|
||||
let size = SizeVecs::forced_import(&db, version, indexes, cached_starts)?;
|
||||
let weight = WeightVecs::forced_import(&db, version, indexes, cached_starts, &size)?;
|
||||
let time = TimeVecs::forced_import(&db, version, indexes)?;
|
||||
let difficulty = DifficultyVecs::forced_import(&db, version, indexer, indexes)?;
|
||||
let halving = HalvingVecs::forced_import(&db, version, indexes)?;
|
||||
|
||||
@@ -41,7 +40,6 @@ impl Vecs {
|
||||
interval,
|
||||
size,
|
||||
weight,
|
||||
time,
|
||||
difficulty,
|
||||
halving,
|
||||
};
|
||||
|
||||
@@ -3,9 +3,10 @@ use brk_traversable::Traversable;
|
||||
use brk_types::{Height, Indexes, Timestamp, Version};
|
||||
use vecdb::{AnyVec, CachedVec, Cursor, Database, EagerVec, Exit, ImportableVec, PcoVec, ReadableVec, Rw, StorageMode, VecIndex};
|
||||
|
||||
use crate::internal::{CachedWindowStarts, Windows, WindowStarts};
|
||||
|
||||
use super::time;
|
||||
use crate::{
|
||||
indexes,
|
||||
internal::{CachedWindowStarts, Windows, WindowStarts},
|
||||
};
|
||||
|
||||
#[derive(Traversable)]
|
||||
pub struct Vecs<M: StorageMode = Rw> {
|
||||
@@ -178,71 +179,71 @@ impl Vecs {
|
||||
|
||||
pub(crate) fn compute(
|
||||
&mut self,
|
||||
time: &time::Vecs,
|
||||
indexes: &indexes::Vecs,
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
self.compute_rolling_start_hours(time, starting_indexes, exit, 1, |s| {
|
||||
self.compute_rolling_start_hours(indexes, starting_indexes, exit, 1, |s| {
|
||||
&mut s._1h
|
||||
})?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 1, |s| &mut s._24h)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 3, |s| &mut s._3d)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 7, |s| &mut s._1w)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 8, |s| &mut s._8d)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 9, |s| &mut s._9d)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 12, |s| &mut s._12d)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 13, |s| &mut s._13d)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 14, |s| &mut s._2w)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 21, |s| &mut s._21d)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 26, |s| &mut s._26d)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 30, |s| &mut s._1m)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 34, |s| &mut s._34d)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 55, |s| &mut s._55d)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 60, |s| &mut s._2m)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 63, |s| &mut s._9w)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 84, |s| &mut s._12w)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 89, |s| &mut s._89d)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 90, |s| &mut s._3m)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 98, |s| &mut s._14w)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 111, |s| {
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 1, |s| &mut s._24h)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 3, |s| &mut s._3d)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 7, |s| &mut s._1w)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 8, |s| &mut s._8d)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 9, |s| &mut s._9d)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 12, |s| &mut s._12d)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 13, |s| &mut s._13d)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 14, |s| &mut s._2w)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 21, |s| &mut s._21d)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 26, |s| &mut s._26d)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 30, |s| &mut s._1m)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 34, |s| &mut s._34d)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 55, |s| &mut s._55d)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 60, |s| &mut s._2m)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 63, |s| &mut s._9w)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 84, |s| &mut s._12w)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 89, |s| &mut s._89d)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 90, |s| &mut s._3m)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 98, |s| &mut s._14w)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 111, |s| {
|
||||
&mut s._111d
|
||||
})?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 144, |s| {
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 144, |s| {
|
||||
&mut s._144d
|
||||
})?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 180, |s| &mut s._6m)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 182, |s| &mut s._26w)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 200, |s| {
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 180, |s| &mut s._6m)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 182, |s| &mut s._26w)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 200, |s| {
|
||||
&mut s._200d
|
||||
})?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 270, |s| &mut s._9m)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 350, |s| {
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 270, |s| &mut s._9m)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 350, |s| {
|
||||
&mut s._350d
|
||||
})?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 360, |s| &mut s._12m)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 365, |s| &mut s._1y)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 420, |s| &mut s._14m)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 730, |s| &mut s._2y)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 780, |s| &mut s._26m)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 1095, |s| &mut s._3y)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 1400, |s| {
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 360, |s| &mut s._12m)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 365, |s| &mut s._1y)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 420, |s| &mut s._14m)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 730, |s| &mut s._2y)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 780, |s| &mut s._26m)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 1095, |s| &mut s._3y)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 1400, |s| {
|
||||
&mut s._200w
|
||||
})?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 1460, |s| &mut s._4y)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 1825, |s| &mut s._5y)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 2190, |s| &mut s._6y)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 2920, |s| &mut s._8y)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 3285, |s| &mut s._9y)?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 3650, |s| {
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 1460, |s| &mut s._4y)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 1825, |s| &mut s._5y)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 2190, |s| &mut s._6y)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 2920, |s| &mut s._8y)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 3285, |s| &mut s._9y)?;
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 3650, |s| {
|
||||
&mut s._10y
|
||||
})?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 4380, |s| {
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 4380, |s| {
|
||||
&mut s._12y
|
||||
})?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 5110, |s| {
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 5110, |s| {
|
||||
&mut s._14y
|
||||
})?;
|
||||
self.compute_rolling_start(time, starting_indexes, exit, 9490, |s| {
|
||||
self.compute_rolling_start(indexes, starting_indexes, exit, 9490, |s| {
|
||||
&mut s._26y
|
||||
})?;
|
||||
|
||||
@@ -251,7 +252,7 @@ impl Vecs {
|
||||
|
||||
fn compute_rolling_start<F>(
|
||||
&mut self,
|
||||
time: &time::Vecs,
|
||||
indexes: &indexes::Vecs,
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
days: usize,
|
||||
@@ -260,14 +261,14 @@ impl Vecs {
|
||||
where
|
||||
F: FnOnce(&mut Self) -> &mut EagerVec<PcoVec<Height, Height>>,
|
||||
{
|
||||
self.compute_rolling_start_inner(time, starting_indexes, exit, get_field, |t, prev_ts| {
|
||||
self.compute_rolling_start_inner(indexes, starting_indexes, exit, get_field, |t, prev_ts| {
|
||||
t.difference_in_days_between(prev_ts) >= days
|
||||
})
|
||||
}
|
||||
|
||||
fn compute_rolling_start_hours<F>(
|
||||
&mut self,
|
||||
time: &time::Vecs,
|
||||
indexes: &indexes::Vecs,
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
hours: usize,
|
||||
@@ -276,14 +277,14 @@ impl Vecs {
|
||||
where
|
||||
F: FnOnce(&mut Self) -> &mut EagerVec<PcoVec<Height, Height>>,
|
||||
{
|
||||
self.compute_rolling_start_inner(time, starting_indexes, exit, get_field, |t, prev_ts| {
|
||||
self.compute_rolling_start_inner(indexes, starting_indexes, exit, get_field, |t, prev_ts| {
|
||||
t.difference_in_hours_between(prev_ts) >= hours
|
||||
})
|
||||
}
|
||||
|
||||
fn compute_rolling_start_inner<F, D>(
|
||||
&mut self,
|
||||
time: &time::Vecs,
|
||||
indexes: &indexes::Vecs,
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
get_field: F,
|
||||
@@ -300,12 +301,12 @@ impl Vecs {
|
||||
} else {
|
||||
Height::ZERO
|
||||
};
|
||||
let mut cursor = Cursor::new(&time.timestamp_monotonic);
|
||||
let mut cursor = Cursor::new(&indexes.timestamp.monotonic);
|
||||
cursor.advance(prev.to_usize());
|
||||
let mut prev_ts = cursor.next().unwrap();
|
||||
Ok(field.compute_transform(
|
||||
starting_indexes.height,
|
||||
&time.timestamp_monotonic,
|
||||
&indexes.timestamp.monotonic,
|
||||
|(h, t, ..)| {
|
||||
while expired(t, prev_ts) {
|
||||
prev.increment();
|
||||
|
||||
@@ -4,7 +4,6 @@ pub mod halving;
|
||||
pub mod interval;
|
||||
pub mod lookback;
|
||||
pub mod size;
|
||||
pub mod time;
|
||||
pub mod weight;
|
||||
|
||||
mod compute;
|
||||
@@ -19,7 +18,6 @@ pub use halving::Vecs as HalvingVecs;
|
||||
pub use interval::Vecs as IntervalVecs;
|
||||
pub use lookback::Vecs as LookbackVecs;
|
||||
pub use size::Vecs as SizeVecs;
|
||||
pub use time::Vecs as TimeVecs;
|
||||
pub use weight::Vecs as WeightVecs;
|
||||
|
||||
pub const DB_NAME: &str = "blocks";
|
||||
@@ -37,7 +35,7 @@ pub(crate) const ONE_TERA_HASH: f64 = 1_000_000_000_000.0;
|
||||
#[derive(Traversable)]
|
||||
pub struct Vecs<M: StorageMode = Rw> {
|
||||
#[traversable(skip)]
|
||||
pub(crate) db: Database,
|
||||
pub db: Database,
|
||||
|
||||
pub count: CountVecs<M>,
|
||||
pub lookback: LookbackVecs<M>,
|
||||
@@ -46,7 +44,6 @@ pub struct Vecs<M: StorageMode = Rw> {
|
||||
pub size: SizeVecs<M>,
|
||||
#[traversable(flatten)]
|
||||
pub weight: WeightVecs<M>,
|
||||
pub time: TimeVecs<M>,
|
||||
pub difficulty: DifficultyVecs<M>,
|
||||
pub halving: HalvingVecs<M>,
|
||||
}
|
||||
|
||||
@@ -1,34 +0,0 @@
|
||||
use brk_error::Result;
|
||||
use brk_indexer::Indexer;
|
||||
use vecdb::{Exit, ReadableVec};
|
||||
|
||||
use super::Vecs;
|
||||
|
||||
impl Vecs {
|
||||
pub(crate) fn compute(
|
||||
&mut self,
|
||||
indexer: &Indexer,
|
||||
starting_height: brk_types::Height,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
let mut prev_timestamp_monotonic = None;
|
||||
self.timestamp_monotonic.compute_transform(
|
||||
starting_height,
|
||||
&indexer.vecs.blocks.timestamp,
|
||||
|(h, timestamp, this)| {
|
||||
if prev_timestamp_monotonic.is_none()
|
||||
&& let Some(prev_h) = h.decremented()
|
||||
{
|
||||
prev_timestamp_monotonic.replace(this.collect_one(prev_h).unwrap());
|
||||
}
|
||||
let timestamp_monotonic =
|
||||
prev_timestamp_monotonic.map_or(timestamp, |prev_d| prev_d.max(timestamp));
|
||||
prev_timestamp_monotonic.replace(timestamp_monotonic);
|
||||
(h, timestamp_monotonic)
|
||||
},
|
||||
exit,
|
||||
)?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
@@ -1,66 +0,0 @@
|
||||
use brk_error::Result;
|
||||
use brk_types::{Date, Height, Version};
|
||||
use vecdb::{Database, EagerVec, ImportableVec, LazyVecFrom1, ReadableCloneableVec};
|
||||
|
||||
use super::{TimestampIndexes, Vecs};
|
||||
use crate::indexes;
|
||||
|
||||
impl Vecs {
|
||||
pub(crate) fn forced_import(
|
||||
db: &Database,
|
||||
version: Version,
|
||||
indexes: &indexes::Vecs,
|
||||
) -> Result<Self> {
|
||||
let timestamp_monotonic = EagerVec::forced_import(db, "timestamp_monotonic", version)?;
|
||||
|
||||
Ok(Self {
|
||||
date: LazyVecFrom1::init(
|
||||
"date",
|
||||
version,
|
||||
timestamp_monotonic.read_only_boxed_clone(),
|
||||
|_height: Height, timestamp| Date::from(timestamp),
|
||||
),
|
||||
timestamp_monotonic,
|
||||
timestamp: TimestampIndexes::forced_import(db, version, indexes)?,
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
impl TimestampIndexes {
|
||||
fn forced_import(db: &Database, version: Version, indexes: &indexes::Vecs) -> Result<Self> {
|
||||
macro_rules! period {
|
||||
($field:ident) => {
|
||||
LazyVecFrom1::init(
|
||||
"timestamp",
|
||||
version,
|
||||
indexes.$field.first_height.read_only_boxed_clone(),
|
||||
|idx, _: Height| idx.to_timestamp(),
|
||||
)
|
||||
};
|
||||
}
|
||||
|
||||
macro_rules! epoch {
|
||||
($field:ident) => {
|
||||
ImportableVec::forced_import(db, "timestamp", version)?
|
||||
};
|
||||
}
|
||||
|
||||
Ok(Self(crate::internal::PerResolution {
|
||||
minute10: period!(minute10),
|
||||
minute30: period!(minute30),
|
||||
hour1: period!(hour1),
|
||||
hour4: period!(hour4),
|
||||
hour12: period!(hour12),
|
||||
day1: period!(day1),
|
||||
day3: period!(day3),
|
||||
week1: period!(week1),
|
||||
month1: period!(month1),
|
||||
month3: period!(month3),
|
||||
month6: period!(month6),
|
||||
year1: period!(year1),
|
||||
year10: period!(year10),
|
||||
halving: epoch!(halving),
|
||||
epoch: epoch!(difficulty),
|
||||
}))
|
||||
}
|
||||
}
|
||||
@@ -1,5 +0,0 @@
|
||||
mod compute;
|
||||
mod import;
|
||||
mod vecs;
|
||||
|
||||
pub use vecs::{TimestampIndexes, Vecs};
|
||||
@@ -1,80 +0,0 @@
|
||||
use brk_error::Result;
|
||||
use brk_traversable::Traversable;
|
||||
use brk_types::{
|
||||
Date, Day1, Day3, Epoch, Halving, Height, Hour1, Hour4, Hour12, Indexes,
|
||||
Minute10, Minute30, Month1, Month3, Month6, Timestamp, Week1, Year1, Year10,
|
||||
};
|
||||
use derive_more::{Deref, DerefMut};
|
||||
use vecdb::{EagerVec, Exit, LazyVecFrom1, PcoVec, ReadableVec, Rw, StorageMode};
|
||||
|
||||
use crate::{indexes, internal::PerResolution};
|
||||
#[derive(Traversable)]
|
||||
pub struct Vecs<M: StorageMode = Rw> {
|
||||
pub date: LazyVecFrom1<Height, Date, Height, Timestamp>,
|
||||
pub timestamp_monotonic: M::Stored<EagerVec<PcoVec<Height, Timestamp>>>,
|
||||
pub timestamp: TimestampIndexes<M>,
|
||||
}
|
||||
|
||||
/// Per-period timestamp indexes.
|
||||
///
|
||||
/// Time-based periods (minute10–year10) are lazy: `idx.to_timestamp()` is a pure
|
||||
/// function of the index, so no storage or decompression is needed.
|
||||
/// Epoch-based periods (halving, difficulty) are eager: their timestamps
|
||||
/// come from block data via `compute_indirect_sequential`.
|
||||
#[derive(Deref, DerefMut, Traversable)]
|
||||
#[traversable(transparent)]
|
||||
pub struct TimestampIndexes<M: StorageMode = Rw>(
|
||||
#[allow(clippy::type_complexity)]
|
||||
pub PerResolution<
|
||||
LazyVecFrom1<Minute10, Timestamp, Minute10, Height>,
|
||||
LazyVecFrom1<Minute30, Timestamp, Minute30, Height>,
|
||||
LazyVecFrom1<Hour1, Timestamp, Hour1, Height>,
|
||||
LazyVecFrom1<Hour4, Timestamp, Hour4, Height>,
|
||||
LazyVecFrom1<Hour12, Timestamp, Hour12, Height>,
|
||||
LazyVecFrom1<Day1, Timestamp, Day1, Height>,
|
||||
LazyVecFrom1<Day3, Timestamp, Day3, Height>,
|
||||
LazyVecFrom1<Week1, Timestamp, Week1, Height>,
|
||||
LazyVecFrom1<Month1, Timestamp, Month1, Height>,
|
||||
LazyVecFrom1<Month3, Timestamp, Month3, Height>,
|
||||
LazyVecFrom1<Month6, Timestamp, Month6, Height>,
|
||||
LazyVecFrom1<Year1, Timestamp, Year1, Height>,
|
||||
LazyVecFrom1<Year10, Timestamp, Year10, Height>,
|
||||
M::Stored<EagerVec<PcoVec<Halving, Timestamp>>>,
|
||||
M::Stored<EagerVec<PcoVec<Epoch, Timestamp>>>,
|
||||
>,
|
||||
);
|
||||
|
||||
impl TimestampIndexes {
|
||||
/// Compute epoch timestamps via indirect lookup from block timestamps.
|
||||
/// Time-based periods are lazy (idx.to_timestamp()) and need no compute.
|
||||
pub(crate) fn compute(
|
||||
&mut self,
|
||||
indexer: &brk_indexer::Indexer,
|
||||
indexes: &indexes::Vecs,
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
let prev_height = starting_indexes.height.decremented().unwrap_or_default();
|
||||
self.halving.compute_indirect_sequential(
|
||||
indexes
|
||||
.height
|
||||
.halving
|
||||
.collect_one(prev_height)
|
||||
.unwrap_or_default(),
|
||||
&indexes.halving.first_height,
|
||||
&indexer.vecs.blocks.timestamp,
|
||||
exit,
|
||||
)?;
|
||||
self.epoch.compute_indirect_sequential(
|
||||
indexes
|
||||
.height
|
||||
.epoch
|
||||
.collect_one(prev_height)
|
||||
.unwrap_or_default(),
|
||||
&indexes.epoch.first_height,
|
||||
&indexer.vecs.blocks.timestamp,
|
||||
exit,
|
||||
)?;
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
@@ -17,6 +17,8 @@ impl Vecs {
|
||||
distribution: &distribution::Vecs,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
self.db.sync_bg_tasks()?;
|
||||
|
||||
// Activity computes first (liveliness, vaultedness, etc.)
|
||||
self.activity
|
||||
.compute(starting_indexes, distribution, exit)?;
|
||||
@@ -80,8 +82,11 @@ impl Vecs {
|
||||
r3?;
|
||||
r4?;
|
||||
|
||||
let _lock = exit.lock();
|
||||
self.db.compact()?;
|
||||
let exit = exit.clone();
|
||||
self.db.run_bg(move |db| {
|
||||
let _lock = exit.lock();
|
||||
db.compact()
|
||||
});
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -227,6 +227,8 @@ impl Vecs {
|
||||
starting_indexes: &mut Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
self.db.sync_bg_tasks()?;
|
||||
|
||||
// 1. Find minimum height we have data for across stateful vecs
|
||||
let current_height = Height::from(self.supply_state.len());
|
||||
let min_stateful = self.min_stateful_len();
|
||||
@@ -300,7 +302,7 @@ impl Vecs {
|
||||
.cents
|
||||
.height
|
||||
.len()
|
||||
.min(blocks.time.timestamp_monotonic.len());
|
||||
.min(indexes.timestamp.monotonic.len());
|
||||
let cache_current_len = self.caches.prices.len();
|
||||
if cache_target_len < cache_current_len {
|
||||
self.caches.prices.truncate(cache_target_len);
|
||||
@@ -312,9 +314,9 @@ impl Vecs {
|
||||
.cents
|
||||
.height
|
||||
.collect_range_at(cache_current_len, cache_target_len);
|
||||
let new_timestamps = blocks
|
||||
.time
|
||||
.timestamp_monotonic
|
||||
let new_timestamps = indexes
|
||||
.timestamp
|
||||
.monotonic
|
||||
.collect_range_at(cache_current_len, cache_target_len);
|
||||
self.caches.prices.extend(new_prices);
|
||||
self.caches.timestamps.extend(new_timestamps);
|
||||
@@ -499,8 +501,11 @@ impl Vecs {
|
||||
self.addr_cohorts
|
||||
.compute_rest_part2(prices, starting_indexes, &all_utxo_count, exit)?;
|
||||
|
||||
let _lock = exit.lock();
|
||||
self.db.compact()?;
|
||||
let exit = exit.clone();
|
||||
self.db.run_bg(move |db| {
|
||||
let _lock = exit.lock();
|
||||
db.compact()
|
||||
});
|
||||
Ok(())
|
||||
}
|
||||
|
||||
|
||||
@@ -13,6 +13,7 @@ mod minute30;
|
||||
mod month1;
|
||||
mod month3;
|
||||
mod month6;
|
||||
pub mod timestamp;
|
||||
mod tx_index;
|
||||
mod txin_index;
|
||||
mod txout_index;
|
||||
@@ -31,13 +32,11 @@ use brk_types::{
|
||||
};
|
||||
use vecdb::{CachedVec, Database, Exit, ReadableVec, Rw, StorageMode};
|
||||
|
||||
use crate::{
|
||||
blocks,
|
||||
internal::db_utils::{finalize_db, open_db},
|
||||
};
|
||||
use crate::internal::db_utils::{finalize_db, open_db};
|
||||
|
||||
pub use cached_mappings::CachedMappings;
|
||||
pub use addr::Vecs as AddrVecs;
|
||||
pub use timestamp::Timestamps;
|
||||
pub use cached_mappings::CachedMappings;
|
||||
pub use day1::Vecs as Day1Vecs;
|
||||
pub use day3::Vecs as Day3Vecs;
|
||||
pub use epoch::Vecs as EpochVecs;
|
||||
@@ -85,6 +84,7 @@ pub struct Vecs<M: StorageMode = Rw> {
|
||||
pub tx_index: TxIndexVecs<M>,
|
||||
pub txin_index: TxInIndexVecs,
|
||||
pub txout_index: TxOutIndexVecs,
|
||||
pub timestamp: Timestamps<M>,
|
||||
}
|
||||
|
||||
impl Vecs {
|
||||
@@ -136,6 +136,11 @@ impl Vecs {
|
||||
epoch_identity: CachedVec::new(&epoch.identity),
|
||||
};
|
||||
|
||||
let timestamp = Timestamps::forced_import_from_locals(
|
||||
&db, version, &minute10, &minute30, &hour1, &hour4, &hour12, &day1, &day3, &week1,
|
||||
&month1, &month3, &month6, &year1, &year10,
|
||||
)?;
|
||||
|
||||
let this = Self {
|
||||
cached_mappings,
|
||||
addr,
|
||||
@@ -158,6 +163,7 @@ impl Vecs {
|
||||
tx_index,
|
||||
txin_index,
|
||||
txout_index,
|
||||
timestamp,
|
||||
db,
|
||||
};
|
||||
|
||||
@@ -168,36 +174,24 @@ impl Vecs {
|
||||
pub(crate) fn compute(
|
||||
&mut self,
|
||||
indexer: &Indexer,
|
||||
blocks: &mut blocks::Vecs,
|
||||
starting_indexes: Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<Indexes> {
|
||||
blocks
|
||||
.time
|
||||
.compute(indexer, starting_indexes.height, exit)?;
|
||||
let indexes = self.compute_(indexer, &blocks.time, starting_indexes, exit)?;
|
||||
let _lock = exit.lock();
|
||||
self.db.compact()?;
|
||||
Ok(indexes)
|
||||
}
|
||||
self.db.sync_bg_tasks()?;
|
||||
|
||||
// timestamp_monotonic must be computed first — other mappings read it
|
||||
self.timestamp
|
||||
.compute_monotonic(indexer, starting_indexes.height, exit)?;
|
||||
|
||||
fn compute_(
|
||||
&mut self,
|
||||
indexer: &Indexer,
|
||||
blocks_time: &blocks::time::Vecs,
|
||||
starting_indexes: Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<Indexes> {
|
||||
self.compute_tx_indexes(indexer, &starting_indexes, exit)?;
|
||||
self.compute_height_indexes(indexer, &starting_indexes, exit)?;
|
||||
|
||||
let prev_height = starting_indexes.height.decremented().unwrap_or_default();
|
||||
|
||||
self.compute_timestamp_mappings(blocks_time, &starting_indexes, exit)?;
|
||||
self.compute_timestamp_mappings(&starting_indexes, exit)?;
|
||||
|
||||
let starting_day1 = self.compute_calendar_mappings(
|
||||
indexer,
|
||||
blocks_time,
|
||||
&starting_indexes,
|
||||
prev_height,
|
||||
exit,
|
||||
@@ -205,13 +199,26 @@ impl Vecs {
|
||||
|
||||
self.compute_period_vecs(
|
||||
indexer,
|
||||
blocks_time,
|
||||
&starting_indexes,
|
||||
prev_height,
|
||||
starting_day1,
|
||||
exit,
|
||||
)?;
|
||||
|
||||
self.timestamp.compute_per_resolution(
|
||||
indexer,
|
||||
&self.height,
|
||||
&self.halving,
|
||||
&self.epoch,
|
||||
&starting_indexes,
|
||||
exit,
|
||||
)?;
|
||||
|
||||
let exit = exit.clone();
|
||||
self.db.run_bg(move |db| {
|
||||
let _lock = exit.lock();
|
||||
db.compact()
|
||||
});
|
||||
Ok(starting_indexes)
|
||||
}
|
||||
|
||||
@@ -266,7 +273,6 @@ impl Vecs {
|
||||
|
||||
fn compute_timestamp_mappings(
|
||||
&mut self,
|
||||
blocks_time: &blocks::time::Vecs,
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
@@ -274,7 +280,7 @@ impl Vecs {
|
||||
($field:ident, $period:ty) => {
|
||||
self.height.$field.compute_transform(
|
||||
starting_indexes.height,
|
||||
&blocks_time.timestamp_monotonic,
|
||||
&self.timestamp.monotonic,
|
||||
|(h, ts, _)| (h, <$period>::from_timestamp(ts)),
|
||||
exit,
|
||||
)?;
|
||||
@@ -294,7 +300,6 @@ impl Vecs {
|
||||
fn compute_calendar_mappings(
|
||||
&mut self,
|
||||
indexer: &Indexer,
|
||||
blocks_time: &blocks::time::Vecs,
|
||||
starting_indexes: &Indexes,
|
||||
prev_height: Height,
|
||||
exit: &Exit,
|
||||
@@ -307,8 +312,8 @@ impl Vecs {
|
||||
|
||||
self.height.day1.compute_transform(
|
||||
starting_indexes.height,
|
||||
&blocks_time.date,
|
||||
|(h, d, ..)| (h, Day1::try_from(d).unwrap()),
|
||||
&self.timestamp.monotonic,
|
||||
|(h, ts, ..)| (h, Day1::try_from(Date::from(ts)).unwrap()),
|
||||
exit,
|
||||
)?;
|
||||
|
||||
@@ -318,7 +323,7 @@ impl Vecs {
|
||||
starting_day1
|
||||
};
|
||||
|
||||
self.compute_epoch(indexer, blocks_time, starting_indexes, prev_height, exit)?;
|
||||
self.compute_epoch(indexer, starting_indexes, prev_height, exit)?;
|
||||
|
||||
self.height.week1.compute_transform(
|
||||
starting_indexes.height,
|
||||
@@ -363,7 +368,6 @@ impl Vecs {
|
||||
fn compute_epoch(
|
||||
&mut self,
|
||||
indexer: &Indexer,
|
||||
blocks_time: &blocks::time::Vecs,
|
||||
starting_indexes: &Indexes,
|
||||
prev_height: Height,
|
||||
exit: &Exit,
|
||||
@@ -389,14 +393,12 @@ impl Vecs {
|
||||
&self.epoch.first_height,
|
||||
exit,
|
||||
)?;
|
||||
self.epoch
|
||||
.height_count
|
||||
.compute_count_from_indexes(
|
||||
starting_difficulty,
|
||||
&self.epoch.first_height,
|
||||
&blocks_time.date,
|
||||
exit,
|
||||
)?;
|
||||
self.epoch.height_count.compute_count_from_indexes(
|
||||
starting_difficulty,
|
||||
&self.epoch.first_height,
|
||||
&self.timestamp.monotonic,
|
||||
exit,
|
||||
)?;
|
||||
|
||||
let starting_halving = self
|
||||
.height
|
||||
@@ -426,7 +428,6 @@ impl Vecs {
|
||||
fn compute_period_vecs(
|
||||
&mut self,
|
||||
indexer: &Indexer,
|
||||
blocks_time: &blocks::time::Vecs,
|
||||
starting_indexes: &Indexes,
|
||||
prev_height: Height,
|
||||
starting_day1: Day1,
|
||||
@@ -478,7 +479,7 @@ impl Vecs {
|
||||
exit,
|
||||
)?;
|
||||
|
||||
let date = &blocks_time.date;
|
||||
let ts = &self.timestamp.monotonic;
|
||||
|
||||
macro_rules! dated_period {
|
||||
($period:ident) => {{
|
||||
@@ -500,7 +501,7 @@ impl Vecs {
|
||||
self.$period.date.compute_transform(
|
||||
start,
|
||||
&self.$period.first_height,
|
||||
|(idx, first_h, _)| (idx, date.collect_one(first_h).unwrap()),
|
||||
|(idx, first_h, _)| (idx, Date::from(ts.collect_one(first_h).unwrap())),
|
||||
exit,
|
||||
)?;
|
||||
}};
|
||||
|
||||
@@ -0,0 +1,150 @@
|
||||
use brk_error::Result;
|
||||
use brk_traversable::Traversable;
|
||||
use brk_types::{
|
||||
Day1, Day3, Epoch, Halving, Height, Hour1, Hour4, Hour12, Indexes, Minute10, Minute30, Month1,
|
||||
Month3, Month6, Timestamp, Week1, Year1, Year10,
|
||||
};
|
||||
use derive_more::{Deref, DerefMut};
|
||||
use vecdb::{
|
||||
Database, EagerVec, Exit, ImportableVec, LazyVecFrom1, PcoVec, ReadableCloneableVec,
|
||||
ReadableVec, Rw, StorageMode, Version,
|
||||
};
|
||||
|
||||
use crate::internal::PerResolution;
|
||||
|
||||
/// Timestamps: monotonic height→timestamp + per-period timestamp lookups.
|
||||
///
|
||||
/// Time-based periods (minute10–year10) are lazy: `idx.to_timestamp()` is a pure
|
||||
/// function of the index, so no storage or decompression is needed.
|
||||
/// Epoch-based periods (halving, difficulty) are eager: their timestamps
|
||||
/// come from block data via `compute_indirect_sequential`.
|
||||
#[derive(Deref, DerefMut, Traversable)]
|
||||
pub struct Timestamps<M: StorageMode = Rw> {
|
||||
pub monotonic: M::Stored<EagerVec<PcoVec<Height, Timestamp>>>,
|
||||
#[deref]
|
||||
#[deref_mut]
|
||||
#[traversable(flatten)]
|
||||
#[allow(clippy::type_complexity)]
|
||||
pub resolutions: PerResolution<
|
||||
LazyVecFrom1<Minute10, Timestamp, Minute10, Height>,
|
||||
LazyVecFrom1<Minute30, Timestamp, Minute30, Height>,
|
||||
LazyVecFrom1<Hour1, Timestamp, Hour1, Height>,
|
||||
LazyVecFrom1<Hour4, Timestamp, Hour4, Height>,
|
||||
LazyVecFrom1<Hour12, Timestamp, Hour12, Height>,
|
||||
LazyVecFrom1<Day1, Timestamp, Day1, Height>,
|
||||
LazyVecFrom1<Day3, Timestamp, Day3, Height>,
|
||||
LazyVecFrom1<Week1, Timestamp, Week1, Height>,
|
||||
LazyVecFrom1<Month1, Timestamp, Month1, Height>,
|
||||
LazyVecFrom1<Month3, Timestamp, Month3, Height>,
|
||||
LazyVecFrom1<Month6, Timestamp, Month6, Height>,
|
||||
LazyVecFrom1<Year1, Timestamp, Year1, Height>,
|
||||
LazyVecFrom1<Year10, Timestamp, Year10, Height>,
|
||||
M::Stored<EagerVec<PcoVec<Halving, Timestamp>>>,
|
||||
M::Stored<EagerVec<PcoVec<Epoch, Timestamp>>>,
|
||||
>,
|
||||
}
|
||||
|
||||
impl Timestamps {
|
||||
#[allow(clippy::too_many_arguments)]
|
||||
pub(crate) fn forced_import_from_locals(
|
||||
db: &Database,
|
||||
version: Version,
|
||||
minute10: &super::Minute10Vecs,
|
||||
minute30: &super::Minute30Vecs,
|
||||
hour1: &super::Hour1Vecs,
|
||||
hour4: &super::Hour4Vecs,
|
||||
hour12: &super::Hour12Vecs,
|
||||
day1: &super::Day1Vecs,
|
||||
day3: &super::Day3Vecs,
|
||||
week1: &super::Week1Vecs,
|
||||
month1: &super::Month1Vecs,
|
||||
month3: &super::Month3Vecs,
|
||||
month6: &super::Month6Vecs,
|
||||
year1: &super::Year1Vecs,
|
||||
year10: &super::Year10Vecs,
|
||||
) -> Result<Self> {
|
||||
let monotonic = EagerVec::forced_import(db, "timestamp_monotonic", version)?;
|
||||
|
||||
macro_rules! period {
|
||||
($field:ident) => {
|
||||
LazyVecFrom1::init(
|
||||
"timestamp",
|
||||
version,
|
||||
$field.first_height.read_only_boxed_clone(),
|
||||
|idx, _: Height| idx.to_timestamp(),
|
||||
)
|
||||
};
|
||||
}
|
||||
|
||||
Ok(Self {
|
||||
monotonic,
|
||||
resolutions: PerResolution {
|
||||
minute10: period!(minute10),
|
||||
minute30: period!(minute30),
|
||||
hour1: period!(hour1),
|
||||
hour4: period!(hour4),
|
||||
hour12: period!(hour12),
|
||||
day1: period!(day1),
|
||||
day3: period!(day3),
|
||||
week1: period!(week1),
|
||||
month1: period!(month1),
|
||||
month3: period!(month3),
|
||||
month6: period!(month6),
|
||||
year1: period!(year1),
|
||||
year10: period!(year10),
|
||||
halving: ImportableVec::forced_import(db, "timestamp", version)?,
|
||||
epoch: ImportableVec::forced_import(db, "timestamp", version)?,
|
||||
},
|
||||
})
|
||||
}
|
||||
|
||||
pub(crate) fn compute_monotonic(
|
||||
&mut self,
|
||||
indexer: &brk_indexer::Indexer,
|
||||
starting_height: Height,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
let mut prev = None;
|
||||
self.monotonic.compute_transform(
|
||||
starting_height,
|
||||
&indexer.vecs.blocks.timestamp,
|
||||
|(h, timestamp, this)| {
|
||||
if prev.is_none()
|
||||
&& let Some(prev_h) = h.decremented()
|
||||
{
|
||||
prev.replace(this.collect_one(prev_h).unwrap());
|
||||
}
|
||||
let monotonic = prev.map_or(timestamp, |p| p.max(timestamp));
|
||||
prev.replace(monotonic);
|
||||
(h, monotonic)
|
||||
},
|
||||
exit,
|
||||
)?;
|
||||
Ok(())
|
||||
}
|
||||
|
||||
pub(crate) fn compute_per_resolution(
|
||||
&mut self,
|
||||
indexer: &brk_indexer::Indexer,
|
||||
height: &super::HeightVecs,
|
||||
halving_vecs: &super::HalvingVecs,
|
||||
epoch_vecs: &super::EpochVecs,
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
let prev_height = starting_indexes.height.decremented().unwrap_or_default();
|
||||
self.resolutions.halving.compute_indirect_sequential(
|
||||
height.halving.collect_one(prev_height).unwrap_or_default(),
|
||||
&halving_vecs.first_height,
|
||||
&indexer.vecs.blocks.timestamp,
|
||||
exit,
|
||||
)?;
|
||||
self.resolutions.epoch.compute_indirect_sequential(
|
||||
height.epoch.collect_one(prev_height).unwrap_or_default(),
|
||||
&epoch_vecs.first_height,
|
||||
&indexer.vecs.blocks.timestamp,
|
||||
exit,
|
||||
)?;
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
@@ -16,6 +16,8 @@ impl Vecs {
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
self.db.sync_bg_tasks()?;
|
||||
|
||||
// Puell Multiple: daily_subsidy_usd / sma_365d_subsidy_usd
|
||||
self.puell_multiple
|
||||
.bps
|
||||
@@ -199,8 +201,11 @@ impl Vecs {
|
||||
exit,
|
||||
)?;
|
||||
|
||||
let _lock = exit.lock();
|
||||
self.db.compact()?;
|
||||
let exit = exit.clone();
|
||||
self.db.run_bg(move |db| {
|
||||
let _lock = exit.lock();
|
||||
db.compact()
|
||||
});
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@ use std::path::Path;
|
||||
use brk_error::Result;
|
||||
use brk_types::Version;
|
||||
|
||||
use super::Vecs;
|
||||
use super::{Vecs, realized_envelope::RealizedEnvelope};
|
||||
use crate::{
|
||||
indexes,
|
||||
internal::{PerBlock, PercentPerBlock, RatioPerBlock, db_utils::{finalize_db, open_db}},
|
||||
@@ -38,6 +38,8 @@ impl Vecs {
|
||||
let seller_exhaustion =
|
||||
PerBlock::forced_import(&db, "seller_exhaustion", v, indexes)?;
|
||||
|
||||
let realized_envelope = RealizedEnvelope::forced_import(&db, v, indexes)?;
|
||||
|
||||
let this = Self {
|
||||
db,
|
||||
puell_multiple,
|
||||
@@ -50,6 +52,7 @@ impl Vecs {
|
||||
dormancy,
|
||||
stock_to_flow,
|
||||
seller_exhaustion,
|
||||
realized_envelope,
|
||||
};
|
||||
finalize_db(&this.db, &this)?;
|
||||
Ok(this)
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
mod compute;
|
||||
mod gini;
|
||||
mod import;
|
||||
pub mod realized_envelope;
|
||||
mod vecs;
|
||||
|
||||
pub use vecs::Vecs;
|
||||
|
||||
@@ -0,0 +1,254 @@
|
||||
use brk_error::Result;
|
||||
use brk_traversable::Traversable;
|
||||
use brk_types::{Cents, Height, Indexes, StoredI8, Version};
|
||||
use vecdb::{AnyVec, Database, EagerVec, Exit, PcoVec, ReadableVec, Rw, StorageMode, WritableVec};
|
||||
|
||||
use crate::{
|
||||
cointime,
|
||||
distribution,
|
||||
indexes,
|
||||
internal::{PerBlock, Price, RatioPerBlockPercentiles},
|
||||
prices,
|
||||
};
|
||||
|
||||
#[derive(Traversable)]
|
||||
pub struct RealizedEnvelope<M: StorageMode = Rw> {
|
||||
pub pct0_5: Price<PerBlock<Cents, M>>,
|
||||
pub pct1: Price<PerBlock<Cents, M>>,
|
||||
pub pct2: Price<PerBlock<Cents, M>>,
|
||||
pub pct5: Price<PerBlock<Cents, M>>,
|
||||
pub pct95: Price<PerBlock<Cents, M>>,
|
||||
pub pct98: Price<PerBlock<Cents, M>>,
|
||||
pub pct99: Price<PerBlock<Cents, M>>,
|
||||
pub pct99_5: Price<PerBlock<Cents, M>>,
|
||||
pub index: PerBlock<StoredI8, M>,
|
||||
pub score: PerBlock<StoredI8, M>,
|
||||
}
|
||||
|
||||
const VERSION: Version = Version::new(3);
|
||||
|
||||
impl RealizedEnvelope {
|
||||
pub(crate) fn forced_import(
|
||||
db: &Database,
|
||||
version: Version,
|
||||
indexes: &indexes::Vecs,
|
||||
) -> Result<Self> {
|
||||
let v = version + VERSION;
|
||||
Ok(Self {
|
||||
pct0_5: Price::forced_import(db, "realized_envelope_pct0_5", v, indexes)?,
|
||||
pct1: Price::forced_import(db, "realized_envelope_pct01", v, indexes)?,
|
||||
pct2: Price::forced_import(db, "realized_envelope_pct02", v, indexes)?,
|
||||
pct5: Price::forced_import(db, "realized_envelope_pct05", v, indexes)?,
|
||||
pct95: Price::forced_import(db, "realized_envelope_pct95", v, indexes)?,
|
||||
pct98: Price::forced_import(db, "realized_envelope_pct98", v, indexes)?,
|
||||
pct99: Price::forced_import(db, "realized_envelope_pct99", v, indexes)?,
|
||||
pct99_5: Price::forced_import(db, "realized_envelope_pct99_5", v, indexes)?,
|
||||
index: PerBlock::forced_import(db, "realized_envelope_index", v, indexes)?,
|
||||
score: PerBlock::forced_import(db, "realized_envelope_score", v, indexes)?,
|
||||
})
|
||||
}
|
||||
|
||||
pub(crate) fn compute(
|
||||
&mut self,
|
||||
distribution: &distribution::Vecs,
|
||||
cointime: &cointime::Vecs,
|
||||
prices: &prices::Vecs,
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
let realized = &distribution.utxo_cohorts.all.metrics.realized;
|
||||
let ct = &cointime.prices;
|
||||
|
||||
let sth_realized = &distribution.utxo_cohorts.sth.metrics.realized;
|
||||
let lth_realized = &distribution.utxo_cohorts.lth.metrics.realized;
|
||||
|
||||
let models: [&RatioPerBlockPercentiles; 10] = [
|
||||
&realized.price_ratio_percentiles,
|
||||
&realized.investor.price.percentiles,
|
||||
&sth_realized.price_ratio_percentiles,
|
||||
&sth_realized.investor.price.percentiles,
|
||||
<h_realized.price_ratio_percentiles,
|
||||
<h_realized.investor.price.percentiles,
|
||||
&ct.vaulted.percentiles,
|
||||
&ct.active.percentiles,
|
||||
&ct.true_market_mean.percentiles,
|
||||
&ct.cointime.percentiles,
|
||||
];
|
||||
|
||||
macro_rules! sources {
|
||||
($pct:ident) => {
|
||||
models.each_ref().map(|m| &m.$pct.price.cents.height)
|
||||
};
|
||||
}
|
||||
|
||||
// Lower percentiles: max across all models (tightest lower bound)
|
||||
self.pct0_5.cents.height.compute_max_of_others(starting_indexes.height, &sources!(pct0_5), exit)?;
|
||||
self.pct1.cents.height.compute_max_of_others(starting_indexes.height, &sources!(pct1), exit)?;
|
||||
self.pct2.cents.height.compute_max_of_others(starting_indexes.height, &sources!(pct2), exit)?;
|
||||
self.pct5.cents.height.compute_max_of_others(starting_indexes.height, &sources!(pct5), exit)?;
|
||||
|
||||
// Upper percentiles: min across all models (tightest upper bound)
|
||||
self.pct95.cents.height.compute_min_of_others(starting_indexes.height, &sources!(pct95), exit)?;
|
||||
self.pct98.cents.height.compute_min_of_others(starting_indexes.height, &sources!(pct98), exit)?;
|
||||
self.pct99.cents.height.compute_min_of_others(starting_indexes.height, &sources!(pct99), exit)?;
|
||||
self.pct99_5.cents.height.compute_min_of_others(starting_indexes.height, &sources!(pct99_5), exit)?;
|
||||
|
||||
let spot = &prices.spot.cents.height;
|
||||
|
||||
// Zone: spot vs own envelope bands (-4 to +4)
|
||||
self.compute_index(spot, starting_indexes, exit)?;
|
||||
|
||||
// Temperature: per-model band crossings (-40 to +40)
|
||||
self.compute_score(&models, spot, starting_indexes, exit)?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
fn compute_index(
|
||||
&mut self,
|
||||
spot: &EagerVec<PcoVec<Height, Cents>>,
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
let bands: [&_; 8] = [
|
||||
&self.pct0_5.cents.height,
|
||||
&self.pct1.cents.height,
|
||||
&self.pct2.cents.height,
|
||||
&self.pct5.cents.height,
|
||||
&self.pct95.cents.height,
|
||||
&self.pct98.cents.height,
|
||||
&self.pct99.cents.height,
|
||||
&self.pct99_5.cents.height,
|
||||
];
|
||||
|
||||
let dep_version: Version = bands.iter().map(|b| b.version()).sum::<Version>() + spot.version();
|
||||
|
||||
self.index.height.validate_computed_version_or_reset(dep_version)?;
|
||||
self.index.height.truncate_if_needed(starting_indexes.height)?;
|
||||
|
||||
self.index.height.repeat_until_complete(exit, |vec| {
|
||||
let skip = vec.len();
|
||||
let source_end = bands.iter().map(|b| b.len()).min().unwrap().min(spot.len());
|
||||
let end = vec.batch_end(source_end);
|
||||
|
||||
if skip >= end {
|
||||
return Ok(());
|
||||
}
|
||||
|
||||
let spot_batch = spot.collect_range_at(skip, end);
|
||||
let b: [Vec<Cents>; 8] = bands.each_ref().map(|v| v.collect_range_at(skip, end));
|
||||
|
||||
for j in 0..(end - skip) {
|
||||
let price = spot_batch[j];
|
||||
let mut score: i8 = 0;
|
||||
|
||||
if price < b[3][j] { score -= 1; }
|
||||
if price < b[2][j] { score -= 1; }
|
||||
if price < b[1][j] { score -= 1; }
|
||||
if price < b[0][j] { score -= 1; }
|
||||
if price > b[4][j] { score += 1; }
|
||||
if price > b[5][j] { score += 1; }
|
||||
if price > b[6][j] { score += 1; }
|
||||
if price > b[7][j] { score += 1; }
|
||||
|
||||
vec.push(StoredI8::new(score));
|
||||
}
|
||||
|
||||
Ok(())
|
||||
})?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
fn compute_score(
|
||||
&mut self,
|
||||
models: &[&RatioPerBlockPercentiles; 10],
|
||||
spot: &EagerVec<PcoVec<Height, Cents>>,
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
let dep_version: Version = models
|
||||
.iter()
|
||||
.map(|p| {
|
||||
p.pct0_5.price.cents.height.version()
|
||||
+ p.pct1.price.cents.height.version()
|
||||
+ p.pct2.price.cents.height.version()
|
||||
+ p.pct5.price.cents.height.version()
|
||||
+ p.pct95.price.cents.height.version()
|
||||
+ p.pct98.price.cents.height.version()
|
||||
+ p.pct99.price.cents.height.version()
|
||||
+ p.pct99_5.price.cents.height.version()
|
||||
})
|
||||
.sum::<Version>()
|
||||
+ spot.version();
|
||||
|
||||
self.score.height.validate_computed_version_or_reset(dep_version)?;
|
||||
self.score.height.truncate_if_needed(starting_indexes.height)?;
|
||||
|
||||
self.score.height.repeat_until_complete(exit, |vec| {
|
||||
let skip = vec.len();
|
||||
let source_end = models
|
||||
.iter()
|
||||
.flat_map(|p| {
|
||||
[
|
||||
p.pct0_5.price.cents.height.len(),
|
||||
p.pct1.price.cents.height.len(),
|
||||
p.pct2.price.cents.height.len(),
|
||||
p.pct5.price.cents.height.len(),
|
||||
p.pct95.price.cents.height.len(),
|
||||
p.pct98.price.cents.height.len(),
|
||||
p.pct99.price.cents.height.len(),
|
||||
p.pct99_5.price.cents.height.len(),
|
||||
]
|
||||
})
|
||||
.min()
|
||||
.unwrap()
|
||||
.min(spot.len());
|
||||
let end = vec.batch_end(source_end);
|
||||
|
||||
if skip >= end {
|
||||
return Ok(());
|
||||
}
|
||||
|
||||
let spot_batch = spot.collect_range_at(skip, end);
|
||||
|
||||
let bands: Vec<[Vec<Cents>; 8]> = models
|
||||
.iter()
|
||||
.map(|p| {
|
||||
[
|
||||
p.pct0_5.price.cents.height.collect_range_at(skip, end),
|
||||
p.pct1.price.cents.height.collect_range_at(skip, end),
|
||||
p.pct2.price.cents.height.collect_range_at(skip, end),
|
||||
p.pct5.price.cents.height.collect_range_at(skip, end),
|
||||
p.pct95.price.cents.height.collect_range_at(skip, end),
|
||||
p.pct98.price.cents.height.collect_range_at(skip, end),
|
||||
p.pct99.price.cents.height.collect_range_at(skip, end),
|
||||
p.pct99_5.price.cents.height.collect_range_at(skip, end),
|
||||
]
|
||||
})
|
||||
.collect();
|
||||
|
||||
for j in 0..(end - skip) {
|
||||
let price = spot_batch[j];
|
||||
let mut total: i8 = 0;
|
||||
|
||||
for model in &bands {
|
||||
if price < model[3][j] { total -= 1; }
|
||||
if price < model[2][j] { total -= 1; }
|
||||
if price < model[1][j] { total -= 1; }
|
||||
if price < model[0][j] { total -= 1; }
|
||||
if price > model[4][j] { total += 1; }
|
||||
if price > model[5][j] { total += 1; }
|
||||
if price > model[6][j] { total += 1; }
|
||||
if price > model[7][j] { total += 1; }
|
||||
}
|
||||
|
||||
vec.push(StoredI8::new(total));
|
||||
}
|
||||
|
||||
Ok(())
|
||||
})?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
@@ -2,6 +2,7 @@ use brk_traversable::Traversable;
|
||||
use brk_types::{BasisPoints16, BasisPoints32, StoredF32};
|
||||
use vecdb::{Database, Rw, StorageMode};
|
||||
|
||||
use super::realized_envelope::RealizedEnvelope;
|
||||
use crate::internal::{PerBlock, PercentPerBlock, RatioPerBlock};
|
||||
|
||||
#[derive(Traversable)]
|
||||
@@ -24,4 +25,5 @@ pub struct Vecs<M: StorageMode = Rw> {
|
||||
pub dormancy: DormancyVecs<M>,
|
||||
pub stock_to_flow: PerBlock<StoredF32, M>,
|
||||
pub seller_exhaustion: PerBlock<StoredF32, M>,
|
||||
pub realized_envelope: RealizedEnvelope<M>,
|
||||
}
|
||||
|
||||
@@ -15,13 +15,18 @@ impl Vecs {
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
self.db.sync_bg_tasks()?;
|
||||
|
||||
self.spent
|
||||
.compute(indexer, starting_indexes, exit)?;
|
||||
self.count
|
||||
.compute(indexer, indexes, blocks, starting_indexes, exit)?;
|
||||
|
||||
let _lock = exit.lock();
|
||||
self.db.compact()?;
|
||||
let exit = exit.clone();
|
||||
self.db.run_bg(move |db| {
|
||||
let _lock = exit.lock();
|
||||
db.compact()
|
||||
});
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -71,20 +71,20 @@ impl ExpandingPercentiles {
|
||||
self.tree.add(Self::to_bucket(value), &1);
|
||||
}
|
||||
|
||||
/// Compute 6 percentiles in one call via kth. O(6 × log N) but with
|
||||
/// shared tree traversal across all 6 targets for better cache locality.
|
||||
/// Compute 8 percentiles in one call via kth. O(8 × log N) but with
|
||||
/// shared tree traversal across all 8 targets for better cache locality.
|
||||
/// Quantiles q must be sorted ascending in (0, 1). Output is in BPS.
|
||||
pub fn quantiles(&self, qs: &[f64; 6], out: &mut [u32; 6]) {
|
||||
pub fn quantiles(&self, qs: &[f64; 8], out: &mut [u32; 8]) {
|
||||
if self.count == 0 {
|
||||
out.iter_mut().for_each(|o| *o = 0);
|
||||
return;
|
||||
}
|
||||
let mut targets = [0u32; 6];
|
||||
let mut targets = [0u32; 8];
|
||||
for (i, &q) in qs.iter().enumerate() {
|
||||
let k = ((q * self.count as f64).ceil() as u32).clamp(1, self.count);
|
||||
targets[i] = k - 1; // 0-indexed
|
||||
}
|
||||
let mut buckets = [0usize; 6];
|
||||
let mut buckets = [0usize; 8];
|
||||
self.tree.kth(&targets, &|n: &u32| *n, &mut buckets);
|
||||
for (i, bucket) in buckets.iter().enumerate() {
|
||||
out[i] = *bucket as u32 * BUCKET_BPS as u32;
|
||||
@@ -97,8 +97,8 @@ mod tests {
|
||||
use super::*;
|
||||
|
||||
fn quantile(ep: &ExpandingPercentiles, q: f64) -> u32 {
|
||||
let mut out = [0u32; 6];
|
||||
ep.quantiles(&[q, q, q, q, q, q], &mut out);
|
||||
let mut out = [0u32; 8];
|
||||
ep.quantiles(&[q, q, q, q, q, q, q, q], &mut out);
|
||||
out[0]
|
||||
}
|
||||
|
||||
|
||||
@@ -22,18 +22,20 @@ pub struct RatioBand<M: StorageMode = Rw> {
|
||||
|
||||
#[derive(Traversable)]
|
||||
pub struct RatioPerBlockPercentiles<M: StorageMode = Rw> {
|
||||
pub pct99_5: RatioBand<M>,
|
||||
pub pct99: RatioBand<M>,
|
||||
pub pct98: RatioBand<M>,
|
||||
pub pct95: RatioBand<M>,
|
||||
pub pct5: RatioBand<M>,
|
||||
pub pct2: RatioBand<M>,
|
||||
pub pct1: RatioBand<M>,
|
||||
pub pct0_5: RatioBand<M>,
|
||||
|
||||
#[traversable(skip)]
|
||||
expanding_pct: ExpandingPercentiles,
|
||||
}
|
||||
|
||||
const VERSION: Version = Version::new(5);
|
||||
const VERSION: Version = Version::new(6);
|
||||
|
||||
/// First height included in ratio percentile computation (first halving).
|
||||
/// Earlier blocks lack meaningful market data and pollute the distribution.
|
||||
@@ -70,12 +72,14 @@ impl RatioPerBlockPercentiles {
|
||||
}
|
||||
|
||||
Ok(Self {
|
||||
pct99_5: import_band!("pct99_5"),
|
||||
pct99: import_band!("pct99"),
|
||||
pct98: import_band!("pct98"),
|
||||
pct95: import_band!("pct95"),
|
||||
pct5: import_band!("pct5"),
|
||||
pct2: import_band!("pct2"),
|
||||
pct1: import_band!("pct1"),
|
||||
pct0_5: import_band!("pct0_5"),
|
||||
expanding_pct: ExpandingPercentiles::default(),
|
||||
})
|
||||
}
|
||||
@@ -114,16 +118,18 @@ impl RatioPerBlockPercentiles {
|
||||
}
|
||||
|
||||
let new_ratios = ratio_source.collect_range_at(start, ratio_len);
|
||||
let mut pct_vecs: [&mut EagerVec<PcoVec<Height, BasisPoints32>>; 6] = [
|
||||
let mut pct_vecs: [&mut EagerVec<PcoVec<Height, BasisPoints32>>; 8] = [
|
||||
&mut self.pct0_5.ratio.bps.height,
|
||||
&mut self.pct1.ratio.bps.height,
|
||||
&mut self.pct2.ratio.bps.height,
|
||||
&mut self.pct5.ratio.bps.height,
|
||||
&mut self.pct95.ratio.bps.height,
|
||||
&mut self.pct98.ratio.bps.height,
|
||||
&mut self.pct99.ratio.bps.height,
|
||||
&mut self.pct99_5.ratio.bps.height,
|
||||
];
|
||||
const PCTS: [f64; 6] = [0.01, 0.02, 0.05, 0.95, 0.98, 0.99];
|
||||
let mut out = [0u32; 6];
|
||||
const PCTS: [f64; 8] = [0.005, 0.01, 0.02, 0.05, 0.95, 0.98, 0.99, 0.995];
|
||||
let mut out = [0u32; 8];
|
||||
|
||||
for vec in pct_vecs.iter_mut() {
|
||||
vec.truncate_if_needed_at(start)?;
|
||||
@@ -160,12 +166,14 @@ impl RatioPerBlockPercentiles {
|
||||
};
|
||||
}
|
||||
|
||||
compute_band!(pct99_5);
|
||||
compute_band!(pct99);
|
||||
compute_band!(pct98);
|
||||
compute_band!(pct95);
|
||||
compute_band!(pct5);
|
||||
compute_band!(pct2);
|
||||
compute_band!(pct1);
|
||||
compute_band!(pct0_5);
|
||||
|
||||
Ok(())
|
||||
}
|
||||
@@ -174,12 +182,14 @@ impl RatioPerBlockPercentiles {
|
||||
&mut self,
|
||||
) -> impl Iterator<Item = &mut EagerVec<PcoVec<Height, BasisPoints32>>> {
|
||||
[
|
||||
&mut self.pct0_5.ratio.bps.height,
|
||||
&mut self.pct1.ratio.bps.height,
|
||||
&mut self.pct2.ratio.bps.height,
|
||||
&mut self.pct5.ratio.bps.height,
|
||||
&mut self.pct95.ratio.bps.height,
|
||||
&mut self.pct98.ratio.bps.height,
|
||||
&mut self.pct99.ratio.bps.height,
|
||||
&mut self.pct99_5.ratio.bps.height,
|
||||
]
|
||||
.into_iter()
|
||||
}
|
||||
|
||||
+22
@@ -1,5 +1,7 @@
|
||||
use brk_traversable::Traversable;
|
||||
|
||||
use crate::market::lookback::ByLookbackPeriod;
|
||||
|
||||
/// DCA period identifiers with their day counts
|
||||
pub const DCA_PERIOD_DAYS: ByDcaPeriod<u32> = ByDcaPeriod {
|
||||
_1w: 7,
|
||||
@@ -173,6 +175,26 @@ impl<T> ByDcaPeriod<T> {
|
||||
}
|
||||
}
|
||||
|
||||
impl<T> ByDcaPeriod<&T> {
|
||||
/// Get the DCA-matching subset from lookback (excludes 24h)
|
||||
pub(crate) fn from_lookback(lookback: &ByLookbackPeriod<T>) -> ByDcaPeriod<&T> {
|
||||
ByDcaPeriod {
|
||||
_1w: &lookback._1w,
|
||||
_1m: &lookback._1m,
|
||||
_3m: &lookback._3m,
|
||||
_6m: &lookback._6m,
|
||||
_1y: &lookback._1y,
|
||||
_2y: &lookback._2y,
|
||||
_3y: &lookback._3y,
|
||||
_4y: &lookback._4y,
|
||||
_5y: &lookback._5y,
|
||||
_6y: &lookback._6y,
|
||||
_8y: &lookback._8y,
|
||||
_10y: &lookback._10y,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Generic wrapper for DCA CAGR data (periods >= 2 years)
|
||||
#[derive(Clone, Default, Traversable)]
|
||||
pub struct ByDcaCagr<T> {
|
||||
+44
-42
@@ -2,8 +2,8 @@ use brk_error::Result;
|
||||
use brk_types::{BasisPointsSigned32, Bitcoin, Cents, Date, Day1, Dollars, Indexes, Sats};
|
||||
use vecdb::{AnyVec, Exit, ReadableOptionVec, ReadableVec, VecIndex};
|
||||
|
||||
use super::Vecs;
|
||||
use crate::{blocks, indexes, internal::RatioDiffCentsBps32, market::lookback, prices};
|
||||
use super::{ByDcaPeriod, Vecs};
|
||||
use crate::{blocks, indexes, internal::RatioDiffCentsBps32, market, prices};
|
||||
|
||||
const DCA_AMOUNT: Dollars = Dollars::mint(100.0);
|
||||
|
||||
@@ -13,10 +13,12 @@ impl Vecs {
|
||||
indexes: &indexes::Vecs,
|
||||
prices: &prices::Vecs,
|
||||
blocks: &blocks::Vecs,
|
||||
lookback: &lookback::Vecs,
|
||||
lookback: &market::lookback::Vecs,
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
self.db.sync_bg_tasks()?;
|
||||
|
||||
let h2d = &indexes.height.day1;
|
||||
let close = &prices.split.close.usd.day1;
|
||||
|
||||
@@ -50,7 +52,7 @@ impl Vecs {
|
||||
}
|
||||
|
||||
// DCA by period - stack (rolling sum via _start vecs)
|
||||
for (stack, days) in self.period.stack.iter_mut_with_days() {
|
||||
for (stack, days) in self.period.dca_stack.iter_mut_with_days() {
|
||||
let window_starts = blocks.lookback.start_vec(days as usize);
|
||||
stack.sats.height.compute_rolling_sum(
|
||||
starting_indexes.height,
|
||||
@@ -61,27 +63,24 @@ impl Vecs {
|
||||
}
|
||||
|
||||
// DCA by period - stack cents (sats × price)
|
||||
for stack in self.period.stack.iter_mut() {
|
||||
for stack in self.period.dca_stack.iter_mut() {
|
||||
stack.compute(prices, starting_indexes.height, exit)?;
|
||||
}
|
||||
|
||||
// DCA by period - average price (derived from stack)
|
||||
let starting_height = starting_indexes.height.to_usize();
|
||||
for (average_price, stack, days) in
|
||||
self.period.cost_basis.zip_mut_with_days(&self.period.stack)
|
||||
for (average_price, stack, days) in self
|
||||
.period
|
||||
.dca_cost_basis
|
||||
.zip_mut_with_days(&self.period.dca_stack)
|
||||
{
|
||||
let days = days as usize;
|
||||
let start = average_price.cents.height.len().min(starting_height);
|
||||
let stack_data = stack
|
||||
.sats
|
||||
.height
|
||||
.collect_range_at(start, stack.sats.height.len());
|
||||
average_price.cents.height.compute_transform(
|
||||
average_price.cents.height.compute_transform2(
|
||||
starting_indexes.height,
|
||||
h2d,
|
||||
|(h, di, _)| {
|
||||
&stack.sats.height,
|
||||
|(h, di, stack_sats, ..)| {
|
||||
let di_usize = di.to_usize();
|
||||
let stack_sats = stack_data[h.to_usize() - start];
|
||||
let avg = if di_usize > first_price_di {
|
||||
let num_days = days.min(di_usize + 1 - first_price_di);
|
||||
Cents::from(DCA_AMOUNT * num_days / Bitcoin::from(stack_sats))
|
||||
@@ -97,9 +96,9 @@ impl Vecs {
|
||||
// DCA by period - returns (compute from average price)
|
||||
for (returns, (average_price, _)) in self
|
||||
.period
|
||||
.r#return
|
||||
.dca_return
|
||||
.iter_mut()
|
||||
.zip(self.period.cost_basis.iter_with_days())
|
||||
.zip(self.period.dca_cost_basis.iter_with_days())
|
||||
{
|
||||
returns.compute_binary::<Cents, Cents, RatioDiffCentsBps32>(
|
||||
starting_indexes.height,
|
||||
@@ -110,7 +109,11 @@ impl Vecs {
|
||||
}
|
||||
|
||||
// DCA by period - CAGR (computed from returns at height level)
|
||||
for (cagr, returns, days) in self.period.cagr.zip_mut_with_period(&self.period.r#return) {
|
||||
for (cagr, returns, days) in self
|
||||
.period
|
||||
.dca_cagr
|
||||
.zip_mut_with_period(&self.period.dca_return)
|
||||
{
|
||||
let years = days as f64 / 365.0;
|
||||
cagr.bps.height.compute_transform(
|
||||
starting_indexes.height,
|
||||
@@ -125,21 +128,16 @@ impl Vecs {
|
||||
}
|
||||
|
||||
// Lump sum by period - stack
|
||||
let lookback_dca = lookback.price_past.as_dca_period();
|
||||
let lookback_dca = ByDcaPeriod::from_lookback(&lookback.price_past);
|
||||
for (stack, lookback_price, days) in
|
||||
self.period.lump_sum_stack.zip_mut_with_days(&lookback_dca)
|
||||
{
|
||||
let total_invested = DCA_AMOUNT * days as usize;
|
||||
let ls_start = stack.sats.height.len().min(starting_height);
|
||||
let lookback_data = lookback_price
|
||||
.cents
|
||||
.height
|
||||
.collect_range_at(ls_start, lookback_price.cents.height.len());
|
||||
stack.sats.height.compute_transform(
|
||||
stack.sats.height.compute_transform2(
|
||||
starting_indexes.height,
|
||||
h2d,
|
||||
|(h, _di, _)| {
|
||||
let lp = lookback_data[h.to_usize() - ls_start];
|
||||
&lookback_price.cents.height,
|
||||
|(h, _di, lp, ..)| {
|
||||
let sats = if lp == Cents::ZERO {
|
||||
Sats::ZERO
|
||||
} else {
|
||||
@@ -173,11 +171,15 @@ impl Vecs {
|
||||
|
||||
// DCA by year class - stack (cumulative sum from class start date)
|
||||
let start_days = super::ByDcaClass::<()>::start_days();
|
||||
for (stack, day1) in self.class.stack.iter_mut().zip(start_days) {
|
||||
for (stack, day1) in self.class.dca_stack.iter_mut().zip(start_days) {
|
||||
let mut last_di: Option<Day1> = None;
|
||||
let cls_start = stack.sats.height.len().min(starting_height);
|
||||
let mut prev_value = if cls_start > 0 {
|
||||
stack.sats.height.collect_one_at(cls_start - 1).unwrap_or_default()
|
||||
stack
|
||||
.sats
|
||||
.height
|
||||
.collect_one_at(cls_start - 1)
|
||||
.unwrap_or_default()
|
||||
} else {
|
||||
Sats::ZERO
|
||||
};
|
||||
@@ -224,7 +226,7 @@ impl Vecs {
|
||||
}
|
||||
|
||||
// DCA by year class - stack cents (sats × price)
|
||||
for stack in self.class.stack.iter_mut() {
|
||||
for stack in self.class.dca_stack.iter_mut() {
|
||||
stack.compute(prices, starting_indexes.height, exit)?;
|
||||
}
|
||||
|
||||
@@ -232,26 +234,21 @@ impl Vecs {
|
||||
let start_days = super::ByDcaClass::<()>::start_days();
|
||||
for ((average_price, stack), from) in self
|
||||
.class
|
||||
.cost_basis
|
||||
.dca_cost_basis
|
||||
.iter_mut()
|
||||
.zip(self.class.stack.iter())
|
||||
.zip(self.class.dca_stack.iter())
|
||||
.zip(start_days)
|
||||
{
|
||||
let from_usize = from.to_usize();
|
||||
let cls_start = average_price.cents.height.len().min(starting_height);
|
||||
let stack_data = stack
|
||||
.sats
|
||||
.height
|
||||
.collect_range_at(cls_start, stack.sats.height.len());
|
||||
average_price.cents.height.compute_transform(
|
||||
average_price.cents.height.compute_transform2(
|
||||
starting_indexes.height,
|
||||
h2d,
|
||||
|(h, di, _)| {
|
||||
&stack.sats.height,
|
||||
|(h, di, stack_sats, ..)| {
|
||||
let di_usize = di.to_usize();
|
||||
if di_usize < from_usize {
|
||||
return (h, Cents::ZERO);
|
||||
}
|
||||
let stack_sats = stack_data[h.to_usize() - cls_start];
|
||||
let num_days = di_usize + 1 - from_usize;
|
||||
let avg = Cents::from(DCA_AMOUNT * num_days / Bitcoin::from(stack_sats));
|
||||
(h, avg)
|
||||
@@ -263,9 +260,9 @@ impl Vecs {
|
||||
// DCA by year class - returns (compute from average price)
|
||||
for (returns, average_price) in self
|
||||
.class
|
||||
.r#return
|
||||
.dca_return
|
||||
.iter_mut()
|
||||
.zip(self.class.cost_basis.iter())
|
||||
.zip(self.class.dca_cost_basis.iter())
|
||||
{
|
||||
returns.compute_binary::<Cents, Cents, RatioDiffCentsBps32>(
|
||||
starting_indexes.height,
|
||||
@@ -275,6 +272,11 @@ impl Vecs {
|
||||
)?;
|
||||
}
|
||||
|
||||
let exit = exit.clone();
|
||||
self.db.run_bg(move |db| {
|
||||
let _lock = exit.lock();
|
||||
db.compact()
|
||||
});
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,86 @@
|
||||
use std::path::Path;
|
||||
|
||||
use brk_error::Result;
|
||||
use brk_types::Version;
|
||||
use vecdb::ImportableVec;
|
||||
|
||||
use super::vecs::{ClassVecs, PeriodVecs};
|
||||
use super::{ByDcaCagr, ByDcaClass, ByDcaPeriod, Vecs};
|
||||
use crate::{
|
||||
indexes,
|
||||
internal::{
|
||||
AmountPerBlock, PercentPerBlock, Price,
|
||||
db_utils::{finalize_db, open_db},
|
||||
},
|
||||
};
|
||||
|
||||
impl Vecs {
|
||||
pub(crate) fn forced_import(
|
||||
parent_path: &Path,
|
||||
parent_version: Version,
|
||||
indexes: &indexes::Vecs,
|
||||
) -> Result<Self> {
|
||||
let db = open_db(parent_path, super::DB_NAME, 50_000)?;
|
||||
let version = parent_version;
|
||||
let stack = ByDcaPeriod::try_new(|name, _days| {
|
||||
AmountPerBlock::forced_import(&db, &format!("dca_stack_{name}"), version, indexes)
|
||||
})?;
|
||||
|
||||
let cost_basis = ByDcaPeriod::try_new(|name, _days| {
|
||||
Price::forced_import(&db, &format!("dca_cost_basis_{name}"), version, indexes)
|
||||
})?;
|
||||
|
||||
let r#return = ByDcaPeriod::try_new(|name, _days| {
|
||||
PercentPerBlock::forced_import(&db, &format!("dca_return_{name}"), version, indexes)
|
||||
})?;
|
||||
|
||||
let cagr = ByDcaCagr::try_new(|name, _days| {
|
||||
PercentPerBlock::forced_import(&db, &format!("dca_cagr_{name}"), version, indexes)
|
||||
})?;
|
||||
|
||||
let lump_sum_stack = ByDcaPeriod::try_new(|name, _days| {
|
||||
AmountPerBlock::forced_import(&db, &format!("lump_sum_stack_{name}"), version, indexes)
|
||||
})?;
|
||||
|
||||
let lump_sum_return = ByDcaPeriod::try_new(|name, _days| {
|
||||
PercentPerBlock::forced_import(
|
||||
&db,
|
||||
&format!("lump_sum_return_{name}"),
|
||||
version,
|
||||
indexes,
|
||||
)
|
||||
})?;
|
||||
|
||||
let class_stack = ByDcaClass::try_new(|name, _year, _day1| {
|
||||
AmountPerBlock::forced_import(&db, &format!("dca_stack_{name}"), version, indexes)
|
||||
})?;
|
||||
|
||||
let class_cost_basis = ByDcaClass::try_new(|name, _year, _day1| {
|
||||
Price::forced_import(&db, &format!("dca_cost_basis_{name}"), version, indexes)
|
||||
})?;
|
||||
|
||||
let class_return = ByDcaClass::try_new(|name, _year, _day1| {
|
||||
PercentPerBlock::forced_import(&db, &format!("dca_return_{name}"), version, indexes)
|
||||
})?;
|
||||
|
||||
let this = Self {
|
||||
sats_per_day: ImportableVec::forced_import(&db, "dca_sats_per_day", version)?,
|
||||
period: PeriodVecs {
|
||||
dca_stack: stack,
|
||||
dca_cost_basis: cost_basis,
|
||||
dca_return: r#return,
|
||||
dca_cagr: cagr,
|
||||
lump_sum_stack,
|
||||
lump_sum_return,
|
||||
},
|
||||
class: ClassVecs {
|
||||
dca_stack: class_stack,
|
||||
dca_cost_basis: class_cost_basis,
|
||||
dca_return: class_return,
|
||||
},
|
||||
db,
|
||||
};
|
||||
finalize_db(&this.db, &this)?;
|
||||
Ok(this)
|
||||
}
|
||||
}
|
||||
@@ -7,3 +7,5 @@ mod vecs;
|
||||
pub use by_class::*;
|
||||
pub use by_period::*;
|
||||
pub use vecs::Vecs;
|
||||
|
||||
pub const DB_NAME: &str = "investing";
|
||||
+10
-8
@@ -1,29 +1,31 @@
|
||||
use brk_traversable::Traversable;
|
||||
use brk_types::{BasisPointsSigned32, Cents, Height, Sats};
|
||||
use vecdb::{EagerVec, PcoVec, Rw, StorageMode};
|
||||
use vecdb::{Database, EagerVec, PcoVec, Rw, StorageMode};
|
||||
|
||||
use super::{ByDcaCagr, ByDcaClass, ByDcaPeriod};
|
||||
use crate::internal::{AmountPerBlock, PerBlock, PercentPerBlock, Price};
|
||||
|
||||
#[derive(Traversable)]
|
||||
pub struct PeriodVecs<M: StorageMode = Rw> {
|
||||
pub stack: ByDcaPeriod<AmountPerBlock<M>>,
|
||||
pub cost_basis: ByDcaPeriod<Price<PerBlock<Cents, M>>>,
|
||||
pub r#return: ByDcaPeriod<PercentPerBlock<BasisPointsSigned32, M>>,
|
||||
pub cagr: ByDcaCagr<PercentPerBlock<BasisPointsSigned32, M>>,
|
||||
pub dca_stack: ByDcaPeriod<AmountPerBlock<M>>,
|
||||
pub dca_cost_basis: ByDcaPeriod<Price<PerBlock<Cents, M>>>,
|
||||
pub dca_return: ByDcaPeriod<PercentPerBlock<BasisPointsSigned32, M>>,
|
||||
pub dca_cagr: ByDcaCagr<PercentPerBlock<BasisPointsSigned32, M>>,
|
||||
pub lump_sum_stack: ByDcaPeriod<AmountPerBlock<M>>,
|
||||
pub lump_sum_return: ByDcaPeriod<PercentPerBlock<BasisPointsSigned32, M>>,
|
||||
}
|
||||
|
||||
#[derive(Traversable)]
|
||||
pub struct ClassVecs<M: StorageMode = Rw> {
|
||||
pub stack: ByDcaClass<AmountPerBlock<M>>,
|
||||
pub cost_basis: ByDcaClass<Price<PerBlock<Cents, M>>>,
|
||||
pub r#return: ByDcaClass<PercentPerBlock<BasisPointsSigned32, M>>,
|
||||
pub dca_stack: ByDcaClass<AmountPerBlock<M>>,
|
||||
pub dca_cost_basis: ByDcaClass<Price<PerBlock<Cents, M>>>,
|
||||
pub dca_return: ByDcaClass<PercentPerBlock<BasisPointsSigned32, M>>,
|
||||
}
|
||||
|
||||
#[derive(Traversable)]
|
||||
pub struct Vecs<M: StorageMode = Rw> {
|
||||
#[traversable(skip)]
|
||||
pub(crate) db: Database,
|
||||
pub sats_per_day: M::Stored<EagerVec<PcoVec<Height, Sats>>>,
|
||||
pub period: PeriodVecs<M>,
|
||||
pub class: ClassVecs<M>,
|
||||
@@ -18,6 +18,7 @@ mod indicators;
|
||||
pub mod indexes;
|
||||
mod inputs;
|
||||
mod internal;
|
||||
mod investing;
|
||||
mod market;
|
||||
mod mining;
|
||||
mod outputs;
|
||||
@@ -39,6 +40,7 @@ pub struct Computer<M: StorageMode = Rw> {
|
||||
pub constants: Box<constants::Vecs>,
|
||||
pub indexes: Box<indexes::Vecs<M>>,
|
||||
pub indicators: Box<indicators::Vecs<M>>,
|
||||
pub investing: Box<investing::Vecs<M>>,
|
||||
pub market: Box<market::Vecs<M>>,
|
||||
pub pools: Box<pools::Vecs<M>>,
|
||||
pub prices: Box<prices::Vecs<M>>,
|
||||
@@ -180,8 +182,8 @@ impl Computer {
|
||||
|
||||
// Market, indicators, and distribution are independent; import in parallel.
|
||||
// Supply depends on distribution so it runs after.
|
||||
let (distribution, market, indicators) =
|
||||
timed("Imported distribution/market/indicators", || {
|
||||
let (distribution, market, indicators, investing) =
|
||||
timed("Imported distribution/market/indicators/investing", || {
|
||||
thread::scope(|s| -> Result<_> {
|
||||
let market_handle = big_thread().spawn_scoped(s, || -> Result<_> {
|
||||
Ok(Box::new(market::Vecs::forced_import(
|
||||
@@ -199,6 +201,14 @@ impl Computer {
|
||||
)?))
|
||||
})?;
|
||||
|
||||
let investing_handle = big_thread().spawn_scoped(s, || -> Result<_> {
|
||||
Ok(Box::new(investing::Vecs::forced_import(
|
||||
&computed_path,
|
||||
VERSION,
|
||||
&indexes,
|
||||
)?))
|
||||
})?;
|
||||
|
||||
let distribution = Box::new(distribution::Vecs::forced_import(
|
||||
&computed_path,
|
||||
VERSION,
|
||||
@@ -208,7 +218,8 @@ impl Computer {
|
||||
|
||||
let market = market_handle.join().unwrap()?;
|
||||
let indicators = indicators_handle.join().unwrap()?;
|
||||
Ok((distribution, market, indicators))
|
||||
let investing = investing_handle.join().unwrap()?;
|
||||
Ok((distribution, market, indicators, investing))
|
||||
})
|
||||
})?;
|
||||
|
||||
@@ -232,6 +243,7 @@ impl Computer {
|
||||
scripts,
|
||||
constants,
|
||||
indicators,
|
||||
investing,
|
||||
market,
|
||||
distribution,
|
||||
supply,
|
||||
@@ -260,6 +272,7 @@ impl Computer {
|
||||
cointime::DB_NAME,
|
||||
indicators::DB_NAME,
|
||||
indexes::DB_NAME,
|
||||
investing::DB_NAME,
|
||||
market::DB_NAME,
|
||||
pools::DB_NAME,
|
||||
prices::DB_NAME,
|
||||
@@ -305,7 +318,7 @@ impl Computer {
|
||||
|
||||
let mut starting_indexes = timed("Computed indexes", || {
|
||||
self.indexes
|
||||
.compute(indexer, &mut self.blocks, starting_indexes, exit)
|
||||
.compute(indexer, starting_indexes, exit)
|
||||
})?;
|
||||
|
||||
thread::scope(|scope| -> Result<()> {
|
||||
@@ -339,8 +352,8 @@ impl Computer {
|
||||
let market = scope.spawn(|| {
|
||||
timed("Computed market", || {
|
||||
self.market.compute(
|
||||
&self.indexes,
|
||||
&self.prices,
|
||||
&self.indexes,
|
||||
&self.blocks,
|
||||
&starting_indexes,
|
||||
exit,
|
||||
@@ -422,6 +435,19 @@ impl Computer {
|
||||
})
|
||||
});
|
||||
|
||||
let investing = scope.spawn(|| {
|
||||
timed("Computed investing", || {
|
||||
self.investing.compute(
|
||||
&self.indexes,
|
||||
&self.prices,
|
||||
&self.blocks,
|
||||
&self.market.lookback,
|
||||
&starting_indexes_clone,
|
||||
exit,
|
||||
)
|
||||
})
|
||||
});
|
||||
|
||||
timed("Computed distribution", || {
|
||||
self.distribution.compute(
|
||||
indexer,
|
||||
@@ -437,6 +463,7 @@ impl Computer {
|
||||
})?;
|
||||
|
||||
pools.join().unwrap()?;
|
||||
investing.join().unwrap()?;
|
||||
Ok(())
|
||||
})?;
|
||||
|
||||
@@ -485,6 +512,14 @@ impl Computer {
|
||||
Ok(())
|
||||
})?;
|
||||
|
||||
self.indicators.realized_envelope.compute(
|
||||
&self.distribution,
|
||||
&self.cointime,
|
||||
&self.prices,
|
||||
&starting_indexes,
|
||||
exit,
|
||||
)?;
|
||||
|
||||
info!("Total compute time: {:?}", compute_start.elapsed());
|
||||
Ok(())
|
||||
}
|
||||
@@ -517,7 +552,7 @@ macro_rules! impl_iter_named {
|
||||
}
|
||||
|
||||
impl_iter_named!(blocks, mining, transactions, scripts, positions, cointime,
|
||||
constants, indicators, indexes, market, pools, prices, distribution, supply, inputs, outputs);
|
||||
constants, indicators, indexes, investing, market, pools, prices, distribution, supply, inputs, outputs);
|
||||
|
||||
fn timed<T>(label: &str, f: impl FnOnce() -> T) -> T {
|
||||
let start = Instant::now();
|
||||
|
||||
@@ -3,13 +3,13 @@ use brk_types::{Indexes, StoredF32, Timestamp};
|
||||
use vecdb::{Exit, ReadableVec, VecIndex};
|
||||
|
||||
use super::Vecs;
|
||||
use crate::{blocks, prices};
|
||||
use crate::{indexes, prices};
|
||||
|
||||
impl Vecs {
|
||||
pub(crate) fn compute(
|
||||
&mut self,
|
||||
prices: &prices::Vecs,
|
||||
blocks: &blocks::Vecs,
|
||||
indexes: &indexes::Vecs,
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
@@ -24,7 +24,7 @@ impl Vecs {
|
||||
starting_indexes.height,
|
||||
&self.high.cents.height,
|
||||
&prices.spot.cents.height,
|
||||
&blocks.time.timestamp_monotonic,
|
||||
&indexes.timestamp.monotonic,
|
||||
|(i, ath, price, ts, slf)| {
|
||||
if ath_ts.is_none() {
|
||||
let idx = i.to_usize();
|
||||
|
||||
@@ -9,17 +9,19 @@ use super::Vecs;
|
||||
impl Vecs {
|
||||
pub(crate) fn compute(
|
||||
&mut self,
|
||||
indexes: &indexes::Vecs,
|
||||
prices: &prices::Vecs,
|
||||
indexes: &indexes::Vecs,
|
||||
blocks: &blocks::Vecs,
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
self.db.sync_bg_tasks()?;
|
||||
|
||||
// Phase 1: Independent sub-modules in parallel
|
||||
let (r1, r2) = rayon::join(
|
||||
|| {
|
||||
rayon::join(
|
||||
|| self.ath.compute(prices, blocks, starting_indexes, exit),
|
||||
|| self.ath.compute(prices, indexes, starting_indexes, exit),
|
||||
|| self.lookback.compute(blocks, prices, starting_indexes, exit),
|
||||
)
|
||||
},
|
||||
@@ -39,24 +41,8 @@ impl Vecs {
|
||||
r2.1?;
|
||||
|
||||
// Phase 2: Depend on lookback
|
||||
let (r3, r4) = rayon::join(
|
||||
|| {
|
||||
self.returns
|
||||
.compute(prices, blocks, &self.lookback, starting_indexes, exit)
|
||||
},
|
||||
|| {
|
||||
self.dca.compute(
|
||||
indexes,
|
||||
prices,
|
||||
blocks,
|
||||
&self.lookback,
|
||||
starting_indexes,
|
||||
exit,
|
||||
)
|
||||
},
|
||||
);
|
||||
r3?;
|
||||
r4?;
|
||||
self.returns
|
||||
.compute(prices, blocks, &self.lookback, starting_indexes, exit)?;
|
||||
|
||||
// Phase 3: Depends on returns, moving_average
|
||||
self.technical.compute(
|
||||
@@ -68,8 +54,11 @@ impl Vecs {
|
||||
exit,
|
||||
)?;
|
||||
|
||||
let _lock = exit.lock();
|
||||
self.db.compact()?;
|
||||
let exit = exit.clone();
|
||||
self.db.run_bg(move |db| {
|
||||
let _lock = exit.lock();
|
||||
db.compact()
|
||||
});
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,76 +0,0 @@
|
||||
use brk_error::Result;
|
||||
use brk_types::Version;
|
||||
use vecdb::{Database, ImportableVec};
|
||||
|
||||
use super::{ByDcaCagr, ByDcaClass, ByDcaPeriod, Vecs};
|
||||
use super::vecs::{ClassVecs, PeriodVecs};
|
||||
use crate::{
|
||||
indexes,
|
||||
internal::{AmountPerBlock, PercentPerBlock, Price},
|
||||
};
|
||||
|
||||
impl Vecs {
|
||||
pub(crate) fn forced_import(
|
||||
db: &Database,
|
||||
version: Version,
|
||||
indexes: &indexes::Vecs,
|
||||
) -> Result<Self> {
|
||||
let stack = ByDcaPeriod::try_new(|name, _days| {
|
||||
AmountPerBlock::forced_import(db, &format!("dca_stack_{name}"), version, indexes)
|
||||
})?;
|
||||
|
||||
let cost_basis = ByDcaPeriod::try_new(|name, _days| {
|
||||
Price::forced_import(db, &format!("dca_cost_basis_{name}"), version, indexes)
|
||||
})?;
|
||||
|
||||
let r#return = ByDcaPeriod::try_new(|name, _days| {
|
||||
PercentPerBlock::forced_import(db, &format!("dca_return_{name}"), version, indexes)
|
||||
})?;
|
||||
|
||||
let cagr = ByDcaCagr::try_new(|name, _days| {
|
||||
PercentPerBlock::forced_import(db, &format!("dca_cagr_{name}"), version, indexes)
|
||||
})?;
|
||||
|
||||
let lump_sum_stack = ByDcaPeriod::try_new(|name, _days| {
|
||||
AmountPerBlock::forced_import(db, &format!("lump_sum_stack_{name}"), version, indexes)
|
||||
})?;
|
||||
|
||||
let lump_sum_return = ByDcaPeriod::try_new(|name, _days| {
|
||||
PercentPerBlock::forced_import(
|
||||
db,
|
||||
&format!("lump_sum_return_{name}"),
|
||||
version,
|
||||
indexes,
|
||||
)
|
||||
})?;
|
||||
|
||||
let class_stack = ByDcaClass::try_new(|name, _year, _day1| {
|
||||
AmountPerBlock::forced_import(db, &format!("dca_stack_{name}"), version, indexes)
|
||||
})?;
|
||||
|
||||
let class_cost_basis = ByDcaClass::try_new(|name, _year, _day1| {
|
||||
Price::forced_import(db, &format!("dca_cost_basis_{name}"), version, indexes)
|
||||
})?;
|
||||
|
||||
let class_return = ByDcaClass::try_new(|name, _year, _day1| {
|
||||
PercentPerBlock::forced_import(db, &format!("dca_return_{name}"), version, indexes)
|
||||
})?;
|
||||
|
||||
Ok(Self {
|
||||
sats_per_day: ImportableVec::forced_import(db, "dca_sats_per_day", version)?,
|
||||
period: PeriodVecs {
|
||||
stack,
|
||||
cost_basis,
|
||||
r#return,
|
||||
cagr,
|
||||
lump_sum_stack,
|
||||
lump_sum_return,
|
||||
},
|
||||
class: ClassVecs {
|
||||
stack: class_stack,
|
||||
cost_basis: class_cost_basis,
|
||||
r#return: class_return,
|
||||
},
|
||||
})
|
||||
}
|
||||
}
|
||||
@@ -9,7 +9,7 @@ use crate::{
|
||||
};
|
||||
|
||||
use super::{
|
||||
AthVecs, DcaVecs, TechnicalVecs, LookbackVecs, MovingAverageVecs, RangeVecs, ReturnsVecs,
|
||||
AthVecs, TechnicalVecs, LookbackVecs, MovingAverageVecs, RangeVecs, ReturnsVecs,
|
||||
Vecs, VolatilityVecs,
|
||||
};
|
||||
|
||||
@@ -28,7 +28,6 @@ impl Vecs {
|
||||
let volatility = VolatilityVecs::forced_import(version, &returns)?;
|
||||
let range = RangeVecs::forced_import(&db, version, indexes)?;
|
||||
let moving_average = MovingAverageVecs::forced_import(&db, version, indexes)?;
|
||||
let dca = DcaVecs::forced_import(&db, version, indexes)?;
|
||||
let technical = TechnicalVecs::forced_import(&db, version, indexes)?;
|
||||
|
||||
let this = Self {
|
||||
@@ -39,7 +38,6 @@ impl Vecs {
|
||||
volatility,
|
||||
range,
|
||||
moving_average,
|
||||
dca,
|
||||
technical,
|
||||
};
|
||||
finalize_db(&this.db, &this)?;
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
use brk_traversable::Traversable;
|
||||
|
||||
use crate::market::dca::ByDcaPeriod;
|
||||
|
||||
/// Lookback period days (includes 24h, unlike DCA)
|
||||
pub const LOOKBACK_PERIOD_DAYS: ByLookbackPeriod<u32> = ByLookbackPeriod {
|
||||
_24h: 1,
|
||||
@@ -117,22 +115,4 @@ impl<T> ByLookbackPeriod<T> {
|
||||
]
|
||||
.into_iter()
|
||||
}
|
||||
|
||||
/// Get the DCA-matching subset (excludes 24h)
|
||||
pub(crate) fn as_dca_period(&self) -> ByDcaPeriod<&T> {
|
||||
ByDcaPeriod {
|
||||
_1w: &self._1w,
|
||||
_1m: &self._1m,
|
||||
_3m: &self._3m,
|
||||
_6m: &self._6m,
|
||||
_1y: &self._1y,
|
||||
_2y: &self._2y,
|
||||
_3y: &self._3y,
|
||||
_4y: &self._4y,
|
||||
_5y: &self._5y,
|
||||
_6y: &self._6y,
|
||||
_8y: &self._8y,
|
||||
_10y: &self._10y,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
pub mod ath;
|
||||
mod compute;
|
||||
pub mod dca;
|
||||
mod import;
|
||||
pub mod technical;
|
||||
pub mod lookback;
|
||||
@@ -13,7 +12,6 @@ use brk_traversable::Traversable;
|
||||
use vecdb::{Database, Rw, StorageMode};
|
||||
|
||||
pub use ath::Vecs as AthVecs;
|
||||
pub use dca::Vecs as DcaVecs;
|
||||
pub use technical::Vecs as TechnicalVecs;
|
||||
pub use lookback::Vecs as LookbackVecs;
|
||||
pub use moving_average::Vecs as MovingAverageVecs;
|
||||
@@ -32,6 +30,5 @@ pub struct Vecs<M: StorageMode = Rw> {
|
||||
pub volatility: VolatilityVecs,
|
||||
pub range: RangeVecs<M>,
|
||||
pub moving_average: MovingAverageVecs<M>,
|
||||
pub dca: DcaVecs<M>,
|
||||
pub technical: TechnicalVecs<M>,
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@ use brk_types::{BasisPointsSigned32, Dollars, Indexes};
|
||||
use vecdb::Exit;
|
||||
|
||||
use super::Vecs;
|
||||
use crate::{blocks, internal::RatioDiffDollarsBps32, market::lookback, prices};
|
||||
use crate::{blocks, internal::RatioDiffDollarsBps32, investing::ByDcaPeriod, market::lookback, prices};
|
||||
|
||||
impl Vecs {
|
||||
pub(crate) fn compute(
|
||||
@@ -29,7 +29,7 @@ impl Vecs {
|
||||
}
|
||||
|
||||
// CAGR computed from returns at height level (2y+ periods only)
|
||||
let price_return_dca = self.periods.as_dca_period();
|
||||
let price_return_dca = ByDcaPeriod::from_lookback(&self.periods);
|
||||
for (cagr, returns, days) in self.cagr.zip_mut_with_period(&price_return_dca) {
|
||||
let years = days as f64 / 365.0;
|
||||
cagr.bps.height.compute_transform(
|
||||
|
||||
@@ -7,7 +7,7 @@ use super::Vecs;
|
||||
use crate::{
|
||||
indexes,
|
||||
internal::{StdDevPerBlock, PercentPerBlock, Windows},
|
||||
market::dca::ByDcaCagr,
|
||||
investing::ByDcaCagr,
|
||||
};
|
||||
|
||||
impl Vecs {
|
||||
|
||||
@@ -4,7 +4,8 @@ use vecdb::{Rw, StorageMode};
|
||||
|
||||
use crate::{
|
||||
internal::{PercentPerBlock, StdDevPerBlock, Windows},
|
||||
market::{dca::ByDcaCagr, lookback::ByLookbackPeriod},
|
||||
investing::ByDcaCagr,
|
||||
market::lookback::ByLookbackPeriod,
|
||||
};
|
||||
|
||||
#[derive(Traversable)]
|
||||
|
||||
@@ -18,6 +18,8 @@ impl Vecs {
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
self.db.sync_bg_tasks()?;
|
||||
|
||||
// Block rewards (coinbase, subsidy, fee_dominance, etc.)
|
||||
self.rewards.compute(
|
||||
indexer,
|
||||
@@ -39,8 +41,11 @@ impl Vecs {
|
||||
exit,
|
||||
)?;
|
||||
|
||||
let _lock = exit.lock();
|
||||
self.db.compact()?;
|
||||
let exit = exit.clone();
|
||||
self.db.run_bg(move |db| {
|
||||
let _lock = exit.lock();
|
||||
db.compact()
|
||||
});
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -18,6 +18,8 @@ impl Vecs {
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
self.db.sync_bg_tasks()?;
|
||||
|
||||
self.count.compute(
|
||||
indexer,
|
||||
indexes,
|
||||
@@ -27,10 +29,13 @@ impl Vecs {
|
||||
starting_indexes,
|
||||
exit,
|
||||
)?;
|
||||
let _lock = self
|
||||
let lock = self
|
||||
.spent
|
||||
.compute(indexer, inputs, starting_indexes, exit)?;
|
||||
self.db.compact()?;
|
||||
self.db.run_bg(move |db| {
|
||||
let _lock = lock;
|
||||
db.compact()
|
||||
});
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -10,13 +10,13 @@ use crate::inputs;
|
||||
const HEIGHT_BATCH: u32 = 10_000;
|
||||
|
||||
impl Vecs {
|
||||
pub(crate) fn compute<'a>(
|
||||
pub(crate) fn compute(
|
||||
&mut self,
|
||||
indexer: &Indexer,
|
||||
inputs: &inputs::Vecs,
|
||||
starting_indexes: &Indexes,
|
||||
exit: &'a Exit,
|
||||
) -> Result<ExitGuard<'a>> {
|
||||
exit: &Exit,
|
||||
) -> Result<ExitGuard> {
|
||||
let target_height = indexer.vecs.blocks.blockhash.len();
|
||||
if target_height == 0 {
|
||||
return Ok(exit.lock());
|
||||
|
||||
@@ -86,6 +86,8 @@ impl Vecs {
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
self.db.sync_bg_tasks()?;
|
||||
|
||||
self.compute_pool(indexer, indexes, starting_indexes, exit)?;
|
||||
|
||||
self.major.par_iter_mut().try_for_each(|(_, vecs)| {
|
||||
@@ -103,8 +105,11 @@ impl Vecs {
|
||||
vecs.compute(starting_indexes, &self.pool, blocks, exit)
|
||||
})?;
|
||||
|
||||
let _lock = exit.lock();
|
||||
self.db.compact()?;
|
||||
let exit = exit.clone();
|
||||
self.db.run_bg(move |db| {
|
||||
let _lock = exit.lock();
|
||||
db.compact()
|
||||
});
|
||||
Ok(())
|
||||
}
|
||||
|
||||
|
||||
@@ -45,9 +45,14 @@ impl Vecs {
|
||||
reader: &Reader,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
self.db.sync_bg_tasks()?;
|
||||
|
||||
self.compute_(indexer, starting_indexes, reader, exit)?;
|
||||
let _lock = exit.lock();
|
||||
self.db.compact()?;
|
||||
let exit = exit.clone();
|
||||
self.db.run_bg(move |db| {
|
||||
let _lock = exit.lock();
|
||||
db.compact()
|
||||
});
|
||||
Ok(())
|
||||
}
|
||||
|
||||
|
||||
@@ -18,6 +18,8 @@ impl Vecs {
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
self.db.sync_bg_tasks()?;
|
||||
|
||||
self.compute_prices(indexer, starting_indexes, exit)?;
|
||||
self.split.open.cents.compute_first(
|
||||
starting_indexes,
|
||||
@@ -47,8 +49,11 @@ impl Vecs {
|
||||
exit,
|
||||
)?;
|
||||
|
||||
let _lock = exit.lock();
|
||||
self.db().compact()?;
|
||||
let exit = exit.clone();
|
||||
self.db.run_bg(move |db| {
|
||||
let _lock = exit.lock();
|
||||
db.compact()
|
||||
});
|
||||
Ok(())
|
||||
}
|
||||
|
||||
|
||||
@@ -25,7 +25,7 @@ pub const DB_NAME: &str = "prices";
|
||||
#[derive(Traversable)]
|
||||
pub struct Vecs<M: StorageMode = Rw> {
|
||||
#[traversable(skip)]
|
||||
pub(crate) db: Database,
|
||||
pub db: Database,
|
||||
|
||||
pub split: SplitByUnit<M>,
|
||||
pub ohlc: OhlcByUnit<M>,
|
||||
@@ -183,7 +183,4 @@ impl Vecs {
|
||||
})
|
||||
}
|
||||
|
||||
pub(crate) fn db(&self) -> &Database {
|
||||
&self.db
|
||||
}
|
||||
}
|
||||
|
||||
@@ -15,13 +15,18 @@ impl Vecs {
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
self.db.sync_bg_tasks()?;
|
||||
|
||||
self.count.compute(indexer, starting_indexes, exit)?;
|
||||
|
||||
self.value
|
||||
.compute(indexer, prices, starting_indexes, exit)?;
|
||||
|
||||
let _lock = exit.lock();
|
||||
self.db.compact()?;
|
||||
let exit = exit.clone();
|
||||
self.db.run_bg(move |db| {
|
||||
let _lock = exit.lock();
|
||||
db.compact()
|
||||
});
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -21,6 +21,8 @@ impl Vecs {
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
self.db.sync_bg_tasks()?;
|
||||
|
||||
// 1. Compute burned/unspendable supply
|
||||
self.burned.compute(
|
||||
scripts,
|
||||
@@ -76,8 +78,11 @@ impl Vecs {
|
||||
)?;
|
||||
}
|
||||
|
||||
let _lock = exit.lock();
|
||||
self.db.compact()?;
|
||||
let exit = exit.clone();
|
||||
self.db.run_bg(move |db| {
|
||||
let _lock = exit.lock();
|
||||
db.compact()
|
||||
});
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
@@ -20,6 +20,8 @@ impl Vecs {
|
||||
starting_indexes: &Indexes,
|
||||
exit: &Exit,
|
||||
) -> Result<()> {
|
||||
self.db.sync_bg_tasks()?;
|
||||
|
||||
let (r1, (r2, r3)) = rayon::join(
|
||||
|| {
|
||||
self.count
|
||||
@@ -57,8 +59,11 @@ impl Vecs {
|
||||
exit,
|
||||
)?;
|
||||
|
||||
let _lock = exit.lock();
|
||||
self.db.compact()?;
|
||||
let exit = exit.clone();
|
||||
self.db.run_bg(move |db| {
|
||||
let _lock = exit.lock();
|
||||
db.compact()
|
||||
});
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,6 +6,7 @@ use brk_error::Result;
|
||||
use brk_iterator::Blocks;
|
||||
use brk_rpc::Client;
|
||||
use brk_types::Height;
|
||||
use fjall::PersistMode;
|
||||
use tracing::{debug, info};
|
||||
use vecdb::{Exit, ReadOnlyClone, ReadableVec, Ro, Rw, StorageMode};
|
||||
mod constants;
|
||||
@@ -107,6 +108,8 @@ impl Indexer {
|
||||
exit: &Exit,
|
||||
check_collisions: bool,
|
||||
) -> Result<Indexes> {
|
||||
self.vecs.db.sync_bg_tasks()?;
|
||||
|
||||
debug!("Starting indexing...");
|
||||
|
||||
let last_blockhash = self.vecs.blocks.blockhash.collect_last();
|
||||
@@ -248,11 +251,32 @@ impl Indexer {
|
||||
|
||||
drop(readers);
|
||||
|
||||
if !is_export_height(indexes.height) {
|
||||
export(stores, vecs, indexes.height)?;
|
||||
}
|
||||
let lock = exit.lock();
|
||||
let tasks = self.stores.take_all_pending_ingests(indexes.height)?;
|
||||
self.vecs.stamped_write(indexes.height)?;
|
||||
let fjall_db = self.stores.db.clone();
|
||||
|
||||
self.vecs.compact()?;
|
||||
self.vecs.db.run_bg(move |db| {
|
||||
let _lock = lock;
|
||||
|
||||
if !tasks.is_empty() {
|
||||
let i = Instant::now();
|
||||
for task in tasks {
|
||||
task().map_err(vecdb::RawDBError::other)?;
|
||||
}
|
||||
info!("Stores committed in {:?}", i.elapsed());
|
||||
|
||||
let i = Instant::now();
|
||||
fjall_db
|
||||
.persist(PersistMode::SyncData)
|
||||
.map_err(vecdb::RawDBError::other)?;
|
||||
info!("Stores persisted in {:?}", i.elapsed());
|
||||
}
|
||||
|
||||
db.flush()?;
|
||||
db.compact()?;
|
||||
Ok(())
|
||||
});
|
||||
|
||||
Ok(starting_indexes)
|
||||
}
|
||||
|
||||
@@ -6,8 +6,8 @@ use brk_cohort::ByAddrType;
|
||||
use brk_error::Result;
|
||||
use brk_store::{AnyStore, Kind, Mode, Store};
|
||||
use brk_types::{
|
||||
AddrHash, AddrIndexOutPoint, AddrIndexTxIndex, BlockHashPrefix, Height, OutPoint,
|
||||
OutputType, StoredString, TxIndex, TxOutIndex, TxidPrefix, TypeIndex, Unit, Version, Vout,
|
||||
AddrHash, AddrIndexOutPoint, AddrIndexTxIndex, BlockHashPrefix, Height, OutPoint, OutputType,
|
||||
StoredString, TxIndex, TxOutIndex, TxidPrefix, TypeIndex, Unit, Version, Vout,
|
||||
};
|
||||
use fjall::{Database, PersistMode};
|
||||
use rayon::prelude::*;
|
||||
@@ -24,8 +24,7 @@ pub struct Stores {
|
||||
|
||||
pub addr_type_to_addr_hash_to_addr_index: ByAddrType<Store<AddrHash, TypeIndex>>,
|
||||
pub addr_type_to_addr_index_and_tx_index: ByAddrType<Store<AddrIndexTxIndex, Unit>>,
|
||||
pub addr_type_to_addr_index_and_unspent_outpoint:
|
||||
ByAddrType<Store<AddrIndexOutPoint, Unit>>,
|
||||
pub addr_type_to_addr_index_and_unspent_outpoint: ByAddrType<Store<AddrIndexOutPoint, Unit>>,
|
||||
pub blockhash_prefix_to_height: Store<BlockHashPrefix, Height>,
|
||||
pub height_to_coinbase_tag: Store<Height, StoredString>,
|
||||
pub txid_prefix_to_tx_index: Store<TxidPrefix, TxIndex>,
|
||||
@@ -194,6 +193,39 @@ impl Stores {
|
||||
Ok(())
|
||||
}
|
||||
|
||||
/// Takes all pending puts/dels from every store and returns closures
|
||||
/// that can ingest them on a background thread.
|
||||
#[allow(clippy::type_complexity)]
|
||||
pub fn take_all_pending_ingests(
|
||||
&mut self,
|
||||
height: Height,
|
||||
) -> Result<Vec<Box<dyn FnOnce() -> Result<()> + Send>>> {
|
||||
let h = height;
|
||||
let mut tasks = Vec::new();
|
||||
|
||||
macro_rules! take {
|
||||
($store:expr) => {
|
||||
tasks.extend($store.take_pending_ingest(h)?);
|
||||
};
|
||||
}
|
||||
|
||||
take!(self.blockhash_prefix_to_height);
|
||||
take!(self.height_to_coinbase_tag);
|
||||
take!(self.txid_prefix_to_tx_index);
|
||||
|
||||
for store in self.addr_type_to_addr_hash_to_addr_index.values_mut() {
|
||||
take!(store);
|
||||
}
|
||||
for store in self.addr_type_to_addr_index_and_tx_index.values_mut() {
|
||||
take!(store);
|
||||
}
|
||||
for store in self.addr_type_to_addr_index_and_unspent_outpoint.values_mut() {
|
||||
take!(store);
|
||||
}
|
||||
|
||||
Ok(tasks)
|
||||
}
|
||||
|
||||
pub fn rollback_if_needed(
|
||||
&mut self,
|
||||
vecs: &mut Vecs,
|
||||
@@ -368,11 +400,7 @@ impl Stores {
|
||||
let addr_type = output_type;
|
||||
let addr_index = type_index;
|
||||
|
||||
addr_index_tx_index_to_remove.insert((
|
||||
addr_type,
|
||||
addr_index,
|
||||
spending_tx_index,
|
||||
));
|
||||
addr_index_tx_index_to_remove.insert((addr_type, addr_index, spending_tx_index));
|
||||
|
||||
self.addr_type_to_addr_index_and_unspent_outpoint
|
||||
.get_mut_unwrap(addr_type)
|
||||
|
||||
@@ -30,7 +30,7 @@ use crate::Indexes;
|
||||
#[derive(Traversable)]
|
||||
pub struct Vecs<M: StorageMode = Rw> {
|
||||
#[traversable(skip)]
|
||||
db: Database,
|
||||
pub db: Database,
|
||||
pub blocks: BlocksVecs<M>,
|
||||
#[traversable(wrap = "transactions", rename = "raw")]
|
||||
pub transactions: TransactionsVecs<M>,
|
||||
@@ -121,8 +121,7 @@ impl Vecs {
|
||||
}
|
||||
|
||||
pub fn flush(&mut self, height: Height) -> Result<()> {
|
||||
self.par_iter_mut_any_stored_vec()
|
||||
.try_for_each(|vec| vec.stamped_write(Stamp::from(height)))?;
|
||||
self.stamped_write(height)?;
|
||||
self.db.flush()?;
|
||||
Ok(())
|
||||
}
|
||||
@@ -137,6 +136,12 @@ impl Vecs {
|
||||
.unwrap()
|
||||
}
|
||||
|
||||
pub fn stamped_write(&mut self, height: Height) -> Result<()> {
|
||||
self.par_iter_mut_any_stored_vec()
|
||||
.try_for_each(|vec| vec.stamped_write(Stamp::from(height)))?;
|
||||
Ok(())
|
||||
}
|
||||
|
||||
pub fn compact(&self) -> Result<()> {
|
||||
self.db.compact()?;
|
||||
Ok(())
|
||||
@@ -168,7 +173,4 @@ impl Vecs {
|
||||
.chain(self.scripts.par_iter_mut_any())
|
||||
}
|
||||
|
||||
pub fn db(&self) -> &Database {
|
||||
&self.db
|
||||
}
|
||||
}
|
||||
|
||||
@@ -46,7 +46,7 @@ impl<'a> Day1Iter<'a> {
|
||||
.to_usize()
|
||||
.saturating_sub(self.start_di.to_usize())
|
||||
+ 1;
|
||||
let timestamps = &self.computer.blocks.time.timestamp.day1;
|
||||
let timestamps = &self.computer.indexes.timestamp.day1;
|
||||
let heights = &self.computer.indexes.day1.first_height;
|
||||
|
||||
let mut entries = Vec::with_capacity(total / self.step + 1);
|
||||
|
||||
@@ -45,8 +45,7 @@ impl Query {
|
||||
|
||||
// Get timestamps using difficulty_to_timestamp for epoch start
|
||||
let epoch_start_timestamp = computer
|
||||
.blocks
|
||||
.time
|
||||
.indexes
|
||||
.timestamp
|
||||
.epoch
|
||||
.collect_one(current_epoch)
|
||||
|
||||
@@ -22,7 +22,7 @@ pub fn iter_difficulty_epochs(
|
||||
.unwrap_or_default();
|
||||
|
||||
let epoch_to_height = &computer.indexes.epoch.first_height;
|
||||
let epoch_to_timestamp = &computer.blocks.time.timestamp.epoch;
|
||||
let epoch_to_timestamp = &computer.indexes.timestamp.epoch;
|
||||
let epoch_to_difficulty = &computer.blocks.difficulty.value.epoch;
|
||||
|
||||
let mut results = Vec::with_capacity(end_epoch.to_usize() - start_epoch.to_usize() + 1);
|
||||
|
||||
@@ -56,7 +56,7 @@ impl Query {
|
||||
let step = (total_days / 200).max(1); // Max ~200 data points
|
||||
|
||||
let hashrate_vec = &computer.mining.hashrate.rate.base.day1;
|
||||
let timestamp_vec = &computer.blocks.time.timestamp.day1;
|
||||
let timestamp_vec = &computer.indexes.timestamp.day1;
|
||||
|
||||
let mut hashrates = Vec::with_capacity(total_days / step + 1);
|
||||
let mut di = start_day1.to_usize();
|
||||
|
||||
@@ -373,7 +373,7 @@ impl Query {
|
||||
// Slow path: rebuild from computer's precomputed monotonic timestamps
|
||||
let mut map = HEIGHT_BY_MONOTONIC_TIMESTAMP.write();
|
||||
if map.len() <= current_height {
|
||||
*map = RangeMap::from(self.computer().blocks.time.timestamp_monotonic.collect());
|
||||
*map = RangeMap::from(self.computer().indexes.timestamp.monotonic.collect());
|
||||
}
|
||||
map.ceil(ts).map(usize::from).unwrap_or(current_height)
|
||||
}
|
||||
|
||||
@@ -1,10 +1,35 @@
|
||||
<!doctype html>
|
||||
<html>
|
||||
<head>
|
||||
<title>BRK API</title>
|
||||
<title>BRK API — Bitcoin Research Kit</title>
|
||||
<meta
|
||||
name="description"
|
||||
content="Bitcoin Research Kit's API documentation via Scalar"
|
||||
content="Free Bitcoin on-chain analytics API. Thousands of time-series, block explorer, address index, mempool, mining stats. No auth required."
|
||||
/>
|
||||
|
||||
<!-- Open Graph -->
|
||||
<meta property="og:title" content="BRK API — Bitcoin Research Kit" />
|
||||
<meta
|
||||
property="og:description"
|
||||
content="Free Bitcoin on-chain analytics API. Thousands of time-series, block explorer, address index, mempool, mining stats. No auth required."
|
||||
/>
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:url" content="https://bitview.space/api" />
|
||||
<meta
|
||||
property="og:image"
|
||||
content="https://bitview.space/assets/favicon-196.png"
|
||||
/>
|
||||
|
||||
<!-- Twitter Card -->
|
||||
<meta name="twitter:card" content="summary" />
|
||||
<meta name="twitter:title" content="BRK API — Bitcoin Research Kit" />
|
||||
<meta
|
||||
name="twitter:description"
|
||||
content="Free Bitcoin on-chain analytics API. Thousands of time-series, block explorer, address index. No auth required."
|
||||
/>
|
||||
<meta
|
||||
name="twitter:image"
|
||||
content="https://bitview.space/assets/favicon-196.png"
|
||||
/>
|
||||
<meta charset="utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
|
||||
@@ -206,6 +206,34 @@ where
|
||||
}
|
||||
}
|
||||
|
||||
/// Takes buffered puts/dels and returns a closure that ingests them into the keyspace.
|
||||
/// The store is left with empty buffers, ready for the next batch.
|
||||
#[allow(clippy::type_complexity)]
|
||||
pub fn take_pending_ingest(
|
||||
&mut self,
|
||||
height: Height,
|
||||
) -> Result<Option<Box<dyn FnOnce() -> Result<()> + Send>>>
|
||||
where
|
||||
K: Send + 'static,
|
||||
V: Send + 'static,
|
||||
for<'a> ByteView: From<&'a K> + From<&'a V>,
|
||||
{
|
||||
self.export_meta_if_needed(height)?;
|
||||
|
||||
let puts = mem::take(&mut self.puts);
|
||||
let dels = mem::take(&mut self.dels);
|
||||
|
||||
if puts.is_empty() && dels.is_empty() {
|
||||
return Ok(None);
|
||||
}
|
||||
|
||||
let keyspace = self.keyspace.clone();
|
||||
|
||||
Ok(Some(Box::new(move || {
|
||||
Self::ingest(&keyspace, puts.iter(), dels.iter())
|
||||
})))
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn iter(&self) -> impl Iterator<Item = (K, V)> {
|
||||
self.keyspace
|
||||
|
||||
+1
-1
@@ -11,7 +11,7 @@ RUN cargo build --release --locked
|
||||
|
||||
FROM debian:bookworm-slim
|
||||
|
||||
RUN apt-get update && apt-get install -y ca-certificates curl && rm -rf /var/lib/apt/lists/*
|
||||
RUN apt-get update && apt-get install -y ca-certificates procps && rm -rf /var/lib/apt/lists/*
|
||||
|
||||
RUN useradd -m -s /bin/bash brk
|
||||
|
||||
|
||||
@@ -32,11 +32,10 @@ services:
|
||||
# - --rpccookiefile
|
||||
# - /bitcoin/.cookie
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "-sf", "http://localhost:3110/health"]
|
||||
test: ["CMD", "pgrep", "-x", "brk"]
|
||||
interval: 30s
|
||||
timeout: 10s
|
||||
retries: 3
|
||||
start_period: 60s
|
||||
start_period: 10s
|
||||
|
||||
volumes:
|
||||
brk-data:
|
||||
|
||||
@@ -4,6 +4,348 @@ All notable changes to the Bitcoin Research Kit (BRK) project will be documented
|
||||
|
||||
> *This changelog was generated by Claude Code*
|
||||
|
||||
## [v0.2.3](https://github.com/bitcoinresearchkit/brk/releases/tag/v0.2.3) - 2026-03-26
|
||||
|
||||
### New Features
|
||||
|
||||
#### `brk_computer`
|
||||
- Added new `investing` module with complete Dollar-Cost Averaging (DCA) and lump-sum investment analysis — computes DCA stack (cumulative sats purchased at $100/day), cost basis, returns, and CAGR by rolling period (1w, 1m, 3m, 6m, 1y through 10y); lump-sum stack and returns by rolling period; and DCA stack, cost basis, and returns by year class (2015 through 2026). Extracted from `market::dca` into a standalone top-level module with parallel import and compute ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_computer/src/investing/mod.rs))
|
||||
- Added `RealizedEnvelope` indicator that computes the tightest percentile bounds across 10 pricing models (realized price, investor price, STH/LTH variants, cointime vaultedness/activity/true market mean/cointime price), producing 8 envelope price bands (0.5th through 99.5th percentile), a zone index (-4 to +4) based on spot price position relative to envelope bands, and a composite score (-40 to +40) summing band crossings across all models ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_computer/src/indicators/realized_envelope.rs))
|
||||
- Expanded `RatioPerBlockPercentiles` from 6 to 8 percentile bands, adding 0.5th and 99.5th percentiles alongside the existing 1st/2nd/5th/95th/98th/99th — `ExpandingPercentiles` Fenwick tree computation also widened from 6-quantile to 8-quantile output ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_computer/src/internal/per_block/ratio/percentiles.rs))
|
||||
- Consolidated timestamp data into a new `indexes::timestamp::Timestamps` struct — moved `timestamp_monotonic`, `date`, and per-resolution timestamp lookups from `blocks::time::Vecs` into the indexes module, making timestamp data accessible without depending on the blocks module ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_computer/src/indexes/timestamp.rs))
|
||||
|
||||
#### `brk_indexer`
|
||||
- Added `take_all_pending_ingests()` to batch all KV store puts/deletes into closures that can be executed on a background thread, enabling the indexer to hand off fjall store commits to `run_bg()` instead of blocking the main indexing loop ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_indexer/src/stores.rs))
|
||||
- Extracted `stamped_write()` from `flush()` so vec stamping can happen on the main thread while compaction and store ingests run in the background ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_indexer/src/vecs/mod.rs))
|
||||
|
||||
#### `brk_store`
|
||||
- Added `take_pending_ingest()` method that drains buffered puts/deletes and returns a `Send` closure for background ingestion into the fjall keyspace ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_store/src/lib.rs))
|
||||
|
||||
#### `website`
|
||||
- Added range preset buttons (1w, 1m, 3m, 6m, 1y, 4y, 8y, YTD, all) to the chart that automatically select the appropriate sub-day resolution index (30min through 1w) and scroll the visible range to that time window ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/website/scripts/chart/index.js))
|
||||
- Added value-dependent coloring support (`colorFn`) for histogram and baseline chart series, enabling per-bar colors based on data values ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/website/scripts/chart/index.js))
|
||||
- Added "Realized Envelope" chart to market indicators showing 8-level percentile price bands as dashed lines, a color-coded zone index histogram, and a score baseline ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/website/scripts/options/market.js))
|
||||
- Added `percentileBands()` and `priceBands()` shared helpers for displaying 8-level percentile bands with dedicated colors per level, reusable across ratio and price chart types ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/website/scripts/options/shared.js))
|
||||
- Added subtle grid lines to charts using a new `offBorder` color variable ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/website/scripts/chart/index.js))
|
||||
|
||||
### Internal Changes
|
||||
|
||||
#### `brk_computer`
|
||||
- Switched all module `compute()` methods to use `db.run_bg()` for background compaction instead of synchronous `db.compact()`, and added `db.sync_bg_tasks()` at compute entry to await prior background work — applies to blocks, cointime, distribution, indicators, inputs, investing, market, mining, outputs, pools, positions, prices, scripts, supply, and transactions ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_computer/src/blocks/compute.rs))
|
||||
- Removed `market::dca` sub-module — DCA types (`ByDcaClass`, `ByDcaPeriod`, `ByDcaCagr`) and computation logic moved to the new top-level `investing` module; `market::returns` now imports `ByDcaPeriod` from `investing` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_computer/src/market/mod.rs))
|
||||
- Removed `blocks::time` sub-module — `timestamp_monotonic` compute logic and per-resolution timestamp imports relocated to `indexes::timestamp::Timestamps` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_computer/src/blocks/mod.rs))
|
||||
- Changed `lookback::compute()` to take `&indexes::Vecs` instead of `&time::Vecs`, sourcing monotonic timestamps from the indexes module ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_computer/src/blocks/lookback.rs))
|
||||
- Changed `market::compute()` parameter order: now takes `(prices, indexes, blocks)` instead of `(indexes, prices, blocks)` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_computer/src/market/compute.rs))
|
||||
|
||||
#### `brk_indexer`
|
||||
- Moved indexer store ingest and fjall persist to background via `run_bg()`, running compaction, store commit, and fjall `SyncData` persist concurrently with the next indexing batch ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_indexer/src/lib.rs))
|
||||
|
||||
#### `brk_client`
|
||||
- Added `Pct0Pct1Pct2Pct5Pct95Pct98Pct99Pattern` replacing `Pct1Pct2Pct5Pct95Pct98Pct99Pattern` to include the new 0.5th and 99.5th percentile bands ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_client/src/lib.rs))
|
||||
- Added `SeriesTree_Investing` with full period/class sub-trees for DCA stack, cost basis, returns, CAGR, and lump-sum series ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_client/src/lib.rs))
|
||||
- Added `SeriesTree_Indicators_RealizedEnvelope` with percentile price bands, index, and score series ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_client/src/lib.rs))
|
||||
- Added `SeriesTree_Indexes_Timestamp` with monotonic and per-resolution timestamp series ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_client/src/lib.rs))
|
||||
- Removed `date` and `timestamp_monotonic` from `SeriesTree_Blocks_Time`, simplified to only expose `timestamp` as a per-resolution pattern ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_client/src/lib.rs))
|
||||
|
||||
#### `brk_query`
|
||||
- Updated all mining query endpoints (`day1_iter`, `difficulty`, `epochs`, `hashrate`) and series timestamp resolution to read from `indexes.timestamp` instead of `blocks.time.timestamp` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/crates/brk_query/src/impl/series.rs))
|
||||
|
||||
#### `website`
|
||||
- Refactored investing chart options to use the new `investing` tree path instead of `market.dca` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/website/scripts/options/investing.js))
|
||||
- Added dedicated percentile color palette (`_0_5` through `_99_5`) replacing the previous 6-color scheme with 8 distinct colors ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/website/scripts/utils/colors.js))
|
||||
- Added `createRatioChart()` and `groupedWindowsCumulative()` shared chart builders for reuse across ratio-based chart options ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/website/scripts/options/shared.js))
|
||||
|
||||
#### `docker`
|
||||
- Switched health check from `curl http://localhost:3110/health` to `pgrep -x brk`, replacing `curl` package dependency with `procps` and reducing start period from 60s to 10s ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/docker/docker-compose.yml))
|
||||
|
||||
#### `workspace`
|
||||
- Bumped Rust toolchain from 1.94.0 to 1.94.1 ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/rust-toolchain.toml))
|
||||
- Bumped `quickmatch-js` from 0.4.0 to 0.4.1 ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.3/modules/quickmatch-js/0.4.1/src/index.js))
|
||||
|
||||
[View changes](https://github.com/bitcoinresearchkit/brk/compare/v0.2.2...v0.2.3)
|
||||
|
||||
## [v0.2.2](https://github.com/bitcoinresearchkit/brk/releases/tag/v0.2.2) - 2026-03-23
|
||||
|
||||
### New Features
|
||||
|
||||
#### `website`
|
||||
- Created a comprehensive LLM-readable API reference (`llms-full.txt`) documenting every endpoint with curl examples, response shapes, parameter descriptions, and series categories — enabling LLM agents to discover and use the BRK API via the [llms.txt standard](https://llmstxt.org/) ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.2/website/llms-full.txt))
|
||||
- Rewrote `llms.txt` from a minimal overview into a structured quick-start guide with live links to key endpoints (search, series data, blocks, transactions, addresses, fees, live price) and links to the full reference, OpenAPI specs, and interactive docs ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.2/website/llms.txt))
|
||||
- Added `llms-full.txt` to `robots.txt` as a sitemap entry so crawlers and LLM agents can discover it ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.2/website/robots.txt))
|
||||
|
||||
#### `brk_server`
|
||||
- Added Open Graph and Twitter Card meta tags to the Scalar API documentation page, providing proper title, description, and image for social media link previews ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.2/crates/brk_server/src/api/scalar.html))
|
||||
- Renamed the API docs page title from "BRK API" to "BRK API — Bitcoin Research Kit" with a richer meta description emphasizing the free, no-auth nature of the API ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.2/crates/brk_server/src/api/scalar.html))
|
||||
|
||||
### Internal Changes
|
||||
|
||||
#### `workspace`
|
||||
- Re-enabled `cargo build --workspace --release` in the release script (was previously commented out) ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.2/scripts/quick-release.sh))
|
||||
|
||||
[View changes](https://github.com/bitcoinresearchkit/brk/compare/v0.2.1...v0.2.2)
|
||||
|
||||
## [v0.2.1](https://github.com/bitcoinresearchkit/brk/releases/tag/v0.2.1) - 2026-03-23
|
||||
|
||||
### Breaking Changes
|
||||
|
||||
#### `brk_rpc`
|
||||
- Made `corepc` the default feature — `brk_rpc` now uses the `brk-corepc-client` RPC backend by default instead of requiring explicit feature opt-in; users relying on `bitcoincore-rpc` must now explicitly enable it ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.1/crates/brk_rpc/Cargo.toml))
|
||||
|
||||
[View changes](https://github.com/bitcoinresearchkit/brk/compare/v0.2.0...v0.2.1)
|
||||
|
||||
## [v0.2.0](https://github.com/bitcoinresearchkit/brk/releases/tag/v0.2.0) - 2026-03-23
|
||||
|
||||
This is a major architectural release. The most significant changes are:
|
||||
|
||||
1. **Self-contained, oracle-only pricing**: The computation pipeline no longer uses exchange APIs for price data. All prices are now derived on-chain via the `brk_oracle` crate from block 550,000 onward, with pre-computed historical prices embedded for earlier blocks. `brk_fetcher` remains as a crate but is no longer used by `brk_computer` or `brk_cli`. Bitcoin Core is now the only runtime dependency — the toolkit runs fully offline and produces deterministic, reproducible results.
|
||||
|
||||
2. **Height-only storage**: All series now store only the per-block (height-indexed) vec on disk. Previously each series stored both a height vec and a date-indexed vec. All non-height resolutions (minute10 through year10, halving, epoch — 15 total, up from 8) are now computed lazily on demand from the height data using `LazyAggVec` with flat height-to-period mappings. This roughly halves on-disk vec count while nearly doubling the number of available resolutions.
|
||||
|
||||
3. **Flat index architecture**: The old cascading index hierarchy (height → date → week → month → quarter → year → decade) is replaced by a flat system where every period type maps directly to Height. This eliminates intermediate stored mappings and enables sub-day resolutions (10min, 30min, 1h, 4h, 12h) that were previously impossible.
|
||||
|
||||
4. **Profitability cohorts**: New UTXO bucketing by unrealized profit/loss percentage — 25 ranges from ">1000% in profit" to "90-100% in loss", plus 14 aggregate profit thresholds and 9 loss thresholds, powered by a 190K-bucket Fenwick tree for O(log N) per-block computation.
|
||||
|
||||
As a consequence of height-only storage, temporal aggregation shifted from date-based (daily sum, daily last, daily cumulative) to **rolling windows** (24h, 1w, 1m, 1y) computed from height data using precomputed lookback start positions (`CachedWindowStarts`). Most series now expose a `block` value, `cumulative` sum, and `RollingComplete` (rolling sums + rolling averages + rolling distribution with min/max/median/percentiles per window) — all derived from the single height vec.
|
||||
|
||||
Resolution data is served through a popularity-based caching layer: up to 256 height-source vecs are cached in memory with LRU eviction based on access frequency, while period-to-height index mappings are always cached since they're small and shared across all series.
|
||||
|
||||
### Breaking Changes
|
||||
|
||||
#### `brk_types`
|
||||
- Renamed all `Address`/`Addresses` types to `Addr`/`Addrs` across the entire public API: `Address` → `Addr`, `AddressBytes` → `AddrBytes`, `AddressHash` → `AddrHash`, `AddressStats` → `AddrStats`, `AddressChainStats` → `AddrChainStats`, `AddressMempoolStats` → `AddrMempoolStats`, `AddressParam` → `AddrParam`, `AddressValidation` → `AddrValidation`, `AnyAddressIndex` → `AnyAddrIndex`, `FundedAddressData` → `FundedAddrData`, `EmptyAddressData` → `EmptyAddrData`, etc. ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_types/src/addr.rs))
|
||||
- Renamed all `Metric`/`Metrics` types to `Series`: `MetricParam` → `SeriesParam`, `MetricData` → `SeriesData`, `MetricOutput` → `SeriesOutput`, `MetricCount` → `SeriesCount`, `MetricSelection` → `SeriesSelection`, `MetricsPaginated` → `SeriesPaginated`, `MetricWithIndex` → `SeriesNameWithIndex` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_types/src/series_data.rs))
|
||||
- Renamed `DateIndex` to `Day1` and removed `DecadeIndex`, `WeekIndex`, `MonthIndex`, `QuarterIndex`, `SemesterIndex`, `YearIndex` — replaced with a comprehensive resolution system: `Minute10`, `Minute30`, `Hour1`, `Hour4`, `Hour12`, `Day1`, `Day3`, `Week1`, `Month1`, `Month3`, `Month6`, `Year1`, `Year10` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_types/src/day1.rs))
|
||||
- Renamed `DifficultyEpoch` to `Epoch` and `HalvingEpoch` to `Halving` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_types/src/epoch.rs))
|
||||
- Renamed `CentsUnsigned` to `Cents` and `CentsUnsignedCompact` to `CentsCompact` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_types/src/cents.rs))
|
||||
- Adopted snake_case for all module file names (e.g. `blockinfo` → `block_info`, `blocktimestamp` → `block_timestamp`, `feeratepercentiles` → `feerate_percentiles`, `txstatus` → `tx_status`, `poolslug` → `pool_slug`, etc.)
|
||||
|
||||
#### `brk_computer`
|
||||
- **All series now store height-indexed data only on disk** — previously each metric stored both a `height: EagerVec` and a `dateindex: EagerVec` (and sometimes cumulative/sum variants at each level). Now `PerBlock<T>` has `height: EagerVec` + `resolutions: Box<Resolutions<T>>` where all 15 resolutions are `LazyAggVec` instances computed on demand. This roughly halves the on-disk vec count per series ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/internal/per_block/computed/base.rs))
|
||||
- **Replaced cascading index hierarchy with flat height-to-period mappings** — old system chained height→dateindex→weekindex→monthindex→yearindex→decadeindex; new system maps every period type directly to Height via `EagerIndexes`, enabling all resolutions to derive from height data without intermediate stored vecs ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/indexes/mod.rs))
|
||||
- Restructured `internal/` SDK from `single`/`multi` hierarchy to concept-oriented modules: `per_block/`, `per_tx/`, `algo/`, `transform/`, `containers/`, `indexes/` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/internal/mod.rs))
|
||||
- Moved `blocks/mining/` and `blocks/rewards/` into a dedicated top-level `mining/` module with `rewards/` and `hashrate/` sub-modules ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/mining/mod.rs))
|
||||
- Moved `market/indicators/` to a top-level `indicators/` module with expanded scope ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/indicators/mod.rs))
|
||||
- Renamed `price` module to `prices` with restructured sub-modules: `by_unit.rs` (multi-currency structs), `ohlcs.rs` (OHLC aggregation), `compute.rs` (oracle-based price computation) ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/prices/mod.rs))
|
||||
- Renamed `cointime/pricing` to `cointime/prices` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/cointime/prices/mod.rs))
|
||||
- Renamed `distribution/address` to `distribution/addr` and `distribution/cohorts/address` to `distribution/cohorts/addr`
|
||||
- Replaced all `Clone`-derived `Vecs` structs with generic `StorageMode` parameter (`Vecs<M: StorageMode = Rw>`) across every computation module (blocks, transactions, market, distribution, supply, etc.) for type-safe read-only sharing
|
||||
- Removed `brk_fetcher` dependency — price computation is now fully on-chain via the oracle, eliminating exchange API calls (Binance, Kraken) and the 12-hour retry/HAR-import fallback logic
|
||||
- Removed `traits/` module (pricing traits) and `utils.rs`
|
||||
- `Computer::forced_import` no longer accepts a `Fetcher` parameter — signature simplified from `(path, indexer, fetcher)` to `(path, indexer)`
|
||||
- Restructured all market sub-modules with new type-safe containers replacing ad-hoc naming: `price_1w_sma` → `sma._1w`, `price_ath` → `high`, `price_drawdown` → `drawdown`, `price_returns` → `periods`, `price_ago` → `price_past`, etc.
|
||||
- Restructured ATH vecs: `price_ath` → `high.cents`, `price_drawdown` → `drawdown`, `days_since_price_ath` → `days_since`, `max_days_between_price_aths` → `max_days_between` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/market/ath/vecs.rs))
|
||||
- Restructured DCA vecs: split into `PeriodVecs` (stack, cost_basis, return, cagr, lump_sum) and `ClassVecs` (stack, cost_basis, return), removing explicit days-in-profit/loss and min/max return fields ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/market/dca/vecs.rs))
|
||||
- Restructured volatility vecs: replaced individual `price_Xw_volatility`, `sharpe_Xw`, `sortino_Xw` fields with `Windows<LazyPerBlock<StoredF32>>` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/market/volatility/vecs.rs))
|
||||
- Restructured returns vecs: replaced individual period fields with `ByLookbackPeriod<PercentPerBlock>`, added `sd_24h: Windows<StdDevPerBlock>` replacing explicit 1w/1m/1y standard deviation and downside fields ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/market/returns/vecs.rs))
|
||||
- Restructured range vecs: replaced 8 individual min/max price fields with `PriceMinMaxVecs` containing `min`/`max` groups, and added choppiness index as `PercentPerBlock` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/market/range/vecs.rs))
|
||||
- Restructured moving average vecs: split into `SmaVecs` and `EmaVecs` using `PriceWithRatioPerBlock<M>` for each period, added Mayer Multiple bands (`_200d_x2_4`, `_200d_x0_8`) ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/market/moving_average/vecs.rs))
|
||||
- Restructured burned supply: merged `opreturn` and `unspendable` into single `total: AmountPerBlockCumulative` with inline computation ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/supply/burned/vecs.rs))
|
||||
- Restructured transaction volume: replaced `sent_sum`/`received_sum`/`annualized_volume` with single `transfer_volume: AmountPerBlockCumulativeRolling`, wrapped throughput metrics in `Windows<PerBlock>` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/transactions/volume/vecs.rs))
|
||||
- Removed `distribution/compute/aggregates.rs` — aggregate computation moved into metric tiers
|
||||
- Removed `distribution/range_map.rs` — range mapping moved to `brk_types::RangeMap`
|
||||
|
||||
#### `brk_query`
|
||||
- Renamed `address()`/`address_txids()`/`address_utxos()` methods to `addr()`/`addr_txids()`/`addr_utxos()` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_query/src/impl/addr.rs))
|
||||
- Renamed `metrics` query module to `series` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_query/src/impl/series.rs))
|
||||
- Removed `resolved.rs` — resolution handling moved inline
|
||||
|
||||
#### `brk_server`
|
||||
- Renamed `/api/address/*` routes and `AddressRoutes` trait to `AddrRoutes` (redirects preserved from old paths) ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_server/src/api/addrs/mod.rs))
|
||||
- Renamed `/api/series/*` routes (previously `/api/metrics/*`) — legacy `/api/metrics/*` routes preserved as redirects ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_server/src/api/series/mod.rs))
|
||||
- Removed `brk_fetcher` dependency
|
||||
- Removed `Client` from `AppState` — server no longer holds a direct RPC client reference
|
||||
|
||||
#### `brk_client`
|
||||
- Switched HTTP backend from `minreq` to `ureq`
|
||||
- Removed `fetch_prices.rs` example
|
||||
|
||||
#### `brk_fetcher`
|
||||
- Switched HTTP backend from `minreq` to `ureq`
|
||||
|
||||
#### `brk_rpc`
|
||||
- Added `corepc` feature integrating `brk-corepc-client` and `brk-corepc-jsonrpc` as alternative RPC backends ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_rpc/Cargo.toml))
|
||||
|
||||
#### `brk_cohort`
|
||||
- Renamed `AddressGroups` to `AddrGroups` with renamed fields: `ge_amount` → `over_amount`, `lt_amount` → `under_amount`, `ByGreatEqualAmount` → `OverAmount`, `ByLowerThanAmount` → `UnderAmount`, `ByAmountRange` → `AmountRange` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_cohort/src/addr.rs))
|
||||
- Renamed `ByAgeRange` to `AgeRange` with renamed fields: `up_to_1h` → `under_1h`, `from_15y` → `over_15y` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_cohort/src/age_range.rs))
|
||||
- Renamed file names from concatenated (`by_age_range.rs`, `by_amount_range.rs`) to snake_case (`age_range.rs`, `amount_range.rs`)
|
||||
|
||||
### New Features
|
||||
|
||||
#### `brk_computer`
|
||||
- Added `indicators/` module computing on-chain indicators: Puell Multiple, RHODL Ratio, NVT Ratio, Thermocap Multiple, Supply-Adjusted CDD, Supply-Adjusted CYD, Supply-Adjusted Dormancy, Dormancy Flow, Stock-to-Flow, Seller Exhaustion Constant, and Gini coefficient ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/indicators/compute.rs))
|
||||
- Added `mining/` module with dedicated hashrate computations: hash rate with 1w/1m/2m/1y SMAs, hash rate ATH and drawdown, hash price and hash value per TH/s and PH/s, hash price/value minimums and rebound metrics ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/mining/hashrate/compute.rs))
|
||||
- Added `mining/rewards/` with coinbase rewards, subsidy, fee dominance, unclaimed rewards — each with block/cumulative/rolling views and sats/btc/usd units ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/mining/rewards/compute.rs))
|
||||
- Added `market/technical/` module implementing RSI with Stochastic RSI (RSI, StochRSI, K-line, D-line with configurable RMA/SMA periods) and MACD (fast/slow EMA, signal line, histogram) ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/market/technical/rsi.rs))
|
||||
- Added Fenwick tree (Binary Indexed Tree) data structure supporting O(log N) point-update, prefix-sum, and multi-target kth walk-down queries ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/internal/algo/fenwick.rs))
|
||||
- Added `ExpandingPercentiles` tracker using Fenwick tree for O(log N) percentile queries with 0.1% resolution, supporting bulk-load initialization ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/internal/algo/expanding_percentiles.rs))
|
||||
- Added `CostBasisFenwick` — 4-field Fenwick tree (all_sats, sth_sats, all_usd, sth_usd) for per-block accurate cost basis percentiles, supply density queries (±5% of spot price), and profitability range computation across 25 ranges with all/STH splits ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/distribution/cohorts/utxo/fenwick.rs))
|
||||
- Added sliding distribution, sliding median, sliding window, and drawdown algorithms in `internal/algo/` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/internal/algo/mod.rs))
|
||||
- Added `Resolutions<T>` — a `PerResolution` of 15 `LazyAggVec` instances that lazily derive all supported resolutions from a single height-indexed source vec, using flat height-to-period mappings and a "last value in period" aggregation strategy ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/internal/per_block/computed/resolutions.rs))
|
||||
- Added `DerivedResolutions<T, S1T>` — doubly-lazy resolution system for `LazyPerBlock` that chains `UnaryTransform` on top of source resolutions, enabling zero-storage derived series at all 15 resolutions ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/internal/per_block/lazy/derived_resolutions.rs))
|
||||
- Added popularity-based resolution caching: `CachedVec` wrapping with a global budget of 256 slots, minimum 2 accesses before caching, and LRU eviction that replaces the least-accessed cached vec when a more popular one requests caching ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/internal/cache_budget.rs))
|
||||
- Added `prices/` module with `SplitByUnit` (open/high/low/close in USD/cents/sats), `OhlcByUnit`, and `PriceByUnit` structured types for multi-currency price access ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/prices/by_unit.rs))
|
||||
- Added `ProfitabilityMetrics` computing per-block supply, realized cap, unrealized PnL, and NUPL across 25 profitability ranges plus 14 profit thresholds and 9 loss thresholds, each with all/STH splits ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/distribution/metrics/profitability.rs))
|
||||
- Restructured distribution metrics into trait-based tiered system with `ActivityLike`, `RealizedLike`, `UnrealizedLike` trait hierarchies — each metric type has core/basic/minimal/full variants enabling flexible per-cohort metric composition ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/distribution/metrics/cohort/mod.rs))
|
||||
- Added `distribution/metrics/relative/` sub-module with 6 variants: `RelativeToAll`, `RelativeForAll`, `RelativeWithExtended`, `RelativeFull`, `RelativeExtendedOwnMarketCap`, `RelativeExtendedOwnPnl` for cohort-to-total ratio metrics ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/distribution/metrics/relative/mod.rs))
|
||||
- Added `distribution/addr/activity.rs` tracking per-block address activity counts (receiving, sending, reactivated, both) globally and per address type, with rolling averages ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/distribution/addr/activity.rs))
|
||||
- Added `distribution/addr/delta.rs` computing rolling address count deltas with change magnitude and basis-point rates ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/distribution/addr/delta.rs))
|
||||
- Added `distribution/state/pending.rs` with `PendingDelta`, `PendingCapDelta`, `PendingInvestorCapDelta` for batched cost basis state updates
|
||||
- Added maturation tracking to age cohorts: `tick_tock_next_block` now returns `AgeRange<Sats>` tracking how many sats mature from each age range into the next older one per block, stored as `matured: AgeRange<AmountPerBlockCumulativeRolling>` on `UTXOCohorts` with cumulative and rolling window views for all 21 age ranges ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/distribution/cohorts/utxo/tick_tock.rs))
|
||||
- Added `pools/major.rs` and `pools/minor.rs` separating major pools (with cumulative rolling rewards and dominance rolling windows) from minor pools (blocks mined with cumulative rolling and dominance ratio) ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_computer/src/pools/major.rs))
|
||||
- Added `blocks/lookback.rs` for precomputed rolling window lookback start vectors used across all windowed computations
|
||||
- Added `cache_budget.rs` system for managing memory cache allocation across vecs
|
||||
- Added `tree.rs` example for inspecting the full series tree structure
|
||||
|
||||
#### `brk_types`
|
||||
- Added 11 new resolution index types expanding from 8 resolutions (day, week, month, quarter, semester, year, decade, difficulty epoch) to 15: `Minute10`, `Minute30`, `Hour1`, `Hour4`, `Hour12` (sub-day — entirely new), `Day3`, `Month3`, `Month6` (new intermediate periods), `Year10` (replaces decade), plus renamed `Day1` (was DateIndex), `Week1` (was WeekIndex), `Month1` (was MonthIndex), `Year1` (was YearIndex), `Halving` (was HalvingEpoch), `Epoch` (was DifficultyEpoch) ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_types/src/hour1.rs))
|
||||
- Added `FromCoarser` trait enabling automatic derivation of finer-grained resolution data from coarser sources ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_types/src/from_coarser.rs))
|
||||
- Added basis points types: `BasisPoints16`, `BasisPoints32`, `BasisPointsSigned16`, `BasisPointsSigned32` for precision ratio/percentage storage without floating point ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_types/src/basis_points_32.rs))
|
||||
- Added `StoredI64` type for signed 64-bit stored values ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_types/src/stored_i64.rs))
|
||||
- Added `RangeIndex` and `RangeMap` types for range-based lookups ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_types/src/range_index.rs))
|
||||
- Added `SearchQuery` type for series full-text search ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_types/src/search_query.rs))
|
||||
- Added `SeriesInfo` type carrying metadata about each data series ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_types/src/series_info.rs))
|
||||
- Added `DataRange` as a dedicated type (previously inline) ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_types/src/data_range.rs))
|
||||
- Added `pools-v2.json` with expanded mining pool identification data
|
||||
- Added `SeriesList` and `SeriesName` types for typed series enumeration
|
||||
|
||||
#### `brk_server`
|
||||
- Added structured JSON error responses with RFC 9457-inspired format: `type` (error category), `code` (machine-readable), `message` (human-readable), `doc_url` (link to API docs) — covers all BRK error variants with proper HTTP status mapping ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_server/src/error.rs))
|
||||
- Added `X-Response-Time` header (in microseconds) on all responses for latency observability
|
||||
- Added Vary header consolidation middleware merging duplicate Vary headers into a single comma-separated value
|
||||
- Added custom panic handler extracting panic messages into structured JSON error responses instead of empty 500s
|
||||
- Added `ContentEncoding` module with server-side content encoding negotiation (zstd > br > gzip > identity) and transparent pre-compression of cached responses via brotli, flate2, and zstd ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_server/src/extended/encoding.rs))
|
||||
- Added pre-compressed Brotli encoding for the Scalar API documentation viewer (`scalar.js.br`) ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_server/src/api/scalar.js.br))
|
||||
- Extracted `finish_openapi()` and `generate_bindings()` as public functions for external use ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_server/src/lib.rs))
|
||||
- Made `ApiRoutes` trait public for external router composition
|
||||
|
||||
#### `brk_query`
|
||||
- Added `list.rs` example for enumerating all available series names ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_query/examples/list.rs))
|
||||
|
||||
#### `brk_cohort`
|
||||
- Added `ProfitabilityRange<T>` with 25 buckets from ">1000% in profit" to "90-100% in loss", with boundary prices computed dynamically from spot price via `compute_profitability_boundaries()` ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_cohort/src/profitability_range.rs))
|
||||
- Added `Profit<T>` with 14 aggregate "at least X% profit" thresholds (prefix sums over ranges) and `Loss<T>` with 9 aggregate "at least X% loss" thresholds (suffix sums over ranges) ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_cohort/src/profit.rs))
|
||||
- Added `AgeRange::from_array()` constructor for building age range structs from fixed-size arrays ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_cohort/src/age_range.rs))
|
||||
- Derived `Traversable` on `AddrGroups` via proc macro (previously manual `Traversable` impl on `AddressGroups`)
|
||||
|
||||
#### `brk_traversable`
|
||||
- Added `iter_any_visible()` method to the `Traversable` trait — allows structs to expose all vecs for disk operations while hiding some from the public series tree ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_traversable/src/lib.rs))
|
||||
- Added `Traversable` impls for `LazyAggVec`, `LazyDeltaVec`, `ReadOnlyCompressedVec`, `ReadOnlyRawVec` — enabling lazy and read-only vecs to appear in the series tree
|
||||
|
||||
#### `brk_traversable_derive`
|
||||
- Added `#[traversable(hidden)]` attribute at struct and field level — hidden structs return empty tree nodes and empty `iter_any_visible()` while still participating in `iter_any_exportable()` for disk I/O ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_traversable_derive/src/lib.rs))
|
||||
- Added automatic `ReadOnlyClone` derive generation — the proc macro now generates `impl ReadOnlyClone` alongside `impl Traversable`, mapping `Rw` to `Ro` storage mode for all fields with `StorageMode` parameters
|
||||
- Added multi-level `wrap` paths (`#[traversable(wrap = "a/b")]`) for creating nested tree structure
|
||||
- Preserved struct field declaration order in tree key ordering (previously normal and flattened fields were separated)
|
||||
|
||||
#### `brk_oracle`
|
||||
- Lowered `START_HEIGHT` from 575,000 to 550,000 — oracle begins computing 25,000 blocks earlier ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_oracle/src/lib.rs))
|
||||
|
||||
#### `brk_reader`
|
||||
- Added timestamp-based pre-filtering in block decoding — blocks are skipped by header timestamp before computing block hash, avoiding expensive RPC calls for out-of-range blocks ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_reader/src/lib.rs))
|
||||
- Added `find_magic()` function with XOR-decoded sliding window for blk file scanning, replacing byte-by-byte loop
|
||||
- Replaced batch-based block decoding pipeline (accumulated blocks, sleep-based backpressure) with direct `par_bridge()` streaming — simpler, no sleep delays
|
||||
|
||||
#### `brk_bindgen`
|
||||
- Added template-based pattern system with discriminator support — `try_detect_template()` handles suffix discriminators (e.g. `ratio_sd` vs `ratio_sd_4y`) and embedded discriminators (e.g. `ratio_pct99_bps` vs `ratio_pct1_bps`) for smarter client code generation ([source](https://github.com/bitcoinresearchkit/brk/blob/v0.2.0/crates/brk_bindgen/src/analysis/positions.rs))
|
||||
- Added two-pass field part analysis: first pass collects instance analyses bottom-up, second pass fills mixed-empty field parts using shortest leaf names
|
||||
- Added `owned_expr()`, `disc_arg_expr()`, `template_expr()` to `LanguageSyntax` trait for language-specific discriminator formatting
|
||||
- Fixed pattern normalization to only erase leaf types when all leaves share the same type (prevents incorrect genericization of mixed-type signatures)
|
||||
|
||||
#### `brk_client` (Rust)
|
||||
- Switched HTTP backend from `minreq` to `ureq`
|
||||
- Removed `fetch_prices.rs` example
|
||||
|
||||
#### `brk_client` (JavaScript)
|
||||
- Added `tests/consistency.js` — verifies all series sharing the same index have the same length (catches stale state after reorg rollback)
|
||||
- Upgraded `quickmatch` 0.3.1 → 0.4.0: expanded default separators (`_- :/`), added prefix indexing and compound word indexing (e.g. "hashrate" now matches "hash_rate"), added `minScore` threshold to reduce false positives, replaced per-match object allocation with pre-allocated `Uint32Array` scoring
|
||||
|
||||
#### `brk_client` (Python)
|
||||
- Added `DateSeriesData` subclass with date-aware methods (`.dates()`, `.date_items()`, `.to_date_dict()`) — date-based indexes return `DateSeriesData`, non-date indexes return `SeriesData`
|
||||
- Added new API methods: `get_series_data()`, `get_series_latest()`, `get_series_len()`, `get_series_version()`, `date_to_index()`
|
||||
- Added `DetailedSeriesCount` with `distinct_series`, `total_endpoints`, `lazy_endpoints`, `stored_endpoints` fields
|
||||
- Added `ErrorDetail`/`ErrorBody` types matching the server's structured error responses
|
||||
- Range parameters now accept `date` and `datetime` objects in addition to integers
|
||||
|
||||
### Internal Changes
|
||||
|
||||
#### `brk_computer`
|
||||
- Rewrote the `internal/` SDK: replaced the `single`/`multi` hierarchy (160+ files with per-combination types like `lazy_binary_computed_full`, `value_lazy_sum_cum`, `ComputedFromHeightAndDateLast`, `ComputedFromHeightSumCum`) with a composable system organized by concept (`per_block/`, `per_tx/`, `algo/`, `transform/`, `containers/`, `indexes/`). Concrete example: block count went from ~15 on-disk vecs (`ComputedFromHeightSumCum` + 4 rolling start vecs + 4 `ComputedFromHeightLast`) down to ~2 on-disk vecs (`PerBlockCumulativeRolling`) with all resolutions lazy
|
||||
- Added `UnaryTransform` trait system in `internal/transform/` replacing ad-hoc closures: `arithmetic.rs`, `bps.rs`, `currency.rs`, `derived.rs`, `ratio.rs`, `specialized.rs`
|
||||
- Added container types in `internal/containers/`: `per_resolution`, `windows`, `windows_from_1w`, `windows_to_1m`, `window_24h`, `distribution_stats`, `constant`, `percent`
|
||||
- Added per-block type variants: `PerBlock`, `PerBlockFull`, `PerBlockCumulative`, `PerBlockCumulativeWithSums`, `PerBlockRolling`, `PerBlockAggregated`, `LazyPerBlock`, `LazyPerBlockRolling`, plus `AmountPerBlock`, `AmountPerBlockCumulative`, `AmountPerBlockCumulativeRolling`, `AmountPerBlockWithDeltas`, `FiatPerBlock`, `PercentPerBlock`, `RatioPerBlock`, `PerBlockRollingAverage`, `PercentRollingWindows`, `PriceWithRatioPerBlock`, `StdDevPerBlock`
|
||||
- Added rolling types: `RollingComplete`, `LazyRollingComplete`, `RollingDistribution`, `LazyRollingSums`, `LazyRollingDeltasFromHeight`
|
||||
- Added per-tx types: `PerTxDerived`, `PerTxDistribution`, `LazyPerTxDerived`, `LazyPerTxDistribution`, `LazyPerTxDistributionTransformed`
|
||||
- Added eager/lazy index helpers in `internal/indexes/`
|
||||
- Introduced `CachedWindowStarts` for shared precomputed lookback window start positions across all modules
|
||||
- Split distribution UTXO cohort vecs into `core.rs`, `minimal.rs`, `type.rs` sub-modules for tiered storage
|
||||
- Added `sum_others` macro in distribution metrics for computing aggregate cohort fields by summing constituent cohorts
|
||||
- Removed `brk_fetcher` dependency — oracle prices are computed directly in the `prices/` module
|
||||
- Removed `distribution/compute/aggregates.rs` — aggregate computation replaced by `compute_from_stateful` / `compute_sum_of_others` within each metric tier
|
||||
|
||||
#### `brk_indexer`
|
||||
- Bumped reindex version 24 → 25 (forces full reindex on upgrade)
|
||||
- Added `StorageMode` generic parameter on `Indexer<M>` and `Vecs<M>` with `ReadOnlyClone` impl producing `Indexer<Ro>` for type-safe read-only sharing
|
||||
- Parallelized block processing pipeline: inputs and outputs now processed in parallel via `rayon::join`, finalization of outputs+inputs runs in parallel with tx metadata storage
|
||||
- Added `BlockBuffers` struct with reusable `FxHashMap`/`FxHashSet` allocations cleared per block, eliminating per-block allocation overhead
|
||||
- Added `AddrTypeVecs<I, B>` and `ScriptTypeVecs<I>` generic sub-structs for uniform per-type vec organization, replacing individually named fields
|
||||
- Added `TxMetadataVecs` sub-struct with `split_for_finalize()` for separating tx metadata vecs from index vecs during parallel finalization
|
||||
- Added `AddrReaders` with `script_pubkey(&self, output_type, type_index) -> ScriptBuf` for typed address-to-script lookup
|
||||
- Block size and weight now computed from pre-computed `ComputedTx.base_size`/`total_size` fields instead of re-serializing transactions
|
||||
- Removed 512MB thread stack size workaround — main function runs directly
|
||||
- Added `schemars` and `serde` dependencies for OpenAPI-compatible schema generation
|
||||
|
||||
#### `brk_server`
|
||||
- Applied `NormalizePathLayer` as an outer wrapping layer (via `ServiceExt`) instead of an inner router layer, fixing route matching for trailing slashes
|
||||
- Reduced in-memory response cache from 5,000 to 1,000 entries
|
||||
- Moved `CatchPanicLayer` after compression in the middleware stack with a custom handler
|
||||
- Restructured response caching to include content encoding in cache keys, pre-compressing responses per-encoding for cache-friendly serving
|
||||
- Added `brotli`, `flate2`, and `zstd` dependencies for server-side compression
|
||||
- Added `color-eyre` for panic reporting
|
||||
|
||||
#### `brk_query`
|
||||
- Removed thread stack-size workaround in the query example — main function now runs directly
|
||||
- Added `parking_lot` and `serde_json` dependencies
|
||||
|
||||
#### `brk_rpc`
|
||||
- Added `serde` and `serde_json` dependencies for `corepc` feature
|
||||
|
||||
#### `brk_store`
|
||||
- Removed `insert_if_needed()` and `remove_if_needed()` — callers now use plain `insert()`/`remove()`
|
||||
- Changed `clear_caches()` to drop allocations entirely (`FxHashMap::default()`) instead of clearing in place
|
||||
|
||||
#### `brk_reader`
|
||||
- Removed batch-based block decoding pipeline — simplified to streaming `par_bridge()`
|
||||
- Removed `AnyBlock` enum, replaced with `decode_block()` standalone function
|
||||
- Added `find_magic()` with XOR-decoded sliding window for efficient blk file scanning
|
||||
|
||||
#### `brk_logger`
|
||||
- Replaced `EnvFilter` with `Targets` for simpler log filter configuration
|
||||
- Separated `LOG` (default level) from `RUST_LOG` (full directive control) environment variables
|
||||
- Added `corepc=off` to default filter list
|
||||
|
||||
#### `brk_error`
|
||||
- Added `brk-corepc-client` and `ureq` error conversions, removed `minreq` error conversions
|
||||
|
||||
#### `brk_cli`
|
||||
- Removed `--fetch` CLI flag and `brk_fetcher` dependency — price fetching handled by the oracle
|
||||
- Removed 512MB thread stack size workaround
|
||||
|
||||
#### `docker`
|
||||
- Switched base image from `rustlang/rust:nightly` to `rust:1.93-bookworm` (stable, pinned)
|
||||
- Replaced `pgrep + nc` healthcheck with `curl -sf http://localhost:3110/health`
|
||||
- Removed `docker-build.sh` helper script and docker-specific `.dockerignore`
|
||||
- Removed all `environment:` variables from `docker-compose.yml` — configuration now via `command:` args only
|
||||
|
||||
#### `scripts`
|
||||
- Added `pool_major_threshold.py` — utility to determine major vs minor pool classification based on rolling dominance thresholds across multiple time windows
|
||||
|
||||
#### `workspace`
|
||||
- Upgraded Rust toolchain to edition 2024
|
||||
- Updated `.dockerignore` to exclude `docker/` directory
|
||||
|
||||
[View changes](https://github.com/bitcoinresearchkit/brk/compare/v0.1.9...v0.2.0)
|
||||
|
||||
## [v0.1.9](https://github.com/bitcoinresearchkit/brk/releases/tag/v0.1.9) - 2026-02-13
|
||||
|
||||
### New Features
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Class: BrkClient
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:6359](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L6359)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:6383](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L6383)
|
||||
|
||||
Main BRK client with series tree and API methods
|
||||
|
||||
@@ -20,7 +20,7 @@ Main BRK client with series tree and API methods
|
||||
|
||||
> **new BrkClient**(`options`): `BrkClient`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:7536](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L7536)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:7560](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L7560)
|
||||
|
||||
#### Parameters
|
||||
|
||||
@@ -42,7 +42,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:7536](https://github.com/
|
||||
|
||||
> **\_cache**: `Cache` \| `null`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1347](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1347)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1347](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1347)
|
||||
|
||||
#### Inherited from
|
||||
|
||||
@@ -54,7 +54,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1347](https://github.com/
|
||||
|
||||
> **\_cachePromise**: `Promise`\<`Cache` \| `null`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1345](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1345)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1345](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1345)
|
||||
|
||||
#### Inherited from
|
||||
|
||||
@@ -66,7 +66,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1345](https://github.com/
|
||||
|
||||
> **series**: [`SeriesTree`](../interfaces/SeriesTree.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:7539](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L7539)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:7563](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L7563)
|
||||
|
||||
## Methods
|
||||
|
||||
@@ -74,7 +74,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:7539](https://github.com/
|
||||
|
||||
> **\_fetchSeriesData**\<`T`\>(`path`, `onUpdate?`): `Promise`\<[`DateSeriesData`](../type-aliases/DateSeriesData.md)\<`T`\>\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1435](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1435)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1435](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1435)
|
||||
|
||||
Fetch series data and wrap with helper methods (internal)
|
||||
|
||||
@@ -108,7 +108,7 @@ Fetch series data and wrap with helper methods (internal)
|
||||
|
||||
> **dateToIndex**(`index`, `d`): `number`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:7528](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L7528)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:7552](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L7552)
|
||||
|
||||
Convert a Date to an index value for date-based indexes.
|
||||
|
||||
@@ -136,7 +136,7 @@ The date to convert
|
||||
|
||||
> **get**(`path`): `Promise`\<`Response`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1355](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1355)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1355](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1355)
|
||||
|
||||
#### Parameters
|
||||
|
||||
@@ -158,7 +158,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1355](https://github.com/
|
||||
|
||||
> **getAddress**(`address`): `Promise`\<[`AddrStats`](../interfaces/AddrStats.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9224](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9224)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9262](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9262)
|
||||
|
||||
Address information
|
||||
|
||||
@@ -184,7 +184,7 @@ Endpoint: `GET /api/address/{address}`
|
||||
|
||||
> **getAddressConfirmedTxs**(`address`, `after_txid?`): `Promise`\<[`Transaction`](../interfaces/Transaction.md)[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9262](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9262)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9300](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9300)
|
||||
|
||||
Address confirmed transactions
|
||||
|
||||
@@ -216,7 +216,7 @@ Txid to paginate from (return transactions before this one)
|
||||
|
||||
> **getAddressMempoolTxs**(`address`): `Promise`\<`string`[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9282](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9282)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9320](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9320)
|
||||
|
||||
Address mempool transactions
|
||||
|
||||
@@ -242,7 +242,7 @@ Endpoint: `GET /api/address/{address}/txs/mempool`
|
||||
|
||||
> **getAddressTxs**(`address`, `after_txid?`): `Promise`\<[`Transaction`](../interfaces/Transaction.md)[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9241](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9241)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9279](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9279)
|
||||
|
||||
Address transactions
|
||||
|
||||
@@ -274,7 +274,7 @@ Txid to paginate from (return transactions before this one)
|
||||
|
||||
> **getAddressUtxos**(`address`): `Promise`\<[`Utxo`](../interfaces/Utxo.md)[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9298](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9298)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9336](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9336)
|
||||
|
||||
Address UTXOs
|
||||
|
||||
@@ -300,7 +300,7 @@ Endpoint: `GET /api/address/{address}/utxo`
|
||||
|
||||
> **getApi**(): `Promise`\<`any`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9208](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9208)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9246](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9246)
|
||||
|
||||
Compact OpenAPI specification
|
||||
|
||||
@@ -318,7 +318,7 @@ Endpoint: `GET /api.json`
|
||||
|
||||
> **getBlock**(`hash`): `Promise`\<[`BlockInfo`](../interfaces/BlockInfo.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9330](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9330)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9368](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9368)
|
||||
|
||||
Block information
|
||||
|
||||
@@ -344,7 +344,7 @@ Endpoint: `GET /api/block/{hash}`
|
||||
|
||||
> **getBlockByHeight**(`height`): `Promise`\<[`BlockInfo`](../interfaces/BlockInfo.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9314](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9314)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9352](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9352)
|
||||
|
||||
Block by height
|
||||
|
||||
@@ -370,7 +370,7 @@ Endpoint: `GET /api/block-height/{height}`
|
||||
|
||||
> **getBlockByTimestamp**(`timestamp`): `Promise`\<[`BlockTimestamp`](../interfaces/BlockTimestamp.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9985](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9985)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10023](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L10023)
|
||||
|
||||
Block by timestamp
|
||||
|
||||
@@ -396,7 +396,7 @@ Endpoint: `GET /api/v1/mining/blocks/timestamp/{timestamp}`
|
||||
|
||||
> **getBlockFeeRates**(`time_period`): `Promise`\<`any`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9921](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9921)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9959](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9959)
|
||||
|
||||
Block fee rates (WIP)
|
||||
|
||||
@@ -422,7 +422,7 @@ Endpoint: `GET /api/v1/mining/blocks/fee-rates/{time_period}`
|
||||
|
||||
> **getBlockFees**(`time_period`): `Promise`\<[`BlockFeesEntry`](../interfaces/BlockFeesEntry.md)[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9937](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9937)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9975](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9975)
|
||||
|
||||
Block fees
|
||||
|
||||
@@ -448,7 +448,7 @@ Endpoint: `GET /api/v1/mining/blocks/fees/{time_period}`
|
||||
|
||||
> **getBlockRaw**(`hash`): `Promise`\<`number`[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9346](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9346)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9384](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9384)
|
||||
|
||||
Raw block
|
||||
|
||||
@@ -474,7 +474,7 @@ Endpoint: `GET /api/block/{hash}/raw`
|
||||
|
||||
> **getBlockRewards**(`time_period`): `Promise`\<[`BlockRewardsEntry`](../interfaces/BlockRewardsEntry.md)[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9953](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9953)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9991](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9991)
|
||||
|
||||
Block rewards
|
||||
|
||||
@@ -500,7 +500,7 @@ Endpoint: `GET /api/v1/mining/blocks/rewards/{time_period}`
|
||||
|
||||
> **getBlocks**(): `Promise`\<[`BlockInfo`](../interfaces/BlockInfo.md)[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9426](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9426)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9464](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9464)
|
||||
|
||||
Recent blocks
|
||||
|
||||
@@ -520,7 +520,7 @@ Endpoint: `GET /api/blocks`
|
||||
|
||||
> **getBlocksFromHeight**(`height`): `Promise`\<[`BlockInfo`](../interfaces/BlockInfo.md)[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9442](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9442)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9480](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9480)
|
||||
|
||||
Blocks from height
|
||||
|
||||
@@ -546,7 +546,7 @@ Endpoint: `GET /api/blocks/{height}`
|
||||
|
||||
> **getBlockSizesWeights**(`time_period`): `Promise`\<[`BlockSizesWeights`](../interfaces/BlockSizesWeights.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9969](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9969)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10007](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L10007)
|
||||
|
||||
Block sizes and weights
|
||||
|
||||
@@ -572,7 +572,7 @@ Endpoint: `GET /api/v1/mining/blocks/sizes-weights/{time_period}`
|
||||
|
||||
> **getBlockStatus**(`hash`): `Promise`\<[`BlockStatus`](../interfaces/BlockStatus.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9362](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9362)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9400](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9400)
|
||||
|
||||
Block status
|
||||
|
||||
@@ -598,7 +598,7 @@ Endpoint: `GET /api/block/{hash}/status`
|
||||
|
||||
> **getBlockTxid**(`hash`, `index`): `Promise`\<`string`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9379](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9379)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9417](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9417)
|
||||
|
||||
Transaction ID at index
|
||||
|
||||
@@ -632,7 +632,7 @@ Transaction index within the block (0-based)
|
||||
|
||||
> **getBlockTxids**(`hash`): `Promise`\<`string`[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9395](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9395)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9433](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9433)
|
||||
|
||||
Block transaction IDs
|
||||
|
||||
@@ -658,7 +658,7 @@ Endpoint: `GET /api/block/{hash}/txids`
|
||||
|
||||
> **getBlockTxs**(`hash`, `start_index`): `Promise`\<[`Transaction`](../interfaces/Transaction.md)[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9412](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9412)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9450](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9450)
|
||||
|
||||
Block transactions (paginated)
|
||||
|
||||
@@ -692,7 +692,7 @@ Starting transaction index within the block (0-based)
|
||||
|
||||
> **getCostBasis**(`cohort`, `date`, `bucket?`, `value?`): `Promise`\<`Object`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9572](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9572)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9610](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9610)
|
||||
|
||||
Cost basis distribution
|
||||
|
||||
@@ -736,7 +736,7 @@ Value type to return. Default: supply.
|
||||
|
||||
> **getCostBasisCohorts**(): `Promise`\<`string`[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9537](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9537)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9575](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9575)
|
||||
|
||||
Available cost basis cohorts
|
||||
|
||||
@@ -754,7 +754,7 @@ Endpoint: `GET /api/series/cost-basis`
|
||||
|
||||
> **getCostBasisDates**(`cohort`): `Promise`\<`number`[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9551](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9551)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9589](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9589)
|
||||
|
||||
Available cost basis dates
|
||||
|
||||
@@ -778,7 +778,7 @@ Endpoint: `GET /api/series/cost-basis/{cohort}/dates`
|
||||
|
||||
> **getDifficultyAdjustment**(): `Promise`\<[`DifficultyAdjustment`](../interfaces/DifficultyAdjustment.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9877](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9877)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9915](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9915)
|
||||
|
||||
Difficulty adjustment
|
||||
|
||||
@@ -798,7 +798,7 @@ Endpoint: `GET /api/v1/difficulty-adjustment`
|
||||
|
||||
> **getDifficultyAdjustments**(): `Promise`\<[`DifficultyAdjustmentEntry`](../interfaces/DifficultyAdjustmentEntry.md)[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9999](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9999)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10037](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L10037)
|
||||
|
||||
Difficulty adjustments (all time)
|
||||
|
||||
@@ -818,7 +818,7 @@ Endpoint: `GET /api/v1/mining/difficulty-adjustments`
|
||||
|
||||
> **getDifficultyAdjustmentsByPeriod**(`time_period`): `Promise`\<[`DifficultyAdjustmentEntry`](../interfaces/DifficultyAdjustmentEntry.md)[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10015](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L10015)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10053](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L10053)
|
||||
|
||||
Difficulty adjustments
|
||||
|
||||
@@ -844,7 +844,7 @@ Endpoint: `GET /api/v1/mining/difficulty-adjustments/{time_period}`
|
||||
|
||||
> **getDiskUsage**(): `Promise`\<[`DiskUsage`](../interfaces/DiskUsage.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9770](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9770)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9808](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9808)
|
||||
|
||||
Disk usage
|
||||
|
||||
@@ -862,7 +862,7 @@ Endpoint: `GET /api/server/disk`
|
||||
|
||||
> **getHashrate**(): `Promise`\<[`HashrateSummary`](../interfaces/HashrateSummary.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10029](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L10029)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10067](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L10067)
|
||||
|
||||
Network hashrate (all time)
|
||||
|
||||
@@ -882,7 +882,7 @@ Endpoint: `GET /api/v1/mining/hashrate`
|
||||
|
||||
> **getHashrateByPeriod**(`time_period`): `Promise`\<[`HashrateSummary`](../interfaces/HashrateSummary.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10045](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L10045)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10083](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L10083)
|
||||
|
||||
Network hashrate
|
||||
|
||||
@@ -908,7 +908,7 @@ Endpoint: `GET /api/v1/mining/hashrate/{time_period}`
|
||||
|
||||
> **getHealth**(): `Promise`\<[`Health`](../interfaces/Health.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10135](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L10135)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10173](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L10173)
|
||||
|
||||
Health check
|
||||
|
||||
@@ -926,7 +926,7 @@ Endpoint: `GET /health`
|
||||
|
||||
> **getIndexes**(): `Promise`\<[`IndexInfo`](../interfaces/IndexInfo.md)[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9601](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9601)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9639](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9639)
|
||||
|
||||
List available indexes
|
||||
|
||||
@@ -944,7 +944,7 @@ Endpoint: `GET /api/series/indexes`
|
||||
|
||||
> **getJson**\<`T`\>(`path`, `onUpdate?`): `Promise`\<`T`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1369](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1369)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1369](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1369)
|
||||
|
||||
Make a GET request - races cache vs network, first to resolve calls onUpdate
|
||||
|
||||
@@ -980,7 +980,7 @@ Called when data is available (may be called twice: cache then network)
|
||||
|
||||
> **getLivePrice**(): `Promise`\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9468](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9468)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9506](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9506)
|
||||
|
||||
Live BTC/USD price
|
||||
|
||||
@@ -998,7 +998,7 @@ Endpoint: `GET /api/mempool/price`
|
||||
|
||||
> **getMempool**(): `Promise`\<[`MempoolInfo`](../interfaces/MempoolInfo.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9456](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9456)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9494](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9494)
|
||||
|
||||
Mempool statistics
|
||||
|
||||
@@ -1018,7 +1018,7 @@ Endpoint: `GET /api/mempool/info`
|
||||
|
||||
> **getMempoolBlocks**(): `Promise`\<[`MempoolBlock`](../interfaces/MempoolBlock.md)[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9891](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9891)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9929](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9929)
|
||||
|
||||
Projected mempool blocks
|
||||
|
||||
@@ -1038,7 +1038,7 @@ Endpoint: `GET /api/v1/fees/mempool-blocks`
|
||||
|
||||
> **getMempoolTxids**(): `Promise`\<`string`[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9482](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9482)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9520](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9520)
|
||||
|
||||
Mempool transaction IDs
|
||||
|
||||
@@ -1058,7 +1058,7 @@ Endpoint: `GET /api/mempool/txids`
|
||||
|
||||
> **getOpenapi**(): `Promise`\<`any`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10147](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L10147)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10185](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L10185)
|
||||
|
||||
OpenAPI specification
|
||||
|
||||
@@ -1076,7 +1076,7 @@ Endpoint: `GET /openapi.json`
|
||||
|
||||
> **getPool**(`slug`): `Promise`\<[`PoolDetail`](../interfaces/PoolDetail.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10061](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L10061)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10099](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L10099)
|
||||
|
||||
Mining pool details
|
||||
|
||||
@@ -1102,7 +1102,7 @@ Endpoint: `GET /api/v1/mining/pool/{slug}`
|
||||
|
||||
> **getPools**(): `Promise`\<[`PoolInfo`](../interfaces/PoolInfo.md)[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10075](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L10075)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10113](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L10113)
|
||||
|
||||
List all mining pools
|
||||
|
||||
@@ -1122,7 +1122,7 @@ Endpoint: `GET /api/v1/mining/pools`
|
||||
|
||||
> **getPoolStats**(`time_period`): `Promise`\<[`PoolsSummary`](../interfaces/PoolsSummary.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10091](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L10091)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10129](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L10129)
|
||||
|
||||
Mining pool statistics
|
||||
|
||||
@@ -1148,7 +1148,7 @@ Endpoint: `GET /api/v1/mining/pools/{time_period}`
|
||||
|
||||
> **getRecommendedFees**(): `Promise`\<[`RecommendedFees`](../interfaces/RecommendedFees.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9905](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9905)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9943](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9943)
|
||||
|
||||
Recommended fees
|
||||
|
||||
@@ -1168,7 +1168,7 @@ Endpoint: `GET /api/v1/fees/recommended`
|
||||
|
||||
> **getRewardStats**(`block_count`): `Promise`\<[`RewardStats`](../interfaces/RewardStats.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10107](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L10107)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10145](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L10145)
|
||||
|
||||
Mining reward statistics
|
||||
|
||||
@@ -1196,7 +1196,7 @@ Number of recent blocks to include
|
||||
|
||||
> **getSeries**(`series`, `index`, `start?`, `end?`, `limit?`, `format?`): `Promise`\<`string` \| [`AnySeriesData`](../type-aliases/AnySeriesData.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9674](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9674)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9712](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9712)
|
||||
|
||||
Get series data
|
||||
|
||||
@@ -1252,7 +1252,7 @@ Format of the output
|
||||
|
||||
> **getSeriesBulk**(`series?`, `index?`, `start?`, `end?`, `limit?`, `format?`): `Promise`\<`string` \| [`AnySeriesData`](../type-aliases/AnySeriesData.md)[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9513](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9513)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9551](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9551)
|
||||
|
||||
Bulk series data
|
||||
|
||||
@@ -1308,7 +1308,7 @@ Format of the output
|
||||
|
||||
> **getSeriesCount**(): `Promise`\<[`SeriesCount`](../interfaces/SeriesCount.md)[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9589](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9589)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9627](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9627)
|
||||
|
||||
Series count
|
||||
|
||||
@@ -1326,7 +1326,7 @@ Endpoint: `GET /api/series/count`
|
||||
|
||||
> **getSeriesData**(`series`, `index`, `start?`, `end?`, `limit?`, `format?`): `Promise`\<`string` \| `boolean`[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9703](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9703)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9741](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9741)
|
||||
|
||||
Get raw series data
|
||||
|
||||
@@ -1382,7 +1382,7 @@ Format of the output
|
||||
|
||||
> **getSeriesInfo**(`series`): `Promise`\<[`SeriesInfo`](../interfaces/SeriesInfo.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9655](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9655)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9693](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9693)
|
||||
|
||||
Get series info
|
||||
|
||||
@@ -1406,7 +1406,7 @@ Endpoint: `GET /api/series/{series}`
|
||||
|
||||
> **getSeriesLatest**(`series`, `index`): `Promise`\<`any`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9728](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9728)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9766](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9766)
|
||||
|
||||
Get latest series value
|
||||
|
||||
@@ -1438,7 +1438,7 @@ Aggregation index
|
||||
|
||||
> **getSeriesLen**(`series`, `index`): `Promise`\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9743](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9743)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9781](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9781)
|
||||
|
||||
Get series data length
|
||||
|
||||
@@ -1470,7 +1470,7 @@ Aggregation index
|
||||
|
||||
> **getSeriesTree**(): `Promise`\<[`TreeNode`](../type-aliases/TreeNode.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9494](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9494)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9532](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9532)
|
||||
|
||||
Series catalog
|
||||
|
||||
@@ -1488,7 +1488,7 @@ Endpoint: `GET /api/series`
|
||||
|
||||
> **getSeriesVersion**(`series`, `index`): `Promise`\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9758](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9758)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9796](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9796)
|
||||
|
||||
Get series version
|
||||
|
||||
@@ -1520,7 +1520,7 @@ Aggregation index
|
||||
|
||||
> **getSyncStatus**(): `Promise`\<[`SyncStatus`](../interfaces/SyncStatus.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9782](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9782)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9820](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9820)
|
||||
|
||||
Sync status
|
||||
|
||||
@@ -1538,7 +1538,7 @@ Endpoint: `GET /api/server/sync`
|
||||
|
||||
> **getText**(`path`): `Promise`\<`string`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1423](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1423)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1423](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1423)
|
||||
|
||||
Make a GET request and return raw text (for CSV responses)
|
||||
|
||||
@@ -1562,7 +1562,7 @@ Make a GET request and return raw text (for CSV responses)
|
||||
|
||||
> **getTx**(`txid`): `Promise`\<[`Transaction`](../interfaces/Transaction.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9798](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9798)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9836](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9836)
|
||||
|
||||
Transaction information
|
||||
|
||||
@@ -1588,7 +1588,7 @@ Endpoint: `GET /api/tx/{txid}`
|
||||
|
||||
> **getTxHex**(`txid`): `Promise`\<`string`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9814](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9814)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9852](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9852)
|
||||
|
||||
Transaction hex
|
||||
|
||||
@@ -1614,7 +1614,7 @@ Endpoint: `GET /api/tx/{txid}/hex`
|
||||
|
||||
> **getTxOutspend**(`txid`, `vout`): `Promise`\<[`TxOutspend`](../interfaces/TxOutspend.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9831](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9831)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9869](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9869)
|
||||
|
||||
Output spend status
|
||||
|
||||
@@ -1648,7 +1648,7 @@ Output index
|
||||
|
||||
> **getTxOutspends**(`txid`): `Promise`\<[`TxOutspend`](../interfaces/TxOutspend.md)[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9847](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9847)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9885](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9885)
|
||||
|
||||
All output spend statuses
|
||||
|
||||
@@ -1674,7 +1674,7 @@ Endpoint: `GET /api/tx/{txid}/outspends`
|
||||
|
||||
> **getTxStatus**(`txid`): `Promise`\<[`TxStatus`](../interfaces/TxStatus.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9863](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9863)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9901](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9901)
|
||||
|
||||
Transaction status
|
||||
|
||||
@@ -1700,7 +1700,7 @@ Endpoint: `GET /api/tx/{txid}/status`
|
||||
|
||||
> **getVersion**(): `Promise`\<`string`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10159](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L10159)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10197](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L10197)
|
||||
|
||||
API version
|
||||
|
||||
@@ -1718,7 +1718,7 @@ Endpoint: `GET /version`
|
||||
|
||||
> **indexToDate**(`index`, `i`): `Date`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:7518](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L7518)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:7542](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L7542)
|
||||
|
||||
Convert an index value to a Date for date-based indexes.
|
||||
|
||||
@@ -1746,7 +1746,7 @@ The index value
|
||||
|
||||
> **listSeries**(`page?`, `per_page?`): `Promise`\<[`PaginatedSeries`](../interfaces/PaginatedSeries.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9616](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9616)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9654](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9654)
|
||||
|
||||
Series list
|
||||
|
||||
@@ -1778,7 +1778,7 @@ Results per page (default: 1000, max: 1000)
|
||||
|
||||
> **searchSeries**(`q?`, `limit?`): `Promise`\<`string`[]\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9636](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9636)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9674](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9674)
|
||||
|
||||
Search series
|
||||
|
||||
@@ -1810,7 +1810,7 @@ Maximum number of results
|
||||
|
||||
> **seriesEndpoint**(`series`, `index`): [`SeriesEndpoint`](../interfaces/SeriesEndpoint.md)\<`unknown`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9196](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L9196)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:9234](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L9234)
|
||||
|
||||
Create a dynamic series endpoint builder for any series/index combination.
|
||||
|
||||
@@ -1841,7 +1841,7 @@ The index name
|
||||
|
||||
> **validateAddress**(`address`): `Promise`\<[`AddrValidation`](../interfaces/AddrValidation.md)\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10123](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L10123)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:10161](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L10161)
|
||||
|
||||
Validate address
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Class: BrkError
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:999](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L999)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:999](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L999)
|
||||
|
||||
Custom error class for BRK client errors
|
||||
|
||||
@@ -20,7 +20,7 @@ Custom error class for BRK client errors
|
||||
|
||||
> **new BrkError**(`message`, `status?`): `BrkError`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1004](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1004)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1004](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1004)
|
||||
|
||||
#### Parameters
|
||||
|
||||
|
||||
@@ -158,7 +158,7 @@
|
||||
- [PaginatedSeries](interfaces/PaginatedSeries.md)
|
||||
- [Pagination](interfaces/Pagination.md)
|
||||
- [Pct05Pct10Pct15Pct20Pct25Pct30Pct35Pct40Pct45Pct50Pct55Pct60Pct65Pct70Pct75Pct80Pct85Pct90Pct95Pattern](interfaces/Pct05Pct10Pct15Pct20Pct25Pct30Pct35Pct40Pct45Pct50Pct55Pct60Pct65Pct70Pct75Pct80Pct85Pct90Pct95Pattern.md)
|
||||
- [Pct1Pct2Pct5Pct95Pct98Pct99Pattern](interfaces/Pct1Pct2Pct5Pct95Pct98Pct99Pattern.md)
|
||||
- [Pct0Pct1Pct2Pct5Pct95Pct98Pct99Pattern](interfaces/Pct0Pct1Pct2Pct5Pct95Pct98Pct99Pattern.md)
|
||||
- [PerPattern](interfaces/PerPattern.md)
|
||||
- [PhsReboundThsPattern](interfaces/PhsReboundThsPattern.md)
|
||||
- [PoolBlockCounts](interfaces/PoolBlockCounts.md)
|
||||
@@ -306,6 +306,7 @@
|
||||
- [SeriesTree\_Indexes\_Month1](interfaces/SeriesTree_Indexes_Month1.md)
|
||||
- [SeriesTree\_Indexes\_Month3](interfaces/SeriesTree_Indexes_Month3.md)
|
||||
- [SeriesTree\_Indexes\_Month6](interfaces/SeriesTree_Indexes_Month6.md)
|
||||
- [SeriesTree\_Indexes\_Timestamp](interfaces/SeriesTree_Indexes_Timestamp.md)
|
||||
- [SeriesTree\_Indexes\_TxIndex](interfaces/SeriesTree_Indexes_TxIndex.md)
|
||||
- [SeriesTree\_Indexes\_TxinIndex](interfaces/SeriesTree_Indexes_TxinIndex.md)
|
||||
- [SeriesTree\_Indexes\_TxoutIndex](interfaces/SeriesTree_Indexes_TxoutIndex.md)
|
||||
@@ -314,18 +315,19 @@
|
||||
- [SeriesTree\_Indexes\_Year10](interfaces/SeriesTree_Indexes_Year10.md)
|
||||
- [SeriesTree\_Indicators](interfaces/SeriesTree_Indicators.md)
|
||||
- [SeriesTree\_Indicators\_Dormancy](interfaces/SeriesTree_Indicators_Dormancy.md)
|
||||
- [SeriesTree\_Indicators\_RealizedEnvelope](interfaces/SeriesTree_Indicators_RealizedEnvelope.md)
|
||||
- [SeriesTree\_Inputs](interfaces/SeriesTree_Inputs.md)
|
||||
- [SeriesTree\_Inputs\_Raw](interfaces/SeriesTree_Inputs_Raw.md)
|
||||
- [SeriesTree\_Inputs\_Spent](interfaces/SeriesTree_Inputs_Spent.md)
|
||||
- [SeriesTree\_Investing](interfaces/SeriesTree_Investing.md)
|
||||
- [SeriesTree\_Investing\_Class](interfaces/SeriesTree_Investing_Class.md)
|
||||
- [SeriesTree\_Investing\_Class\_DcaCostBasis](interfaces/SeriesTree_Investing_Class_DcaCostBasis.md)
|
||||
- [SeriesTree\_Investing\_Class\_DcaReturn](interfaces/SeriesTree_Investing_Class_DcaReturn.md)
|
||||
- [SeriesTree\_Investing\_Class\_DcaStack](interfaces/SeriesTree_Investing_Class_DcaStack.md)
|
||||
- [SeriesTree\_Investing\_Period](interfaces/SeriesTree_Investing_Period.md)
|
||||
- [SeriesTree\_Investing\_Period\_DcaCostBasis](interfaces/SeriesTree_Investing_Period_DcaCostBasis.md)
|
||||
- [SeriesTree\_Market](interfaces/SeriesTree_Market.md)
|
||||
- [SeriesTree\_Market\_Ath](interfaces/SeriesTree_Market_Ath.md)
|
||||
- [SeriesTree\_Market\_Dca](interfaces/SeriesTree_Market_Dca.md)
|
||||
- [SeriesTree\_Market\_Dca\_Class](interfaces/SeriesTree_Market_Dca_Class.md)
|
||||
- [SeriesTree\_Market\_Dca\_Class\_CostBasis](interfaces/SeriesTree_Market_Dca_Class_CostBasis.md)
|
||||
- [SeriesTree\_Market\_Dca\_Class\_Return](interfaces/SeriesTree_Market_Dca_Class_Return.md)
|
||||
- [SeriesTree\_Market\_Dca\_Class\_Stack](interfaces/SeriesTree_Market_Dca_Class_Stack.md)
|
||||
- [SeriesTree\_Market\_Dca\_Period](interfaces/SeriesTree_Market_Dca_Period.md)
|
||||
- [SeriesTree\_Market\_Dca\_Period\_CostBasis](interfaces/SeriesTree_Market_Dca_Period_CostBasis.md)
|
||||
- [SeriesTree\_Market\_Lookback](interfaces/SeriesTree_Market_Lookback.md)
|
||||
- [SeriesTree\_Market\_MovingAverage](interfaces/SeriesTree_Market_MovingAverage.md)
|
||||
- [SeriesTree\_Market\_MovingAverage\_Ema](interfaces/SeriesTree_Market_MovingAverage_Ema.md)
|
||||
|
||||
+16
-16
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_0sdM0M1M1sdM2M2sdM3sdP0P1P1sdP2P2sdP3sdSdZscorePattern
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1685](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1685)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1685](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1685)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1685](https://github.com/
|
||||
|
||||
> **\_0sd**: [`CentsSatsUsdPattern`](CentsSatsUsdPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1686](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1686)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1686](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1686)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1686](https://github.com/
|
||||
|
||||
> **m05sd**: [`PriceRatioPattern`](PriceRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1687](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1687)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1687](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1687)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1687](https://github.com/
|
||||
|
||||
> **m15sd**: [`PriceRatioPattern`](PriceRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1688](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1688)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1688](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1688)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,7 +38,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1688](https://github.com/
|
||||
|
||||
> **m1sd**: [`PriceRatioPattern`](PriceRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1689](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1689)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1689](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1689)
|
||||
|
||||
***
|
||||
|
||||
@@ -46,7 +46,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1689](https://github.com/
|
||||
|
||||
> **m25sd**: [`PriceRatioPattern`](PriceRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1690](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1690)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1690](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1690)
|
||||
|
||||
***
|
||||
|
||||
@@ -54,7 +54,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1690](https://github.com/
|
||||
|
||||
> **m2sd**: [`PriceRatioPattern`](PriceRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1691](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1691)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1691](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1691)
|
||||
|
||||
***
|
||||
|
||||
@@ -62,7 +62,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1691](https://github.com/
|
||||
|
||||
> **m3sd**: [`PriceRatioPattern`](PriceRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1692](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1692)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1692](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1692)
|
||||
|
||||
***
|
||||
|
||||
@@ -70,7 +70,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1692](https://github.com/
|
||||
|
||||
> **p05sd**: [`PriceRatioPattern`](PriceRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1693](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1693)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1693](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1693)
|
||||
|
||||
***
|
||||
|
||||
@@ -78,7 +78,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1693](https://github.com/
|
||||
|
||||
> **p15sd**: [`PriceRatioPattern`](PriceRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1694](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1694)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1694](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1694)
|
||||
|
||||
***
|
||||
|
||||
@@ -86,7 +86,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1694](https://github.com/
|
||||
|
||||
> **p1sd**: [`PriceRatioPattern`](PriceRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1695](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1695)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1695](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1695)
|
||||
|
||||
***
|
||||
|
||||
@@ -94,7 +94,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1695](https://github.com/
|
||||
|
||||
> **p25sd**: [`PriceRatioPattern`](PriceRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1696](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1696)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1696](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1696)
|
||||
|
||||
***
|
||||
|
||||
@@ -102,7 +102,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1696](https://github.com/
|
||||
|
||||
> **p2sd**: [`PriceRatioPattern`](PriceRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1697](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1697)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1697](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1697)
|
||||
|
||||
***
|
||||
|
||||
@@ -110,7 +110,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1697](https://github.com/
|
||||
|
||||
> **p3sd**: [`PriceRatioPattern`](PriceRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1698](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1698)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1698](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1698)
|
||||
|
||||
***
|
||||
|
||||
@@ -118,7 +118,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1698](https://github.com/
|
||||
|
||||
> **sd**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1699](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1699)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1699](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1699)
|
||||
|
||||
***
|
||||
|
||||
@@ -126,4 +126,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1699](https://github.com/
|
||||
|
||||
> **zscore**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1700](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1700)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1700](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1700)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_10y1m1w1y2y3m3y4y5y6m6y8yPattern2
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1704](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1704)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1704](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1704)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1704](https://github.com/
|
||||
|
||||
> **\_10y**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1705](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1705)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1705](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1705)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1705](https://github.com/
|
||||
|
||||
> **\_1m**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1706](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1706)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1706](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1706)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1706](https://github.com/
|
||||
|
||||
> **\_1w**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1707](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1707)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1707](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1707)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,7 +38,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1707](https://github.com/
|
||||
|
||||
> **\_1y**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1708](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1708)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1708](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1708)
|
||||
|
||||
***
|
||||
|
||||
@@ -46,7 +46,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1708](https://github.com/
|
||||
|
||||
> **\_2y**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1709](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1709)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1709](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1709)
|
||||
|
||||
***
|
||||
|
||||
@@ -54,7 +54,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1709](https://github.com/
|
||||
|
||||
> **\_3m**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1710](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1710)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1710](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1710)
|
||||
|
||||
***
|
||||
|
||||
@@ -62,7 +62,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1710](https://github.com/
|
||||
|
||||
> **\_3y**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1711](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1711)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1711](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1711)
|
||||
|
||||
***
|
||||
|
||||
@@ -70,7 +70,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1711](https://github.com/
|
||||
|
||||
> **\_4y**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1712](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1712)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1712](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1712)
|
||||
|
||||
***
|
||||
|
||||
@@ -78,7 +78,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1712](https://github.com/
|
||||
|
||||
> **\_5y**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1713](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1713)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1713](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1713)
|
||||
|
||||
***
|
||||
|
||||
@@ -86,7 +86,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1713](https://github.com/
|
||||
|
||||
> **\_6m**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1714](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1714)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1714](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1714)
|
||||
|
||||
***
|
||||
|
||||
@@ -94,7 +94,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1714](https://github.com/
|
||||
|
||||
> **\_6y**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1715](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1715)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1715](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1715)
|
||||
|
||||
***
|
||||
|
||||
@@ -102,4 +102,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1715](https://github.com/
|
||||
|
||||
> **\_8y**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1716](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1716)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1716](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1716)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_10y1m1w1y2y3m3y4y5y6m6y8yPattern3
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1743](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1743)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1743](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1743)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1743](https://github.com/
|
||||
|
||||
> **\_10y**: [`BtcCentsSatsUsdPattern3`](BtcCentsSatsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1744](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1744)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1744](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1744)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1744](https://github.com/
|
||||
|
||||
> **\_1m**: [`BtcCentsSatsUsdPattern3`](BtcCentsSatsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1745](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1745)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1745](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1745)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1745](https://github.com/
|
||||
|
||||
> **\_1w**: [`BtcCentsSatsUsdPattern3`](BtcCentsSatsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1746](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1746)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1746](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1746)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,7 +38,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1746](https://github.com/
|
||||
|
||||
> **\_1y**: [`BtcCentsSatsUsdPattern3`](BtcCentsSatsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1747](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1747)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1747](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1747)
|
||||
|
||||
***
|
||||
|
||||
@@ -46,7 +46,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1747](https://github.com/
|
||||
|
||||
> **\_2y**: [`BtcCentsSatsUsdPattern3`](BtcCentsSatsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1748](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1748)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1748](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1748)
|
||||
|
||||
***
|
||||
|
||||
@@ -54,7 +54,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1748](https://github.com/
|
||||
|
||||
> **\_3m**: [`BtcCentsSatsUsdPattern3`](BtcCentsSatsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1749](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1749)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1749](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1749)
|
||||
|
||||
***
|
||||
|
||||
@@ -62,7 +62,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1749](https://github.com/
|
||||
|
||||
> **\_3y**: [`BtcCentsSatsUsdPattern3`](BtcCentsSatsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1750](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1750)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1750](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1750)
|
||||
|
||||
***
|
||||
|
||||
@@ -70,7 +70,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1750](https://github.com/
|
||||
|
||||
> **\_4y**: [`BtcCentsSatsUsdPattern3`](BtcCentsSatsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1751](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1751)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1751](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1751)
|
||||
|
||||
***
|
||||
|
||||
@@ -78,7 +78,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1751](https://github.com/
|
||||
|
||||
> **\_5y**: [`BtcCentsSatsUsdPattern3`](BtcCentsSatsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1752](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1752)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1752](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1752)
|
||||
|
||||
***
|
||||
|
||||
@@ -86,7 +86,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1752](https://github.com/
|
||||
|
||||
> **\_6m**: [`BtcCentsSatsUsdPattern3`](BtcCentsSatsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1753](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1753)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1753](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1753)
|
||||
|
||||
***
|
||||
|
||||
@@ -94,7 +94,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1753](https://github.com/
|
||||
|
||||
> **\_6y**: [`BtcCentsSatsUsdPattern3`](BtcCentsSatsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1754](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1754)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1754](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1754)
|
||||
|
||||
***
|
||||
|
||||
@@ -102,4 +102,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1754](https://github.com/
|
||||
|
||||
> **\_8y**: [`BtcCentsSatsUsdPattern3`](BtcCentsSatsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1755](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1755)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1755](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1755)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_10y2y3y4y5y6y8yPattern
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1985](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1985)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2016](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2016)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1985](https://github.com/
|
||||
|
||||
> **\_10y**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1986](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1986)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2017](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2017)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1986](https://github.com/
|
||||
|
||||
> **\_2y**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1987](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1987)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2018](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2018)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1987](https://github.com/
|
||||
|
||||
> **\_3y**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1988](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1988)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2019](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2019)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,7 +38,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1988](https://github.com/
|
||||
|
||||
> **\_4y**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1989](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1989)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2020](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2020)
|
||||
|
||||
***
|
||||
|
||||
@@ -46,7 +46,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1989](https://github.com/
|
||||
|
||||
> **\_5y**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1990](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1990)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2021](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2021)
|
||||
|
||||
***
|
||||
|
||||
@@ -54,7 +54,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1990](https://github.com/
|
||||
|
||||
> **\_6y**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1991](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1991)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2022](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2022)
|
||||
|
||||
***
|
||||
|
||||
@@ -62,4 +62,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1991](https://github.com/
|
||||
|
||||
> **\_8y**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1992](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1992)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2023](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2023)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_1m1w1y24hBlockPattern
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2404](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2404)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2408](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2408)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2404](https://github.com/
|
||||
|
||||
> **\_1m**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2405](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2405)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2409](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2409)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2405](https://github.com/
|
||||
|
||||
> **\_1w**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2406](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2406)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2410](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2410)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2406](https://github.com/
|
||||
|
||||
> **\_1y**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2407](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2407)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2411](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2411)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,7 +38,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2407](https://github.com/
|
||||
|
||||
> **\_24h**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2408](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2408)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2412](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2412)
|
||||
|
||||
***
|
||||
|
||||
@@ -46,4 +46,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2408](https://github.com/
|
||||
|
||||
> **block**: [`SeriesPattern18`](../type-aliases/SeriesPattern18.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2409](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2409)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2413](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2413)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_1m1w1y24hBpsPercentRatioPattern
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2014](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2014)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2045](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2045)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2014](https://github.com/
|
||||
|
||||
> **\_1m**: [`BpsPercentRatioPattern3`](BpsPercentRatioPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2015](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2015)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2046](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2046)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2015](https://github.com/
|
||||
|
||||
> **\_1w**: [`BpsPercentRatioPattern3`](BpsPercentRatioPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2016](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2016)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2047](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2047)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2016](https://github.com/
|
||||
|
||||
> **\_1y**: [`BpsPercentRatioPattern3`](BpsPercentRatioPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2017](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2017)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2048](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2048)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,7 +38,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2017](https://github.com/
|
||||
|
||||
> **\_24h**: [`BpsPercentRatioPattern3`](BpsPercentRatioPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2018](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2018)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2049](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2049)
|
||||
|
||||
***
|
||||
|
||||
@@ -46,7 +46,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2018](https://github.com/
|
||||
|
||||
> **bps**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2019](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2019)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2050](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2050)
|
||||
|
||||
***
|
||||
|
||||
@@ -54,7 +54,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2019](https://github.com/
|
||||
|
||||
> **percent**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2020](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2020)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2051](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2051)
|
||||
|
||||
***
|
||||
|
||||
@@ -62,4 +62,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2020](https://github.com/
|
||||
|
||||
> **ratio**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2021](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2021)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2052](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2052)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_1m1w1y24hPattern\<T\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3207](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3207)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3211](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3211)
|
||||
|
||||
## Type Parameters
|
||||
|
||||
@@ -20,7 +20,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:3207](https://github.com/
|
||||
|
||||
> **\_1m**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`T`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3208](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3208)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3212](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3212)
|
||||
|
||||
***
|
||||
|
||||
@@ -28,7 +28,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:3208](https://github.com/
|
||||
|
||||
> **\_1w**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`T`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3209](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3209)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3213](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3213)
|
||||
|
||||
***
|
||||
|
||||
@@ -36,7 +36,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:3209](https://github.com/
|
||||
|
||||
> **\_1y**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`T`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3210](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3210)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3214](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3214)
|
||||
|
||||
***
|
||||
|
||||
@@ -44,4 +44,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:3210](https://github.com/
|
||||
|
||||
> **\_24h**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`T`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3211](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3211)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3215](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3215)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_1m1w1y24hPattern2
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2738](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2738)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2742](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2742)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2738](https://github.com/
|
||||
|
||||
> **\_1m**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2739](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2739)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2743](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2743)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2739](https://github.com/
|
||||
|
||||
> **\_1w**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2740](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2740)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2744](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2744)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2740](https://github.com/
|
||||
|
||||
> **\_1y**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2741](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2741)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2745](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2745)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,4 +38,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2741](https://github.com/
|
||||
|
||||
> **\_24h**: [`BpsPercentRatioPattern`](BpsPercentRatioPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2742](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2742)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2746](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2746)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_1m1w1y24hPattern3
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2784](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2784)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2788](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2788)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2784](https://github.com/
|
||||
|
||||
> **\_1m**: [`BtcCentsSatsUsdPattern`](BtcCentsSatsUsdPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2785](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2785)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2789](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2789)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2785](https://github.com/
|
||||
|
||||
> **\_1w**: [`BtcCentsSatsUsdPattern`](BtcCentsSatsUsdPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2786](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2786)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2790](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2790)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2786](https://github.com/
|
||||
|
||||
> **\_1y**: [`BtcCentsSatsUsdPattern`](BtcCentsSatsUsdPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2787](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2787)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2791](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2791)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,4 +38,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2787](https://github.com/
|
||||
|
||||
> **\_24h**: [`BtcCentsSatsUsdPattern`](BtcCentsSatsUsdPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2788](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2788)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2792](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2792)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_1m1w1y24hPattern4
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2807](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2807)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2811](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2811)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2807](https://github.com/
|
||||
|
||||
> **\_1m**: [`BtcCentsSatsUsdPattern3`](BtcCentsSatsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2808](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2808)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2812](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2812)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2808](https://github.com/
|
||||
|
||||
> **\_1w**: [`BtcCentsSatsUsdPattern3`](BtcCentsSatsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2809](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2809)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2813](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2813)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2809](https://github.com/
|
||||
|
||||
> **\_1y**: [`BtcCentsSatsUsdPattern3`](BtcCentsSatsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2810](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2810)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2814](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2814)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,4 +38,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2810](https://github.com/
|
||||
|
||||
> **\_24h**: [`BtcCentsSatsUsdPattern3`](BtcCentsSatsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2811](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2811)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2815](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2815)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_1m1w1y24hPattern5
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2853](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2853)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2857](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2857)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2853](https://github.com/
|
||||
|
||||
> **\_1m**: [`CentsUsdPattern`](CentsUsdPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2854](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2854)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2858](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2858)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2854](https://github.com/
|
||||
|
||||
> **\_1w**: [`CentsUsdPattern`](CentsUsdPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2855](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2855)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2859](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2859)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2855](https://github.com/
|
||||
|
||||
> **\_1y**: [`CentsUsdPattern`](CentsUsdPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2856](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2856)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2860](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2860)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,4 +38,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2856](https://github.com/
|
||||
|
||||
> **\_24h**: [`CentsUsdPattern`](CentsUsdPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2857](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2857)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2861](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2861)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_1m1w1y24hPattern6
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2876](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2876)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2880](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2880)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2876](https://github.com/
|
||||
|
||||
> **\_1m**: [`CentsUsdPattern3`](CentsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2877](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2877)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2881](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2881)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2877](https://github.com/
|
||||
|
||||
> **\_1w**: [`CentsUsdPattern3`](CentsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2878](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2878)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2882](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2882)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2878](https://github.com/
|
||||
|
||||
> **\_1y**: [`CentsUsdPattern3`](CentsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2879](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2879)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2883](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2883)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,4 +38,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2879](https://github.com/
|
||||
|
||||
> **\_24h**: [`CentsUsdPattern3`](CentsUsdPattern3.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2880](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2880)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2884](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2884)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_1m1w1y24hPattern7
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2761](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2761)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2765](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2765)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2761](https://github.com/
|
||||
|
||||
> **\_1m**: [`BpsPercentRatioPattern4`](BpsPercentRatioPattern4.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2762](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2762)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2766](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2766)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2762](https://github.com/
|
||||
|
||||
> **\_1w**: [`BpsPercentRatioPattern4`](BpsPercentRatioPattern4.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2763](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2763)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2767](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2767)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2763](https://github.com/
|
||||
|
||||
> **\_1y**: [`BpsPercentRatioPattern4`](BpsPercentRatioPattern4.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2764](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2764)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2768](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2768)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,4 +38,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2764](https://github.com/
|
||||
|
||||
> **\_24h**: [`BpsPercentRatioPattern4`](BpsPercentRatioPattern4.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2765](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2765)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2769](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2769)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_1m1w1y2wPattern
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2830](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2830)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2834](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2834)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2830](https://github.com/
|
||||
|
||||
> **\_1m**: [`CentsSatsUsdPattern`](CentsSatsUsdPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2831](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2831)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2835](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2835)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2831](https://github.com/
|
||||
|
||||
> **\_1w**: [`CentsSatsUsdPattern`](CentsSatsUsdPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2832](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2832)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2836](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2836)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2832](https://github.com/
|
||||
|
||||
> **\_1y**: [`CentsSatsUsdPattern`](CentsSatsUsdPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2833](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2833)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2837](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2837)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,4 +38,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2833](https://github.com/
|
||||
|
||||
> **\_2w**: [`CentsSatsUsdPattern`](CentsSatsUsdPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2834](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2834)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2838](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2838)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_1m1w1y2y4yAllPattern
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2161](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2161)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2192](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2192)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2161](https://github.com/
|
||||
|
||||
> **\_1m**: [`BpsRatioPattern2`](BpsRatioPattern2.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2162](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2162)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2193](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2193)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2162](https://github.com/
|
||||
|
||||
> **\_1w**: [`BpsRatioPattern2`](BpsRatioPattern2.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2163](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2163)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2194](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2194)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2163](https://github.com/
|
||||
|
||||
> **\_1y**: [`BpsRatioPattern2`](BpsRatioPattern2.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2164](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2164)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2195](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2195)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,7 +38,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2164](https://github.com/
|
||||
|
||||
> **\_2y**: [`BpsRatioPattern2`](BpsRatioPattern2.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2165](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2165)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2196](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2196)
|
||||
|
||||
***
|
||||
|
||||
@@ -46,7 +46,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2165](https://github.com/
|
||||
|
||||
> **\_4y**: [`BpsRatioPattern2`](BpsRatioPattern2.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2166](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2166)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2197](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2197)
|
||||
|
||||
***
|
||||
|
||||
@@ -54,4 +54,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2166](https://github.com/
|
||||
|
||||
> **all**: [`BpsRatioPattern2`](BpsRatioPattern2.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2167](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2167)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2198](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2198)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_1y2y4yAllPattern
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2899](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2899)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2903](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2903)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2899](https://github.com/
|
||||
|
||||
> **\_1y**: [`_0sdM0M1M1sdM2M2sdM3sdP0P1P1sdP2P2sdP3sdSdZscorePattern`](0sdM0M1M1sdM2M2sdM3sdP0P1P1sdP2P2sdP3sdSdZscorePattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2900](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2900)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2904](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2904)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2900](https://github.com/
|
||||
|
||||
> **\_2y**: [`_0sdM0M1M1sdM2M2sdM3sdP0P1P1sdP2P2sdP3sdSdZscorePattern`](0sdM0M1M1sdM2M2sdM3sdP0P1P1sdP2P2sdP3sdSdZscorePattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2901](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2901)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2905](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2905)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2901](https://github.com/
|
||||
|
||||
> **\_4y**: [`_0sdM0M1M1sdM2M2sdM3sdP0P1P1sdP2P2sdP3sdSdZscorePattern`](0sdM0M1M1sdM2M2sdM3sdP0P1P1sdP2P2sdP3sdSdZscorePattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2902](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2902)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2906](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2906)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,4 +38,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2902](https://github.com/
|
||||
|
||||
> **all**: [`_0sdM0M1M1sdM2M2sdM3sdP0P1P1sdP2P2sdP3sdSdZscorePattern`](0sdM0M1M1sdM2M2sdM3sdP0P1P1sdP2P2sdP3sdSdZscorePattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2903](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2903)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2907](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2907)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_24hPattern
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:4066](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L4066)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:4070](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L4070)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,4 +14,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:4066](https://github.com/
|
||||
|
||||
> **\_24h**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:4067](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L4067)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:4071](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L4071)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: \_6bBlockTxPattern\<T\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3637](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3637)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3641](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3641)
|
||||
|
||||
## Type Parameters
|
||||
|
||||
@@ -20,7 +20,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:3637](https://github.com/
|
||||
|
||||
> **\_6b**: [`MaxMedianMinPct10Pct25Pct75Pct90Pattern`](MaxMedianMinPct10Pct25Pct75Pct90Pattern.md)\<`T`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3638](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3638)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3642](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3642)
|
||||
|
||||
***
|
||||
|
||||
@@ -28,7 +28,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:3638](https://github.com/
|
||||
|
||||
> **block**: [`MaxMedianMinPct10Pct25Pct75Pct90Pattern`](MaxMedianMinPct10Pct25Pct75Pct90Pattern.md)\<`T`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3639](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3639)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3643](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3643)
|
||||
|
||||
***
|
||||
|
||||
@@ -36,4 +36,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:3639](https://github.com/
|
||||
|
||||
> **txIndex**: [`SeriesPattern19`](../type-aliases/SeriesPattern19.md)\<`T`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3640](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3640)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3644](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3644)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: AbsoluteRatePattern
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3659](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3659)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3663](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3663)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:3659](https://github.com/
|
||||
|
||||
> **absolute**: [`_1m1w1y24hPattern`](1m1w1y24hPattern.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3660](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3660)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3664](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3664)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,4 +22,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:3660](https://github.com/
|
||||
|
||||
> **rate**: [`_1m1w1y24hPattern2`](1m1w1y24hPattern2.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3661](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3661)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3665](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3665)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: AbsoluteRatePattern2
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3678](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3678)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3682](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3682)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:3678](https://github.com/
|
||||
|
||||
> **absolute**: [`_1m1w1y24hPattern5`](1m1w1y24hPattern5.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3679](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3679)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3683](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3683)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,4 +22,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:3679](https://github.com/
|
||||
|
||||
> **rate**: [`_1m1w1y24hPattern2`](1m1w1y24hPattern2.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3680](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3680)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3684](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3684)
|
||||
|
||||
+7
-7
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: ActivityAddrOutputsRealizedSupplyUnrealizedPattern
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2188](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2188)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2219](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2219)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2188](https://github.com/
|
||||
|
||||
> **activity**: [`TransferPattern`](TransferPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2189](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2189)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2220](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2220)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2189](https://github.com/
|
||||
|
||||
> **addrCount**: [`BaseDeltaPattern`](BaseDeltaPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2190](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2190)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2221](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2221)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2190](https://github.com/
|
||||
|
||||
> **outputs**: [`SpendingSpentUnspentPattern`](SpendingSpentUnspentPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2191](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2191)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2222](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2222)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,7 +38,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2191](https://github.com/
|
||||
|
||||
> **realized**: [`CapLossMvrvPriceProfitPattern`](CapLossMvrvPriceProfitPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2192](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2192)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2223](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2223)
|
||||
|
||||
***
|
||||
|
||||
@@ -46,7 +46,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2192](https://github.com/
|
||||
|
||||
> **supply**: [`DeltaTotalPattern`](DeltaTotalPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2193](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2193)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2224](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2224)
|
||||
|
||||
***
|
||||
|
||||
@@ -54,4 +54,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2193](https://github.com/
|
||||
|
||||
> **unrealized**: [`NuplPattern`](NuplPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2194](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2194)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2225](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2225)
|
||||
|
||||
+6
-6
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: ActivityOutputsRealizedSupplyUnrealizedPattern
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2429](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2429)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2433](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2433)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2429](https://github.com/
|
||||
|
||||
> **activity**: [`CoindaysTransferPattern`](CoindaysTransferPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2430](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2430)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2434](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2434)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2430](https://github.com/
|
||||
|
||||
> **outputs**: [`SpendingSpentUnspentPattern`](SpendingSpentUnspentPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2431](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2431)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2435](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2435)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2431](https://github.com/
|
||||
|
||||
> **realized**: [`CapLossMvrvNetPriceProfitSoprPattern`](CapLossMvrvNetPriceProfitSoprPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2432](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2432)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2436](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2436)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,7 +38,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2432](https://github.com/
|
||||
|
||||
> **supply**: [`DeltaHalfInToTotalPattern`](DeltaHalfInToTotalPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2433](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2433)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2437](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2437)
|
||||
|
||||
***
|
||||
|
||||
@@ -46,4 +46,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2433](https://github.com/
|
||||
|
||||
> **unrealized**: [`LossNetNuplProfitPattern`](LossNetNuplProfitPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2434](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2434)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2438](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2438)
|
||||
|
||||
+6
-6
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: ActivityOutputsRealizedSupplyUnrealizedPattern2
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2479](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2479)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2483](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2483)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2479](https://github.com/
|
||||
|
||||
> **activity**: [`TransferPattern`](TransferPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2480](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2480)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2484](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2484)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2480](https://github.com/
|
||||
|
||||
> **outputs**: [`SpendingSpentUnspentPattern`](SpendingSpentUnspentPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2481](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2481)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2485](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2485)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2481](https://github.com/
|
||||
|
||||
> **realized**: [`CapLossMvrvPriceProfitPattern`](CapLossMvrvPriceProfitPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2482](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2482)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2486](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2486)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,7 +38,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2482](https://github.com/
|
||||
|
||||
> **supply**: [`DeltaTotalPattern`](DeltaTotalPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2483](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2483)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2487](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2487)
|
||||
|
||||
***
|
||||
|
||||
@@ -46,4 +46,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2483](https://github.com/
|
||||
|
||||
> **unrealized**: [`NuplPattern`](NuplPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2484](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2484)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2488](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2488)
|
||||
|
||||
+6
-6
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: ActivityOutputsRealizedSupplyUnrealizedPattern3
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2454](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2454)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2458](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2458)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2454](https://github.com/
|
||||
|
||||
> **activity**: [`TransferPattern`](TransferPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2455](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2455)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2459](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2459)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2455](https://github.com/
|
||||
|
||||
> **outputs**: [`SpendingSpentUnspentPattern`](SpendingSpentUnspentPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2456](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2456)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2460](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2460)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2456](https://github.com/
|
||||
|
||||
> **realized**: [`CapLossMvrvPriceProfitPattern`](CapLossMvrvPriceProfitPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2457](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2457)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2461](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2461)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,7 +38,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2457](https://github.com/
|
||||
|
||||
> **supply**: [`DeltaHalfInTotalPattern2`](DeltaHalfInTotalPattern2.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2458](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2458)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2462](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2462)
|
||||
|
||||
***
|
||||
|
||||
@@ -46,4 +46,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:2458](https://github.com/
|
||||
|
||||
> **unrealized**: [`LossNuplProfitPattern`](LossNuplProfitPattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2459](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L2459)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:2463](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L2463)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: AddrChainStats
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:16](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L16)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:16](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L16)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:16](https://github.com/bi
|
||||
|
||||
> **fundedTxoCount**: `number`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:17](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L17)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:17](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L17)
|
||||
|
||||
Total number of transaction outputs that funded this address
|
||||
|
||||
@@ -24,7 +24,7 @@ Total number of transaction outputs that funded this address
|
||||
|
||||
> **fundedTxoSum**: `number`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:18](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L18)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:18](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L18)
|
||||
|
||||
Total amount in satoshis received by this address across all funded outputs
|
||||
|
||||
@@ -34,7 +34,7 @@ Total amount in satoshis received by this address across all funded outputs
|
||||
|
||||
> **spentTxoCount**: `number`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:19](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L19)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:19](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L19)
|
||||
|
||||
Total number of transaction outputs spent from this address
|
||||
|
||||
@@ -44,7 +44,7 @@ Total number of transaction outputs spent from this address
|
||||
|
||||
> **spentTxoSum**: `number`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:20](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L20)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:20](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L20)
|
||||
|
||||
Total amount in satoshis spent from this address
|
||||
|
||||
@@ -54,7 +54,7 @@ Total amount in satoshis spent from this address
|
||||
|
||||
> **txCount**: `number`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:21](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L21)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:21](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L21)
|
||||
|
||||
Total number of confirmed transactions involving this address
|
||||
|
||||
@@ -64,6 +64,6 @@ Total number of confirmed transactions involving this address
|
||||
|
||||
> **typeIndex**: `number`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:22](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L22)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:22](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L22)
|
||||
|
||||
Index of this address within its type on the blockchain
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: AddrMempoolStats
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:29](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L29)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:29](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L29)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:29](https://github.com/bi
|
||||
|
||||
> **fundedTxoCount**: `number`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:30](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L30)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:30](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L30)
|
||||
|
||||
Number of unconfirmed transaction outputs funding this address
|
||||
|
||||
@@ -24,7 +24,7 @@ Number of unconfirmed transaction outputs funding this address
|
||||
|
||||
> **fundedTxoSum**: `number`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:31](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L31)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:31](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L31)
|
||||
|
||||
Total amount in satoshis being received in unconfirmed transactions
|
||||
|
||||
@@ -34,7 +34,7 @@ Total amount in satoshis being received in unconfirmed transactions
|
||||
|
||||
> **spentTxoCount**: `number`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:32](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L32)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:32](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L32)
|
||||
|
||||
Number of unconfirmed transaction inputs spending from this address
|
||||
|
||||
@@ -44,7 +44,7 @@ Number of unconfirmed transaction inputs spending from this address
|
||||
|
||||
> **spentTxoSum**: `number`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:33](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L33)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:33](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L33)
|
||||
|
||||
Total amount in satoshis being spent in unconfirmed transactions
|
||||
|
||||
@@ -54,6 +54,6 @@ Total amount in satoshis being spent in unconfirmed transactions
|
||||
|
||||
> **txCount**: `number`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:34](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L34)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:34](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L34)
|
||||
|
||||
Number of unconfirmed transactions involving this address
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: AddrParam
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:37](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L37)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:37](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L37)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,4 +14,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:37](https://github.com/bi
|
||||
|
||||
> **address**: `string`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:38](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L38)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:38](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L38)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: AddrStats
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:43](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L43)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:43](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L43)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:43](https://github.com/bi
|
||||
|
||||
> **address**: `string`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:44](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L44)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:44](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L44)
|
||||
|
||||
Bitcoin address string
|
||||
|
||||
@@ -24,7 +24,7 @@ Bitcoin address string
|
||||
|
||||
> **chainStats**: [`AddrChainStats`](AddrChainStats.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:45](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L45)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:45](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L45)
|
||||
|
||||
Statistics for confirmed transactions on the blockchain
|
||||
|
||||
@@ -34,6 +34,6 @@ Statistics for confirmed transactions on the blockchain
|
||||
|
||||
> `optional` **mempoolStats?**: [`AddrMempoolStats`](AddrMempoolStats.md) \| `null`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:46](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L46)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:46](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L46)
|
||||
|
||||
Statistics for unconfirmed transactions in the mempool
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: AddrTxidsParam
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:49](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L49)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:49](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L49)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,6 +14,6 @@ Defined in: [Developer/brk/modules/brk-client/index.js:49](https://github.com/bi
|
||||
|
||||
> `optional` **afterTxid?**: `string` \| `null`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:50](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L50)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:50](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L50)
|
||||
|
||||
Txid to paginate from (return transactions before this one)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: AddrValidation
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:55](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L55)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:55](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L55)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:55](https://github.com/bi
|
||||
|
||||
> `optional` **address?**: `string` \| `null`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:57](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L57)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:57](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L57)
|
||||
|
||||
The validated address
|
||||
|
||||
@@ -24,7 +24,7 @@ The validated address
|
||||
|
||||
> `optional` **isscript?**: `boolean` \| `null`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:59](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L59)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:59](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L59)
|
||||
|
||||
Whether this is a script address (P2SH)
|
||||
|
||||
@@ -34,7 +34,7 @@ Whether this is a script address (P2SH)
|
||||
|
||||
> **isvalid**: `boolean`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:56](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L56)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:56](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L56)
|
||||
|
||||
Whether the address is valid
|
||||
|
||||
@@ -44,7 +44,7 @@ Whether the address is valid
|
||||
|
||||
> `optional` **iswitness?**: `boolean` \| `null`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:60](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L60)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:60](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L60)
|
||||
|
||||
Whether this is a witness address
|
||||
|
||||
@@ -54,7 +54,7 @@ Whether this is a witness address
|
||||
|
||||
> `optional` **scriptPubKey?**: `string` \| `null`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:58](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L58)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:58](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L58)
|
||||
|
||||
The scriptPubKey in hex
|
||||
|
||||
@@ -64,7 +64,7 @@ The scriptPubKey in hex
|
||||
|
||||
> `optional` **witnessProgram?**: `string` \| `null`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:62](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L62)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:62](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L62)
|
||||
|
||||
Witness program in hex
|
||||
|
||||
@@ -74,6 +74,6 @@ Witness program in hex
|
||||
|
||||
> `optional` **witnessVersion?**: `number` \| `null`
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:61](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L61)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:61](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L61)
|
||||
|
||||
Witness version (0 for P2WPKH/P2WSH, 1 for P2TR)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: AdjustedRatioValuePattern
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3256](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3256)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3260](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3260)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:3256](https://github.com/
|
||||
|
||||
> **adjusted**: [`RatioTransferValuePattern`](RatioTransferValuePattern.md)
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3257](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3257)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3261](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3261)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:3257](https://github.com/
|
||||
|
||||
> **ratio**: [`_1m1w1y24hPattern`](1m1w1y24hPattern.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3258](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3258)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3262](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3262)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,4 +30,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:3258](https://github.com/
|
||||
|
||||
> **valueDestroyed**: [`AverageBlockCumulativeSumPattern`](AverageBlockCumulativeSumPattern.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3259](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3259)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3263](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3263)
|
||||
|
||||
+10
-10
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: AllP2aP2pk33P2pk65P2pkhP2shP2trP2wpkhP2wshPattern3
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1874](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1874)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1874](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1874)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1874](https://github.com/
|
||||
|
||||
> **all**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1875](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1875)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1875](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1875)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,7 +22,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1875](https://github.com/
|
||||
|
||||
> **p2a**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1876](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1876)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1876](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1876)
|
||||
|
||||
***
|
||||
|
||||
@@ -30,7 +30,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1876](https://github.com/
|
||||
|
||||
> **p2pk33**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1877](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1877)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1877](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1877)
|
||||
|
||||
***
|
||||
|
||||
@@ -38,7 +38,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1877](https://github.com/
|
||||
|
||||
> **p2pk65**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1878](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1878)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1878](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1878)
|
||||
|
||||
***
|
||||
|
||||
@@ -46,7 +46,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1878](https://github.com/
|
||||
|
||||
> **p2pkh**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1879](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1879)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1879](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1879)
|
||||
|
||||
***
|
||||
|
||||
@@ -54,7 +54,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1879](https://github.com/
|
||||
|
||||
> **p2sh**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1880](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1880)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1880](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1880)
|
||||
|
||||
***
|
||||
|
||||
@@ -62,7 +62,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1880](https://github.com/
|
||||
|
||||
> **p2tr**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1881](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1881)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1881](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1881)
|
||||
|
||||
***
|
||||
|
||||
@@ -70,7 +70,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1881](https://github.com/
|
||||
|
||||
> **p2wpkh**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1882](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1882)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1882](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1882)
|
||||
|
||||
***
|
||||
|
||||
@@ -78,4 +78,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:1882](https://github.com/
|
||||
|
||||
> **p2wsh**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1883](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L1883)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:1883](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L1883)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
# Interface: AllSthPattern
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3716](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3716)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3720](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3720)
|
||||
|
||||
## Properties
|
||||
|
||||
@@ -14,7 +14,7 @@ Defined in: [Developer/brk/modules/brk-client/index.js:3716](https://github.com/
|
||||
|
||||
> **all**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3717](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3717)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3721](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3721)
|
||||
|
||||
***
|
||||
|
||||
@@ -22,4 +22,4 @@ Defined in: [Developer/brk/modules/brk-client/index.js:3717](https://github.com/
|
||||
|
||||
> **sth**: [`SeriesPattern1`](../type-aliases/SeriesPattern1.md)\<`number`\>
|
||||
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3718](https://github.com/bitcoinresearchkit/brk/blob/ec6420254a230ae65df0ed8b66cad1cffcf46447/modules/brk-client/index.js#L3718)
|
||||
Defined in: [Developer/brk/modules/brk-client/index.js:3722](https://github.com/bitcoinresearchkit/brk/blob/041652d85d1f6ed0371402865bf343ad227ee250/modules/brk-client/index.js#L3722)
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user