LEMO Catalogue Spec Assistant¶
Give OpenCode direct access to LEMO catalogue PDFs, build a structured spec database, and surface specs on the storefront as a product-page spec table driven by Shopify metafields. Status: B Series in progress (K series deferred). Started 2026-07-11.
Concept¶
The 11 LEMO catalogue PDFs live in /home/dini/vault/catalogues/ and are extracted to searchable text in catalogues/text/. OpenCode reads them directly (replaces manual NotebookLM lookups), and the parsed specs become the source of truth for storefront spec tables and tag generation.
Data pipeline (done)¶
- 11 PDFs →
catalogues/text/*.txtviapdftotext -layout; index incatalogues/INDEX.md. - Verified dataset:
catalogues/specs/b_series_multipole.json= 74 unique B-series multipole(shell_size, insert_config)records. Per-size counts match source exactly (0B:7, 1B:10, 2B:15, 3B:16, 4B:11, 5B:13, XB:2). - Human reference:
catalogues/specs/b_series_multipole.md. Parser:/tmp/opencode/parse_bkt.py(source table =BKT_series.txtlines 4268–4760). - Fields per record: series, shell_size, insert_config, contact_count, contact_diameter_mm, terminations (solder/crimp/pcb_straight/pcb_elbow), wire_gauge_awg_range, test_voltage_kv, rated_current_a.
Part-number join key¶
- LEMO grammar:
MODEL.SIZE+SERIES.INSERTCFG.HOUSING-INSULATOR-CONTACT-COLLET.CABLEØ(e.g.FGG.1B.306.CLAD62). Insert-config last 2 digits = contact count. - Store SKU =
LEM.<LEMO_PART_NO>(e.g.LEM.ECG1B302CLL). Inserts matchLEM.<MODEL><SIZE>B<3-digit-config>...; accessories use100/200codes.
Storefront spec table (Dawn theme — local files only, not yet pushed)¶
snippets/spec-table.liquid— renders a styled table fromproduct.metafields.specs.*; only shows wheninsert_configis set.sections/main-product.liquid— newspec_sheetblock (loop case + schema; heading setting).templates/product.lemo-product.json—spec_sheetblock instance afterdescription(this is the template in use).- Visual preview:
catalogues/specs/spec-preview.html(real302data — confirmed OK).
Metafields (live on store)¶
Namespace specs (additive; separate from the existing custom.* fields). Keys: series, shell_size, insert_config, contact_count, contact_diameter_mm, wire_gauge_awg, rated_current_a, test_voltage_kv, termination_solder, termination_crimp, termination_pcb_straight, termination_pcb_elbow.
Written via Shopify MCP update-product (accepts metafields[]). Done for 7 sample 1B products: ECG1B302/304/306/308/316 CLL, EEG1B302CLL, EAG1B316CLN.
Blockers / gotchas¶
- Data: store sells
LEM.ECG1B310CLL(10-pin 1B) but the catalogue has no1B.310(310 is 3B-only). Skipped pending decision. - MCP:
get-productshas no cursor (can't page whole catalog);get-product-by-iddoesn't return metafields;update-productdoes write metafields. - Theme deploy: Shopify (2025) blocks
themeCreate/themeFilesUpsertfor custom-app tokens without exemption → notheme push/create via theshpua_token.shopify theme devwith a token rejects--store-passworddespite the password (moyeem) being correct. Real preview needs an interactiveshopify theme devbrowser login from a local terminal.
Next steps¶
- Interactive
theme devlogin → verify the 7 samples render → bulk-write specs to all B inserts (per-sizesearchTitlebatches via MCPupdate-product). - Resolve
1B.310; then extend the pipeline to K series.
Relationship to Other Tools¶
- Drives the spec table on [[JBS LEMO Shopify Storefront]]; can also feed tag generation and the spec-to-tag workflow.
- Replaces manual NotebookLM spec lookups.