Files
leleka/limits-baseline.json
T
Pavlo Ratushnyi 7610ba3568 STRA-338 size-gw: the 19 oversize files of control-plane and desktop-core split by topic (no file over 400 lines); mechanical child modules renamed
Tests become directory modules named after what they test, with a shared fixtures/harness module:
control-plane/src/{responses,ggml_bridge,gguf_f32_stream,prepare_preview}/tests/, desktop-core/src/runtime_rpc/tests/;
integration targets become tests/<name>/main.rs plus topic modules and a harness (backend_worker_http, vision_http,
memory_gate_http, tool_corpus, mcp_hub, api_over_runtime, runtime_gateway_sdet, native_tools_sdet,
native_tools_retry_sdet, managed_worker, gateway); target names are unchanged. Sources: leleka-inference.rs becomes
src/bin/leleka-inference/ (main.rs plus one module per operator option group), the cp_replay example becomes
examples/cp_replay/, and the tonic service impl of runtime_rpc delegates to session_rpc, model_rpc and generate_rpc
(bodies unchanged). impl_* modules are renamed after what they hold (base_provenance, count_tokens, manifest_fetch,
fetcher, record, capture, in_flight, tool_policy, tool_plan, server). The self-spawning tests that name themselves
(credential_child, the managed worker fixture) use the new module path or stay at the target root.

Test ids: 543 before and after in both crates (strata-control, strata-desktop-core, --all-targets), 0 missing, 0 new,
0 outcome changes; 241 ids differ only in the module path. Warnings in the two crates: 0 before and after.
Counts (strata-control / strata-desktop-core): oversize files 19 -> 0 (13 + 6). Functions over 30 lines, complexity 10,
nesting 4, wide lines, prod: 187/135/17/199 -> 187/135/17/196 and 81/59/6/54 -> 81/59/6/54; test: 214/17/30/133 ->
214/17/30/133 and 65/3/3/30 -> 65/3/3/27. The 211 functions that moved verbatim are in limits-allowlist.json (owner
STRA-338) because the diff gate treats a moved function as added; the entries fall as the functions are shortened.
2026-11-06 13:13:59 +01:00

396 lines
7.0 KiB
JSON

{
"_comment": "The legacy census of scripts/check-limits.py: functions over each limit and lines over the width, per scope (prod, test) and crate. A total over all crates may only fall (a function moved between crates keeps it). Do not edit by hand; regenerate with scripts/check-limits.py --update-baseline. Policy: limits.json.",
"limits": {
"fn_lines": 30,
"complexity": 10,
"nesting": 4,
"width": 120
},
"census": {
"prod": {
"leleka-backend-api": {
"width": 16,
"complexity": 2,
"fn_lines": 3
},
"leleka-context": {
"fn_lines": 6,
"complexity": 6,
"width": 10
},
"leleka-cpu-kernels": {
"fn_lines": 1
},
"leleka-cpu-sys": {
"fn_lines": 19,
"width": 5,
"complexity": 3,
"nesting": 2
},
"leleka-cpu-worker": {
"fn_lines": 7,
"complexity": 5,
"width": 6
},
"leleka-cuda-driver": {
"fn_lines": 657,
"width": 2561,
"complexity": 668,
"nesting": 32
},
"leleka-deploy": {
"fn_lines": 105,
"width": 387,
"complexity": 53,
"nesting": 7
},
"leleka-engine-core": {
"fn_lines": 40,
"complexity": 32,
"width": 57
},
"leleka-engine-fake": {
"width": 1
},
"leleka-engine-qwen35-cuda": {
"fn_lines": 593,
"width": 1934,
"complexity": 584,
"nesting": 30
},
"leleka-experimental-ref": {
"fn_lines": 15,
"width": 19,
"complexity": 11,
"nesting": 1
},
"leleka-gateway-domain": {
"width": 53,
"fn_lines": 16,
"complexity": 13,
"nesting": 6
},
"leleka-gateway-text": {
"width": 64,
"complexity": 16,
"fn_lines": 15,
"nesting": 1
},
"leleka-gguf": {
"fn_lines": 6,
"width": 3,
"complexity": 6
},
"leleka-gptoss": {
"fn_lines": 13,
"complexity": 6,
"nesting": 1,
"width": 1
},
"leleka-gptoss-igpu": {
"fn_lines": 1,
"complexity": 1,
"width": 2
},
"leleka-gptoss-npu": {
"fn_lines": 5,
"complexity": 3,
"nesting": 2,
"width": 3
},
"leleka-gpu-npu-worker": {
"fn_lines": 3,
"width": 3,
"complexity": 1
},
"leleka-harmony": {
"fn_lines": 4,
"complexity": 6,
"width": 1,
"nesting": 2
},
"leleka-igpu": {
"fn_lines": 12,
"complexity": 1,
"width": 5
},
"leleka-igpu-worker": {
"fn_lines": 2,
"complexity": 1,
"width": 1
},
"leleka-kar-codec": {
"fn_lines": 4,
"complexity": 3
},
"leleka-libc-shim": {
"width": 35,
"fn_lines": 2,
"complexity": 2
},
"leleka-memory": {
"width": 164,
"fn_lines": 21,
"complexity": 11,
"nesting": 1
},
"leleka-model-format": {
"fn_lines": 84,
"complexity": 62,
"width": 100,
"nesting": 4
},
"leleka-native-cpu-expert": {
"complexity": 84,
"fn_lines": 6,
"width": 1106,
"nesting": 24
},
"leleka-native-parity-bench": {
"width": 9
},
"leleka-npu-service": {
"fn_lines": 6,
"complexity": 5,
"width": 14
},
"leleka-npu-worker": {
"fn_lines": 2,
"complexity": 1,
"width": 2
},
"leleka-obs": {
"width": 16,
"fn_lines": 4,
"complexity": 4,
"nesting": 1
},
"leleka-offline-tools": {
"fn_lines": 8,
"complexity": 5,
"width": 1
},
"leleka-openvino": {
"fn_lines": 2,
"width": 1
},
"leleka-quant-core": {
"fn_lines": 1,
"nesting": 2
},
"leleka-runtime": {
"width": 2
},
"leleka-runtime-client": {
"fn_lines": 9,
"complexity": 4,
"width": 4
},
"leleka-sampler-ref": {
"fn_lines": 9,
"complexity": 4
},
"leleka-serving-policy": {
"fn_lines": 13,
"complexity": 10,
"width": 6
},
"leleka-shm": {
"fn_lines": 2
},
"leleka-tokenizer": {
"width": 21,
"fn_lines": 13,
"complexity": 7
},
"leleka-worker-protocol": {
"fn_lines": 3,
"complexity": 3
},
"python": {
"complexity": 1,
"width": 2
},
"strata-control": {
"fn_lines": 187,
"complexity": 135,
"width": 196,
"nesting": 17
},
"strata-desktop-core": {
"fn_lines": 81,
"complexity": 59,
"width": 54,
"nesting": 6
}
},
"test": {
"leleka-backend-api": {
"fn_lines": 5
},
"leleka-context": {
"fn_lines": 12,
"complexity": 1,
"width": 1
},
"leleka-cpu-kernels": {
"fn_lines": 8,
"nesting": 5,
"complexity": 3,
"width": 1
},
"leleka-cpu-sys": {
"fn_lines": 16,
"width": 2
},
"leleka-cpu-worker": {
"fn_lines": 6,
"nesting": 2,
"width": 11,
"complexity": 1
},
"leleka-cuda-driver": {
"fn_lines": 134,
"complexity": 32,
"width": 188,
"nesting": 6
},
"leleka-deploy": {
"fn_lines": 89,
"width": 67
},
"leleka-engine-core": {
"fn_lines": 35,
"width": 46,
"complexity": 9,
"nesting": 1
},
"leleka-engine-qwen35-cuda": {
"fn_lines": 96,
"width": 202,
"complexity": 18,
"nesting": 5
},
"leleka-experimental-ref": {
"fn_lines": 14,
"width": 58,
"complexity": 2,
"nesting": 2
},
"leleka-gateway-domain": {
"width": 1,
"fn_lines": 3
},
"leleka-gateway-text": {
"fn_lines": 13,
"nesting": 2,
"width": 21
},
"leleka-gguf": {
"fn_lines": 5,
"width": 1
},
"leleka-gptoss": {
"fn_lines": 16,
"complexity": 4,
"width": 7
},
"leleka-gptoss-igpu": {
"fn_lines": 5,
"width": 3
},
"leleka-gptoss-npu": {
"fn_lines": 4,
"width": 6
},
"leleka-gpu-npu-worker": {
"fn_lines": 2,
"width": 4,
"complexity": 1
},
"leleka-harmony": {
"fn_lines": 3,
"width": 5
},
"leleka-igpu": {
"fn_lines": 12,
"complexity": 1
},
"leleka-libc-shim": {
"width": 2
},
"leleka-memory": {
"fn_lines": 2,
"complexity": 1,
"nesting": 1,
"width": 67
},
"leleka-model-format": {
"fn_lines": 83,
"width": 70,
"complexity": 14,
"nesting": 4
},
"leleka-native-cpu-expert": {
"fn_lines": 26,
"complexity": 22,
"nesting": 6,
"width": 325
},
"leleka-npu-service": {
"fn_lines": 3,
"nesting": 1,
"width": 1
},
"leleka-npu-worker": {
"fn_lines": 2
},
"leleka-obs": {
"width": 7
},
"leleka-offline-tools": {
"fn_lines": 3
},
"leleka-quant-core": {
"fn_lines": 11,
"complexity": 1
},
"leleka-runtime-client": {
"fn_lines": 9
},
"leleka-sampler-ref": {
"fn_lines": 14,
"nesting": 2,
"complexity": 1
},
"leleka-serving-policy": {
"fn_lines": 9,
"width": 1
},
"leleka-tokenizer": {
"fn_lines": 10,
"width": 10,
"complexity": 1
},
"leleka-worker-protocol": {
"fn_lines": 1
},
"python": {
"width": 1
},
"strata-control": {
"fn_lines": 214,
"complexity": 17,
"width": 133,
"nesting": 30
},
"strata-desktop-core": {
"fn_lines": 65,
"complexity": 3,
"width": 27,
"nesting": 3
}
}
}
}