Skip to content

v0.0.7

Choose a tag to compare

@AlyShmahell AlyShmahell released this 18 Sep 12:09
· 4 commits to main since this release

Changelog

MatchMedia v0.0.7

  • match.prefer.anime is a typed-job auto-match hint only. Untyped scan/ingest never prefer, and job.candidates is always the full ranked list.
  • Displayed Score is scaled into [0, 1]: (J + title_lift · max(func, parentCov) + exact_lift · exact) / (1 + title_lift + exact_lift). Title-in-synopsis no longer fills Score to 1.0.
  • Auto-match adds a Score-leader path and a unique full-query-coverage path (nicknames and long official titles). solo_min_score is ignored.
  • Alias GETs run when any job title token is missing from the primary name (Spy×Family loads Spy x Family).
  • When Jaccard is already 1, synopsis/parent lift is omitted so identical titles are not reordered by a blurb ([Oshi no Ko] anime vs live action).
  • HTTP routes ServeMedia pins (POST /v1/scan, untyped POST /v1/ingest, poll GET /v1/jobs?session=) and skipDefer (Jaccard) are unchanged.
  • The release tarball is still binary, config/, public/, and LICENSE.

Prefer

  • prefer.anime (language: Japanese, kind: Animation) runs only when job.type is a key under match.prefer (ingest type: anime).
  • Rank always scores every provider hit. Prefer never deletes rows, so select can still pick a Scripted TVMaze title next to a Japanese Animation hit (The 100 vs The 100 Girlfriends).
  • Jikan still ships static attrs: { language: Japanese, kind: Animation } so typed anime prefer can see those hits.
  • A single prefer-shaped hit does not auto-match.

Ranking

Score is no longer J + (1 − J) · plot. After the same titleNorm (lowercase, strip non-alnum, no stemming):

  • Jaccard J is still the best |q ∩ t| / |q ∪ t| over the primary title and each title* attr.
  • Title-in-synopsis func is coverage of job title content tokens in the candidate synopsis (not plot-to-plot). Shared tokens in this result list are down-weighted (0.25).
  • exact is 1 when titleNorm of the job equals titleNorm of the primary title (aliases do not count).
  • Shipped title_lift / exact_lift are 0.15 / 0.25. Divide by 1 + title_lift + exact_lift so Score stays in [0, 1] without clamping.
  • When J == 1, func and parentCov are not added. Primary exact is (1 + exact_lift) / den (~0.89), not 1.0 from a synopsis token.

Sort is unchanged: content-token overlap, then Score, then title prefix, then Jaccard, then year.

Auto-match

job.candidates stays the full list. Auto-matched if:

  1. best max(Jaccard, Score) >= match.min_score and (one candidate, or that strength gap to second is >= match.min_margin), or
  2. best Score >= match.min_score and the Score gap to second is >= match.min_margin, or
  3. typed prefer, at least two prefer hits, best of those has queryCov == 1, and the Score gap to the next prefer hit is >= match.min_margin, or
  4. the job has a content token and exactly one work has queryCov == 1 and that row is ranked first.

Path 4 is for short nicknames (Anohana) and solo official titles with extra words (Apothecary Diaries, Berserk Memorial Edition). Provider clones that share the covering title (best-Jaccard primary/alias) and year count as one work (TVMaze + Jikan Banished). Season 2 or The Office US/UK stay manual. Girls vs Girls und Panzer still two works.

defer: true providers still run only if the fast pass is thin (fewer than match.min_hits or best Jaccard below match.min_score). A Jaccard auto-match on the fast pass skips defer. Unique queryCov is applied on the final ranked list so a weak TVMaze substring does not lock in before Jikan.

Aliases

  • Skip the extra titles GET only when the primary title already covers every job title token, not only content tokens (plot_stop / length < 3).
  • Stored aliases still must share a content token. Bookworm / Erased subset skips are unchanged.
  • Spy X Family vs TVMaze Spy×Family now fetches AKA Spy x Family, so Jaccard can be 1 via the alias.

Config

  • version: is 0.0.7.
  • New tunables: match.title_lift (shipped 0.15), match.exact_lift (shipped 0.25). Unset still defaults to those values.
  • match.solo_min_score is removed from shipped YAML and ignored if an overlay still has it.
  • Leave match.min_score / min_margin / match.workers, cooldown YAML, and provider defer / min_interval_ms / provider_timeout_ms as shipped in 0.0.6.

Upgrade notes

  • HTTP contract is unchanged. Rematch existing sessions if you want the new Score, prefer-not-filtering, and unique queryCov on old jobs (ranker: set is the same key; Score numbers are not).
  • Overlay data/config.yaml must not rely on prefer deleting non-anime rows, or on Score 1.0 from title-in-synopsis. Drop solo_min_score if present.
  • Scan jobs still have empty type. Western TV + anime-shaped hits stay on the same picker (The 100). Typed CSV type: anime still uses prefer for auto-match only.
  • Exact primary titles display ~0.89, not 1.0. Auto-match still uses max(Jaccard, Score), so Jaccard 1 still matches.
  • Unique queryCov can auto-match a unique official title below min_score. Two seasons or two years of the same covering title stay manual.