Commit ·
6ded0ab
1
Parent(s): f2930ce
logs
Browse files
README.md
CHANGED
|
@@ -164,4 +164,34 @@ Requires a built vector index at `data/processed/index/`. See
|
|
| 164 |
|
| 165 |
This app surfaces public salary statistics and the published text of EU
|
| 166 |
Directive 2023/970. It is **not legal advice**. For binding interpretation,
|
| 167 |
-
talk to your union or a lawyer.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 164 |
|
| 165 |
This app surfaces public salary statistics and the published text of EU
|
| 166 |
Directive 2023/970. It is **not legal advice**. For binding interpretation,
|
| 167 |
+
talk to your union or a lawyer.
|
| 168 |
+
|
| 169 |
+
# Development log
|
| 170 |
+
|
| 171 |
+
### Jun 9 — Setup
|
| 172 |
+
Created the Hugging Face Space inside `build-small-hackathon`, joined the org, downloaded the EU Directive 2023/970 and the salary statistics PDF. Scoped v1 to Danish engineers under IDA (the engineer union) only; Djøf (white-collar jobs union) and France left as future work. Wired in ML-Intern, and Gradio Server as the core stack.
|
| 173 |
+
|
| 174 |
+
### Jun 10 — Knowledge extraction
|
| 175 |
+
Sent ML-Intern to parse both sources on HF Jobs (a10g-large GPU):
|
| 176 |
+
- **EU Directive** — Nemotron Parse over rasterized pages → 24 pages, 366 elements, JSON-Schema validated. Caught and removed the `TableInsertionLogitsProcessor`, which was forcing tabular output and mangling prose recitals into fake tables.
|
| 177 |
+
- **IDA + Djøf lønstatistik** — separate extractors (lattice for IDA, header-anchored for Djøf's borderless tables), normalized into typed records with derived experience years and citation-bearing RAG text. 266 non-salary rows dropped during cleanup.
|
| 178 |
+
|
| 179 |
+
Both outputs published as private HF Datasets.
|
| 180 |
+
|
| 181 |
+
### Jun 14 — Index and retrieval
|
| 182 |
+
Embedded all chunks on Modal (local CPU too slow for the Nemotron 1B encoder), assembled a FAISS `IndexFlatIP` locally. Hit HF's 10MB non-LFS file ceiling — installed git-lfs and shipped the 20MB `index.faiss` as a pointer.
|
| 183 |
+
|
| 184 |
+
### Jun 15 — RAG, frontend, chat
|
| 185 |
+
Four major pieces in one push:
|
| 186 |
+
1. **Dual-source Reciprocal Rank Fusion** — query the directive and IDA independently, fuse the ranked lists.
|
| 187 |
+
2. **Typed salary layer** — `IdaSalaryRecord` schema, `Profile` / `Dashboard` models, wildcard matching, specificity ranking, reliability-tier gating, 2026 temporal projection.
|
| 188 |
+
3. **Re-extracted IDA tables** with a panel-aware `pdfplumber` parser, recovering multi-axis data (region, gender × leadership, public position) that v1 had flattened — 559 records. This restored the gender pay-gap data, the core of the equal-pay feature. Biggest data win of the project.
|
| 189 |
+
4. **Custom frontend** — hand-authored HTML/CSS/JS SPA served by `gradio.Server` (no Gradio Blocks at the root), profile-driven dashboard with hand-drawn SVG visuals, Branch A (employed) and Branch B (job-seeking) onboarding flows, contextual rights chat. Sage/ink Scandinavian palette.
|
| 190 |
+
|
| 191 |
+
GPU warmup triggered on the first wizard answer so Tiny Aya is ready by the time the user reaches the chat. Added token streaming, then removed it for a cleaner single response.
|
| 192 |
+
|
| 193 |
+
### Jun 15–16 — The number bug
|
| 194 |
+
Salaries rendering ~10× too small. The small multilingual LLM was reading thousands separators as decimal points: first the Danish `47.010` → `4,701`, then the en-US `47,300` → `4,730` after switching format. Fix: bare integers with no separators in everything the model reads (`rag_text`, injected context), plus a "copy digits exactly" system instruction. Regenerated `chunks.jsonl` only — FAISS rows stayed aligned, so no re-embed needed.
|
| 195 |
+
|
| 196 |
+
### Jun 16 — Submission
|
| 197 |
+
Scrubbed a write token that had leaked into the git remote URL. Final README pass — motivation, IDA scope, Djøf and France as future work, track/sponsor/achievement tags, demo video, social links. Added a "coming soon: Djøf" dashboard banner. Last issue was a ZeroGPU container prestart-hook error on the Space — diagnosed as platform infrastructure (no code changes resolved it), fixed by a Factory reboot.
|