Skip to content

Commit 17a44ef

Browse files
committed
logbook: add agda docs update
1 parent 8a42d3f commit 17a44ef

File tree

1 file changed

+31
-25
lines changed

1 file changed

+31
-25
lines changed

Logbook.md

Lines changed: 31 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# Leios logbook
22

3+
## 2025-05-17
4+
5+
### Web-based enhanced formal specification documentation
6+
7+
Added a comprehensive web-based documentation for the Ouroboros Leios formal specification, available at [https://leios.cardano-scaling.org/formal-spec/](https://leios.cardano-scaling.org/formal-spec/). This enhanced documentation offers a simple way to explore the different Leios modules as types are linked together, and includes full text search capabilities.
8+
39
## 2025-05-16
410

511
### Trace verifier improvements
@@ -800,15 +806,15 @@ The resulting completion outcome is plotted to the terminal together with the ex
800806

801807
Learnings from this exercise:
802808

803-
- latencies within the topologies examined (from the topology generator as well as the realistic set from the Rust simulation) very clearly consist of differing near/far components (theres a knee in the graphs)
804-
- latency-weighted Dijkstra shortest paths are _extremely long_ in terms of hop count, much longer than I expected (mean 4–5, max 8 for the topology-100; min 8, max 20 for the realistic topology)
809+
- latencies within the topologies examined (from the topology generator as well as the "realistic" set from the Rust simulation) very clearly consist of differing near/far components (there's a "knee" in the graphs)
810+
- latency-weighted Dijkstra shortest paths are _extremely long_ in terms of hop count, much longer than I expected (mean 4–5, max 8 for the topology-100; min 8, max 20 for the "realistic" topology)
805811
- composing a ΔQ model as a sequence of some number of near hops (with early exit probabilities) and some number of far hops (also with early exit) yields models that roughly fit the overall shape, which is dominated by the `far` component of latencies, but there always is a significant deviation at low latencies
806-
- the deviation is that observed completion starts out much slower than the model would predict, so the model goes faster first, then pauses for 100ms or so, crossing the observed CDF again, then catching up — thereafter the high latency behaviour works out quite well
812+
- the deviation is that observed completion starts out much slower than the model would predict, so the model goes faster first, then "pauses" for 100ms or so, crossing the observed CDF again, then catching up — thereafter the high latency behaviour works out quite well
807813

808814
My hope had been to use a model that can be understood behaviourally, not just statistically, so that the resource usage tracking features of the `delta_q` library could be brought to bear.
809815
**This has not yet been achieved.**
810816
While the timeliness graph can be made to match to some degree, doing this results in a ΔQ expression for which at least I no longer understand the load multiplication factors that should be applied — in other words, how many peer connections are supposedly used at each step of the process.
811-
The remaining part of this weeks plan was to be able to use the fitted model to obtain a formula for creating such models algebraically;
817+
The remaining part of this week's plan was to be able to use the fitted model to obtain a formula for creating such models algebraically;
812818
this has been put on hold because it seems easier to just generate a topology with the desired properties and then use the `topology-checker` to get the corresponding ΔQSD model.
813819

814820
In any case, the `topology-checker` now outputs the fitted ΔQSD model in the syntax needed for the `delta_q` web app, so that you can directly play with the results.
@@ -1055,7 +1061,7 @@ stake to determine how connected each relay is.
10551061

10561062
### DeltaQ update
10571063

1058-
Wrote a report on the work since Sep24:
1064+
Wrote a report on the work since Sep'24:
10591065
[Report 2025-01.md](./delta_q/docs/Report%202025-01.md)
10601066

10611067
## 2025-01-30
@@ -1800,15 +1806,15 @@ correct even when there are too many messages to simulate in real time.
18001806
- general structure of completion matches the timings, but the completion rate
18011807
is overall quite different
18021808
- spreading to neighbor clusters (3×68ms) followed by another such hop should
1803-
hit all clusters, but that also doesnt happen in the simulation, it waits
1809+
hit all clusters, but that also doesn't happen in the simulation, it waits
18041810
until 3×268ms before it can break through 74% completion
1805-
- **conclusion:** I dont really understand what the simulation is doing, even
1811+
- **conclusion:** I don't really understand what the simulation is doing, even
18061812
though the Rust code looks obvious enough, and obviously correct on the node
18071813
level; will dive into the machine room later
18081814
- created a ΔQ model (`comparison_hs.txt`) of Praos block diffusion in the
18091815
Haskell simulation:
18101816
- hs simulates TCP window collapse, which adds a very latency-dependent
1811-
additional delay to block transfer times — I wasnt able to adequately model
1817+
additional delay to block transfer times — I wasn't able to adequately model
18121818
that, plausible ΔQ expressions lead to too slow completion
18131819
- when TCP window collapse is hacked out (thanks Andrea!) I get close matching
18141820
of the result with a ΔQ expression, however, that expression does not match
@@ -2008,13 +2014,13 @@ Unforutnately, this is a bug.
20082014
- gossip is a large part of the Leios problem space, which makes resource
20092015
tracking like CPU/mem/disk hard: there are >2500 CPU metrics to consider in
20102016
principle!
2011-
- currently trying the approach of making which node am I? the main random
2017+
- currently trying the approach of making "which node am I?" the main random
20122018
variable during gossip, allowing probabilistic handling of per-node resource
20132019
usage
20142020
- results are getting more reasonable, but still not fully correct (test case is
20152021
diffusion of 1MB blob with 100ms CPU validation time: should never use CPU
20162022
with intensity two, and should yield integral of 1 CPU for 100ms when adding
2017-
up probability densities; instead, Im seeing CPU intensity 2 during some time
2023+
up probability densities; instead, I'm seeing CPU intensity 2 during some time
20182024
periods)
20192025

20202026
## 2024-11-27
@@ -2044,8 +2050,8 @@ settling on the details of Leios voting and certificates.
20442050
### Curve fit to empirically observed distribution of stake pools
20452051

20462052
The cumulative distribution function for the beta distribution
2047-
(the [regularized incomplete beta function](https://en.wikipedia.org/wiki/Regularized_incomplete_beta_function))
2048-
with parameters `α = 11` and `β = 1` nicely fits the empirical distribution of
2053+
(the [regularized incomplete beta function](https://en.wikipedia.org/wiki/Regularized_incomplete_beta_function))
2054+
with parameters `α = 11` and `β = 1` nicely fits the empirical distribution of
20492055
stake pools at epoch 500. To use this for 2000 stake pools, just divide the x
20502056
axis into 2000 points and take the difference in consecutive y values as the
20512057
amount of stake the corresponding pool has.
@@ -2610,9 +2616,9 @@ latency of requests
26102616
- this reproduces the values taken from the Tech Report when using roughly
26112617
size=2500, branching=15, cluster_coeff=0.08 (but this understanding should
26122618
definitely be deepened)
2613-
- when playing with gossip parameters, one quickly enters stack overflow
2619+
- when playing with gossip parameters, one quickly enters "stack overflow"
26142620
territory because `DeltaQ::eval()` is just a recursive function; therefore,
2615-
Ill move iteration state to the heap (it turns out that WASM stack is
2621+
I'll move iteration state to the heap (it turns out that WASM stack is
26162622
smaller than I thought, so it already affects quite reasonable ΔQ
26172623
expressions)
26182624

@@ -2778,7 +2784,7 @@ Agenda:
27782784

27792785
### Rust simulation
27802786

2781-
Rewrote the simulation to use separate tokio tasks for each node, multithreading
2787+
Rewritten the simulation to use separate tokio tasks for each node, multithreading
27822788
as much as possible. It can simulate 85tps in almost realtime, but the slowdown
27832789
makes its results inaccurate (a smaller percentage of IBs propagated across the
27842790
network compared to the non-netsim branch).
@@ -3522,7 +3528,7 @@ product/usage
35223528
Report on ΔQ work in Rust so far (Roland):
35233529

35243530
- implemented MVP in the sense of being able to create ΔQ expressions as per the
3525-
Mind your outcomes paper and evaluate them
3531+
"Mind your outcomes" paper and evaluate them
35263532
- added a recursion operator that is purely syntactical: recursive unfolding of
35273533
a named expression with a given depth limit
35283534
- project uses yew/trunk to render the HTML/CSS frontend, which uses WASM (tools
@@ -3544,7 +3550,7 @@ Implementation notes:
35443550
one of the same distance; this yields more even pruning along the x axis
35453551
- the EvaluationContext holds all named expressions and allows resolving names,
35463552
but also tracks the current recursion allowance for each name (recursion with
3547-
allowance isnt allowed while already recursing on that name; allowing this
3553+
allowance isn't allowed while already recursing on that name; allowing this
35483554
results in infinite loop)
35493555

35503556
Comments raised while presenting this to the team today:
@@ -3558,21 +3564,21 @@ Comments raised while presenting this to the team today:
35583564
which operation that would be)
35593565
- recursion as template unfolding was understood as some fix point
35603566
representation by Duncan, but currently that is not how it is implemented
3561-
- treating the propagation of messages across a network graph isnt faithfully
3567+
- treating the propagation of messages across a network graph isn't faithfully
35623568
modelled, but it could be if recursion was actually some kind of fix point
35633569
operation
3564-
- it would be great to have an operator that expresses only broadcast the
3565-
first copy of the message I receive, which would allow pruning the infinite
3570+
- it would be great to have an operator that expresses "only broadcast the
3571+
first copy of the message I receive", which would allow pruning the infinite
35663572
evaluation tree
3567-
- this is unclear to me because ΔQ speaks in CDFs which arent concrete in
3568-
this way, so pruning wouldnt apply to CDFs but to some execution of the
3573+
- this is unclear to me because ΔQ speaks in CDFs which aren't concrete in
3574+
this way, so pruning wouldn't apply to CDFs but to some execution of the
35693575
modelled process
35703576
- Pi asked how this work relates to the Rust-based network graph simulator,
35713577
which has at least two answers:
35723578
- compute CDFs that are used by the simulator using ΔQ
35733579
- use simulation results (CDFs) as inputs for further ΔQ modelling, e.g. on a
35743580
higher level
3575-
- on the website well need something that can quickly answer high-level
3581+
- on the website we'll need something that can quickly answer high-level
35763582
questions, running a simulation would probably not be feasible but ΔQ should
35773583
be
35783584
- it occurred to me that if we can get a load profile from a ΔQ model, we can
@@ -3766,7 +3772,7 @@ on Agda-based conformance testing:
37663772
[#18](https://github.com/input-output-hk/ouroboros-leios/issues/18)
37673773
- Nominal objectives, tasks, and deliverables for next 12 months
37683774
- Work agreement
3769-
- Write down everything in a research journal
3775+
- Write down "everything" in a "research journal"
37703776
- what we do
37713777
- why we do it
37723778
- what are the expected results vs. actual results.
@@ -3778,7 +3784,7 @@ on Agda-based conformance testing:
37783784
- Processes and workflows can emerge from our needs, and do not have to match
37793785
typical production enviroments
37803786
- However, QA and checking each others' work is important
3781-
- Ensure all results are easily reproducible by the community
3787+
- Ensure all results are "easily" reproducible by the community
37823788
- Arnaud will pair with engineering staff each week in October
37833789
- Technical report each quarter -- the next will be in December
37843790
- CIP at conclusion of innovation workstream

0 commit comments

Comments
 (0)