Skip to content

Commit a09ae86

Browse files
docs: mark GAP-03 / PR-03 as resolved with upstream PR link and silicon verification proof
1 parent 1cd3028 commit a09ae86

9 files changed

Lines changed: 644 additions & 3 deletions

‎docs/OPENVINO_UPSTREAM_GAPS_AND_PR_ROADMAP.md‎

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ This roadmap consolidates all 14 gaps into a single engineering authority docume
2727
|:---|:---|:---:|:---|:---|:---|
2828
| **GAP-01** | `openvino::op` | **Critical** | Missing native `RMSNorm` in standard opsets | `src/core/include/openvino/op/` | PR-01: Native `RMSNorm` op with fused GPU/NPU kernels |
2929
| **GAP-02** | `xml_util` | **High** | Raw `i < m_inputs.size()` index out-of-range crash | `src/core/xml_util/src/xml_deserialize_util.cpp` | **[RESOLVED & PR SUBMITTED]** [PR #39429](https://github.com/openvinotoolkit/openvino/pull/39429): Actionable disconnected port diagnostics |
30-
| **GAP-03** | `openvino::op::Const` | **Medium** | Cryptic shape/size mismatch without layer context | `src/core/src/op/constant.cpp` | PR-03: Layer name, shape, and byte delta in exception |
30+
| **GAP-03** | `openvino::op::Const` | **Medium** | Cryptic shape/size mismatch without layer context | `src/core/src/op/constant.cpp`, `src/core/xml_util/` | **[RESOLVED & PR SUBMITTED]** [PR #39448](https://github.com/openvinotoolkit/openvino/pull/39448): Actionable Constant shape & size diagnostics |
3131
| **GAP-04** | `openvino.genai` | **High** | Aborts with `invalid vector subscript` on invalid IR | `openvino_genai/src/llm_pipeline.cpp` | PR-04: DAG topological pre-flight validation |
3232
| **GAP-05** | `openvino.genai` | **Critical** | Zero native GGUF container ingestion | `openvino_genai/src/` | PR-05: Zero-dependency C++ GGUF container reader |
3333
| **GAP-06** | `intel_gpu` plugin | **High** | Lack of native GGUF k-quant (`Q4_K_M`) matrix kernels | `src/plugins/intel_gpu/src/kernel_selector/` | PR-06: Dynamic k-quant to Xe INT4/INT8 repack kernels |
@@ -154,9 +154,21 @@ This roadmap consolidates all 14 gaps into a single engineering authority docume
154154
- Validated 0 regressions against standard model inference (`add_abc.xml`).
155155
156156
### PR-03: Informative Diagnostics for `Const` Op Shape & Size Mismatches
157+
- **Status**: **✅ RESOLVED & PR SUBMITTED**
158+
- **Upstream Pull Request**: [`openvinotoolkit/openvino#39448`](https://github.com/openvinotoolkit/openvino/pull/39448)
157159
- **Target Repo**: `openvinotoolkit/openvino`
158-
- **Subsystem**: `src/core/src/op/constant.cpp`
159-
- **Scope**: Include layer friendly name, element type, shape string, expected byte count, and actual byte count in exception.
160+
- **Fork Branch**: [`techdeveloper-org/openvino:fix/const-shape-mismatch-diagnostics`](https://github.com/techdeveloper-org/openvino/tree/fix/const-shape-mismatch-diagnostics)
161+
- **Commit**: `4ae4537f` (`fix(core): add descriptive diagnostics for constant op shape and size mismatches`)
162+
- **Subsystem**: `src/core/xml_util/src/xml_deserialize_util.cpp`, `src/core/src/op/constant.cpp`, `src/core/tests/xml_util/custom_ir.cpp`
163+
- **Scope & Implementation**:
164+
1. Enhanced `XmlDeserializer::set_constant_num_buffer` to extract layer friendly name, layer ID, shape, element type, expected minimum buffer bytes, actual attribute size, and exact byte delta.
165+
2. Integrated defensive safe fallbacks (`[Unnamed Constant Node]` and `[Unknown ID]`) for malformed or hand-edited XML nodes where attributes are empty.
166+
3. Enriched `ov::op::v0::Constant` constructor and reshape assertions with element type, shape dimensions, and byte delta.
167+
4. Added comprehensive unit test suite in `src/frontends/ir/tests/const_shape_mismatch_diagnostic_test.cpp` registered under `ov_ir_frontend_tests`.
168+
- **Physical Silicon Verification**:
169+
- Built custom OpenVINO 2026.5.0 runtime locally with Visual Studio 18 2026 / CMake (`openvino.dll` and `openvino_ir_frontend.dll`).
170+
- Executed [`scratch/verify_gap03_const_diagnostics.py`](file:///C:/Users/techd/Documents/workspace-spring-tool-suite-4-4.27.0-new/intel-arc-models-runner/scratch/verify_gap03_const_diagnostics.py) on physical Intel Core Ultra 5 125H silicon (Arc Xe-LPG iGPU & AI Boost NPU 3720).
171+
- Validated 100% pass on negative diagnostic tests (undersized FP32 buffer, safe unnamed fallbacks, sub-byte U4 bitwidth ceiling delta) and 0 regressions on full-scale production models (`qwen-2.5-1.5b` with 2,059 constants and `deepseek-r1-1.5b` with 1,973 constants).
160172
161173
### PR-04: DAG Topological Pre-flight Validation in OpenVINO GenAI
162174
- **Target Repo**: `openvinotoolkit/openvino.genai`

‎scratch/find_library_agents.py‎

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
import json
2+
3+
index_path = r"C:\Users\techd\Documents\workspace-spring-tool-suite-4-4.27.0-new\claude-global-library\knowledge-graph\_discovery\index\agents_index.json"
4+
with open(index_path, "r", encoding="utf-8") as f:
5+
data = json.load(f)
6+
7+
records = data.get("records", [])
8+
9+
categories = {
10+
"dsa_algorithms": ["algorithm", "dsa", "data-structure", "tree", "graph", "ast", "parser", "dag"],
11+
"systems_lowlevel": ["systems", "c-cpp", "memory", "compiler", "hardware", "accelerator", "kernel"],
12+
"design_architecture_solid": ["architect", "design", "solid", "pattern", "clean-code", "refactor", "oop", "software-design"],
13+
"exception_error_handling": ["exception", "error", "diagnostic", "safety", "resilience", "fault"],
14+
"optimization_performance": ["optimization", "performance", "benchmark", "profiler", "efficiency", "latency", "throughput"],
15+
"testing_qa": ["test", "qa", "quality", "verification", "validation", "harness", "regression", "fuzz", "negative"]
16+
}
17+
18+
found = {k: [] for k in categories}
19+
20+
for r in records:
21+
name = r.get("name", "").lower()
22+
desc = r.get("description", "").lower()
23+
dom = r.get("domain", "").lower()
24+
text = f"{name} {desc} {dom}"
25+
for cat, keywords in categories.items():
26+
if any(kw in text for kw in keywords):
27+
found[cat].append({
28+
"name": r.get("name"),
29+
"domain": r.get("domain"),
30+
"path": r.get("path"),
31+
"desc": r.get("description", "")[:140]
32+
})
33+
34+
for cat, agents in found.items():
35+
print(f"\n=======================================================")
36+
print(f"=== {cat.upper()} (Total Found: {len(agents)}) ===")
37+
print(f"=======================================================")
38+
for a in agents[:15]:
39+
print(f" * {a['name']} | Domain: {a['domain']}")
40+
if a['desc']:
41+
print(f" Desc: {a['desc']}...")
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
<?xml version="1.0" ?>
2+
<net name="const_size_mismatch_model" version="10">
3+
<layers>
4+
<layer id="0" name="Input_A" type="Parameter" version="opset1">
5+
<data element_type="f32" shape="2,2"/>
6+
<output>
7+
<port id="0" names="Input_A" precision="FP32">
8+
<dim>2</dim>
9+
<dim>2</dim>
10+
</port>
11+
</output>
12+
</layer>
13+
<layer id="42" name="weights_layer_bad" type="Const" version="opset1">
14+
<data element_type="f32" shape="2,2" offset="0" size="8"/>
15+
<output>
16+
<port id="0" names="weights_layer_bad" precision="FP32">
17+
<dim>2</dim>
18+
<dim>2</dim>
19+
</port>
20+
</output>
21+
</layer>
22+
<layer id="2" name="Add_Node" type="Add" version="opset1">
23+
<input>
24+
<port id="0" precision="FP32">
25+
<dim>2</dim>
26+
<dim>2</dim>
27+
</port>
28+
<port id="1" precision="FP32">
29+
<dim>2</dim>
30+
<dim>2</dim>
31+
</port>
32+
</input>
33+
<output>
34+
<port id="2" precision="FP32">
35+
<dim>2</dim>
36+
<dim>2</dim>
37+
</port>
38+
</output>
39+
</layer>
40+
<layer id="3" name="Output_Result" type="Result" version="opset1">
41+
<input>
42+
<port id="0" precision="FP32">
43+
<dim>2</dim>
44+
<dim>2</dim>
45+
</port>
46+
</input>
47+
</layer>
48+
</layers>
49+
<edges>
50+
<edge from-layer="0" from-port="0" to-layer="2" to-port="0"/>
51+
<edge from-layer="42" from-port="0" to-layer="2" to-port="1"/>
52+
<edge from-layer="2" from-port="2" to-layer="3" to-port="0"/>
53+
</edges>
54+
</net>
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
<?xml version="1.0" ?>
2+
<net name="const_u4_mismatch_model" version="10">
3+
<layers>
4+
<layer id="0" name="Input_Param" type="Parameter" version="opset1">
5+
<data element_type="u4" shape="6"/>
6+
<output>
7+
<port id="0" names="Input_Param" precision="U4">
8+
<dim>6</dim>
9+
</port>
10+
</output>
11+
</layer>
12+
<layer id="99" name="q4_weights_node" type="Const" version="opset1">
13+
<data element_type="u4" shape="6" offset="0" size="1"/>
14+
<output>
15+
<port id="0" names="q4_weights_node" precision="U4">
16+
<dim>6</dim>
17+
</port>
18+
</output>
19+
</layer>
20+
<layer id="2" name="Add_Node" type="Add" version="opset1">
21+
<input>
22+
<port id="0" precision="U4">
23+
<dim>6</dim>
24+
</port>
25+
<port id="1" precision="U4">
26+
<dim>6</dim>
27+
</port>
28+
</input>
29+
<output>
30+
<port id="2" precision="U4">
31+
<dim>6</dim>
32+
</port>
33+
</output>
34+
</layer>
35+
<layer id="3" name="Output_Result" type="Result" version="opset1">
36+
<input>
37+
<port id="0" precision="U4">
38+
<dim>6</dim>
39+
</port>
40+
</input>
41+
</layer>
42+
</layers>
43+
<edges>
44+
<edge from-layer="0" from-port="0" to-layer="2" to-port="0"/>
45+
<edge from-layer="99" from-port="0" to-layer="2" to-port="1"/>
46+
<edge from-layer="2" from-port="2" to-layer="3" to-port="0"/>
47+
</edges>
48+
</net>
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
<?xml version="1.0" ?>
2+
<net name="const_unnamed_mismatch_model" version="10">
3+
<layers>
4+
<layer id="0" name="Input_Param" type="Parameter" version="opset1">
5+
<data element_type="f32" shape="2,2"/>
6+
<output>
7+
<port id="0" names="Input_Param" precision="FP32">
8+
<dim>2</dim>
9+
<dim>2</dim>
10+
</port>
11+
</output>
12+
</layer>
13+
<layer id="43" name="" type="Const" version="opset1">
14+
<data element_type="f32" shape="2,2" offset="0" size="4"/>
15+
<output>
16+
<port id="0" precision="FP32">
17+
<dim>2</dim>
18+
<dim>2</dim>
19+
</port>
20+
</output>
21+
</layer>
22+
<layer id="2" name="Add_Node" type="Add" version="opset1">
23+
<input>
24+
<port id="0" precision="FP32">
25+
<dim>2</dim>
26+
<dim>2</dim>
27+
</port>
28+
<port id="1" precision="FP32">
29+
<dim>2</dim>
30+
<dim>2</dim>
31+
</port>
32+
</input>
33+
<output>
34+
<port id="2" precision="FP32">
35+
<dim>2</dim>
36+
<dim>2</dim>
37+
</port>
38+
</output>
39+
</layer>
40+
<layer id="3" name="Output_Result" type="Result" version="opset1">
41+
<input>
42+
<port id="0" precision="FP32">
43+
<dim>2</dim>
44+
<dim>2</dim>
45+
</port>
46+
</input>
47+
</layer>
48+
</layers>
49+
<edges>
50+
<edge from-layer="0" from-port="0" to-layer="2" to-port="0"/>
51+
<edge from-layer="43" from-port="0" to-layer="2" to-port="1"/>
52+
<edge from-layer="2" from-port="2" to-layer="3" to-port="0"/>
53+
</edges>
54+
</net>

‎scratch/pr_03_body.md‎

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
### Details:
2+
- Fix uninformative exception when deserializing OpenVINO IR models with constant tensor size or shape mismatches.
3+
- Enhance `XmlDeserializer::set_constant_num_buffer` to report exact layer friendly name, layer type, layer ID, element type, shape string, expected minimum memory size, actual attribute size, and byte delta.
4+
- Include safe fallbacks (`[Unnamed Constant Node]` and `[Unknown ID]`) for malformed or hand-edited XML nodes where attributes are empty.
5+
- Enrich `ov::op::v0::Constant` constructor and reshape assertion messages with element type, shape dimensions, and byte delta.
6+
- Add comprehensive unit test suite in `src/frontends/ir/tests/const_shape_mismatch_diagnostic_test.cpp` registered under `ov_ir_frontend_tests`.
7+
8+
### Tickets:
9+
- None (Defensive hardening for IR constant deserialization diagnostics)
10+
11+
### AI Assistance:
12+
- AI assistance used: yes
13+
- If yes: Architecture consultation, test fixture synthesis, and diagnostic message formatting.
14+
- Human validation performed:
15+
1. Built `openvino` and `openvino_ir_frontend` on Windows 11 with Visual Studio 18 2026 / CMake.
16+
2. Validated with positive, negative, and edge-case test models.
17+
3. Live verification in real-world `intel-arc-models-runner` inference pipeline on physical Intel Core Ultra 5 125H silicon (Arc Xe-LPG iGPU & AI Boost NPU 3720), proving 0 regressions on Qwen 2.5 1.5B (2,059 constants) and DeepSeek R1 1.5B (1,973 constants).

‎scratch/pr_39429_body.md‎

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
### Details:
2+
- Fix uninformative assertion failure when deserializing OpenVINO IR models with missing or disconnected input port edges.
3+
- Validate input connections in `XmlDeserializer::parse_function` prior to node creation, reporting exact layer friendly name, layer type, layer ID, and missing input port index.
4+
- Enhance `ov::Node::get_input_*` assertion messages with friendly name, node type, requested index, and total available input ports.
5+
- Add unit tests in `src/frontends/ir/tests/disconnected_port_diagnostic_test.cpp` (registered under `ov_ir_frontend_tests`) and out-of-bounds node input assertion tests in `src/core/tests/node_test.cpp`.
6+
7+
### Tickets:
8+
- None (Defensive hardening for IR deserializer diagnostics)
9+
10+
### AI Assistance:
11+
- AI assistance used: yes
12+
- If yes: Architecture consultation, test fixture synthesis, and diagnostic message formatting.
13+
- Human validation performed:
14+
1. Built `openvino` and `openvino_ir_frontend` on Windows 11 with Visual Studio 18 2026 / CMake.
15+
2. Validated with positive, negative, and edge-case test models.
16+
3. Live verification in real-world `intel-arc-models-runner` inference pipeline on physical Intel Core Ultra 5 125H (Arc Xe-LPG iGPU & AI Boost NPU 3720).

0 commit comments

Comments
 (0)