Skip to content

Commit f26abde

Browse files
committed
configurable ui set path
1 parent f7bd4a3 commit f26abde

2 files changed

Lines changed: 6 additions & 4 deletions

File tree

src/swarm_notes/config.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,9 @@ class Settings(BaseModel):
136136
# Data files
137137
taxonomy_file: Path = Field(default=REPO_ROOT / "vault" / "taxonomy.json")
138138
public_feed_file: Path = Field(default=REPO_ROOT / "public_feed.json")
139+
site_config_file: Path = Field(
140+
default=REPO_ROOT / "swarm-notes-ui" / "src" / "content" / "site-config.json"
141+
)
139142

140143
# LLM keys and model
141144
llm_api_key: str = Field(default_factory=lambda: os.environ.get("LLM_API_KEY", ""))
@@ -169,7 +172,7 @@ class Settings(BaseModel):
169172
# Experimental features
170173
enable_domain_expert: bool = False
171174

172-
# Site identity (written to website/src/content/site-config.json)
175+
# Site identity (written to site_config_file)
173176
site_name: str = "Swarm Notes"
174177
site_description: str = "Automated research paper tracking and knowledge synthesis."
175178

src/swarm_notes/vault_writer.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -437,7 +437,7 @@ def update_public_feed(analyses: list[PaperAnalysis]) -> None:
437437

438438

439439
def write_site_config() -> None:
440-
"""Write site identity metadata to ``website/src/content/site-config.json``.
440+
"""Write site identity metadata to ``settings.site_config_file``.
441441
442442
The JSON file is read by the Astro website at build time to populate the
443443
hero section with the deployment-specific name, description, and tracked
@@ -455,8 +455,7 @@ def write_site_config() -> None:
455455
updated_at : str
456456
ISO-8601 UTC timestamp of the last pipeline run.
457457
"""
458-
repo_root = Path(__file__).parent.parent.parent.resolve()
459-
out_path = repo_root / "website" / "src" / "content" / "site-config.json"
458+
out_path = settings.site_config_file
460459
out_path.parent.mkdir(parents=True, exist_ok=True)
461460

462461
payload = {

0 commit comments

Comments
 (0)