- Rust 98.2%
- TypeScript 0.7%
- CSS 0.4%
- Shell 0.3%
- Python 0.3%
| .bmad-core | ||
| .claude/commands/BMad | ||
| .cursor/rules/bmad | ||
| .gemini/commands/BMad | ||
| .github | ||
| .qwen/bmad-method | ||
| .serena | ||
| .windsurf/workflows | ||
| benches | ||
| claudedocs | ||
| crates | ||
| docs | ||
| examples | ||
| frontend/src/components/consistency | ||
| scripts | ||
| tools | ||
| .env.local | ||
| .envrc | ||
| .gitignore | ||
| .kilocodemodes | ||
| .pre-commit-config.yaml | ||
| ADD_PROVIDER_FIX_SUMMARY.md | ||
| ADD_PROVIDER_FLOW_DIAGRAM.md | ||
| add_reasoning_field.py | ||
| AGENTS.md | ||
| AI_INTEGRATION_IMPLEMENTATION_SUMMARY.md | ||
| Cargo.toml | ||
| compilation_progress_report.md | ||
| DEVELOPMENT_SHORTCUTS.md | ||
| EPIC4_COMPLETION_STATUS.md | ||
| EPIC4_REAL_DATA_INTEGRATION_COMPLETE.md | ||
| EPIC4_REAL_DATA_INTEGRATION_SUMMARY.md | ||
| EPIC4_REAL_DATA_STATUS.md | ||
| EPIC4_STATUS.md | ||
| EPIC5_PERFORMANCE_BENCHMARKS.md | ||
| EPIC5_STATUS_REPORT.md | ||
| EPIC6_IMPLEMENTATION_COMPLETE.md | ||
| EPIC7_STORY71_IMPLEMENTATION_SUMMARY.md | ||
| EPIC8_ADD_PROVIDER_FIX.md | ||
| EPIC8_IMPLEMENTATION_STATUS.md | ||
| error_analysis.md | ||
| final_status_report.md | ||
| fix_plan.md | ||
| fix_reasoning.py | ||
| fix_reasoning.sh | ||
| fix_reasoning_tokens.sh | ||
| flake.lock | ||
| flake.nix | ||
| opencode.jsonc | ||
| PERFORMANCE_OPTIMIZATION_SUMMARY.md | ||
| PLACEHOLDER_FINDINGS_REPORT.md | ||
| PLACEHOLDER_FIXES_SUMMARY.md | ||
| QUICK_REFERENCE_TESTING.md | ||
| README.md | ||
| REAL_DATA_INTEGRATION_DEPLOYMENT_GUIDE.md | ||
| REAL_DATA_INTEGRATION_STATUS.md | ||
| REAL_PARALLEL_PROCESSING_IMPLEMENTATION.md | ||
| S0.5_COMPLETION_SUMMARY.md | ||
| STORY_8_1_IMPLEMENTATION_SUMMARY.md | ||
| STORY_8_5_IMPLEMENTATION_SUMMARY.md | ||
| test_ai_integration.rs | ||
| test_enhanced_synthesis.py | ||
| test_parallel | ||
| test_parallel.rs | ||
| test_performance.rs | ||
| test_real_parallel_processing.rs | ||
| test_regex.js | ||
| test_simple.rs | ||
| test_story_4_2_core_synthesis_report.md | ||
| TESTING_AND_ERROR_HANDLING_REVIEW.md | ||
| TESTING_REVIEW_INDEX.md | ||
| TESTING_REVIEW_SUMMARY.md | ||
AI Grading Application
A desktop application built with Rust and Dioxus for grading documents using multiple AI providers.
Features
- Multi-provider AI integration (OpenAI, Anthropic, Google, Custom)
- Batch processing of documents
- Fallback and error recovery mechanisms
- Rate limiting and resource management
- Multi-modal pipeline with result aggregation
- Local SQLite database for data persistence
- Cross-platform desktop application
Requirements
- Rust 1.70 or higher
- Node.js and npm (for building frontend assets)
- SQLite 3 (included with the application)
Installation
Option 1: Using Nix (Recommended)
The easiest way to set up the development environment is using Nix with flakes and direnv:
- Install Nix with flakes enabled
- Install direnv and the nix-direnv extension
- Clone the repository:
git clone https://github.com/your-username/ai-grading-app.git cd ai-grading-app - Allow direnv to load the environment:
direnv allow
For detailed instructions, see docs/NIX_SETUP.md.
Option 2: Traditional Setup
-
Clone the repository:
git clone https://github.com/your-username/ai-grading-app.git cd ai-grading-app -
Install Rust dependencies:
cargo build --release
Running the Application
Development Mode
To run the application in development mode with hot reloading:
cargo run
Release Mode
To run the optimized release version:
cargo run --release
Building a Distribution Package
To build a distributable package for your platform:
cargo bundle --release
This will create a platform-specific package in the target/release/bundle/ directory:
- macOS:
.appbundle - Windows:
.msiinstaller - Linux:
.debpackage
Configuration
The application stores its configuration and data in the following locations:
- Windows:
%APPDATA%/ai-grading-app/ - macOS:
~/Library/Application Support/ai-grading-app/ - Linux:
~/.local/share/ai-grading-app/
API Keys
To use AI providers, you need to configure your API keys:
- Open the application
- Navigate to AI Configuration in the sidebar
- Add your providers and API keys
- Save the configuration
Development
Project Structure
ai-grading-app/
├── Cargo.toml # Workspace configuration
├── flake.nix # Nix flake configuration
├── .envrc # direnv configuration
├── README.md # This file
├── crates/ # Rust crates
│ ├── app/ # Main application
│ ├── shared/ # Shared types and utilities
│ ├── document_processing/ # Document content extraction
│ ├── ai_integration/ # AI provider integration
│ ├── rate_limiting/ # Rate limiting functionality
│ ├── fallback_manager/ # Error recovery mechanisms
│ ├── batch_processing/ # Batch processing logic
│ ├── multimodal_pipeline/ # Multi-modal analysis
│ ├── data_storage/ # Database abstraction
│ └── testing/ # Testing utilities
├── docs/ # Documentation
└── target/ # Build output
Running Tests
To run all tests:
cargo test
To run tests for a specific crate:
cargo test -p shared
Linting
To run Clippy for code quality checks:
cargo clippy -- -D warnings
Formatting
To format the code according to Rust standards:
cargo fmt
Architecture
The application follows a modular architecture with separate crates for different concerns:
- app: The main Dioxus desktop application
- shared: Common types and utilities used across crates
- document_processing: Extracts content from various document formats
- ai_integration: Handles communication with AI providers
- rate_limiting: Manages API rate limits
- fallback_manager: Implements error recovery strategies
- batch_processing: Coordinates batch operations
- multimodal_pipeline: Orchestrates multi-model analysis
- data_storage: Provides database abstraction
- testing: Contains testing utilities and mocks
Contributing
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
License
This project is licensed under the MIT License - see the LICENSE file for details.
Troubleshooting
Build Issues
If you encounter build issues, try:
- Using the Nix development environment (recommended)
- Updating Rust:
rustup update - Cleaning the build cache:
cargo clean - Rebuilding:
cargo build --release
OpenSSL Issues
If you encounter OpenSSL-related errors:
- Use the Nix development environment (recommended)
- Install OpenSSL development packages for your system
- Set the appropriate environment variables
Database Issues
If you encounter database-related errors:
- The application uses SQLite, which should work out of the box
- Database files are stored in the application data directory
- You can reset the database by deleting the
database.dbfile in the data directory
Nix Environment Issues
If you encounter issues with the Nix environment:
- Make sure Nix is installed with flakes enabled
- Check that direnv is properly configured
- Run
direnv allowin the project directory - See docs/NIX_SETUP.md for detailed troubleshooting