Commit graph

2380 commits

Author SHA1 Message Date
Till JS
bc0ffb4440 fix(manacore/web): restore guest mode imports via local re-export
The pre-commit linter was stripping createGuestMode, GuestWelcomeModal,
and NotificationBar imports because it couldn't resolve them during
staged-file linting. Fix by creating a local re-export file at
$lib/stores/guest-mode.svelte.ts that the linter can resolve.

Also restore the GuestWelcomeModal and NotificationBar template blocks
that were removed by the linter.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 16:38:58 +02:00
Till JS
5280cc6dc7 refactor(analytics): add module context to all Umami events
Resolves event name collisions in the unified app (e.g. view_changed,
deck_created, search_performed) by adding a `module` property to every
tracked event via createModuleTracker. Also fixes duplicate tracking in
Planta routes (now only tracked in mutations.ts).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 16:35:27 +02:00
Till JS
779a8ba322 feat(shared-stores): add createArchiveOps factory + unify archive pattern
Standardize two-stage deletion across modules: archive (isArchived) +
soft-delete (deletedAt). Add shared factory, Archivable type mixin,
filterActive/filterArchived/filterNotDeleted query helpers. 13 tests.

Migrate memoro, chat, picture, contacts to use createArchiveOps.
Standardize picture from archivedAt timestamp to isArchived boolean.
Picture toggleFavorite now uses shared toggleField (1 param, not 2).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 16:33:07 +02:00
Till JS
7d3114df16 fix(manacore/web): add svelte-sonner dependency for uload settings
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 16:31:17 +02:00
Till JS
51da1f8a59 fix(uload): add input validation, migrate clicks to dedicated table
- Add URL validation (must be valid http/https), short code uniqueness check,
  custom code format validation, maxClicks >= 1, expiresAt must be future
- Migrate uload-server click tracking from sync_changes to uload.clicks table
  for performant analytics with SQL indexes on link_id, clicked_at, country
- Migrate analytics queries from JSON aggregation on sync_changes to direct
  SQL on uload.clicks (typed columns instead of data->>'field' extraction)
- Make short URL domain configurable via PUBLIC_ULOAD_DOMAIN env var

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 16:30:17 +02:00
Till JS
3bd717bc93 feat(manacore/web): add unified QuickInputBar with context-aware adapters
Implement adapter pattern for the QuickInputBar that automatically
switches behavior based on the current route:
- /todo: NL task parser (priority, dates, labels, subtasks)
- /calendar: NL event parser (time, duration, recurrence, location)
- /contacts: NL contact parser (company, email, phone, tags)
- /times: search alarms and world clocks
- /planta: NL plant parser (species, care actions)
- fallback: cross-app search via SearchRegistry

Architecture: InputBarAdapter interface, lazy-loaded adapters per
module, route-reactive resolution in layout. Contact parser ported
from standalone contacts app.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 16:24:17 +02:00
Till JS
475ed87a41 refactor(uload): remove unused schema tables, keep only clicks
The uload-server reads links from sync_changes (local-first via mana-sync)
and never used the Drizzle schema tables (users, accounts, workspaces, links).
Strip uload-database package to only the clicks table which is needed for
performant analytics aggregation with proper SQL indexes.

- Remove 5 unused tables (users, accounts, workspaces, links, relations)
- Keep only uload.clicks with indexes on link_id, clicked_at, country, device_type
- Simplify uload-database package from ~190 LOC to ~40 LOC

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 16:23:33 +02:00
Till JS
d5c40a4543 feat(shared-ui): add generic ColorPicker with standard palettes
Extract TagColorPicker logic into generic ColorPicker that accepts custom
color palettes. TagColorPicker is now a thin wrapper. Add COLORS_12 and
COLORS_16 standard palettes for consistent color selection across all
modules (projects, folders, calendars, categories, etc.). 10 new tests.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 16:23:26 +02:00
Till JS
4667d5df33 feat: unified guest mode with AuthGate + createGuestMode composable
Major refactor of ManaCore's (app) layout for guest mode support:

- New createGuestMode() composable in shared-stores — encapsulates
  welcome modal state, nudge timer, and notifications in one call
- Replace monolith onMount with AuthGate + handleAuthReady callback:
  Phase A (auth-independent): DB init, migration, uload, dashboard
  Phase B (auth-dependent): sync, user settings, onboarding
  Phase C (guest-only): welcome modal + registration nudge
- Root route / always redirects to /home (no auth check)
- PillNav shows login button for guests, user email for auth users
- GuestWelcomeModal with manacore-specific features
- SessionWarning only renders for authenticated users
- Proper cleanup via onDestroy

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 16:22:43 +02:00
Till JS
ead4e71af5 feat(shared-ui,shared-stores): add FavoriteButton component and toggleField utility
FavoriteButton: reusable heart/star/pin toggle with filled/outline states,
accessible labels, configurable colors. toggleField: generic boolean field
toggle for Dexie records (isFavorite, isPinned, etc.) with timestamp.
Includes 11 tests (6 FavoriteButton + 5 toggleField).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 16:16:23 +02:00
Till JS
d49a3d727d feat(manacore/web): add tag junction tables and stores for all 23 modules
Every module now has a tag junction table in IndexedDB and a tag store
with createTagLinkOps for consistent tag-entity linking. Tags are shared
globally via globalTags; each module only manages its own junctions.

New junction tables: eventTags, contactTags, conversationTags, deckTags,
zitareListTags, songTags, presiDeckTags, invItemTags, skillTags,
ccLocationTags, entryTags, documentTags, questionTags, mealTags,
plantTags, moodTags, guideTags.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 16:10:49 +02:00
Till JS
be20de23db feat(manacore/web): uload feature parity — tags, analytics, settings
Port missing features from standalone uload app to unified ManaCore module:
- Add Tag Management page (/uload/tags) with CRUD, color picker, inline edit
- Replace analytics placeholder with full server dashboard (timeline chart,
  device/country/referrer breakdowns, graceful fallback when server unavailable)
- Add Settings page (/uload/settings) with data overview, JSON export, clear data
- Fix bugs: missing LocalTag type, unregistered uloadTags table, wrong table
  name in AppView (linkFolders → uloadFolders)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 16:10:10 +02:00
Till JS
8c98dd871d refactor(manacore/web): unify all module tags into shared globalTags
Migrate 7 modules (picture, photos, storage, memoro, times, uload, todo)
from module-specific tag tables to the shared globalTags system. Each
module now reads tags from the global pool and keeps only its junction
table for entity-tag linking via createTagLinkOps.

Removed: pictureTags, photoTags, storageTags, memoroTags, timeTags,
uloadTags, labels tables from IndexedDB schema and SYNC_APP_MAP.
Kept: all junction tables (imageTags, photoMediaTags, fileTags, etc.)
pointing to globalTags IDs.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 15:34:55 +02:00
Till JS
48aac82bcb feat(shared-stores): add createTagLinkOps factory for junction tables
Reusable factory for tag-entity junction operations (addTag, removeTag,
setTags, getTagIds, hasTag) used by all modules. Also loosen ViewStore
filter constraint from Record<string, unknown> to object for interface
compatibility. Includes 14 tests.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 15:33:18 +02:00
Till JS
eabd9200a3 feat(manacore/web): theme-aware AppViews with inline creation
Rewrite Todo, Calendar, and Contacts AppView components for the
workbench paper-sheet pages:
- Theme-aware styling (light paper-sheet + dark mode)
- Todo: quick-add input, checkbox toggle, filter tabs
- Calendar: week strip with event dots, inline event creation
- Contacts: search + inline create form (name, email)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 14:33:22 +02:00
Till JS
3ea28b9065 refactor(db): consolidate ~20+ databases into 2 (mana_platform + mana_sync)
Mirrors the frontend unification (single IndexedDB) on the backend.
All services now use pgSchema() for isolation within one shared database,
enabling cross-schema JOINs, simplified ops, and zero DB setup for new apps.

- Migrate 7 services from pgTable() to pgSchema(): mana-user (usr),
  mana-media (media), todo, traces, presi, uload, cards
- Update all DATABASE_URLs in .env.development, docker-compose, configs
- Rewrite init-db scripts for 2 databases + 12 schemas
- Rewrite setup-databases.sh for consolidated architecture
- Update shared-drizzle-config default to mana_platform
- Update CLAUDE.md with new database architecture docs

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 14:31:28 +02:00
Till JS
b1a5c95f1d refactor(inventar,times): use shared createViewStore factory
Replace ~230 LOC of duplicated view store boilerplate with 20-line
factory calls. Both modules had identical copy-pasted implementations.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 14:25:48 +02:00
Till JS
934f3337e3 feat(shared-stores): add createViewStore factory for view/filter/sort
Generic factory that eliminates ~110 LOC boilerplate per module for
view mode, sort, filters, and saved filter presets with localStorage
persistence. Includes 23 tests covering all store operations.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 14:25:31 +02:00
Till JS
de8335277a refactor(todo,photos): use shared TagChip and TagSelector components
Replace todo's custom 87-line TagSelector with thin wrapper around
shared-ui TagSelector. Replace inline tag chip HTML in TaskItem,
KanbanTaskCard, and PhotoDetailModal with shared TagChip component.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 14:24:34 +02:00
Till JS
04fcbd15c9 feat(shared-ui): add TagChip component and tag component tests
Add compact inline TagChip for list items/cards (smaller than TagBadge).
Set up vitest with jsdom for shared-ui package and add 44 tests covering
TagChip, TagBadge, TagColorPicker, TagSelector, and constants.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 14:24:19 +02:00
Till JS
f2af192172 feat(manacore/web): workbench with app pages carousel on home
Replace the static app-grid home page with a workbench carousel where
each app renders as a paper-sheet page that can be minimized, maximized,
reordered, and resized:

- AppPage.svelte: paper-sheet shell with lazy-loaded app modules
- AppPagePicker.svelte: picker showing all 23 available apps
- App component registry: maps appId to dynamic AppView imports
- Horizontal fokus-track carousel with snap-scroll
- Edit FAB with width pills (S/M/L/XL)
- Minimized tabs bar for collapsed apps
- Drag-and-drop reordering + arrow buttons in edit mode
- Workbench state persisted to IndexedDB via shared-stores
- Default layout: Todo + Calendar + Contacts

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 14:13:28 +02:00
Till JS
3d124f04a4 feat(manacore/web): add inline QuickEventPopover for calendar
Replace the full-screen modal with a compact floating popover that
appears directly at the drag-to-create position in the week grid.
Includes title, time display, location field, and "Weitere Optionen"
link to expand into the full EventForm modal. Mobile: bottom sheet.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 14:12:01 +02:00
Till JS
983da8540e chore: remove orphaned jest.config.js, raise vitest coverage to 70%
- Delete jest.config.js (no jest dependency in any package.json, was dead config)
- Vitest is the sole test runner (already used by all packages)
- Raise coverage thresholds from 50% to 70% (lines, functions, branches, statements)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 14:11:03 +02:00
Till JS
996ec81a0e refactor(shared-python): extract shared auth package from mana-stt and mana-tts
Create packages/shared-python/manacore_auth/ with:
- auth.py: API key validation, rate limiting, local + external auth
- external_auth.py: mana-core-auth remote validation with caching
- create_auth_dependency(scope): factory for per-service auth deps

Migrated services:
- mana-stt: auth.py now wraps shared auth with scope="stt" (272→42 LOC)
- mana-tts: auth.py now wraps shared auth with scope="tts" (272→42 LOC)

The only difference between services was the scope parameter ("stt" vs "tts").
Both external_auth.py files were 100% identical and are now thin re-exports.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 14:09:32 +02:00
Till JS
e11aa50106 chore: remove unused Supabase auth store, archive stub services
- shared-auth-stores: delete createSupabaseAuthStore (zero usage across monorepo,
  all apps use createManaAuthStore). Remove export + types from index.ts.
- services: move ollama-metrics-proxy (stub — just a Grafana dashboard JSON) and
  it-landing (Astro landing page, not a service) to services-archived/
- lint-staged: add services-archived/ to eslint ignore pattern

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 13:59:53 +02:00
Till JS
4f70e1ca6c refactor(shared-go): extract shared auth package from 3 Go services
Create packages/shared-go/authutil/ with two JWT validator implementations:
- JWKSValidator: EdDSA JWKS validation with key caching (extracted from mana-sync)
- RemoteValidator: delegates to mana-core-auth /api/v1/auth/validate (from mana-notify/gateway)

Plus shared types (Claims, User), middleware factories (JWTMiddleware, ServiceKeyMiddleware),
context helpers (GetUser, GetUserID, GetUserRole), and token extraction.

Migrated services:
- mana-sync: internal/auth/jwt.go now wraps authutil.JWKSValidator
- mana-notify: internal/auth/auth.go now wraps authutil.RemoteValidator + ServiceKeyMiddleware
- mana-api-gateway: internal/middleware/jwt.go now wraps authutil.RemoteValidator

All 3 services compile and pass tests. Service-level packages re-export types
for backward compatibility so no consumer code changes are needed.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 13:27:44 +02:00
Till JS
509a541b70 feat(manacore/web): add minimized tabs bar to todo pages
Wire up the minimize/restore/maximize flow for todo pages:
- Minimized pages appear as a floating tab bar at the bottom
- Each tab shows color dot + title, with maximize and close buttons
- Click tab title to restore, click arrows-out to maximize
- Tab bar has paper-sheet aesthetic matching the pages
- Plus button on tab bar opens page picker
- Tabs slide up with animation when pages are minimized

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 13:25:08 +02:00
Till JS
97730cd9f2 feat(manacore/web): port full contact creation modal from standalone app
Expand the minimal 6-field contact form to include all sections from
the old contacts app: name, contact (email/mobile/phone), work
(company/position/website), address (street/city/postal/country),
birthday, notes, and social media (collapsible). Add mobile, street,
city, postalCode, country, and social fields to the data model.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 13:19:01 +02:00
Till JS
a4a8ff06b5 feat(manacore/web): add custom pages system to unified todo module
Port the paper-sheet pages system from standalone todo app into the
ManaCore unified app's todo module at mana.how/todo:
- Paper-sheet horizontal carousel with snap-scroll
- Edit FAB (pencil icon) toggles inline edit mode
- Custom pages with configurable filter rules (priority, date range, completed)
- PageEditBar with icon picker, filter pills, reorder arrows
- Width pills (S/M/L/XL) in edit mode
- PagePicker with preset pages + "Eigene Seite" creation
- Custom pages persisted to todoSettings

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 13:15:18 +02:00
Till JS
ee831992de feat(mana-sync): unified WebSocket — one connection per user instead of 27
Add unified /ws endpoint that serves all app notifications over a single connection.
The server now includes appId in the sync-available message payload so the client
knows which app to pull. Legacy /ws/{appId} endpoint remains for backward compatibility.

Backend (Go):
- hub.go: Message struct gains AppId field, NotifyUser sends to all user clients
  (unified clients receive everything, legacy clients filtered by appId)
- main.go: new GET /ws route (empty appId = unified mode)

Frontend (sync.ts):
- Single connectUnifiedWs() replaces 27 per-app connectWs() calls
- Parses msg.appId from server to pull only the affected app
- Reconnect/offline logic simplified to one WS

This reduces WebSocket connections from 27 per user to 1, cutting server
connection overhead by ~96%.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 13:09:10 +02:00
Till JS
df7395e57a chore: add archived clock app to apps-archived/
The Clock app source is preserved in apps-archived/ for reference.
This directory is excluded from the pnpm workspace.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 13:07:38 +02:00
Till JS
99d0dc6fb0 fix(manacore/web): float DateStrip at bottom, remove sidebar
Position DateStrip fixed above PillNav with glass blur effect.
Remove MiniCalendar sidebar to give calendar view full width.
Restore @clock/shared package from archive (needed by clock module).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 13:06:55 +02:00
Till JS
e870270734 refactor: consolidate Clock app into Times
Merge the standalone Clock app (alarms, countdown timers, stopwatch,
world clock, pomodoro) into the Times app as a unified time management
application.

Times standalone app:
- Add 3 new collections (alarms, countdownTimers, worldClocks) to timesStore
- Add Clock types and constants to @times/shared
- Add 6 new stores (alarms, countdown-timers, world-clocks, stopwatch, session-*)
- Add 5 new routes under /clock/* (dashboard, alarms, timers, stopwatch, world-clock)
- Extend layout with Clock context providers and navigation items
- Add clock.* i18n namespace (de/en)
- Add WorldMap and CircularProgress components

Manacore unified app:
- Merge clock module into times module (stores, queries, types, components)
- Move Clock DB tables under times appId (timeAlarms, timeCountdownTimers, timeWorldClocks)
- Update search provider, splitscreen registry, dashboard widgets
- Add redirects from /clock/* to /times/clock/*
- Remove @clock/shared dependency

Cleanup:
- Archive Clock app to apps-archived/clock/
- Remove dev:clock:* scripts from root package.json
- Remove Clock from mana-apps.ts, update Times description
- Update CLAUDE.md documentation

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 13:04:07 +02:00
Till JS
35f4bd48de fix: resolve port conflict (mana-image-gen 3025→3026) and replace APP_URLS with internal routes
- mana-image-gen: change default port from 3025 to 3026 to avoid conflict with mana-llm
- Dashboard widgets (12): replace APP_URLS.{app}.dev/prod with internal route paths (/todo, /calendar, etc.)
  and remove target="_blank" since all apps are now internal routes in the unified app
- Home page: use goto() for internal apps, keep window.open() only for external apps (matrix, arcade)
- AppRow: remove unused APP_URLS import

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 12:56:37 +02:00
Till JS
67567605fa feat(manacore/web): add DateStrip to calendar module
Port the horizontal scrolling DateStrip from the standalone calendar
app with all features: event indicator dots, moon phases, weekend
highlighting, month dividers, lazy-loading virtual scroll, smart
today button, and view range highlighting.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 12:46:37 +02:00
Till JS
1cd89af80d feat(todo/web): add custom pages with inline visual editor
Bring back the custom pages system from the old standalone todo app:
- Edit FAB (pencil icon) toggles inline edit mode on the homepage
- Custom pages with configurable filter rules (priority, date range, completed)
- Inline PageEditBar with icon picker (10 icons), filter pills, reorder arrows
- Width pills (S/M/L/XL) visible in edit mode to resize all sheets
- Custom pages persisted to todoSettings.customPages
- Auto-enable edit mode when creating a new custom page
- PagePicker now includes "Eigene Seite" creation option

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 12:44:14 +02:00
Till JS
4c9b4583bc chore: uncommitted WIP from previous session
Includes todo page edit bar, minimized pages store, times shared
types, manacore data layer cleanup, and dashboard widget updates.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 12:40:37 +02:00
Till JS
05e5e957e8 feat(manacore/web): unified IndexedDB sync via Dexie hooks, eliminate cross-app readers
Activate sync for the unified manacore IndexedDB by adding automatic change tracking
via Dexie hooks on all 120+ tables. This replaces the unused manual trackChange() approach
and eliminates the need for 12 separate cross-app IndexedDB reader instances.

Key changes:
- database.ts: Dexie hooks auto-record _pendingChanges for every write, TABLE_TO_SYNC_NAME mapping
- sync.ts: rewritten with correct backend URLs, auth token, table name translation, server change guard
- layout: unified sync engine replaces per-app manacoreStore/tag/link sync + 12 cross-app readers
- cross-app-queries.ts: rewritten to query unified DB directly instead of via cross-app-stores
- legacy-migration.ts: one-time migration from old per-app DBs (manacore-todo etc.) to unified DB
- local-store.ts: refactored to use unified DB with collection wrappers instead of createLocalStore()
- Deleted cross-app-stores.ts (383 lines) and change-tracker.ts (80 lines)
- Updated ActivityFeed, TasksTodayWidget, CalendarEventsWidget, ContactsFavoritesWidget, spiral/collect.ts
- Updated CLAUDE.md with unified IndexedDB architecture documentation

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 12:40:31 +02:00
Till JS
88864fd3a1 fix(shared-ui): open AppDrawer above PillNav instead of below
The panel was positioned below the trigger button using top, causing
it to render off-screen since PillNav sits at the bottom. Changed to
bottom positioning so the drawer opens upward.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 12:31:56 +02:00
Till JS
919cb4bf35 fix(local-llm): wrap @mlc-ai/web-llm in dynamic import for Docker builds
Move hasModelInCache to local-llm package with dynamic import wrapper
so the browser-only dependency doesn't break server-side builds.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 12:22:20 +02:00
Till JS
d574dda6a4 fix(manacore/web): externalize @mlc-ai/web-llm from SSR build
Browser-only WebGPU package that cannot be bundled server-side.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 12:17:30 +02:00
Till JS
f625c7b263 fix(manacore/web): disable SSR for llm-test page
@mlc-ai/web-llm is browser-only (WebGPU) and cannot be resolved
during SSR build in Docker. Setting ssr: false for the page.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 12:14:50 +02:00
Till JS
78e726ce1b fix(docker): add local-llm package to Docker build context
Add @manacore/local-llm to both sveltekit-base and manacore web
Dockerfile so pnpm can resolve the workspace dependency.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 12:07:36 +02:00
Till JS
82516e9ba3 fix(manacore/web): fix build errors for production deployment
Remove deleted PlaygroundLogo export, migrate onclick|stopPropagation
to Svelte 5 syntax, fix @const placement, and increase PWA max file
size to 8 MiB for unified app bundle.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 12:05:49 +02:00
Till JS
3bef29b9c8 feat(local-llm): add generate utilities and reactive Svelte status
Add generate.ts with streaming chat completions, JSON extraction, and
text classification helpers. Add status.svelte.ts with Svelte 5 runes
reactive wrapper for LLM engine state.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 11:57:50 +02:00
Till JS
91d61e5428 refactor: remove leaflet dependency, replace with OSM embeds
Remove leaflet, leaflet.markercluster, and @types/leaflet from
citycorners. Replace interactive Leaflet maps with zero-dependency
OpenStreetMap iframe embeds on both map and location detail pages
(standalone citycorners + manacore integrated). Add filtered location
list below map as replacement for interactive markers.

Also removes remaining bauntown files missed in previous commit.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 11:56:26 +02:00
Till JS
c3c02c6a22 feat(manacore/web): add benchmark, compare history, markdown & cache status to LLM test
- Benchmark tab: run same prompt N times against loaded model, show
  avg/min/max/median for latency and tok/s with per-run table and bars
- Compare history: save results to localStorage (max 20), restore or
  delete previous comparisons via History panel
- Markdown rendering: use marked for assistant responses in chat tab
  and compare outputs with proper code blocks, lists, headings
- Model cache status: check browser Cache API via WebLLM hasModelInCache,
  show cached/uncached per model with size badges
- Add marked dependency

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 11:50:23 +02:00
Till JS
348b6ff231 chore: remove playground, reader, bauntown, voxelava, and worldream apps
These apps were either stubs (voxelava, worldream), planning-stage
(reader), dev-tools (playground), or inactive (bauntown). Removing
to reduce monorepo surface area. All recoverable from git history.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 11:47:54 +02:00
Till JS
e5a6946d8b feat(manacore/web): add model comparison tab to LLM test page
Add a "Compare" tab that sequentially runs the same prompt against all
available models (currently Qwen 2.5 1.5B and 0.5B), showing results
side-by-side with a stats table (latency, tok/s, token counts) and
streaming preview during inference. Also includes fixes from earlier:
$derived.by for statusText, removed unused generateText import, added
chat auto-scroll with max-height.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 11:25:44 +02:00
Till JS
a658822a40 fix(manacore/web): fix LLM test page derived rune, unused import, and auto-scroll
- Change $derived(() => ...) to $derived.by(() => ...) for statusText
- Remove unused generateText import
- Add auto-scroll to chat container on new messages and streaming
- Add max-height with overflow-y-auto to prevent chat from growing unbounded

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 11:17:06 +02:00