Back to Portfolio
StackAudit • Open Source Intelligence
// OPEN SOURCE INTELLIGENCE Active & Maintained 2024 - Present

StackAudit

Open Source Contribution Intelligence Platform

Bridging the gap between ambitious developers and impactful open-source contributions through intelligent issue matching and deep architectural analysis.

ROLE & SCOPE Lead Architect & Full-Stack Engineer
PRIMARY ARCHITECTURE Backend API Service
DATABASE & CACHE PostgreSQL • Redis
85%
Latency Reduction

Achieved through multi-tier Redis caching for GitHub API responses and parsed repository ASTs.

< 1.2s
Analysis Latency

Average response time for end-to-end repository architectural decomposition and module mapping.

5,000+
Rate Limit Shield

Efficient ETag and TTL caching protects against GitHub REST/GraphQL API hourly rate exhaustion.

100+
Repositories Indexed

Curated dataset of active open-source projects across TypeScript, C++, Python, and Go.

The Problem & System Scope

StackAudit was built to solve a pervasive problem in open source: developers spend hours sifting through thousands of stale, mislabeled, or overwhelmingly complex GitHub issues. StackAudit indexes repositories, evaluates developer proficiencies against issue prerequisites, and generates instant architectural file-tree maps to dramatically shorten the ramp-up time before submitting a pull request.

End-to-End Architectural Design

StackAudit employs a decoupled full-stack architecture. The Next.js frontend delivers a high-speed, interactive search and inspection UI. The Node.js and Express backend coordinates background ingestion workers, queries GitHub APIs with conditional HTTP headers, stores persistent user profiles and bookmarks in PostgreSQL via Prisma ORM, and caches volatile repository structures in Redis.

01

Frontend Application

Next.js 14React 18Tailwind CSSLucide Icons

Server-side rendered search interface, responsive repository dashboard, interactive file-tree visualizer.

02

Backend API Service

Node.jsExpress.jsTypeScriptRESTful Endpoints

Request routing, GitHub API orchestration, rate-limit management, matching algorithms, authentication middleware.

03

In-Memory Cache & Rate Limiter

RedisioredisTTL Expiry

High-speed storage of volatile GitHub API payloads, ETag headers, and user rate-limit token buckets.

04

Relational Persistence

PostgreSQLPrisma ORMSupabase

User accounts, saved repositories, custom developer skill profiles, and contribution bookmarks.

Execution Pipeline & Data Flow
  1. STEP 1 Developer inputs query criteria (preferred language, tech stack, issue difficulty, repository activity velocity).
  2. STEP 2 API gateway checks Redis in-memory cache for recent indexed snapshots of matching repositories and issue lists.
  3. STEP 3 On cache miss, backend worker dispatches asynchronous requests to GitHub REST and GraphQL APIs with authorization tokens.
  4. STEP 4 The ingestion engine analyzes repository trees, filtering out build artifacts (dist, node_modules) and identifying core architecture entry points.
  5. STEP 5 A multi-factor matching algorithm calculates a compatibility score between developer skills and issue requirements.
  6. STEP 6 Persisted metrics and user bookmarks are committed to PostgreSQL via Prisma ORM for instantaneous recall.

Technology Choices & Justifications

Frontend Framework Next.js 14 & React

Enables instant server-side page loads for SEO, paired with React client components for dynamic filtering and responsive UI interactions.

Backend Runtime & Framework Node.js & Express.js

Asynchronous non-blocking I/O allows concurrent querying of external GitHub endpoints without thread starvation.

Database & Data Access PostgreSQL & Prisma ORM

Strict relational integrity and strong type-safety generated directly from schema definitions, eliminating runtime query bugs.

In-Memory Cache Redis

Essential for shielding the application against GitHub API rate limits (5,000 requests/hr) and serving frequent queries with sub-5ms latency.

Language TypeScript

End-to-end type safety between database models, backend API responses, and frontend component states.

Deep Technical Breakthroughs

CHALLENGE 01

GitHub API Rate Limit Depletion & Throttling

THE PROBLEM

Deeply querying repositories for file trees, commits, and issue metadata quickly exhausts GitHub API rate limits (5,000 req/hr) when multiple users search simultaneously.

ENGINEERING TRADEOFFS

Storing everything permanently in SQL would cause stale repository data; querying on every request leads to immediate 429 Too Many Requests errors.

IMPLEMENTED SOLUTION

Engineered a tiered Redis caching architecture with conditional HTTP ETags. Static repository structures are cached for 24 hours, active issues for 60 minutes. When re-fetching, the backend supplies `If-None-Match: [etag]` headers — if unchanged, GitHub returns 304 Not Modified which consumes 0 rate-limit quota.

CHALLENGE 02

Developer–Issue Compatibility Matching Algorithm

THE PROBLEM

Many issues labeled "good first issue" in major open-source repos actually involve undocumented internal abstractions, leading to frustration and abandoned PRs.

ENGINEERING TRADEOFFS

Simple keyword search missed context, while full LLM evaluation of every issue was cost-prohibitive.

IMPLEMENTED SOLUTION

Built a weighted heuristic scoring algorithm factoring in: (1) Lines of code modified in prior closed PRs with similar labels, (2) Language proficiency overlap, (3) Complexity of touched directory paths, and (4) Issue description clarity. Only top-ranked candidates are passed to LLM for final synthesis.

CHALLENGE 03

Large Repository Tree Traversal & Context Bloat

THE PROBLEM

Scanning repositories with tens of thousands of files overloaded client browsers and blew past token limits when passing code structure to analysis engines.

ENGINEERING TRADEOFFS

Truncating arbitrarily created blind spots; downloading full archives took too long.

IMPLEMENTED SOLUTION

Implemented an intelligent tree-pruning heuristic: auto-ignores known directories (`node_modules`, `vendor`, `dist`, `tests`), extracts key architectural indicators (`package.json`, `go.mod`, `Cargo.toml`, router directories), and maps high-level entry points into a streamlined 2-level architecture overview.

Production Engineering Logic

Redis Caching & ETag Conditional Fetcher TYPESCRIPT
Demonstrates intelligent rate-limit preservation with conditional ETags and tiered Redis TTLs.
import Redis from 'ioredis';
import axios, { AxiosResponse } from 'axios';

const redis = new Redis(process.env.REDIS_URL!);

interface CachedRepoData {
    etag: string;
    data: any;
}

export async function fetchRepositoryWithCache(owner: string, repo: string): Promise<any> {
    const cacheKey = `repo:${owner}:${repo}:meta`;
    const cached = await redis.get(cacheKey);

    let etagHeader: string | undefined;
    if (cached) {
        const parsed: CachedRepoData = JSON.parse(cached);
        etagHeader = parsed.etag;
    }

    try {
        const response: AxiosResponse = await axios.get(
            `https://api.github.com/repos/${owner}/${repo}`,
            {
                headers: {
                    Authorization: `Bearer ${process.env.GITHUB_TOKEN}`,
                    ...(etagHeader ? { 'If-None-Match': etagHeader } : {}),
                },
                validateStatus: (status) => status === 200 || status === 304,
            }
        );

        if (response.status === 304 && cached) {
            // Unchanged: refresh TTL, consume 0 rate limit units
            await redis.expire(cacheKey, 3600);
            return JSON.parse(cached).data;
        }

        // Fresh data: cache data with current ETag
        const payload: CachedRepoData = {
            etag: response.headers['etag'] || '',
            data: response.data,
        };
        await redis.setex(cacheKey, 3600, JSON.stringify(payload));
        return response.data;
    } catch (error) {
        // Fallback to cache if GitHub API fails
        if (cached) return JSON.parse(cached).data;
        throw error;
    }
}

Persistence & Schema Design

PostgreSQL schema modeled with Prisma ORM, balancing normalized developer data with fast indexed lookups for bookmarks and query telemetry.

❖

User

Developer accounts authenticated via GitHub OAuth.

KEY FIELDS
  • id: UUID
  • githubId: String
  • username: String
  • skills: String[]
  • createdAt: DateTime
❖

SavedIssue

Bookmarked issues tracked through contribution lifecycle.

KEY FIELDS
  • id: UUID
  • userId: UUID (FK)
  • issueUrl: String
  • status: Enum (INTERESTED, IN_PROGRESS, PR_SUBMITTED, MERGED)
❖

RepoAnalysisCache

Persisted architectural breakdown and relevant file mapping.

KEY FIELDS
  • repoId: String (PK)
  • architectureSummary: Json
  • lastSyncedAt: DateTime

Key Learnings & Future Enhancements

✓ Key Engineering Learnings

  • Mastered production caching design: combining HTTP ETags with Redis TTLs delivers near-infinite read scalability on top of strict third-party rate limits.
  • Learned how to model complex developer proficiency vectors against heterogeneous issue metadata.
  • Understood the performance boundary between relational SQL transactions and ephemeral in-memory key-value stores.

⚡ Future Roadmap (v2)

  • Add automated PR draft generation based on issue requirement specifications.
  • Introduce developer team workspaces for university open-source clubs.
  • Implement semantic vector embeddings via pgvector for natural language issue discovery.
// HIRE OR COLLABORATE

Interested in Discussing This Architecture?

I am actively looking for engineering opportunities, backend roles, and impactful software projects. Let's talk system design and code.