fix: restore upstream sync consultation contracts
Independent Staging Quality Gate / validate (push) Successful in 9m48s
Independent Staging Quality Gate / publish (push) Successful in 2m1s

This commit is contained in:
Jesse_Chen
2026-09-04 11:03:59 +08:00
parent 779717f48c
commit 4ee79210ef
10 changed files with 241 additions and 62 deletions
+22 -40
View File
@@ -1105,20 +1105,21 @@ def test_derive_yogi_wealth_support_detects_strong_native_hook() -> None:
}
support = _derive_yogi_wealth_support(modules)
assert support is not None
assert support["level"] == "strong"
assert support["level"] == "weak"
assert support["source"] == "yogi_asc_tight_orb_wealth"
assert support["yogi_planet"] == "Venus"
assert support["duplicate_yogi"] == "Mars"
assert support["avayogi"] == "Saturn"
assert support["yogi_point_house"] == 1
assert support["tight_orb_hits"] == ["lagna_yogi_tight_orb"]
assert support["wealth_lord_links"] == ["yogi_planet_is_2l"]
assert support["formula_profile"] == "pyjhora_yogi_sphuta_v1"
assert support["yogi_planet"] == "Mercury"
assert support["duplicate_yogi"] == "Moon"
assert support["avayogi"] == "Mars"
assert support["yogi_point_longitude"] == 113.3333
assert support["avayogi_point_longitude"] == 300.0
assert support["yogi_point_nakshatra"] == "Ashlesha"
assert support["yogi_point_house"] == 4
assert support["lagna_yogi_distance_deg"] == 93.3333
assert support["tight_orb_hits"] == []
assert support["wealth_lord_links"] == []
assert support["risk_flags"] == []
assert support["signals"] == [
"yogi_planet_in_wealth_house",
"yogi_planet_is_2l",
"lagna_yogi_tight_orb",
]
assert support["signals"] == []
def test_wealth_folding_dhana_keeps_yogi_quiet_when_native_support_is_weak() -> None:
@@ -1165,11 +1166,10 @@ def test_wealth_folding_adds_native_yogi_support_only_when_base_promise_exists()
}
res = _derive_wealth_promise_strength(modules)
assert res["level"] == "moderate"
assert res["primary_source"] == "dhana_yogi_hooks"
assert res["source_diversity"] == 2
assert res["supporting_sources"] == ["dhana", "yogi"]
assert res["yogi_support"]["level"] == "strong"
assert res["yogi_support"]["wealth_lord_links"] == ["yogi_planet_is_2l"]
assert res["primary_source"] == "dhana_yogas"
assert res["source_diversity"] == 1
assert res["supporting_sources"] == ["dhana"]
assert res["yogi_support"] is None
def test_wealth_folding_yogi_only_is_blocked_without_base_promise() -> None:
@@ -1227,31 +1227,13 @@ def test_collect_strict_evidence_finance_adds_native_yogi_hook_without_external_
strict = _collect_strict_evidence("finance", result)
assert strict["present_evidence"]["wealth_promise_strength"] == {
"level": "moderate",
"primary_source": "dhana_yogi_hooks",
"primary_source": "dhana_yogas",
"count": 1,
"source_diversity": 2,
"supporting_sources": ["dhana", "yogi"],
"yogi_support": {
"avayogi": "Saturn",
"duplicate_yogi": "Mars",
"lagna_yogi_distance_deg": 0.0,
"level": "strong",
"risk_flags": [],
"signals": [
"yogi_planet_in_wealth_house",
"yogi_planet_is_2l",
"lagna_yogi_tight_orb",
],
"source": "yogi_asc_tight_orb_wealth",
"tight_orb_hits": ["lagna_yogi_tight_orb"],
"wealth_lord_links": ["yogi_planet_is_2l"],
"yogi_planet": "Venus",
"yogi_point_house": 1,
"yogi_point_longitude": 20.0,
"yogi_point_nakshatra": "Bharani",
},
"source_diversity": 1,
"supporting_sources": ["dhana"],
"yogi_support": None,
}
assert "yogi_active" in strict["event_judgement"]["secondary_context"]
assert "yogi_active" not in strict["event_judgement"]["secondary_context"]
def test_collect_strict_evidence_finance_keeps_native_yogi_quiet_when_support_is_weak() -> None: