Composing work packages

Project wiring diagrams · Essai 04

The drawing
that forks.

One controlled drawing reaches the wall team and the roof fabricator. A revision arrives. Does changing where it enters the wiring change what can fit together?

The wall team sets out a line from its issued drawing. Separately, a fabricator cuts a roof kit from another copy. This toy trial assumes their recorded drawing revisions must agree before the two outputs can be accepted together.

End

Make a project interface explainable when two work packages depend on the same information.

Way

Compose typed boxes in sequence and in parallel; give their wiring an explicit finite interpretation.

Means

Move one revision box across an explicit copy, then compare the outputs at the join.

Try one change

Which side of the copy receives revision B?

Both constructions start with controlled drawing A, contain one revision operation, and have the same outer input and output types. The revision moves; the result changes.

01

The revision arrives after copying

Swipe the diagram to see the join →

Late roof-copy revisionControlled drawing A enters an explicit copy box. The upper A copy goes to wall set-out. The lower A copy is revised to B before roof prefabrication. Their outputs A and B meet at a comparison box, which rejects them under the stated equality rule. OUTER BOUNDARY · DRAWING → AGREEMENT Drawing A CopyD → D ⊗ D A Set out wallA → wall line A A Issue BA → B B Make roof kitB → roof kit B wall A kit B CompareA ≠ B · reject

A / B · Matching port types, differing recorded revisions. The stated join condition has no accepted output.

02

The revision becomes the controlled issue

Swipe the diagram to see the join →

Revision before copyingControlled drawing A is revised to B before the explicit copy box. Both B copies go to wall set-out and roof prefabrication. Their B outputs meet at a comparison box, which accepts them under the stated equality rule. OUTER BOUNDARY · DRAWING → AGREEMENT Drawing A Issue BA → B B CopyD → D ⊗ D B Set out wallB → wall line B B Make roof kitB → roof kit B wall B kit B CompareB = B · accept

B / B · The same declared revision reaches both work packages. Their recorded outputs satisfy the toy join rule.

Selected construction

Roof copy revised after issue: wall line A meets roof kit B. Revision agreement fails.

Under the picture

One type does not mean one version.

Every thin line labelled D carries a value of type Drawing. Both A and B are values of that type, so both diagrams are well typed. The Copy box is explicit: ordinary symmetric monoidal wiring gives serial and parallel composition, not free duplication of a physical resource or an authorised document.

D = drawing revision; L = wall-line record; K = roof-kit record Δ : D → D ⊗ D explicit information copy u : D → D change the recorded issue to B w : D → L; p : D → K make branch records c : L ⊗ K → Agreement compare recorded revisions late = Δ » (id_D ⊗ u) » (w ⊗ p) » c early = u » Δ » (w ⊗ p) » c

The diagrams DisCoPy draws

These two SVGs are exported from the same late and early DisCoPy objects used by the independent check, rather than redrawn for this page. Read them from top to bottom. Their wires name types; they do not display the A/B revision values.

DisCoPy-generated wiring: copy the drawing; set out the wall on one branch; revise the roof branch to B before making its kit; compare both outputs.
After copy: the revision box sits on one branch. Open the SVG.
DisCoPy-generated wiring: issue revision B before copying the drawing; set out the wall and make the roof kit on parallel branches; compare both outputs.
Before copy: the revision box feeds the explicit copy. Open the SVG.

Rendering confirms the authored serial and parallel wiring can be drawn from typed DisCoPy objects. It does not prove revision agreement. The A/B and B/B results come from the separately declared finite interpretation below.

» means “then”; ⊗ means “alongside”. The Agreement type is interpreted as a Boolean diagnostic here. With initial value A, late(A)=false and early(A)=true. If we interpret c as an acceptance relation allowing only true, the A/B case has no permitted result. Moving u changes the interpreted behaviour without changing either outer type.

Under this interpretation, u » Δ = Δ » (u ⊗ u): revising before copying agrees with revising both copies. Updating only one branch changes the process; it is not a valid slide of a box across the copy in the free wiring syntax.

What the change teaches: a revision process has to be placed relative to the issue boundary. “All boxes were given a drawing” is weaker than “both outputs were made from an agreed issue”. The model does not decide who has authority to issue B, whether either record is accurate, whether the roof fits the wall, or how long any work takes.

What is borrowed; what is tried here

Source → concept → construction → limit

Typed, acyclic wiring

Patterson, Spivak & Vagner provide an operadic account of directed acyclic wiring diagrams and their SMC interpretation. Here, the outer types match in both arrangements; that formal fact does not make their behaviours equal.

Independent composition check

DisCoPy represents the explicit copy, the two parallel branch boxes, their serial composition and the join. Its drawing function produces the two SVGs above from those objects. A functor into Python functions independently evaluates both diagrams on A and B. The reproducible check is retained in the source repository; its decisive construction is shown below.

Our project interpretation

We chose the wall set-out and prefabricated roof-kit story, the A/B revision values, the update operation and an equality rule at their join. Matching revision is necessary only under this declared toy rule; neither DisCoPy nor the paper establishes project readiness, fit, document authority or a schedule.

See the DisCoPy composition
do_work = (set_out @ prefab) >> join
late = copy >> (Id(drawing) @ update) >> do_work
early = update >> copy >> do_work

Here @ puts boxes alongside one another and >> connects them in sequence. copy is an explicit Drawing → Drawing ⊗ Drawing box. Under the declared finite interpretation, its two outputs carry the same revision, update sets the revision to B, and join checks equality. The source check also verifies the outer types and rejects an ill-typed connection.