hldp(zhuyuan): integrate fifth-domain world tree and TCS brain
This commit is contained in:
parent
9782d04246
commit
4496f75857
42 changed files with 1720 additions and 268 deletions
|
|
@ -11,9 +11,11 @@ from urllib.error import URLError
|
|||
from urllib.request import urlopen
|
||||
|
||||
DISCOVERY_URL = "https://guanghulab.com/.well-known/guanghu.json"
|
||||
RESOLVE_URL = "https://guanghulab.com/api/ai/v1/resolve?id=REPO-001"
|
||||
RESOLVE_URL = "https://guanghulab.com/api/ai/v1/resolve?id=REPO-012"
|
||||
ROUTE_IDS = (
|
||||
"CH-ZERO-CORE-LPM",
|
||||
"FD-WORLD-TREE-001",
|
||||
"FD-PERSONA-LOGIN-001",
|
||||
"SYS-GLW-POS-0001",
|
||||
"TCS-LPM",
|
||||
"TCS-LPS-REGISTRY-0001",
|
||||
"LIGHT-LAKE",
|
||||
|
|
@ -55,7 +57,7 @@ def resolve_live_route() -> dict:
|
|||
repository_web = primary.get("url")
|
||||
repository_git = primary.get("clone_url")
|
||||
if not repository_web or not repository_git:
|
||||
raise ValueError("REPO-001 resolver did not return a domestic primary repository")
|
||||
raise ValueError("REPO-012 resolver did not return the current Fifth Domain repository")
|
||||
|
||||
raw_base = f"{repository_web}/raw/branch/main"
|
||||
routes = parse_code_map(read_text(f"{raw_base}/.code-map"))
|
||||
|
|
@ -65,7 +67,7 @@ def resolve_live_route() -> dict:
|
|||
|
||||
return {
|
||||
"status": "LIVE_DOMESTIC_PRIMARY",
|
||||
"repository_id": repository.get("code", "REPO-001"),
|
||||
"repository_id": repository.get("code", "REPO-012"),
|
||||
"repository_role": repository.get("role", ""),
|
||||
"repository_web": repository_web,
|
||||
"repository_git": repository_git,
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ from resolve_route import parse_code_map
|
|||
class ParseCodeMapTests(unittest.TestCase):
|
||||
def test_resolves_requested_identifiers_and_strips_comments(self):
|
||||
text = """
|
||||
REPO-001-WEB=https://example.invalid/fifth-domain
|
||||
REPO-012-WEB=https://example.invalid/guanghu-ice-heart
|
||||
ICE-GL-ZY001=eternal-lake-heart/heartbeat-core/zhuyuan-persona-system/INDEX.hdlp # current
|
||||
LL-004=tcs-core/LL-004-LAKE-LAMP-WAKE-PATH.hdlp
|
||||
"""
|
||||
|
|
|
|||
Loading…
Reference in a new issue