Legal-AI codebase rebranded as marketingOS with a 12k-line skill prompt library
pkbtran's fork replaces the upstream legal product with a marketing assistant, adding 39 skill prompt files and a loader that injects them by slash command. The underlying tool infrastructure is preserved; the legal UI is hidden with CSS rather than removed.
The main commit (16aee533) drops 39 backend/marketing-skills/*.md files covering A/B testing, SEO audits, copywriting, CRO, churn analysis, ads strategy, and more. A skillEngine.ts reads them from disk by name. In chatTools.ts, the skill-detection block scans the last user message for a leading /skillname, loads that file, and prepends it as [SKILL INSTRUCTIONS] before the LLM call. No allowlist -- any /word pattern attempts a skill lookup.
The frontend rebrand is surface-level: logo, page title, nav labels, and chat placeholder swap from legal to marketing copy. The /documents and /workflows routes get display: none in CSS rather than being removed or rerouted.
The demo commit introduced a serious regression: chatTools.ts was truncated to a // ... unchanged placeholder, wiping PROJECT_EXTRA_TOOLS, TABULAR_TOOLS, WORKFLOW_TOOLS, TOOLS, and runLLMStream. Commit 3d176db4 restores all of it. Two more commits sort out a Puppeteer type problem -- adding @types/puppeteer, then abandoning types entirely with const puppeteer = require('puppeteer') and browser: any.
Two pieces are portable if you want them: browser.ts (headless Puppeteer fetch with cheerio text extraction) and search.ts (Brave search wrapper). Both are under 50 lines. The Brave key uses a non-null assertion at module load, so a missing BRAVE_SEARCH_API_KEY won't fail until the first actual search call.
Spotted something wrong? Or know the PR text has fresher detail than the writeup above?