Data to identification to display. A scan becomes a CardTraits object, the traits run through rules and vector matching, an LLM verifies, and a FeatureCard displays the verdict. This page is the interactive demo of that strategy.
One typed object carries every visual and metadata trait. Required fields are plain. Optional fields carry a question mark. Arrays hold color data. The form below builds this exact object.
interface CardTraits {
player: string;
year: string;
set: string;
series?: string;
manufacturer: string;
cardNumber: string;
team: string;
conditionGrade?: string;
serialNumbered?: string;
parallelType?: string;
autograph?: boolean;
cutout?: boolean;
redemption?: boolean;
borderStyle?: string;
borderColors?: string[];
colorCombos?: string[];
multicolorStripes?: string[];
sparkles?: boolean;
foil?: boolean;
refractorType?: string;
imageHash?: string; // For similarity match
slabbed?: boolean;
gradingCompany?: string;
grade?: string;
population?: number;
}
Fill any fields. Text lists take comma separated values. Empty fields are left out of the JSON. Load the LeBron refractor example to see a complete object.
Fill the form and generate the JSON. The object appears here.
The engine does not just name a card. It says: this is the 2003 Topps Chrome #111 LeBron James RC Refractor PSA 10 Pop 49, not the base Chrome and not a reprint. Three steps: scan to traits, rules plus vector matching, final verdict.
Pick a sample scan. OCR reads player, year, team, and set. Computer vision reads border type, colorway, serial, and parallel. Embedding matches the visual fingerprint to known card images. All three stages are simulated here.
No scan run yet.
Extracted traits appear here as a table.
Similarity is trait overlap against the 6 seeded synthetic cards: matched fields divided by compared fields, as a percentage. Rules run after matching. A hard rule violation caps confidence and flags the card.
Seeded card database (synthetic, 6 cards):
| ID | Card | Parallel | Slab | Note |
|---|---|---|---|---|
| LEB-2003-TC-111-REF | 2003 Topps Chrome #111 LeBron James RC | Refractor | PSA 10, Pop 49 | Source worked example. Pop 49 is the source claim. |
| LEB-2003-TC-111-BASE | 2003 Topps Chrome #111 LeBron James RC | Base | Raw | Same card, base parallel. Not the refractor. |
| LEB-2003-TC-111-REPRINT | 2003 Topps Chrome #111 LeBron James RC | Reprint | Raw | Unauthorized reprint. Foil pattern and stock differ. |
| LEB-2003-TC-111-FAKE | 2003 Topps Chrome #111 LeBron James RC | Refractor, signed | Raw | Fake or replica case. Refractor never came with a signature. |
| SYN-2003-001 | 2003 Sample Chrome #001 Alex Sample RC | Refractor | Raw | Fully synthetic card, for matching contrast. |
| SYN-2003-002 | 2003 Sample Base #002 Jordan Example | Base | Raw | Fully synthetic card, for matching contrast. |
Validation rules:
| Rule | Check | Result on violation |
|---|---|---|
| R1 | Refractor parallel plus autograph is true | Hard fail: this parallel never came with a signature. |
| R2 | Set is Topps Chrome plus cardNumber is 221 | Hard fail: card number 221 belongs to Topps Base, not Topps Chrome. |
| R3 | Parallel is Reprint plus a grade is present | Hard fail: a reprint presented as a graded original. |
| W1 | Foil is true plus parallel is Base | Warning: base parallel should not show foil. Possible misread or reprint. |
Run a scan in Step A first, or send traits from the form in Section 1. Matching results appear here.
Confidence is computed from the simulated pipeline: top similarity as a percentage, capped at 45 when a hard rule fails. Unsure when the top match is under 85 and no rule fails. No match when the top match is under 60.
No verdict yet. Run Step B.
Evidence lines appear here after a verdict. Each line names the trait or rule that decided the call, so a human can override it or send it back for retraining.
Human override: if the verdict is wrong, correct it in the Admin Feedback UI in Section 7. The correction enters the retrain queue and the learning loop in Section 5 picks it up on the next nightly retrain.
The source says the FeatureCard holds the visual and display layer. A workspace search for FeatureCard across ts, tsx, jsx, js, html, and md files returned zero matches. No prior FeatureCard was found on disk, so this is the first implementation. It renders the current verdict.
No card identified yet. Run the Intelligence Engine in Section 2 and the FeatureCard renders here.
The backend and infrastructure model from the source, drawn as steps. The retrain loop feeds back from the verdict into the matching engine.
Store every scan, mark it successful or unsure, correct it when wrong, and retrain nightly with that feedback. Accuracy starts at 84.0 percent. Each correction applied in a retrain adds 0.6 points, capped at 99.0. Each retrain applies one update type in rotation: new checklists, pop reports, fakes and replicas, obscure parallels.
Scans stored: 0. Successful: 0. Unsure: 0. Wrong: 0. Corrections queued: 0. Nights retrained: 0. Accuracy: 84.0%.
| Night | Corrections applied | Update type | Accuracy after |
|---|---|---|---|
| No retrains yet. | |||
Update types in rotation: new checklists, pop reports, fakes and replicas, obscure parallels. New releases arrive by web scraping in the production design; this demo uses seeded data only.
The stack from the source, layer by layer. This demo is the frontend behavior only. The backend pieces below are the production design, not running systems.
| Layer | Stack | Role |
|---|---|---|
| Frontend | React plus Tailwind | FeatureCard display, trait forms, scan upload |
| Backend | FastAPI or Node.js | Extractor microservice, similarity endpoint, feedback API |
| Database | Postgres plus Pinecone or Weaviate | CardTraits records plus vector embeddings |
| Model | CLIP plus custom LLM plus Vision Transformer | Embedding match, trait validation, reasoning |
| Dev stack | Vite, Supabase, LangChain | Build, auth and storage, pipelines |
Each idea from the source, built as a runnable mini-tool. All of them run against the same 6 seeded synthetic cards.
Accepts a scan, returns a trait object. Simulated endpoint: POST /v1/extract.
Response appears here.
Compare traits plus image to the closest matches. Simulated endpoint: GET /v1/similar. Ranked by trait overlap.
Ranked matches appear here.
Correct a mistake and it enters the retrain queue. The queue feeds the learning loop in Section 5.
| Scan | Engine said | Correct card | |
|---|---|---|---|
| SCAN-003 | LeBron Refractor (wrong) | ||
| SCAN-004 | LeBron Refractor (wrong) | ||
| SCAN-002 | LeBron Base (wrong) |
Retrain queue: 0 corrections waiting. Submit a correction to add one.
Runs a batch of 100 seeded synthetic scans and finds inconsistencies. Deterministic by construction: scans 1 to 70 are exact copies of seeded cards, scans 71 to 85 have the parallel perturbed, scans 86 to 100 have an autograph injected on a refractor, which trips rule R1. Expected counts: 70 correct, 15 unsure, 15 flagged, 15 inconsistencies found, 70.0 percent accuracy.
Results appear here.
Pricing is simulated with a toy formula. No live Ludex or eBay data. Formula: base 100 times grade, plus 500 for Refractor, plus 200 for a rookie card. Low is 90 percent of value, high is 110 percent.
Simulated estimate appears here. This is not a market price.