Skip to content

kopon1/learnai

Repository files navigation

Abi - Your AI Study Assistant

Abi is a voice-first AI study assistant mobile application that uses your device camera to analyze study materials in real-time and provides intelligent, context-aware assistance powered by Anthropic's Claude AI.

Features

  • 📝 Homework Helper: Get hints and guidance without direct answers
  • 📖 Reading Comprehension: Understand complex texts with summaries and definitions
  • 🎓 Lecture Notes: Extract key points from lectures and presentations
  • 💻 Code Helper: Debug code and get improvement suggestions
  • 📚 History: Save and review past analyses
  • ⚙️ Customizable: Adjust image quality, auto-capture intervals, and more

Quick Start

Prerequisites

  • Flutter 3.16+ installed
  • Anthropic API key (Get one here)
  • iOS or Android device/emulator

Installation

  1. Clone and setup

    cd /path/to/learnai
    flutter pub get
  2. Get your API key

  3. Run the app

    flutter run
  4. Configure API key

    • Open the app
    • Go to Settings (gear icon)
    • Enter your Anthropic API key
    • The key will be validated and saved securely

Usage

  1. Select a mode (Homework, Reading, Lecture, or Code)
  2. Point your camera at study materials
  3. Tap the capture button to analyze
  4. View AI suggestions in the response modal
  5. Save to history for later review

Additional Features

  • Gallery: Analyze images from your photo library
  • Flash: Toggle for low-light environments
  • History: Access past analyses from the history screen
  • Auto-Capture: Enable to capture every 3/5/10 seconds

Project Structure

lib/
├── models/          # Data models
├── services/        # Business logic (Camera, API, Storage)
├── providers/       # State management
├── screens/         # Main UI screens
├── widgets/         # Reusable components
└── utils/           # Helper functions and constants

Configuration

Settings Available

  • Image Quality: High/Medium/Low (affects API costs)
  • Auto-Capture Interval: 3s/5s/10s
  • Response Length: Concise/Detailed
  • Reading Level: High School/College/Graduate
  • Text-to-Speech: Enable read-aloud feature
  • Save Images: Store images in history (can be disabled for privacy)

Development

Common Commands

# Install dependencies
flutter pub get

# Run app
flutter run

# Run tests
flutter test

# Build APK
flutter build apk --release

# Analyze code
flutter analyze

# Format code
dart format .

Architecture

StudentVision uses:

  • Provider for state management
  • Clean architecture with separation of concerns
  • Claude Vision API (claude-sonnet-4-20250514) for AI analysis
  • Secure storage for API keys
  • SharedPreferences for settings and history

See CLAUDE.md for detailed architecture documentation.

Privacy & Security

  • API key stored securely using flutter_secure_storage
  • Images can be excluded from history storage
  • No data sent to external servers except Anthropic API
  • All processing happens locally except AI analysis

Troubleshooting

Camera not working

  • Ensure camera permissions are granted
  • Check Settings > App Permissions

API errors

  • 401 Invalid API key: Check your API key in Settings
  • 429 Rate limit: Wait 60 seconds before retrying
  • Network error: Check internet connection

App won't build

flutter clean
flutter pub get
flutter run

Tech Stack

  • Framework: Flutter 3.16+
  • Language: Dart 3.2+
  • AI: Anthropic Claude Vision API
  • State Management: Provider
  • Storage: SharedPreferences, flutter_secure_storage
  • Camera: camera package
  • Permissions: permission_handler

License

This project is for educational purposes.

Support

For issues or questions:

  1. Check CLAUDE.md for detailed documentation
  2. Review the troubleshooting section above
  3. Ensure all dependencies are installed correctly

Credits

Powered by Claude AI from Anthropic

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published