feat(tradein): estimator deals tier (PR M, #564 Phase 3) #600
No reviewers
Labels
No labels
admin
analytics
auth
automation
bug
business
chore
ci
compliance
data
data-moat
docs
duplicate
dx
enhancement
Fable 5 ревью
feedback/max
generative
GG-форсайт
needs-discussion
needs-human
observability
pause-bots
performance
priority/p0
priority/p1
priority/p2
priority/p3
scope/backend
scope/db
scope/devops
scope/frontend
scope/qa
scrapers
security
site-finder
stage/1
stage/2
status/blocked
status/done
status/needs-analysis
status/needs-fix
status/qa
status/ready
status/review
status/wip
tech-debt
tradein
ux
week ревью 1
wontfix
вторичка
ИРД
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: lekss361/gendesign#600
Loading…
Add table
Reference in a new issue
No description provided.
Delete branch "feat/tradein-estimator-deals-tier"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Закрывает финальную фазу #564. Estimator теперь возвращает tier classification для каждой rosreestr-сделки в
actual_dealsoutput.Changes
schemas/trade_in.py:AnalogLot.tier: str | None(T0_per_house / T1_per_street)services/estimator.py:_deal_to_analogcomputes tier через kadastr_num heuristic_fetch_dealsSQL includekadastr_numReality check
Open dataset Росреестра имеет
kadastr_num=NULLдля всех 49,791 ДКП → все классифицируются T1_per_street. Поле зарезервировано на случай ЕГРН direct feed в будущем.Tests
Closes #564.
Remove stale NOTE 2026-05-24 + add tier field на AnalogLot. - schemas/trade_in.py: AnalogLot добавлено поле `tier: str | None` ('T0_per_house' / 'T1_per_street' — для rosreestr deals) - services/estimator.py: * _deal_to_analog: compute tier via kadastr_num heuristic ('66:41:0204016:10' → T0; '66:41:...:0' OR NULL → T1) * estimate_quality docstring: replaced устаревший NOTE с corrected explanation что importer (PR-A 2026-05-24) уже фильтрует doc_type='ДКП' и deals идут в actual_deals output * _fetch_deals SQL: include kadastr_num в SELECT (для tier classify) Observation: open dataset Росреестра (current state) имеет kadastr_num=NULL для всех 49,791 ДКП-сделок → все классифицируются как T1_per_street. Поле зарезервировано на случай будущего ЕГРН direct feed. Tests: ruff clean, services/ pytest 19/19 pass. Closes #564 Phase 3.