# AnyLogic workflow rebuild specification This specification translates the supplied runnable Python model into blocks and state definitions for a future native AnyLogic model. It is a specification, not a tested .alp file. The delivered visual lab already executes the Python discrete-event engine. ## Entity and clock One agent represents one production-readiness package. Retain package ID, arrival, admission, complexity, current visit, author ID, total labor, release, review completions and escalation flag. Clock unit is operating hours. Eight hours equal one workday and 240 workdays one operating year. Do not add calendar weekends on top of this clock. ## Block route Source → admission backlog → WIP gate → configuration delay and ME work → readiness delay and ME work → assembly delay and ME work → review delay → split into ME, QA and controls tasks → join all three → finding decision. A finding returns to assembly for at most two repeat loops. A further finding adds eight ME labor-hours in expert resolution. Otherwise continue through resolution/authorization using ME, then controlled release using document control, then Sink. Release frees the admission slot. Use explicit resource pools ME=3, QA=1, CE=1 and DC=1 at reference staffing. Reference allocated fractions are .65, .35, .30 and .40. Resource occupied duration is labor/allocated fraction. Record labor separately so derating does not inflate labor cost. ME review must seize a person different from the assembly author for that visit. A simple generic service block without that eligibility rule will not match the supplied model. ## Arrivals and distributions Use exponential gaps with a mean of 20 operating hours. Product classes have probabilities .30/.50/.20 and multipliers .7/1/1.5, divided by weighted mean 1.01. Stage labor multipliers are mean-one lognormal with CV=.35; sigma=sqrt(ln(1+CV^2)) and mu=-sigma^2/2. Exogenous delays use a mean-one gamma multiplier with shape=1/CV^2 and scale=CV^2, CV=.65. Stage means, finding probabilities, resource allocations and WIP limits come from config.json. Record all branch draws by replication, package, stage and visit. For exact numerical correspondence, import pre-generated random draws from Python; the same numeric seed in another engine does not imply the same random stream. Pair scenario demand and task draws. The qualification constraint can change scheduling even when task means match. ## Experiments Replications: 40 independent streams. Initialize for 240 workdays, measure 960 additional workdays, then stop arrivals and drain all packages. Lead-time and labor cohorts use arrivals in the measurement window, including late completions. Throughput counts releases within the measurement window. WIP and occupancy use interval overlap with the same window. Compare baseline, redesign and later improvement using paired replication differences. Preserve the 12 declared statistical contrasts and their simultaneous confidence intervals. ## Animation Show admission backlog and six process states, three concurrent review lanes, resource pools, release count, rework returns, a selected-package timeline, and WIP over time. Separate package counts from reviewer task counts. Show initialization versus measurement interval and avoid implying animation speed affects the calculated results. ## Acceptance cases 1. Single package, no delays/rework, full allocation: 38 labor-hours and 34 elapsed hours. 2. Halved allocation with otherwise identical inputs: 38 labor-hours and 68 elapsed hours. 3. Three simultaneous packages with gate one: releases at 34, 68 and 102 hours in the deterministic fixture. 4. Force findings: exactly two assembly/review repeats, then expert resolution. 5. Verify no overlap for each individual resource and no author self-review. 6. Verify every arrival releases after drain, all timestamps are ordered, WIP gate is respected and integral N(t)dt equals sum of arrival-to-release durations on the empty-to-empty path. 7. Validate sample flow and distribution diagnostics against exported raw records before comparing steady-state estimates. Matching one headline mean alone is insufficient.