Languages
TPT StrategyGraph
An open-source enterprise knowledge and market intelligence engine. Automates the research and synthesis phase of management consulting by ingesting documents, scraping websites, extracting entities and relationships into a knowledge graph, and enabling strategic querying and brief generation via LLM.
Built by TPT Solutions · Licensed under the Apache License 2.0
Features
- Document Ingestion — Upload PDF, DOCX, HTML, TXT, and Markdown files; automatic chunking and entity extraction
- Web Scraping — Single-page or recursive crawls with configurable depth and cron schedules; Playwright fallback for JS-heavy sites
- Knowledge Graph — Visualize entities (companies, people, products, markets, regulations, etc.) and their relationships via interactive Cytoscape graph
- RAG Query — Ask strategic questions; retrieves relevant document chunks via semantic search before querying the LLM
- Strategic Briefs — Generate Market Entry, Competitive Landscape, M&A Target Analysis, SWOT, and Industry Overview reports; export as Markdown, PDF, DOCX, or PPTX
- Multi-LLM Support — Anthropic (Claude), OpenAI (GPT), OpenRouter, and Groq; configurable model and temperature per provider
- Local Embeddings — Semantic search powered by
all-MiniLM-L6-v2via@xenova/transformers; no external embedding API required - Offline-capable — SQLite database stored locally at
~/.tpt-strategygraph/data.db
Quick Start
Requirements
- Node.js 18+
- npm 9+
Install & Run
npm install
npm run dev
This starts the Electron main process (TypeScript watch) and the Vite renderer dev server concurrently.
Configure an LLM Provider
Open Settings and add at least one provider:
| Provider | Recommended model |
|---|---|
| Anthropic | claude-sonnet-4-20250514 |
| OpenAI | gpt-4o |
| OpenRouter | any available model |
| Groq | llama-3.3-70b-versatile |
Set one provider as active and save.
Build & Distribute
npm run build # compile renderer (Vite) + main process (tsc)
npm run dist # package for Windows (NSIS), macOS (DMG), Linux (AppImage)
Distribution output is written to release/.
Architecture
src/
├── main/ # Electron main process — DB, LLM, scraping, ingestion, IPC
├── preload/ # contextBridge IPC bridge (window.electronAPI)
├── renderer/ # React 18 + Vite frontend
└── shared/ # TypeScript interfaces and IPC channel constants
All renderer↔main communication goes through typed IPC channels defined in src/shared/types.ts. See CLAUDE.md for a full architectural breakdown.
Keyboard Shortcuts
| Shortcut | Action |
|---|---|
Alt+1 | Strategic Query |
Alt+2 | Knowledge Graph |
Alt+3 | Documents |
Alt+4 | Web Scraping |
Alt+5 | Strategic Briefs |
Alt+6 | Settings |
B | Toggle sidebar |
Contributing
Contributions are welcome. Please open an issue before submitting a pull request for significant changes.
License
Copyright 2026 TPT Solutions
Licensed under the Apache License, Version 2.0. See LICENSE for the full text.