Files
genshin-assistant/package.json
T
AzuTear b7dbc618b3 feat(eval): add field-level OCR accuracy harness + seed corpus
Adds a measurement gate for the artifact OCR parser (ADR-007), the prerequisite
for the layout-profile and preprocessing rework. runOcrEval feeds labeled OCR
text through the real parseArtifactCandidate and scores per-field / per-case
accuracy.

- src/eval/ocrEvalHarness.ts: pure metrics (per-field, critical-field, exact).
- src/eval/corpus/seedCorpus.ts: 23 cases transcribed from the verified parser
  test assertions; runs at 100%.
- src/eval/reviewSampleCorpus.ts: converts review samples into label *candidates*
  (never ground truth) so the review queue can grow the corpus.
- src/eval/ocrEval.test.ts + reviewSampleCorpus.test.ts: gate (must stay 1.0) and
  converter unit tests.
- npm run eval script; docs/ocr-eval.md; ADR-007/008/009.

Also records the agreed rework direction: C# input/capture sidecar (ADR-008) and
resolution-anchored layout profiles + OCR preprocessing (ADR-009).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-05 20:41:30 +02:00

57 lines
1.8 KiB
JSON

{
"name": "genshin-artifact-assistant",
"version": "0.1.0",
"private": true,
"description": "Local Windows assistant for scanning Genshin artifacts and suggesting no-brainer builds.",
"main": "dist-electron/main.js",
"type": "module",
"scripts": {
"predev": "powershell -NoProfile -ExecutionPolicy Bypass -File scripts\\kill-stale-instances.ps1 && tsc -p tsconfig.electron.json && copy electron\\preload.cjs dist-electron\\preload.cjs",
"dev": "concurrently -k \"vite --host 127.0.0.1\" \"wait-on tcp:5173 && cross-env VITE_DEV_SERVER_URL=http://127.0.0.1:5173 electron .\"",
"dev:admin": ".\\dev-admin.cmd",
"build": "tsc && vite build && tsc -p tsconfig.electron.json && copy electron\\\\preload.cjs dist-electron\\\\preload.cjs",
"preview": "vite preview --host 127.0.0.1",
"start": "electron .",
"lint": "tsc --noEmit",
"test": "vitest run",
"eval": "vitest run src/eval/ocrEval.test.ts",
"data:genshin": "node scripts/generate-genshin-data.cjs"
},
"dependencies": {
"@vitejs/plugin-react": "^4.3.4",
"electron": "33.2.1",
"genshin-db": "^5.2.12",
"lucide-react": "^0.468.0",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"tesseract.js": "^7.0.0",
"vite": "^6.0.3"
},
"devDependencies": {
"@types/node": "^22.10.2",
"@types/react": "^18.3.17",
"@types/react-dom": "^18.3.5",
"concurrently": "^9.1.0",
"cross-env": "^7.0.3",
"typescript": "^5.7.2",
"vitest": "^2.1.8",
"wait-on": "^8.0.1"
},
"build": {
"appId": "local.genshin.artifact-assistant",
"productName": "Genshin Artifact Assistant",
"directories": {
"output": "outputs/dist"
},
"files": [
"dist/**/*",
"dist-electron/**/*",
"package.json"
],
"win": {
"target": "nsis",
"requestedExecutionLevel": "requireAdministrator"
}
}
}