fix(consult): run the local skill's full technique spectrum on the web path
Independent Staging Quality Gate / validate (push) Successful in 10m59s
Independent Staging Quality Gate / publish (push) Successful in 9m7s

Web answers were thinner than a local Agent calling yinduzhanxing-skill:
theme-subset vargas, no visible audit table, and a prompt that dropped the
invocation contract. Bind the commercial method, compute D1–D60 plus Western
layers, and deliver the same Full-Spectrum checklist.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Jesse_Chen
2026-08-18 23:30:36 +08:00
co-authored by Cursor
parent d04fc30b63
commit 2bf7472645
29 changed files with 1176 additions and 191 deletions
+37 -7
View File
@@ -342,17 +342,19 @@ class UnifiedConsultationOrchestrator:
if code not in selected:
selected.append(code)
formal = [f"D{division}" for division in FORMAL_DIVISIONS]
research = [f"D{division}" for division in range(2, 61) if division not in FORMAL_DIVISIONS]
return {
"question": question or "",
"themes": normalized_themes,
"presentation_mode": "research" if is_research else "default",
"appendix_expanded": is_research,
"varga_dispatch": {
"mode": "on_demand",
"mode": "full_spectrum",
"selected_theme_vargas": selected,
"all_formal_vargas": formal,
"deferred_vargas": [code for code in formal if code not in selected],
"rule": "先调用与主题直接相关的分盘;其余正式分盘只在追问或冲突时展开。",
"research_dn_vargas": research,
"deferred_vargas": [],
"rule": "主题相关分盘优先解读;D1–D60 正式分盘与其余 D-N 研究分盘均已计算,未计算的标 blocked,不得静默省略。",
},
}
@@ -566,6 +568,20 @@ class UnifiedConsultationOrchestrator:
return "official_verified"
return "official_blocked"
@staticmethod
def _named_varga_chart(varga: dict[str, Any], division: int) -> Any:
exact = f"D{division}"
if exact in varga:
return varga[exact]
prefix = f"D{division}_"
for key, value in varga.items():
if not isinstance(key, str) or not key.startswith(prefix):
continue
rest = key[len(prefix):]
if rest and not rest[0].isdigit():
return value
return None
@staticmethod
def _section(value: Any, source_path: str) -> dict[str, Any]:
present = bool(value)
@@ -687,10 +703,10 @@ class UnifiedConsultationOrchestrator:
base_chart.get("planets") and base_chart.get("ascendant"),
"chart.planets+chart.ascendant",
),
"D9": self._section(varga.get("D9_Navamsa") or varga.get("D9"), "modules.varga_full.D9"),
"D10": self._section(varga.get("D10_Dasamsa") or varga.get("D10"), "modules.varga_full.D10"),
"D2": self._section(varga.get("D2_Hora") or varga.get("D2"), "modules.varga_full.D2"),
"D4": self._section(varga.get("D4_Chaturthamsa") or varga.get("D4"), "modules.varga_full.D4"),
"D9": self._section(self._named_varga_chart(varga, 9), "modules.varga_full.D9"),
"D10": self._section(self._named_varga_chart(varga, 10), "modules.varga_full.D10"),
"D2": self._section(self._named_varga_chart(varga, 2), "modules.varga_full.D2"),
"D4": self._section(self._named_varga_chart(varga, 4), "modules.varga_full.D4"),
"planet_degrees": self._section(base_chart.get("planets"), "chart.planets"),
"house_degrees": self._section(base_chart.get("houses") or chart_data.get("houses"), "chart.houses"),
"dasha_boundaries": self._section(modules.get("dasha") or chart_data.get("dasha"), "modules.dasha"),
@@ -732,6 +748,20 @@ class UnifiedConsultationOrchestrator:
"vedastro_gateway.archives",
),
}
for division in FORMAL_DIVISIONS:
if division == 1:
continue
key = f"D{division}"
if key not in sections:
sections[key] = self._section(
self._named_varga_chart(varga, division),
f"modules.varga_full.{key}",
)
spectrum = modules.get("varga_spectrum") if isinstance(modules.get("varga_spectrum"), dict) else {}
sections["varga_spectrum"] = self._section(
spectrum if spectrum.get("status") == "used" else None,
"modules.varga_spectrum",
)
missing = [name for name, section in sections.items() if section.get("status") == "missing"]
signals = chart_data.get("cross_system_signals")
if not isinstance(signals, list):