Skip to content

domchang1/dailypapers

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DeepRead (React + Express)

Modernized glass-style daily AI/ML papers app using a Vite/React client and an Express API proxy to arXiv.

Stack

  • Frontend: React 18 + Vite, custom CSS.
  • Backend: Express + fast-xml-parser, JSON file store for user interests/history.
  • Deploy: works on Render/Railway (backend) + GitHub Pages/Vercel (frontend).

Quick start (local dev)

Prereqs: Node 18+ and npm.

  1. Start the API (uses PORT, defaults to 5050 to avoid macOS 5000 conflict):

    cd server
    npm install
    PORT=5050 npm start

    Runs on http://localhost:5050 by default.

  2. Start the client (separate terminal):

    cd client
    npm install
    # point to your API; for local server on 5050:
    VITE_API_BASE=http://localhost:5050/api npm run dev -- --host

    Vite dev server: http://localhost:5173. If you prefer the proxy, start the client with API_PORT=5050 npm run dev -- --host and use /api in the client.

API

  • GET /api/health — simple health check.
  • GET /api/papers?interests=comma,separated&preferFresh=true|false
    • interests: optional, comma-separated keywords. Up to 12 kept.
    • preferFresh: true to sort by submission date, otherwise last-updated. Returns { source: "live" | "fallback", papers: [...], lastUpdated }.

Client notes

  • Interests and history are persisted in localStorage (gp_interests, gp_history).
  • Buttons disable during fetches; fallbacks show if the API call fails.
  • Set VITE_API_BASE to point at a remote API; set VITE_BASE to your repo base when building for GitHub Pages (e.g., /your-repo-name/). Defaults are /api for dev and / base for builds.

Deploy

Backend (Render/Railway):

  • Build: npm install
  • Start: npm start
  • Env: PORT=5050 (or your choice). Copy the public URL, e.g., https://your-app.onrender.com/api.

Frontend (GitHub Pages via workflow in .github/workflows/deploy-gh-pages.yml):

  • Set repo secret VITE_API_BASE to your backend URL (include /api).
  • Workflow sets VITE_BASE=/<repo-name>/ for Pages.
  • On push to main, the action builds client/dist and publishes to gh-pages. Ensure Pages source is set to gh-pages.

Frontend (Vercel):

  • Root: client
  • Build: npm run build
  • Output: dist
  • Env: VITE_API_BASE=https://your-app.onrender.com/api
  • Optional: VITE_BASE=/

Notes on arXiv rendering

  • Abstracts escape HTML, render \emph{} / \textit{}, inline $...$ and simple \frac{a}{b}, and map common Greek tokens (e.g., \varepsilon -> ε).
  • History pills link directly to the arXiv paper URLs.

About

a simple, liquid glass website that provides daily AI/ML papers with customization features

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors