Wikantik Development

This cluster documents the development history of the Wikantik platform itself — the architecture decisions, feature implementations, and engineering patterns that have shaped the system over time.

Core Engineering Pillars

Module Structure

Wikantik is a Maven multi-module reactor. Key modules:

ModuleRole
wikantik-apiCore interfaces — manager contracts, frontmatter types, KG service, Page Graph interfaces
wikantik-mainMain implementation — Markdown rendering (Flexmark), providers, auth (JAAS), search, entity extraction, math parser
wikantik-eventEvent system for decoupled component communication
wikantik-utilUtility classes and helpers
wikantik-cacheEhCache-based caching layer (1-hour TTL, 10K entry capacity)
wikantik-httpServlet filters — CSRF, CORS, CSP, security headers, SPA routing
wikantik-restREST/JSON API (/api/*) and admin endpoints (/admin/*)
wikantik-admin-mcpAdmin MCP server at /wikantik-admin-mcp — 26 tools
wikantik-knowledgeKnowledge MCP server at /knowledge-mcp — 19–20 read-only tools; also hosts the KG service, hybrid retriever, RAG bundle
wikantik-ontologyRDF/OWL ontology (Apache Jena + TDB2) — T-Box, projectors, SHACL gate, public SPARQL surface
wikantik-ingestDerived-page document extraction (Apache Tika 3.3.0 + flexmark-html2md)
wikantik-scimSCIM 2.0 provisioning at /scim/v2/*
wikantik-toolsOpenAPI 3.1 tool server at /tools/* — 2 tools for non-MCP clients
wikantik-observabilityHealth checks, Prometheus metrics, request correlation
wikantik-frontendReact SPA (Vite) — reader, editor, admin panel, Page Graph viewer, Knowledge Graph viewer
wikantik-warWAR packaging; bundles the React build
wikantik-it-testsIntegration tests (Selenide, REST, Cargo-launched Tomcat + PostgreSQL + pgvector)

Architecture Evolution

Wikantik began as a fork of Apache JSPWiki. Through a sustained modernization effort starting March 2026, the platform was transformed:

Key Design Decisions

  1. ADR-001: Extract Manager Interfaces to API — Decouples MCP modules from the core engine; wikantik-api is the only dependency MCP modules need for type-safe engine access.
  2. Frontmatter as Source of Truth — Wiki page YAML frontmatter is the canonical source for cluster membership, tags, type, audience, verification, and SEO metadata. The server-authoritative FrontmatterSchema drives live validation and Save-gating in the editor.
  3. Page Graph vs Knowledge Graph — Two strictly separate subsystems. The Page Graph tracks real wikilink edges; the Knowledge Graph tracks LLM-extracted entities and relations. See PageGraphVsKnowledgeGraph.
  4. Fail-closed retrieval — The hybrid retriever degrades to BM25 when the embedding service (Ollama) is unavailable; the context bundle dense source uses Lucene HNSW in-process (the docker1 production default) so there is no mandatory external network dependency for search.

Feature Timeline

DateFeature
2026-03-23Test stub conversion for decoupled testing
2026-03-28JSP → React SPA migration
2026-04-03User profile management, attachment handling
2026-04-04Knowledge Graph core — entity extraction, kg_* tables, pgvector embeddings
2026-04-25Agent-grade content layer — type: runbook, page verification, get_page_for_agent, retrieval-quality CI
2026-05-02Structural spine — canonical_id, cluster:, list_clusters/list_tags/list_pages_by_filter; typed relations: frontmatter removed
2026-05-30Session stability — SameSite=Lax auth cookies, remember-me re-auth filter
2026-06-05SCIM deactivation auth guard; auth lock enforcement per-login-module
2026-06-08RDF/OWL ontology layer — T-Box, SHACL gate, public SPARQL/JSON-LD/dumps, SEO @type re-sourced from ontology
2026-06-09Structured frontmatter editor — live validation, Save-gating, page-scoped KG curation panel
2026-06-14RAG-as-a-Service Phase 1 — context bundle (GET /api/bundle, assemble_bundle MCP), derived pages (Tika ingest), chunker heading-fidelity fix, contextual embeddings
2026-06-19Bundle hybrid source (BM25+dense RRF default-on); admin-MCP reconciled to 26 tools; list_retrieval_queries added

See Also