ai-codex  by skibidiskib

Compact codebase indexing for AI assistants

Created 1 month ago
255 stars

Top 98.8% on SourcePulse

GitHubView on GitHub
Project Summary

Summary

This project addresses the inefficiency of AI coding assistants repeatedly scanning large codebases, which consumes significant token budgets. ai-codex generates a compact, structured index of project elements, allowing AI assistants to instantly grasp project context. This benefits developers by saving AI interaction costs and accelerating AI-driven coding tasks.

How It Works

The tool automatically scans a project's directories to identify and index key structural elements. It generates five distinct Markdown files: API routes with HTTP methods, pages with rendering strategies, library function signatures, database schema details, and component trees with props. This pre-built index replaces the need for AI assistants to perform extensive file exploration, providing immediate context.

Quick Start & Requirements

  • Primary install/run command: npx ai-codex
  • Prerequisites: Node.js and npm/npx are implicitly required.
  • Configuration: Supports CLI flags (e.g., --output, --include, --exclude, --schema) and a codex.config.json file for customization.

Highlighted Details

  • Indexed Content: Captures API routes, page rendering strategies, library function signatures, database schemas (key fields, relationships), and component props.
  • Framework Support: Auto-detects and supports Next.js (App and Pages Routers) and generic TypeScript projects.
  • ORM Support: Integrates with Prisma and Drizzle ORMs for schema indexing.
  • Integration: Provides clear instructions for integrating the generated index with AI assistants like Claude Code and Cursor, and offers examples for Git pre-commit hooks and CI/CD pipelines.

Maintenance & Community

The project was entirely designed and written by Anthropic's AI coding assistant, Claude Code. No specific human contributors, community links (Discord/Slack), or roadmaps are mentioned in the README.

Licensing & Compatibility

  • License: MIT.
  • Compatibility: The MIT license is permissive and generally compatible with commercial use and closed-source projects.

Limitations & Caveats

Current framework support is primarily focused on Next.js and generic TypeScript. While ideas for supporting more frameworks (SvelteKit, Remix, Astro) and Python projects are listed under contributions, these are not yet implemented. Features like watch mode for continuous regeneration are also noted as potential future additions.

Health Check
Last Commit

3 days ago

Responsiveness

Inactive

Pull Requests (30d)
1
Issues (30d)
1
Star History
23 stars in the last 30 days

Explore Similar Projects

Feedback? Help us improve.