feat: implement full arch design dashboard #1

Open
openclaw wants to merge 38 commits from feat/full-implementation into main
3 changed files with 55 additions and 0 deletions
Showing only changes of commit e523d5b31c - Show all commits

View File

@ -0,0 +1,18 @@
from dataclasses import dataclass
from datetime import datetime
@dataclass
class ImplProgress:
module_id: str
percentage: float # 0-100
source: str # auto, llm, manual
evaluated_at: datetime
@dataclass
class CodeStructure:
root_path: str
directories: list[str]
files: list[str]
matched_modules: list[str]

View File

@ -0,0 +1,33 @@
from pathlib import Path
from app.modules.impl_tracker.domain.entities import CodeStructure
from app.modules.scanner.domain.entities import ScanResult
def scan_code_directory(code_dir: str, scan_result: ScanResult) -> CodeStructure:
root = Path(code_dir)
if not root.is_dir():
return CodeStructure(root_path=code_dir, directories=[], files=[], matched_modules=[])
directories = []
files = []
for p in sorted(root.rglob("*")):
rel = str(p.relative_to(root))
if p.is_dir():
directories.append(rel)
elif p.is_file():
files.append(rel)
# Match modules by checking if code_root from CodebaseAlignment exists
matched = []
for alignment in scan_result.codebase_alignments:
code_root = alignment.code_root
if (root / code_root).exists():
matched.append(alignment.module_id)
return CodeStructure(
root_path=code_dir,
directories=directories,
files=files,
matched_modules=matched,
)

View File

@ -0,0 +1,4 @@
class LlmClient:
def evaluate_module(self, module_design: str, module_code: str) -> float:
"""Stub: returns 0.0. Real implementation would call LLM API."""
return 0.0