Link Search Menu Expand Document

Developer Documentation

Technical documentation for extending and contributing to EiplGrader.

Documentation Sections

🏗️ Architecture Overview

Understand the system design and component relationships.

  • System architecture diagrams
  • Core design principles
  • Component interactions
  • Data flow patterns

🧩 Core Components

Deep dive into the main components.

🌐 Language System

Learn how language support works.

📚 API Reference

Complete API documentation.

  • Class methods and signatures
  • Parameter descriptions
  • Return value formats
  • Usage examples

🧪 Testing

Quality assurance and testing strategies.

  • Unit test structure
  • Integration testing
  • Language-specific tests
  • Performance benchmarks

🤝 Contributing

How to contribute to EiplGrader.

  • Development setup
  • Code style guidelines
  • Pull request process
  • Release procedures

Architecture at a Glance

┌─────────────────┐     ┌─────────────────┐
│  CodeGenerator  │     │   CodeTester    │
└────────┬────────┘     └────────┬────────┘
         │                       │
         ▼                       ▼
┌─────────────────┐     ┌─────────────────┐
│Language Adapters│     │Language Executors│
└────────┬────────┘     └────────┬────────┘
         │                       │
         └───────────┬───────────┘
                     ▼
            ┌─────────────────┐
            │Language Registry│
            └─────────────────┘

Key Concepts for Developers

Separation of Concerns

  • Adapters: Handle language-specific code generation
  • Executors: Handle language-specific code execution
  • Registry: Central registration and discovery

Extension Points

  1. New Languages: Add adapter + executor + register
  2. New LLM Providers: Implement ModelRequest interface
  3. Custom Test Runners: Extend CodeTester class
  4. New Generation Types: Extend prompt templates

Type System

  • Dynamic Languages: Automatic type inference
  • Static Languages: Explicit type validation
  • Type Mappers: Generic to language-specific types

Development Workflow

Setting Up

# Clone repository
git clone https://github.com/hamiltonfour/eiplgrader.git
cd eiplgrader

# Install development dependencies
pip install -e ".[dev]"

# Run tests
python -m pytest

# Run linting
./lint.sh

Adding a Feature

  1. Create feature branch
  2. Implement with tests
  3. Update documentation
  4. Submit pull request

Testing Changes

# Run unit tests
python -m pytest tests/unit/

# Run integration tests
python -m pytest tests/integration/

# Run specific language tests
python -m pytest tests/ -k "python"

Performance Considerations

Optimization Points

  • Parallel test execution
  • Executor pooling and reuse
  • Compilation caching
  • LLM response caching

Resource Management

  • Temporary file cleanup
  • Process isolation
  • Memory limits
  • Timeout enforcement

Security Model

Code Execution Isolation

  • Subprocess execution
  • Filesystem isolation
  • Network restrictions
  • Resource limits

Best Practices

  • Never execute in main process
  • Always validate inputs
  • Clean up temporary files

Getting Started

New to the codebase? Follow this path:

  1. Read Architecture Overview
  2. Explore Core Components
  3. Understand Language System
  4. Set up Development Environment

Ready to contribute? Check out our open issues or propose a new feature!


Table of contents