CI and images / lint (push) Successful in 2s
CI and images / extension-version (push) Successful in 3s
CI and images / extension-test (push) Successful in 20s
CI and images / frontend-build (push) Successful in 23s
CI and images / backend-lint-and-test (push) Successful in 32s
CI and images / integration (push) Successful in 2m24s
CI and images / sign-extension (push) Successful in 3s
CI and images / build-agent (push) Successful in 5s
CI and images / build-web (push) Successful in 1m35s
CI and images / smoke-web (push) Successful in 56s
CI and images / promote (push) Successful in 1s
The soft tier (#1474) tagged `wip` on any post titled sketch, doodle or scribble: 6,096 of the library's 8,876 wip tags. Its conflict audit flagged most of them, because finished art scores >= 0.5 on some content head, which filled the Gallery strip with 2,086 cards. A "sketch" is usually finished work, so the operator retired the tier. The artist's own "WIP" / "work in progress" title rule and human wip tags stay. - Removed: the soft matcher, source and prefilter; the importer and backfill soft branches; soft_wip_conflict_audit with its task and beat; the wip_soft_title_tagging_enabled setting, API field and toggle; and wip_title_soft from _AUTO_SOURCES. - Migration 0112: a soft tag the operator confirmed, or kept from the strip, becomes `manual`. Every other soft tag is deleted, along with the open review cards whose tag is gone. The column is dropped. - Review strip (#4424): each card asks "Is this a WIP?" (or banner, and so on), and the buttons read "Is a WIP" / "Is not a WIP". The content tag it also scored on is shown as the reason it was flagged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01LVjrnpQjRgHdvq95rASoiR
51 lines
1.7 KiB
Python
51 lines
1.7 KiB
Python
"""Title-based WIP matcher (task #1458) — pure unit tests for
|
|
``matches_wip_title``, the precision-first heuristic that decides whether a post
|
|
title explicitly declares work-in-progress. No DB, no network.
|
|
|
|
Precision matters more than recall here: a false positive applies the ``wip``
|
|
system tag, which HIDES a finished post from the Explore browse — so the
|
|
negative cases (substrings like ``swipe`` / ``wiped``) are the load-bearing ones.
|
|
"""
|
|
import pytest
|
|
|
|
from backend.app.services.wip_title import matches_wip_title
|
|
|
|
|
|
@pytest.mark.parametrize("title", [
|
|
"WIP",
|
|
"wip",
|
|
"WiP",
|
|
"Nami Heroines - WIP Part 1", # the real-world example from the gate work
|
|
"sketch (WIP)",
|
|
"[WIP] new piece",
|
|
"WIP: colour test",
|
|
"cool art WIP2", # trailing digit = "WIP part 2", still WIP
|
|
"W.I.P.",
|
|
"W.I.P",
|
|
"work in progress",
|
|
"Work In Progress",
|
|
"commission work-in-progress",
|
|
"big_project_work_in_progress",
|
|
"final touches, wip",
|
|
])
|
|
def test_matches_positive(title):
|
|
assert matches_wip_title(title) is True
|
|
|
|
|
|
@pytest.mark.parametrize("title", [
|
|
None,
|
|
"",
|
|
"a quick swipe left", # 'wip' inside swipe — must NOT match
|
|
"she wiped the counter", # wiped
|
|
"wiping down the desk", # wiping
|
|
"unwiped surface",
|
|
"progressive rock cover", # 'progress' inside progressive, no 'work in'
|
|
"workin on it", # not the full phrase
|
|
"finished at last",
|
|
"Kawips diner", # 'wip' mid-word
|
|
"swipright",
|
|
"quick sketch of Nami", # soft cue — NOT a HARD WIP match
|
|
])
|
|
def test_matches_negative(title):
|
|
assert matches_wip_title(title) is False
|