Tag wiki fix

This commit is contained in:
2026-09-22 00:39:44 -07:00
parent 627ab3aec6
commit 43fbd8a834
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -20,7 +20,7 @@ MODEL_PRESETS_PATH = str(ROOT_DIR / "model_presets.toml")
RES_PRESETS_PATH = str(ROOT_DIR / "resolution_presets.toml")
TAG_DATABASE_PATH = str(ROOT_DIR / "danbooru.csv")
TAG_SEARCH_LIMIT = 20
ENABLE_TAG_WIKI = False
ENABLE_TAG_WIKI = True
DANBOORU_LOGIN = "" # Your Danbooru username (Optional)
DANBOORU_API_KEY = "" # Your Danbooru API key (Optional)
+1 -1
View File
@@ -67,7 +67,7 @@ async def _fetch_wiki_info(tag_name: str) -> Optional[str]:
if resp.status_code == 200:
data = resp.json()
wiki_body = data.get("wiki_page", {}).get("body")
wiki_body = data.get("body")
if wiki_body:
# Strip HTML tags for the LLM
return re.sub(r'<[^>]*>', '', wiki_body).strip()