feat(schema): complete hardware tables with GPU identity, lookups, and slot links - #45
Open
AlbinoGeek wants to merge 1 commit into
Open
AlbinoGeek wants to merge 1 commit into
AlbinoGeek wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
The unresolved critical GPU-history issue and two moderate compatibility/slot-link issues must be addressed.
Get a fresh assessment by requesting another Copilot review.
Review effort: Lite
Findings: 1
Open (3)
What changed in this PR
This pull request completes the hardware schema for GPU identity, lookup data, interconnects, TFLOPS provenance, and system-slot relationships.
Changes:
- Adds lookup seed data for VRAM, architectures, compute formats, TFLOPS sources, and interfaces.
- Expands hardware, GPU, system, slot-link, and run-metrics relationships.
- Documents the schema additions in the changelog.
| File | Summary |
|---|---|
schema/seeds/vram_types.json |
Seeds VRAM technologies. |
schema/seeds/tflops_sources.json |
Seeds TFLOPS provenance sources. |
schema/seeds/interface_types.json |
Seeds PCIe and interconnect types. |
schema/seeds/gpu_architectures.json |
Seeds GPU architectures. |
schema/seeds/compute_formats.json |
Seeds compute formats. |
schema/schema.sql |
Defines expanded hardware relationships. Findings: Moderate (3 votes): enforce paired nullability for slot-link identifiers. Critical (1 vote): preserve GPU identity for historical metrics. Moderate (2 votes): retain cpu_cores or update the collector and persistence contract. |
CHANGELOG.md |
Documents the schema changes. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
+617
to
+618
| FOREIGN KEY (system_hardware_id, slot_index) | ||
| REFERENCES system_gpu_link (system_hardware_id, slot_index) |
Comment on lines
+557
to
+558
| cpu_threads INT, | ||
| cpu_base_clock_mhz INT, |
Comment on lines
+611
to
+612
| system_hardware_id INT, | ||
| slot_index INT, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Implements the schema asked for in #38 (and #17–#22), for @gissf1's review before it lands, per the approval requirement on #38.
Design choices where the issues were unsettled (newer issue wins):
vram_typeis an FK to a seededvram_typestable (per Tables are not defined properly and missing many fields. #38 and the Hardware tables disk persistence — analysis and layout #22 comment).gpu_tflops(GPU ×compute_formats×tflops_sources).pci_subsystem_device_id,tdp_w.lane_transfer_rateis a float (PCIe 1.0 is 2.5 GT/s).USB4,eGPUandintegratedseed rows dropped (not in schema: implement interface_type lookup table with seed data #17); an integrated GPU has a null native interface.model_architectures.schema_version_idonsystem_hardwareleft out, pending the UUID-migration design.Validated by loading all of
schema.sqlin PGlite: seed counts correct, duplicate PCI identity and bad slot links rejected.gategreen. No application code reads these tables yet (auto-detection per #18–#20 is not started).Still open: the
run_hardware_metricsfields at the end of #8 that #21 didn't cover.Refs #38
🤖 Generated with Claude Code