Skip to content

zebbern/repolens

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

150 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

RepoLens

AI-powered GitHub repository analysis โ€” just add m before any github.com URL

GitHub Stars Latest Release MIT License

Website ยท Quick Start ยท Features ยท AI Providers

repolens-show.mp4

Pro tip: Turn any GitHub URL into a RepoLens analysis by adding m before github.com. For example: github.com/facebook/react โ†’ mgithub.com/VrianCao/Uptimer


Features

  • Repository Overview โ€” Instant project summary, tech stack detection, and interactive file tree visualization
  • Code Browser โ€” Syntax-highlighted source viewer powered by Shiki, with file outline and breadcrumb navigation
  • Issues Scanner โ€” Automated code quality analysis that detects security vulnerabilities, performance problems, and best practice violations
  • Diagrams โ€” Auto-generated architecture diagrams using Mermaid.js โ€” dependency graphs, component relationships, and more
  • Documentation Generator โ€” AI-powered docs generation including README, Architecture Overview, API Reference, and Contributing Guide
  • AI Chat โ€” Ask questions about any codebase with full context awareness and 9 specialized AI tools for deep analysis
  • Compare โ€” Side-by-side repository comparison to evaluate alternatives

How It Works

  1. Navigate to mgithub.com/owner/repo (or paste any GitHub URL on the homepage)
  2. RepoLens fetches the entire repo via GitHub's Zipball API in a single download
  3. Files are indexed and cached in IndexedDB for instant repeat visits
  4. All tabs become available โ€” browse code, scan issues, generate docs, chat with AI

Supported AI Providers

RepoLens works with multiple AI providers. You configure API keys directly in the app โ€” no environment variables needed.

Provider Example Models
OpenAI Latest Models
Google Latest Models
Anthropic Latest Models
OpenRouter Latest Models

GitHub Personal Access Token

Add a GitHub Personal Access Token (PAT) to access private repositories and raise the API rate limit from 60 to 5,000 requests/hour. When a PAT is configured, GitHub API calls go directly from your browser to api.github.com โ€” the token never touches the RepoLens server.

How to Configure

  1. Create a fine-grained PAT on GitHub.
  2. Grant Contents: Read-only and Metadata: Read-only permissions (select only the repositories you need, or choose All repositories).
  3. In RepoLens, click the gear icon (Settings) โ†’ GitHub tab โ†’ paste your token โ†’ Test Connection.

Recommended Scopes

Goal Scope
Private repository access Contents: Read-only + Metadata: Read-only
Public repos (higher rate limit only) No additional permissions needed

Security

  • The token is stored in your browser's localStorage โ€” same as AI API keys.
  • API calls are made directly from the browser over HTTPS; the token is never sent to the RepoLens server.
  • Already signed in with OAuth? OAuth continues to work through server-side proxy routes. You can use either method, or both.

Quick Start

Prerequisites

Requirement Install Verify
Node.js 18+ nodejs.org node -v
pnpm pnpm.io pnpm -v
AI API key At least one: OpenAI, Google AI, Anthropic, or OpenRouter โ€”

Setup

git clone https://github.com/zebbern/repolens.git
cd repolens/workproject
pnpm install
pnpm dev

Open http://localhost:3000, click the gear icon (Settings), and enter your API key(s).

Environment Variables (Optional)

Variable Description
NEXT_PUBLIC_AUTH_ENABLED=true Enable authentication (requires NextAuth setup)

AI keys are configured in the UI โ€” no environment variables required for basic usage.


Usage

Action How
Analyze a repo Add m before any github.com URL โ†’ mgithub.com/owner/repo
Paste a URL Enter any GitHub repo URL on the homepage
Browse code Open the Code tab to view syntax-highlighted files with outline navigation
Scan for issues Open the Issues tab for automated security and quality analysis
Generate docs Open the Docs tab and select a document type
Chat with AI Open the Chat tab and ask questions about the codebase
Compare repos Navigate to the Compare tab to evaluate repositories side-by-side

Tech Stack

Category Technology
Framework Next.js 15 (App Router)
UI React 19, Tailwind CSS, shadcn/ui
Language TypeScript 5
AI Vercel AI SDK v6
Diagrams Mermaid.js
Syntax highlighting Shiki
Repo extraction JSZip
Testing Vitest, Playwright
Deployment Vercel

Contributing

  1. Fork the repo and create a branch.
  2. Make your changes.
  3. Run pnpm test to verify.
  4. Open a pull request.

About

Find functions, trace logic, and instantly ๐ฏ๐ข๐ฌ๐ฎ๐š๐ฅ๐ข๐ณ๐ž ๐†๐ข๐ญ๐‡๐ฎ๐› ๐ฉ๐ซ๐จ๐ฃ๐ž๐œ๐ญ๐ฌ. Surface tech debt, hidden risks, and poor coding practices before they become problems.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages