""" CatLLM brand CSS theme for the HuggingFace Space. Mirrors the catllm.com site palette and the desktop app: dark mode with teal (primary) and orange (secondary) accents, paired with IBM Plex Sans (display), DM Sans (body), and DM Mono (codes & metadata). Kept in sync with app/components/css.py — copy that file over when the desktop theme changes. """ import base64 import os import streamlit as st def inject_css(): """Inject the CatLLM CSS theme into the page.""" st.markdown(CSS, unsafe_allow_html=True) def _load_logo_uri(filename: str = "logo_mark.png") -> str: """Return a base64 data URI for the cat-shield mark, or empty string.""" path = os.path.join(os.path.dirname(__file__), filename) try: with open(path, "rb") as f: return "data:image/png;base64," + base64.b64encode(f.read()).decode("ascii") except FileNotFoundError: return "" LOGO_MARK_URI = _load_logo_uri() def render_wordmark(subtitle: str = "Research-grade text classification with LLMs"): """Render the CatLLM cat-shield + IBM Plex Sans wordmark + a short subtitle.""" st.markdown( f"""
CatLLM {subtitle}
""", unsafe_allow_html=True, ) CSS = """ """