What does Lazy Tool Hubs conclude, in numbers, about “Classical Sources East and West: Offices and Duties in the Rites of Zhou and Dewey's Decimal Scheme”?

Answer: Chapter 7 examines "establishing offices and dividing duties" and "great matters go through the head, small matters are dealt with directly" in the Rites of Zhou, and Dewey's decimal scheme and subject index of 1876.

Scope of the numbers: Selection accuracy lacks reliable peer-reviewed primary evidence and is demoted to an author's hypothesis. Marked boxes separate published evidence, runnable Python calculations (17 programs), classical sources and the author's hypotheses.

中文版

Data table

The numbers below are printed verbatim by the chapter's Python program and can be reproduced by running it. standard-library Python only

designtokens/lookupdecisions
flat menu of 360 posts9080.01
best two-level 19 x 191108.72
six offices of sixty1810.02
six of sixty, 6 go direct1361.21 or 2
six of sixty, 12 go direct1351.61 or 2
six of sixty, 24 go direct1487.11 or 2
6-ary Huffman (no meaning)597.7varies
3-level 6 x 6 x 10790.03
Show the full program
# Chapter 7. p71: six offices of sixty as a routing tree.
# The Rites of Zhou (Lesser Steward) lists six offices, each with sixty
# subordinate posts: 360 leaves under 6 heads. Treat each post as a
# tool with Zipf(1) shares placed at random (seeded; the shares are
# illustrative, not historical). A decision reads its menu (S = 25
# tokens a line) plus a hop (HOP = 80). "Small matters go direct" is
# modelled as m hot posts listed beside the six heads at the root.
import heapq
import math
import random

rng = random.Random(20261113)
N, S, HOP = 360, 25, 80


def zipf(n, a):
    w = [1.0 / (i ** a) for i in range(1, n + 1)]
    t = math.fsum(w)
    return [x / t for x in w]


def huff_cost(p, k):
    items = [(x, i, (i,)) for i, x in enumerate(p)]
    seq, pad = len(p), 0
    while (len(items) + pad - 1) % (k - 1):
        pad += 1
    for _ in range(pad):
        items.append((0.0, seq, ()))
        seq += 1
    heapq.heapify(items)
    terms = []
    while len(items) > 1:
        kids = [heapq.heappop(items) for _ in range(min(k, len(items)))]
        real = len([c for c in kids if c[2] or c[0] > 0])
        w = math.fsum(c[0] for c in kids)
        terms.append(w * (HOP + real * S))
        leaves = ()
        for c in kids:
            leaves += c[2]
        heapq.heappush(items, (w, seq, leaves))
        seq += 1
    return math.fsum(terms)


p = zipf(N, 1.0)
rng.shuffle(p)
rank = sorted(range(N), key=lambda i: -p[i])


def six_sixty(m):
    hot = set(rank[:m])
    terms = []
    for i in range(N):
        root = HOP + (6 + m) * S
        terms.append(p[i] * (root if i in hot else root + HOP + 60 * S))
    return math.fsum(terms)


print("design                         tokens/lookup  decisions")
print("%-30s %13.1f %10d" % ("flat menu of 360 posts", HOP + N * S, 1))
k1 = min(range(2, N), key=lambda k: k + N / k)
print("%-30s %13.1f %10d" % ("best two-level %d x %d"
      % (k1, math.ceil(N / k1)), 2 * HOP + (k1 + N / k1) * S, 2))
print("%-30s %13.1f %10d" % ("six offices of sixty", six_sixty(0), 2))
for m in (6, 12, 24):
    print("%-30s %13.1f %10s" % ("six of sixty, %d go direct" % m,
                                 six_sixty(m), "1 or 2"))
print("%-30s %13.1f %10s" % ("6-ary Huffman (no meaning)",
                             huff_cost(p, 6), "varies"))
print("%-30s %13.1f %10s" % ("3-level 6 x 6 x 10",
                             3 * HOP + (6 + 6 + 10) * S, 3))

Single source and citation

Fan, Y. (2026). A Lazy-Loading Private Tool Hub: Near-Zero Opening Context for Hundreds of Checkers and On-Demand Routing Trees (Version 1.0.0), Chapter 7: Classical Sources East and West: Offices and Duties in the Rites of Zhou and Dewey's Decimal Scheme. 5D Library. DOI pending

DOI pending · monograph page goes live after publication · 5DL-B-257 · v1.0.0 · CC-BY-NC-ND-4.0

BibTeX
@book{fan2026257,
  author    = {Fan, Yafu},
  title     = {A Lazy-Loading Private Tool Hub: Near-Zero Opening Context for Hundreds of Checkers and On-Demand Routing Trees},
  year      = {2026},
  publisher = {5D Library},
  edition   = {1.0.0},
  note      = {DOI pending}
}

Other chapter answers in this book