Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion cli/assets/scripts/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ def __init__(self, k1=1.5, b=0.75):
def tokenize(self, text):
"""Lowercase, split, remove punctuation, filter short words"""
text = re.sub(r'[^\w\s]', ' ', str(text).lower())
return [w for w in text.split() if len(w) > 2]
return [w for w in text.split() if len(w) > 1]

def fit(self, documents):
"""Build BM25 index from documents"""
Expand Down
3 changes: 2 additions & 1 deletion cli/assets/scripts/design_system.py
Original file line number Diff line number Diff line change
Expand Up @@ -504,7 +504,8 @@ def persist_design_system(design_system: dict, page: str = None, output_dir: str
base_dir = Path(output_dir) if output_dir else Path.cwd()

# Use project name for project-specific folder
project_name = design_system.get("project_name", "default")
project_name = design_system.get("project_name")
project_name = project_name if project_name is not None else "default"
project_slug = project_name.lower().replace(' ', '-')

design_system_dir = base_dir / "design-system" / project_slug
Expand Down
2 changes: 1 addition & 1 deletion src/ui-ux-pro-max/scripts/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ def __init__(self, k1=1.5, b=0.75):
def tokenize(self, text):
"""Lowercase, split, remove punctuation, filter short words"""
text = re.sub(r'[^\w\s]', ' ', str(text).lower())
return [w for w in text.split() if len(w) > 2]
return [w for w in text.split() if len(w) > 1]

def fit(self, documents):
"""Build BM25 index from documents"""
Expand Down
3 changes: 2 additions & 1 deletion src/ui-ux-pro-max/scripts/design_system.py
Original file line number Diff line number Diff line change
Expand Up @@ -504,7 +504,8 @@ def persist_design_system(design_system: dict, page: str = None, output_dir: str
base_dir = Path(output_dir) if output_dir else Path.cwd()

# Use project name for project-specific folder
project_name = design_system.get("project_name", "default")
project_name = design_system.get("project_name")
project_name = project_name if project_name is not None else "default"
project_slug = project_name.lower().replace(' ', '-')

design_system_dir = base_dir / "design-system" / project_slug
Expand Down