Commit Graph

16 Commits

Author SHA1 Message Date
popovskik e12724bbd1 Bot pages: use root-relative links so they work on any host
The generated /links-for-bots/ pages linked to absolute https://msosorg.com/...
URLs, which 404 when the site is served from another host (e.g. local dev, or
before this branch is deployed). Switch the pages' navigation links to
root-relative (/llms.txt, /en/..., /links-for-bots/...). Canonical tags stay
absolute (SEO) and llms.txt keeps absolute URLs (llmstxt.org convention).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-05 18:18:32 +02:00
popovskik ac052c2b09 Bot pages: expose them in the footer under a "For bots" column
Previously /llms.txt and /links-for-bots/ existed but were not linked anywhere,
so users/bots couldn't find them. Following Proxify's pattern, add a "For bots"
footer column (all 225 pages, EN/MK/SI) linking to category link lists and an
AI summary page.

build_botlinks.py now also generates:
  /links-for-bots/blog|guide|projects/   per-section link lists (EN/MK/SI)
  /links-for-bots/about-msos/            "Hey AI, learn about us" summary
  /links-for-bots/  hub  +  /llms.txt

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-05 18:12:04 +02:00
popovskik d75dbc1edd Blog: add personal essay "How I coped with leaving home" (trilingual, prose)
Publish Vasil Handziski's personal essay in MK (original) with EN/SI AI-drafted
translations. Adds a prose article variant (no scrollspy sidebar, centred column,
custom byline) via .article-page--prose, plus blog index cards in all languages.
Converter now omits the "last checked" line when empty.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-05 17:37:14 +02:00
popovskik ae3f5e30c9 Blog: publish trilingual post 5 "Welcome Days" (EN/SI/MK)
Build the Welcome Days article in all three languages from the multilingual
source (# English / # Slovenščina / # Македонски sections + shared sources),
no machine translation. Date registered, SEO injected. Cards already existed.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-05 17:29:03 +02:00
popovskik 3fed4db226 Blog: post 6 "Accommodation" now trilingual (MK/SI AI-drafted)
Add Macedonian and Slovenian versions of the accommodation post (AI-drafted,
flagged for native review), rebuild EN with a proper Student Welcome Guide link
and a real Sources section, and add MK/SI blog index cards. Converter now treats
a secondary "# Sources" heading as a section.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-05 17:26:32 +02:00
popovskik c7481ca998 Blog: publish trilingual posts 2-4 in EN/MK/SI from source content
Build full articles for "Learning Slovene", "Study in North Macedonia
(government scholarship)" and "Ad futura scholarship" in all three languages,
split from the trilingual Markdown sources (no machine translation). Dates
registered in ARTICLE_DATES and SEO re-injected per page. Blog index cards for
these already existed and now point to real content instead of stubs.

Hero images are placeholders pending topical photos.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-05 17:16:17 +02:00
popovskik 9d53216b08 Blog: add markdown->page converter + new post "Where to search for accommodation" (EN)
tools/build_blog.py converts a Markdown source into the site's scrollspy blog
article (title, header, hero, sidebar nav from ## headings, body). First output:
the new EN post "Where to search for student accommodation in Slovenia", added at
the top of the blog index (newest first), dated 2026-08-03, SEO injected.

MK/SI of this post and the rest of the blog batch (refresh 1-5, split trilingual
posts 2-4, personal essay post 7) still to come.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-05 17:09:09 +02:00
popovskik 195a48205c changes.txt #6: sync homepage "Latest news" from the News hub
Add tools/build_listings.py: copies the top 3 cards from each language's News
hub into the homepage "Latest news" block (marker-wrapped), so editing the News
page now updates the homepage. The News hub stays the hand-edited source of truth
(it may hold curated teaser cards without a detail page).

Also: fix the Gallery meta description (was a copy of the FAQ text) and add a
durable gallery override to seo_inject.py; refresh llms.txt / links-for-bots.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-05 16:20:55 +02:00
popovskik c14a227ac7 changes.txt #2: AI/crawler discovery files (llms.txt + links-for-bots)
Add tools/build_botlinks.py which regenerates, from the pages already on disk:
- /llms.txt          llmstxt.org-style Markdown index (English, with descriptions)
- /links-for-bots/   a lightweight fully-linked crawl hub covering EN/MK/SI

Re-run `python tools/build_botlinks.py` after adding or removing pages; it only
reads each page's <title> and meta description, so it stays current automatically.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-05 16:10:38 +02:00
popovskik 661943bb34 feat(assistant): v2 — query-language detection, analytics, chips, auto-index
Addresses real gaps found in testing (a Macedonian question on an English
page returned nothing):

- Detect the language of the QUESTION (Cyrillic -> MK; Slovene markers -> SI;
  else the page language) and load that language's index + curated answers.
  Fixes cross-language questions.
- Expand curated multilingual intents (now incl. enrolment/eVŠ, deadlines,
  health, "what is MSOS", etc.) with stem keywords for better paraphrase
  matching. MK/SI answers machine-drafted — proofread before launch.
- Suggested-question chips on open (localized) to guide users.
- Privacy-safe analytics: fire a GA4 'assistant_query' event ONLY after the
  visitor accepts cookies (q text, result type, question vs page language) so
  the team can see real FAQs and unanswered questions.
- Move the widget to bottom-left on pages with the floating "Become a member"
  CTA so they never overlap. Design polish (chips, typing dots, launcher pulse).
- CI: rebuild the search index on every deploy (setup-python + build script)
  so the assistant stays in sync with content automatically. Build script is
  now path-portable (no hardcoded path).

Verified in a headless browser: MK-on-EN now answers correctly, chips work,
analytics event fires only with consent, become-a-member offset applies,
zero console errors.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-04 01:48:39 +02:00
popovskik f7f297bd65 feat: offline in-browser "Ask MSOS" assistant (no API, zero cost)
A privacy-friendly help widget that answers visitor questions from the
site's own content and links to the full page — runs 100% in the browser,
no API, no server, no per-token cost.

- tools/build_search_index.py: parses every EN/MK/SI page into ~720
  heading-level chunks per language -> assistant/index-<lang>.json
  (lazy-loaded only when the chat is opened; gzips to ~80 KB).
- assistant.js: dependency-free BM25 search + multilingual stopword
  filtering + a curated short-answer layer for common questions, plus an
  accessible chat widget (role=dialog, keyboard, aria). CSP-safe (self only).
- assistant.css: scoped .msa-* styles in the site's teal palette;
  responsive (full-screen panel on mobile).
- Injected on 208 pages (blog WIP excluded; picks it up when that lands).

Verified in a headless browser across EN/MK/SI: curated answers, search
fallback with correct ranking (rare terms win), correct deep links,
Cyrillic + Slovene diacritics, and zero console errors. Curated MK/SI
answers are machine-drafted — proofread before launch.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-04 01:29:22 +02:00
popovskik f24fc704d6 Add GDPR cookie-consent banner (Consent Mode v2)
- consent.js: self-contained, non-blocking bottom banner in EN/MK/SI,
  remembers the choice in localStorage, links to the per-language cookie
  policy. Accept -> gtag consent 'update' granted; Decline stays denied.
- Head GA snippet restores a returning visitor's prior "granted" choice
  before the first hit; loads /consent.js on every page.
- Re-openable via window.msosOpenConsent() for a "manage cookies" link.

Verified in-browser: shows for new visitors, Accept grants + remembers,
reload keeps consent without re-prompting, Slovene text + /si/ policy link.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-02 18:30:35 +02:00
popovskik 9a6d2c335c Add Google Analytics 4 (G-WVYV807VSS) with Consent Mode v2
- gtag.js injected on all 201 pages via tools/seo_inject.py + on 404.html
- Consent Mode v2 defaults all storage to 'denied' (EEA-safe: tag loads,
  no tracking cookies until a consent banner grants analytics_storage)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-02 12:52:19 +02:00
popovskik 788084e094 Add article dates, brand OG image, launch SEO checklist
- Add datePublished/dateModified to Article JSON-LD on the 11 dated
  articles (curated once from EN, applied to all languages)
- Replace og-default.jpg with the official brand OG image (1200x630)
- Add docs/launch-seo-checklist.md (go-live steps: redirects, Search
  Console, analytics, rich-result validation, monitoring)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-02 12:38:20 +02:00
popovskik 314667f692 SEO polish: OG image, favicons, 404, article schema, image optimization
- Add branded 1200x630 og-default.jpg; article pages use their hero as
  og:image, others use the default
- Wire the existing (previously unlinked) favicon set into every page
- Add branded 404.html with root-absolute paths + noindex
- Emit Article + localized BreadcrumbList JSON-LD on all article pages
- Convert 74 heavy served photos to WebP (28MB -> 8.5MB, -70%), rewrite
  references, add loading=lazy/decoding=async to below-fold images and
  fetchpriority=high to heroes (protect LCP)
- Stop tracking images/original/ (458MB of unused source masters; kept on
  disk, gitignored) and ignore .playwright-mcp/

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-02 12:15:53 +02:00
popovskik b393859467 Add technical SEO foundation, MK/SI about-us + timeline, content fixes
SEO (all 201 pages, en/mk/si):
- Inject canonical, hreflang (en/mk/sl + x-default), Open Graph, Twitter
  cards and Organization JSON-LD via idempotent SEO:START/END block
- Generate multilingual sitemap.xml (xhtml:link alternates) + robots.txt
- Curated meta descriptions for lead-less pages (home, become-a-member,
  faq, news hub, my-route); every page now has a description
- Absolute URLs target final domain msosorg.com, not the temp host
- Add reusable tools/seo_inject.py (+ README)

Content fixes:
- Translate about-us and timeline-and-milestones into MK + SI, wire up
  their pages, and repair the previously-dead "Who We Are" nav links
  across all mk/si pages
- Remove duplicate en/projects/makedonska-studentska-vecer-vo-ljubljana
  (unreferenced; already covered by macedonian-student-night-in-ljubljana)

Locale correctness:
- Normalise Slovene pages to <html lang="sl"> (correct ISO 639-1)
- Map sl->si in main.js so the language-switcher highlight and newsletter
  i18n keep working on Slovene pages (data-lang="si" still maps to /si/)

MK/SI translations and descriptions are AI-drafted; flag for native review.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-08-02 11:43:10 +02:00