scanning v1

This commit is contained in:
2026-03-22 01:35:53 -05:00
parent 2ee3f37576
commit 7524274e86
3 changed files with 1395 additions and 468 deletions

24
LabWise/AIvsPubChem.md Normal file
View File

@@ -0,0 +1,24 @@
CAS locked in → PubChem lookup fires
┌────────────┴────────────┐
PubChem has name? No name
↓ ↓
AI has name? keep AI name (if any)
┌───────┴───────┐ aiSatisfied = !aiName.isEmpty
Yes No
↓ ↓
arbitrate use PubChem name directly
↓ aiSatisfied = true
isSameCompound?
┌────┴────┐
Yes No
↓ ↓
labelIsCommonName? trust PubChem (CAS is reliable)
┌────┴────┐
Yes No
↓ ↓
use use
label PubChem
name name
("CHAPS")
aiSatisfied = true → no more AI re-triggers

View File

@@ -108,6 +108,9 @@ struct InventoryView: View {
}
case .scan:
ScanView()
.onDisappear {
Task { await viewModel.loadChemicals() }
}
}
}
.task {

File diff suppressed because it is too large Load Diff