english-compiler  by uilicious

AI compiler POC for converting English markdown specs into code

created 2 years ago
296 stars

Top 90.6% on sourcepulse

GitHubView on GitHub
Project Summary

This project is a Proof-of-Concept (POC) AI-based compiler that translates English markdown specifications into functional code. It targets developers and researchers interested in novel code generation methods, aiming to demonstrate a future where natural language serves as a primary programming abstraction.

How It Works

The compiler tackles the input/output token limitations of current AI models by employing extensive prompt chaining and engineering. This allows it to generate larger codebases across multiple files or very large single files, which would otherwise exceed typical AI model constraints. The process involves numerous AI calls per file, making it slow but validating the concept of AI as an abstraction layer in programming.

Quick Start & Requirements

  • Install via npm: npm install -g english-compiler
  • Requires an OpenAI API key, configured in english-compiler.jsonc.
  • Supports caching for faster builds and resilience against API rate limits.
  • Demo projects are available with precomputed caches.

Highlighted Details

  • Capable of generating entire applications or large code files by overcoming AI token limits.
  • Uses a 1-to-1 mapping of markdown specification files (*.spec.md) to code files.
  • Supports an optional test: true parameter for JavaScript test script generation.
  • The project is a successor to internal work on AI for UI and unit test generation.

Maintenance & Community

The project is presented as a hackathon POC. The README mentions a successor project, smol-dev-js, and ongoing efforts to build better models for code generation, with fundraising mentioned.

Licensing & Compatibility

The README does not explicitly state a license. Given the project's origin and open-source release during a hackathon, users should verify licensing for commercial or closed-source use.

Limitations & Caveats

This is a POC and not production-ready, with known minor bugs in generated code. The build process is described as "slow as ass" due to the extensive AI calls required. The project's viability is dependent on OpenAI API availability and performance.

Health Check
Last commit

1 year ago

Responsiveness

Inactive

Pull Requests (30d)
0
Issues (30d)
0
Star History
7 stars in the last 90 days

Explore Similar Projects

Feedback? Help us improve.