Skip to content

BuddhaYi/topic-pilot

Repository files navigation

TopicPilot - AI Research Topic Discovery Assistant

TopicPilot is an AI-powered research topic selection assistant that helps researchers discover promising research directions through systematic literature analysis.

Features

  • 6-Phase Research Workflow: Intent parsing → Literature landscape → Gap identification → Candidate generation → Convergence → Report
  • Multi-Strategy Gap Discovery: 5 strategies including explicit, implicit, trend-based, discussion RAG, and citation graph structural holes
  • Adversarial Validation: Agent loops that challenge and verify discovered gaps
  • Evidence Self-Healing: Automatically finds replacement citations for invalid references
  • Citation Graph Analysis: Betweenness centrality and co-citation gap detection (zero LLM calls)
  • Multi-LLM Support: DeepSeek (default), OpenAI, Anthropic
  • Export: PDF, PPTX, XLSX, Markdown report generation
  • Demo & Live Modes: Try with built-in demo data or connect to real APIs

Tech Stack

  • Frontend: Next.js 16, React 19, Zustand, Tailwind CSS
  • Backend: Next.js API Routes, Prisma ORM, PostgreSQL
  • AI: DeepSeek / OpenAI / Anthropic APIs
  • Data Sources: Semantic Scholar, arXiv, OpenAlex
  • ML: SPECTER2 embeddings, k-Means clustering, UMAP projection

Quick Start

Prerequisites

  • Node.js 20+
  • Docker Desktop (for PostgreSQL)
  • An LLM API key (DeepSeek recommended)

Setup

git clone https://github.com/BuddhaYi/topic-pilot.git
cd topic-pilot
npm install
cp .env.example .env
# Edit .env and add your LLM_API_KEY

Run

make start

This will:

  1. Start PostgreSQL in Docker
  2. Sync database schema (Prisma)
  3. Launch the dev server at http://localhost:3000

Other Commands

make db          # Start PostgreSQL only
make db-stop     # Stop PostgreSQL
make migrate     # Sync Prisma schema
make stop        # Kill dev server

Environment Variables

Variable Required Default Description
DATABASE_URL Yes (see .env.example) PostgreSQL connection string
LLM_PROVIDER No deepseek LLM provider: deepseek, openai, anthropic
LLM_API_KEY Yes - API key for the LLM provider
LLM_BASE_URL No auto Override API base URL
LLM_MODEL No auto Override model name
SEMANTIC_SCHOLAR_API_KEY No - Increases S2 API rate limit
LOG_LEVEL No info Logging level

Project Structure

src/
├── app/
│   ├── api/              # 27 API routes (analyze, papers, report, sessions, eval)
│   └── page.tsx          # 3-column layout: KnowledgeBase | Session | Studio
├── components/
│   ├── phases/           # 12 phase components (Phase1 → Phase6)
│   ├── layout/           # ResearchSession, KnowledgeBase, Studio
│   ├── chat/             # Chat interface
│   └── shared/           # Reusable UI components
├── lib/                  # 45 utility modules (LLM, prompts, citation graph, etc.)
├── store/                # Zustand state management
└── types/                # TypeScript type definitions

License

MIT

About

AI-powered research topic discovery assistant with multi-strategy gap identification, adversarial validation, and citation graph analysis

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages