<?xml version="1.0" encoding="UTF-8"?>
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1100 620" width="1100" height="620" font-family="Helvetica, Arial, sans-serif">
  <defs>
    <linearGradient id="engineGrad" x1="0%" y1="0%" x2="0%" y2="100%">
      <stop offset="0%" style="stop-color:#E3F2FD"/>
      <stop offset="100%" style="stop-color:#BBDEFB"/>
    </linearGradient>
    <linearGradient id="taskGrad" x1="0%" y1="0%" x2="0%" y2="100%">
      <stop offset="0%" style="stop-color:#FFF3E0"/>
      <stop offset="100%" style="stop-color:#FFE0B2"/>
    </linearGradient>
    <linearGradient id="wallGrad" x1="0%" y1="0%" x2="100%" y2="0%">
      <stop offset="0%" style="stop-color:#B71C1C" stop-opacity="0.0"/>
      <stop offset="50%" style="stop-color:#B71C1C" stop-opacity="0.85"/>
      <stop offset="100%" style="stop-color:#B71C1C" stop-opacity="0.0"/>
    </linearGradient>
    <filter id="shadow" x="-4%" y="-4%" width="110%" height="115%">
      <feDropShadow dx="2" dy="2" stdDeviation="2.5" flood-color="#000" flood-opacity="0.18"/>
    </filter>
    <marker id="arr-blocked" markerWidth="9" markerHeight="9" refX="8" refY="4.5" orient="auto" markerUnits="strokeWidth">
      <polygon points="0 0,9 4.5,0 9" fill="#B71C1C"/>
    </marker>
  </defs>

  <rect width="1100" height="620" fill="#FAFAFA" rx="6"/>

  <!-- TITLE -->
  <text x="550" y="34" text-anchor="middle" font-size="20" font-weight="bold" fill="#1A237E">The Black-Box Problem in BPMN</text>
  <text x="550" y="56" text-anchor="middle" font-size="13" fill="#666" font-style="italic">The engine has the knowledge. The task cannot reach it.</text>

  <!-- ENGINE / RUNTIME (outer) -->
  <rect x="40" y="90" width="1020" height="490" rx="14" fill="url(#engineGrad)" stroke="#1565C0" stroke-width="2" filter="url(#shadow)"/>
  <text x="60" y="118" font-size="14" font-weight="bold" fill="#0D47A1">BPMN Process Engine — runtime knowledge available, but not delivered to the task</text>

  <!-- Aspect tiles around the perimeter -->
  <g font-size="12" fill="#0D47A1">
    <!-- top row -->
    <rect x="70" y="140" width="190" height="64" rx="8" fill="#fff" stroke="#1976D2" stroke-width="1.4"/>
    <text x="165" y="162" text-anchor="middle" font-weight="bold">Instance History</text>
    <text x="165" y="182" text-anchor="middle" font-size="11">what prior tasks decided</text>

    <rect x="280" y="140" width="190" height="64" rx="8" fill="#fff" stroke="#1976D2" stroke-width="1.4"/>
    <text x="375" y="162" text-anchor="middle" font-weight="bold">Audit Log</text>
    <text x="375" y="182" text-anchor="middle" font-size="11">10,000 similar prior cases</text>

    <rect x="630" y="140" width="190" height="64" rx="8" fill="#fff" stroke="#1976D2" stroke-width="1.4"/>
    <text x="725" y="162" text-anchor="middle" font-weight="bold">Semantic Lineage</text>
    <text x="725" y="182" text-anchor="middle" font-size="11">how each value was derived</text>

    <rect x="840" y="140" width="190" height="64" rx="8" fill="#fff" stroke="#1976D2" stroke-width="1.4"/>
    <text x="935" y="162" text-anchor="middle" font-weight="bold">Peer-Task State</text>
    <text x="935" y="182" text-anchor="middle" font-size="11">what siblings are doing now</text>

    <!-- bottom row -->
    <rect x="70" y="486" width="190" height="64" rx="8" fill="#fff" stroke="#1976D2" stroke-width="1.4"/>
    <text x="165" y="508" text-anchor="middle" font-weight="bold">Goal Context</text>
    <text x="165" y="528" text-anchor="middle" font-size="11">what this case is trying to achieve</text>

    <rect x="280" y="486" width="190" height="64" rx="8" fill="#fff" stroke="#1976D2" stroke-width="1.4"/>
    <text x="375" y="508" text-anchor="middle" font-weight="bold">Preference Weights</text>
    <text x="375" y="528" text-anchor="middle" font-size="11">organizational trade-off guidance</text>

    <rect x="630" y="486" width="190" height="64" rx="8" fill="#fff" stroke="#1976D2" stroke-width="1.4"/>
    <text x="725" y="508" text-anchor="middle" font-weight="bold">Policy / Ontology Version</text>
    <text x="725" y="528" text-anchor="middle" font-size="11">rules in effect right now</text>

    <rect x="840" y="486" width="190" height="64" rx="8" fill="#fff" stroke="#1976D2" stroke-width="1.4"/>
    <text x="935" y="508" text-anchor="middle" font-weight="bold">External Context</text>
    <text x="935" y="528" text-anchor="middle" font-size="11">live signal from outside</text>
  </g>

  <!-- WALL around task -->
  <rect x="380" y="240" width="340" height="220" rx="10" fill="none" stroke="#B71C1C" stroke-width="3" stroke-dasharray="10 6"/>
  <text x="550" y="262" text-anchor="middle" font-size="12" font-weight="bold" fill="#B71C1C">no access path from task to runtime</text>

  <!-- Service Task -->
  <rect x="430" y="290" width="240" height="120" rx="14" fill="url(#taskGrad)" stroke="#E65100" stroke-width="2" filter="url(#shadow)"/>
  <text x="550" y="320" text-anchor="middle" font-size="15" font-weight="bold" fill="#BF360C">BPMN Service Task</text>
  <text x="550" y="342" text-anchor="middle" font-size="12" fill="#5D4037" font-style="italic">sees only its input map</text>

  <!-- Input map inside -->
  <rect x="455" y="358" width="190" height="40" rx="6" fill="#fff" stroke="#FFB74D" stroke-width="1.2"/>
  <text x="550" y="375" text-anchor="middle" font-size="11" fill="#5D4037" font-weight="bold">Input Variables</text>
  <text x="550" y="390" text-anchor="middle" font-size="10" fill="#5D4037" font-style="italic">a few values, no context</text>

  <!-- Blocked arrows from each aspect tile to task -->
  <g stroke="#B71C1C" stroke-width="1.6" fill="none" stroke-dasharray="4 4">
    <line x1="165" y1="206" x2="425" y2="296" marker-end="url(#arr-blocked)"/>
    <line x1="375" y1="206" x2="470" y2="288" marker-end="url(#arr-blocked)"/>
    <line x1="725" y1="206" x2="630" y2="288" marker-end="url(#arr-blocked)"/>
    <line x1="935" y1="206" x2="675" y2="296" marker-end="url(#arr-blocked)"/>
    <line x1="165" y1="486" x2="425" y2="404" marker-end="url(#arr-blocked)"/>
    <line x1="375" y1="486" x2="470" y2="412" marker-end="url(#arr-blocked)"/>
    <line x1="725" y1="486" x2="630" y2="412" marker-end="url(#arr-blocked)"/>
    <line x1="935" y1="486" x2="675" y2="404" marker-end="url(#arr-blocked)"/>
  </g>

  <!-- Caption strip -->
  <rect x="40" y="588" width="1020" height="0" stroke="none" fill="none"/>
  <text x="550" y="606" text-anchor="middle" font-size="12" fill="#37474F" font-style="italic">
    Without a uniform delivery mechanism, every concern outside the input map is either hand-wired into the diagram or lost.
  </text>
</svg>
