System Module Active

Globally Aligned Optimization

Hierarchically decomposed by time phase, globally aligned by a shared objective. Not local optimization, not monolithic optimization -- the correct middle ground for tractable, real-time port control.

The Global Objective

One Shared Business Target

Every layer, every solver, every replan serves a single measurable goal: minimize total weighted controllable vessel sojourn time.

Global Objective (L0)
minvVwv(TvdepTvready)\min \sum_{v \in \mathcal{V}} w_v \Big( T^{\text{dep}}_v - T^{\text{ready}}_v \Big)
where:
  T^ready_v   =  time vessel v becomes service-eligible
  T^dep_v     =  actual departure-ready time of vessel v
  w_v         =  priority weight of vessel v

Minimize the total weighted controllable sojourn time across all vessels. This captures only the time the port controls -- from service-eligibility to departure readiness -- not the full arrival-to-departure span.

MECE Time Decomposition
TvdepTvready=(TvberthTvready)Pre-Berth+(TvdoneTvberth)Service+(TvdepTvdone)Post-ServiceT^{\text{dep}}_v - T^{\text{ready}}_v = \underbrace{\big(T^{\text{berth}}_v - T^{\text{ready}}_v\big)}_{\text{Pre-Berth}} + \underbrace{\big(T^{\text{done}}_v - T^{\text{berth}}_v\big)}_{\text{Service}} + \underbrace{\big(T^{\text{dep}}_v - T^{\text{done}}_v\big)}_{\text{Post-Service}}
Pre-Berth:    admission delay
Service:      berth service time
Post-Service: release delay

The controllable sojourn decomposes into three mutually exclusive, collectively exhaustive phases. Each phase maps to exactly one optimization layer. No gap, no overlap.

Why This Objective
Controllable, Not Naive

Naive arrival-to-departure includes uncontrollable factors (vessel early arrival, weather delays). We measure only what the port can actually optimize.

Weighted Priority

w_v encodes commercial priority, vessel size, and contractual commitments. High-priority vessels get proportionally more optimization pressure.

MECE Decomposition

Three phases, three layers. Every second of controllable sojourn belongs to exactly one layer. No optimization gap, no double-counting.

Design Rationale

Why This Architecture

Two common approaches fail at port-scale. The correct answer is in the middle: decomposed for tractability, aligned for correctness.

Not Local Optimization

Optimizing each equipment subsystem independently produces local optima that conflict at boundaries. A crane-optimal plan can starve AGVs; an AGV-optimal route can block yard access. Local optimality does not equal system optimality.

Not Monolithic Optimization

A single giant solver across all resources is too large to scale, too slow to run in real-time, and too brittle when any sub-problem changes. Monolithic formulations collapse under operational complexity.

Hierarchical + Globally Aligned

Decompose by time phase, not equipment. Each layer solves a tractable sub-problem while a global coordinator enforces inter-layer consistency constraints. Decomposition gives speed; alignment gives correctness.

CRITICAL
Pure local optimization is wrong -- local optima conflict at layer boundaries. Fully monolithic optimization is also wrong -- too large, too slow, too brittle. The correct architecture: hierarchically decomposed by time phase, globally aligned through a shared objective and bidirectional feedback.
3-Layer Architecture

MECE Time Decomposition

Each layer owns exactly one phase of the controllable vessel sojourn. Proposals flow forward, evaluations flow backward, creating a closed coordination loop.

L1Pre-Berth Layer

Admission delay minimization. Assigns vessels to berths, determines berth start timing, and sequences admission under marine-access and capacity constraints.

Scope
Hours. Full vessel queue and berth inventory.
L2Service Layer

Berth service time minimization. Orchestrates STS crane assignment, AGV/truck dispatch, and yard-side container absorption. The most operationally critical layer.

Scope
Minutes. Active cranes, vehicle fleet, yard blocks.
L3Post-Service Layer

Release delay minimization. Manages departure clearance, berth release sequencing, and resource conflict resolution for outbound vessels.

Scope
Minutes to hours. Departure resources, berth turnover.
Formal Decomposition
minx,y,z  F(x,y,z)s.t. inter-layer consistency constraints\min_{x,\,y,\,z} \; F(x, y, z) \quad \text{s.t. inter-layer consistency constraints}
Variables:
  x = Pre-Berth decisions
  y = Service decisions
  z = Post-Service decisions

Output of x shapes feasible region of y.
Output of y shapes feasible region of z.

The optimization is not a pipeline -- it is a coupled system where each layer's decisions constrain the next layer's feasible set.

Bidirectional Coordination
Forward: Proposals

Pre-Berth sends berth assignment proposals and berth start timing to Service.

Service sends projected work-done times and resource forecasts to Post-Service.

Backward: Evaluations

Service returns feasibility flags, congestion penalties, fragility scores, and infeasibility cuts.

Post-Service returns berth release times and departure resource conflicts.

Closed loop -- not a one-way pipeline

Cross-Layer Feedback

Coordination Mechanism

The 7-step production operating logic that turns three independent solvers into one coherent system.

1. World State Update

Ingest current vessel positions, berth occupancy, crane status, AGV fleet state, yard density, and departure queue into a unified state snapshot.

2. Pre-Berth Proposes

Pre-Berth layer generates berth assignment proposals and berth start timing based on vessel queue, priority weights, and marine access windows.

3. Service Evaluates

Service layer evaluates each proposal: returns projected work-done time, resource requirements, congestion penalty, fragility score, and feasibility flag.

4. Feedback Returns

If infeasible or fragile, Service sends infeasibility cuts and congestion penalties back to Pre-Berth. Pre-Berth re-proposes with tighter bounds.

5. Plan Commits

Once feasible, the berth plan commits. Service begins execution. Post-Service receives projected work-done times and prepares departure resources.

6. Post-Service Evaluates

Post-Service returns berth release times and flags departure resource conflicts. Conflicts propagate back to the coordinator for resolution.

7. Freeze and Execute

Committed decisions are frozen. Only the remaining horizon is re-optimized on the next trigger. Plan stability is preserved as a first-class objective.

Interface Schemas
BerthPlanPre-Berth output

vessel_id

berth_id

planned_berth_start

priority_weight

work_profile

marine_access_window

ServiceEvaluationService feedback

vessel_id

feasible_flag

projected_work_done_time

projected_qc/agv/yard_requirements

congestion_penalty

fragility_score

ReleaseEvaluationPost-Service feedback

vessel_id

projected_departure_ready_time

berth_release_time

departure_resource_conflict

Dynamic Replanning

Rolling-Horizon Control

Optimization is not one-and-done. The system continuously re-solves on triggers while preserving committed decisions and plan stability.

Replan Policy
1
Update world state

Ingest the triggering event into the unified state model.

2
Freeze committed decisions

Lock in-flight operations that cannot be reversed without operational cost.

3
Reoptimize remaining horizon

Re-solve only the uncommitted future window with updated constraints.

4
Preserve plan stability

Penalize unnecessary churn. Minimize the delta between old plan and new plan.

Trigger Examples
ETA change

Pre-Berth re-sequences admission queue

Crane breakdown

Service re-dispatches cranes and AGVs

AGV congestion

Service adjusts routes, signals Pre-Berth

Yard blockage

Service reroutes absorption; may delay berth start

Delayed departure

Post-Service re-sequences release queue

Tug/pilot shift

Post-Service adjusts departure windows

Solver Stack
Global Coordinator

Rule engine + optimization orchestrator

Enforces inter-layer consistency, routes feedback, manages freeze/commit cycle

Pre-Berth

MILP, CP-SAT, decomposition-based admission scheduler

Berth assignment and admission sequencing under capacity and marine constraints

Service

MILP, CP-SAT, LNS, hybrid heuristics, dispatch policy layer

Crane-vehicle-yard coupled optimization with real-time feasibility repair

Post-Service

Event-driven repair heuristic, local reoptimization

Departure clearance and berth release with conflict resolution

AINOS Smart Port -- Central Brain Documentation
Globally Aligned Optimization Engine