Inspiration
I've had the idea to write a similar app to LittleChef for a long time. As the person in charge for meal planning and grocesy shopping lists for the household, I went through many different tools and systems. From pen and paper notebooks, to Apple Notes, eventually landing at Obsidian and recipes in markdown format, using AI tools to suggest and plan meals. LittleChef is an attempt at combining all these different workflows into one app.
What it does
LittleChef is an AI-powered recipe management app for iOS/iPadOS that revolutionizes how people organize, discover, and cook recipes. Key features include:
- AI Recipe Import: Extract recipes from any URL using GPT-4o, Gemini, or on-device Foundation Models
- Markdown-First Storage: Recipes stored as human-readable markdown files for ultimate portability
- Intelligent Shopping Lists: Auto-generated from planned recipes with ingredient merging and categorization
How we built it
Architecture & Framework:
- The Composable Architecture (TCA): Type-safe state management with comprehensive testing
- Tuist: Modular project structure with strict dependency boundaries
- SwiftUI: Modern iOS interface with iPad support
- Repository Pattern: Database-agnostic interfaces with GRDB SQLite (SQLiteData) implementation
Key Technical Innovations:
- Markdown as Source of Truth: Instead of complex database schemas, recipes are stored as portable markdown files
- MarkdownRecipeCodec: Bi-directional conversion between markdown and Recipe objects while preserving user content
- Smart AI Provider Selection: On-device Foundation Models for free users (quota-free), cloud providers for Pro users
- Quota Management System: iCloud-synced quota tracking with reservation/confirmation pattern
- Multi-Provider AI Integration: OpenAI GPT-4o, Gemini 1.5, and Apple Foundation Models with tier-based routing
Development Practices:
- Swift 6: Strict concurrency with configurable levels per module
- Comprehensive Testing: Swift Testing framework with exhaustive TCA reducer tests
- CI/CD: Hybrid GitHub Actions + Xcode Cloud approach
- Code Quality: SwiftLint, SwiftFormat, Danger PR validation
Challenges we ran into
Technical Architecture:
- Markdown Complexity: Designing bi-directional conversion that preserves user formatting while maintaining the same structure
- AI Provider Coordination: Managing multiple AI providers with different capabilities, costs, and availability
- Quota Management: Building fair usage system with iCloud sync, reservation patterns, and monthly resets
- Modular Boundaries: Maintaining strict dependency separation across 20+ modules in Tuist
AI Integration Challenges:
- Provider Reliability: Handling network failures, rate limits, and parsing errors across multiple AI services
- On-Device vs Cloud: Implementing fallback strategies when on-device AI fails
- Content Extraction: Reliable recipe extraction from varied website formats using SwiftSoup
iOS Development Complexity:
- TCA Testing: Comprehensive test coverage for async operations, effects, and state mutations
- Screenshot Automation: Supporting iPhone 16 and iPad M4 devices with device mapping for frameit
- Subscription Management: RevenueCat integration with tier-based feature gating
Accomplishments that we're proud of
- Markdown-First Approach: data model that combines human readability with programmatic structure
- TCA Test Coverage: Every reducer comprehensively tested with Swift Testing framework
- Modular Architecture: 20+ independent modules with clean interfaces and dependency injection
- Performance Optimization: Efficient ingredient deduplication using SHA256 hashing
- Cross-Platform Ready: Architecture designed for future macOS/visionOS expansion
- Smart Shopping Lists: Automatic ingredient merging with grocery store categorization
What we learned
Architecture Insights:
- TCA + Modular Design: The Composable Architecture scales excellently with Tuist's modular approach
- Repository Pattern: Database-agnostic interfaces enable easy testing and future migrations. The underlying database technology was changed multiple times throughout development (Swift Data > GRDB > SQLiteData), but thanks to the repositories these were mostly trivial and migration didn't affect the other features at all.
AI Integration Lessons:
- Multi-Provider Strategy: Provider diversification essential for reliability and cost optimization
- Quota Psychology: Transparent limits with on-device fallbacks create better user experience than hard blocks
- Content Preservation: AI should enhance, not replace, user-generated content
iOS Development:
- Swift 6 Migration: Gradual concurrency adoption via configurable levels per module works effectively
- Testing Strategy: Swift Testing framework significantly improves test readability over XCTest
- CI/CD Hybrid: GitHub Actions for code quality + Xcode Cloud for iOS testing provides optimal coverage
What's next for LittleChef - Smart recipe manager
As an upcoming feature, I'll be implementing iCloud sync and iCloud sharing, allowing sharing of meal plans, recipes and shopping lists with family members
Log in or sign up for Devpost to join the conversation.