Skip to content

ProfessorMoose74/keystone-ai

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

3 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Keystone AI - Biblical β€’ Constitutional β€’ Economic Wisdom

Keystone AI Logo

iOS App Store Android Play Store Web App

The world's most advanced AI system combining biblical wisdom, constitutional principles, and conservative economic theory

🌟 What Makes Keystone AI Unique

Keystone AI is the only AI platform that seamlessly integrates:

  • πŸ“– Ethiopian Orthodox Bible (81 books) - The complete canon
  • πŸ›οΈ American Founding Documents - Constitution, Federalist Papers, Declaration of Independence
  • πŸ“Š Austrian/Chicago School Economics - Sound money, free markets, economic freedom
  • βš–οΈ Natural Law Philosophy - Timeless principles for modern challenges

πŸš€ Superior to Competitors

Unlike ChatGPT, Claude, or other generic AI systems, Keystone AI offers:

βœ… Purpose-Built Wisdom - Specifically designed for principled decision-making βœ… Multi-Modal Excellence - Chat, voice, widgets, CarPlay, Siri integration βœ… Advanced Personalization - Learns your growth patterns and adapts content βœ… Community Learning - Wisdom circles, study groups, mentorship programs βœ… Enterprise-Grade Security - GDPR/CCPA compliant with enterprise SSO βœ… Cultural Sensitivity - 20+ languages with cultural adaptations βœ… Offline Capability - Local AI processing with on-device models

πŸ“± Mobile Apps (NEW!)

iOS App Features

  • Modern Chat Interface - Claude/ChatGPT-style conversation experience
  • 5 Widget Types - Daily wisdom, quick access, streak tracking, search
  • Siri Integration - "Hey Siri, ask Keystone AI about leadership"
  • CarPlay Support - Safe, voice-first experience while driving
  • HealthKit Integration - Track mindfulness and spiritual growth
  • Family Accounts - Parental controls and age-appropriate content

Android App Features

  • Material Design 3 - Beautiful, modern interface
  • Google Assistant Integration - Voice commands and shortcuts
  • Android Auto Support - Dashboard-friendly experience
  • Adaptive Widgets - Dynamic content updates
  • Enterprise MDM - Corporate deployment ready

πŸ—οΈ Architecture Overview

Backend (FastAPI + Python)

  • RAG System: Advanced retrieval-augmented generation
  • Vector Database: ChromaDB with semantic search
  • Local AI Models: Gemma-3-1B-IT for on-device processing
  • Multi-language Support: 20+ languages with cultural adaptations

Frontend (React + TypeScript)

  • Modern UI: Responsive, accessible design
  • Real-time Features: WebSocket connections
  • PWA Support: Installable web app
  • Offline Mode: Full functionality without internet

Mobile (Native iOS/Android)

  • SwiftUI (iOS): Native iOS experience with system integrations
  • Kotlin + Compose (Android): Material Design with Android features
  • Cross-Platform Services: Shared business logic and data models

πŸš€ Quick Start Guide

πŸ“± Mobile Installation

iOS (Recommended)

# For development
git clone https://github.com/your-org/keystone-ai.git
cd keystone-ai/mobile/ios
open KeystoneAI.xcodeproj

# For users - Download from App Store
# https://apps.apple.com/app/keystone-ai

Android

# For development
git clone https://github.com/your-org/keystone-ai.git
cd keystone-ai/mobile/android
./gradlew build

# For users - Download from Play Store
# https://play.google.com/store/apps/details?id=com.keystoneai.app

🌐 Web Application

# Clone repository
git clone https://github.com/your-org/keystone-ai.git
cd keystone-ai

# Backend setup
cd backend
python -m venv venv
source venv/bin/activate  # Windows: venv\Scripts\activate
pip install -r requirements.txt
uvicorn main:app --reload

# Frontend setup
cd ../frontend
npm install
npm run dev

βš™οΈ System Requirements

Mobile

  • iOS: iPhone 12+ with iOS 17.4+, iPad 9th gen+ with iPadOS 17.4+
  • Android: Android 8.0+ (API level 26), 4GB+ RAM recommended

Web/Desktop

  • Browser: Chrome 90+, Safari 15+, Firefox 88+, Edge 90+
  • RAM: 4GB minimum, 8GB recommended
  • Storage: 2GB available space

🎯 Core Features

πŸ’¬ AI Chat Experience

  • Natural Conversations - Context-aware, multi-turn dialogues
  • Voice Input/Output - Speak your questions, hear the responses
  • Citation Tracking - Every answer includes biblical/constitutional sources
  • Conversation Memory - Remembers context across sessions

πŸ“š Knowledge Integration

  • Ethiopian Orthodox Bible (81 Books) - Complete canonical texts
  • U.S. Constitution & Amendments - Founding documents analysis
  • Economic Principles - Austrian school, Chicago school, free market theory
  • Historical Context - Founding fathers' writings and speeches

πŸŽ›οΈ Advanced Personalization

  • Learning Patterns - AI adapts to your interests and growth level
  • Content Difficulty - Beginner to expert level explanations
  • Cultural Adaptation - Content adjusted for your region and language
  • Growth Tracking - Monitor your spiritual, civic, and economic understanding

🌍 Community Features

  • Wisdom Circles - Private groups for focused study
  • Study Groups - Structured learning with assignments
  • Mentorship Program - Connect with experienced guides
  • Prayer Network - Share and receive prayer requests
  • Discussion Forums - Engage with like-minded community

πŸ“Š Analytics & Insights

  • Personal Growth Dashboard - Track your learning journey
  • Achievement System - Unlock milestones and badges
  • Weekly Reports - See your progress and recommendations
  • Habit Tracking - Build consistent spiritual and civic practices

πŸ” Privacy & Security

  • End-to-End Encryption - All personal data protected
  • Local Processing - Sensitive conversations processed on-device
  • GDPR/CCPA Compliant - Full data privacy rights
  • Enterprise Security - SOC 2 compliance, audit logs

πŸ“Š Account Types

Individual ($9.99/month)

  • Full AI chat access
  • Personal growth tracking
  • Basic widgets and shortcuts
  • Cloud sync across devices

Family ($19.99/month)

  • Up to 6 family members
  • Parental controls and content filtering
  • Family sharing of wisdom and insights
  • Screen time management
  • Age-appropriate content delivery

Enterprise ($49.99/user/month)

  • Single sign-on (SSO) integration
  • Admin dashboard and user management
  • Audit logs and compliance reporting
  • Custom branding and deployment
  • Priority support and training

πŸ—οΈ Project Structure

keystone-ai/
β”œβ”€β”€ mobile/
β”‚   β”œβ”€β”€ ios/                    # Native iOS app (SwiftUI)
β”‚   β”‚   β”œβ”€β”€ KeystoneAI/        # Main app target
β”‚   β”‚   β”œβ”€β”€ KeystoneAIWidgets/ # Home screen widgets
β”‚   β”‚   β”œβ”€β”€ Intents/           # Siri Shortcuts
β”‚   β”‚   └── Services/          # Core services
β”‚   └── android/               # Native Android app (Kotlin + Compose)
β”œβ”€β”€ backend/                   # FastAPI Python backend
β”‚   β”œβ”€β”€ app/                   # Application code
β”‚   β”œβ”€β”€ models/                # Data models
β”‚   β”œβ”€β”€ services/              # Business logic
β”‚   └── api/                   # API endpoints
β”œβ”€β”€ frontend/                  # React web application
β”‚   β”œβ”€β”€ src/                   # Source code
β”‚   β”œβ”€β”€ components/            # UI components
β”‚   └── services/              # API clients
β”œβ”€β”€ data/
β”‚   β”œβ”€β”€ sources/               # Source documents (Bible, Constitution, Economics)
β”‚   β”œβ”€β”€ vectors/               # Vector embeddings database
β”‚   └── localization/          # Multi-language content
β”œβ”€β”€ docs/                      # Documentation
β”‚   β”œβ”€β”€ api/                   # API documentation
β”‚   β”œβ”€β”€ mobile/                # Mobile development guides
β”‚   └── deployment/            # Deployment instructions
└── tests/                     # Comprehensive test suites
    β”œβ”€β”€ unit/                  # Unit tests
    β”œβ”€β”€ integration/           # Integration tests
    └── e2e/                   # End-to-end tests

πŸ› οΈ Development

Mobile Development

iOS Development Setup

# Prerequisites: macOS, Xcode 15.0+, iOS 17.4+ SDK
git clone https://github.com/your-org/keystone-ai.git
cd keystone-ai/mobile/ios

# Open in Xcode
open KeystoneAI.xcodeproj

# Build and run
# Select target device/simulator and press Cmd+R

# Build for different targets
./build.sh simulator      # Build for simulator
./build.sh device-debug   # Debug build for device
./build.sh archive        # Create App Store archive
./build.sh testflight     # Build for TestFlight

Android Development Setup

# Prerequisites: Android Studio, Android SDK 26+
git clone https://github.com/your-org/keystone-ai.git
cd keystone-ai/mobile/android

# Build with Gradle
./gradlew assembleDebug   # Debug build
./gradlew assembleRelease # Release build
./gradlew bundle          # Create Play Store bundle

Backend Development

# Set up Python environment
python -m venv venv
source venv/bin/activate  # Windows: venv\Scripts\activate

# Install dependencies
pip install -r requirements.txt
pip install -r requirements-dev.txt

# Set up pre-commit hooks
pre-commit install

# Run tests
pytest tests/ -v

# Start development server
uvicorn app.main:app --reload --host 0.0.0.0 --port 8000

Frontend Development

# Install dependencies
npm install

# Start development server
npm run dev

# Run tests
npm test

# Build for production
npm run build

Testing

Automated Testing

# Run all tests
npm run test:all

# Run mobile tests
cd mobile/ios && xcodebuild test
cd mobile/android && ./gradlew test

# Run backend tests
pytest backend/tests/ -v --cov=app

# Run frontend tests
cd frontend && npm test

Manual Testing Checklist

  • Chat interface responsiveness
  • Voice input/output functionality
  • Widget updates and interactions
  • Siri/Google Assistant integration
  • Offline mode functionality
  • Multi-language support
  • Accessibility features
  • Performance under load

Documentation

  • API Docs: Available at /docs when running backend
  • Mobile Guides: See mobile/ios/INSTALLATION.md and mobile/android/INSTALLATION.md
  • Architecture: See docs/architecture.md
  • Deployment: See docs/deployment/

πŸš€ Deployment

Mobile App Store Deployment

iOS App Store

  1. Prepare for Submission

    cd mobile/ios
    ./build.sh archive
    ./build.sh upload
  2. App Store Connect Configuration

    • Set app metadata and screenshots
    • Configure pricing and availability
    • Submit for App Review
  3. TestFlight Beta Testing

    ./build.sh testflight

Android Play Store

  1. Create Release Bundle

    cd mobile/android
    ./gradlew bundleRelease
  2. Upload to Play Console

    • Upload AAB file
    • Set store listing details
    • Configure rollout strategy

Web Application Deployment

Docker Deployment

# Build and deploy with Docker
docker-compose up -d

# Or deploy individual services
docker build -t keystone-ai-backend ./backend
docker build -t keystone-ai-frontend ./frontend

Cloud Deployment (AWS/GCP/Azure)

# Backend deployment
terraform init
terraform plan
terraform apply

# Frontend deployment (CDN)
aws s3 sync frontend/dist/ s3://keystone-ai-frontend
aws cloudfront create-invalidation

πŸ“– API Documentation

Authentication

# Get access token
POST /auth/token
{
  "email": "user@example.com",
  "password": "secure_password"
}

Chat API

# Send message
POST /chat/message
{
  "message": "What does the Bible say about leadership?",
  "context_type": "biblical",
  "conversation_id": "uuid"
}

# Get conversation history
GET /chat/conversations/{conversation_id}

Search API

# Semantic search
POST /search/semantic
{
  "query": "constitutional principles",
  "filters": ["biblical", "constitutional"],
  "limit": 10
}

User Management

# Create user account
POST /users/register
{
  "email": "user@example.com",
  "password": "secure_password",
  "account_type": "individual"
}

# Update user profile
PUT /users/profile
{
  "display_name": "John Doe",
  "preferences": {...}
}

πŸ”§ Configuration

Environment Variables

Backend (.env)

# Database
DATABASE_URL=postgresql://user:pass@localhost/keystone_ai
REDIS_URL=redis://localhost:6379

# API Keys
OPENAI_API_KEY=your_openai_key
ANTHROPIC_API_KEY=your_anthropic_key

# Security
SECRET_KEY=your_secret_key
JWT_SECRET=your_jwt_secret

# Services
SMTP_SERVER=smtp.gmail.com
SMTP_PORT=587
SMTP_USERNAME=your_email
SMTP_PASSWORD=your_password

# CloudKit (iOS)
CLOUDKIT_CONTAINER_ID=iCloud.com.keystoneai.app
CLOUDKIT_ENVIRONMENT=production

Mobile Configuration

# iOS (Config.plist)
API_BASE_URL=https://api.keystoneai.com
GEMMA_MODEL_VERSION=3-1b-it
ENABLE_OFFLINE_MODE=true
ENABLE_ANALYTICS=false

# Android (config.properties)
api.base.url=https://api.keystoneai.com
gemma.model.version=3-1b-it
enable.offline.mode=true
enable.analytics=false

🀝 Contributing

We welcome contributions! Please see CONTRIBUTING.md for guidelines.

Development Workflow

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Make your changes
  4. Add tests for new functionality
  5. Run the test suite (npm run test:all)
  6. Commit your changes (git commit -m 'Add amazing feature')
  7. Push to the branch (git push origin feature/amazing-feature)
  8. Open a Pull Request

Code Style Guidelines

  • Swift: Follow Swift API Design Guidelines
  • Kotlin: Follow Kotlin coding conventions
  • Python: Follow PEP 8 with Black formatting
  • TypeScript: Follow Airbnb JavaScript/TypeScript style guide
  • Documentation: Use clear, concise language with examples

πŸ› Bug Reports & Feature Requests

Bug Reports

Please use the issue tracker with:

  • Clear description of the issue
  • Steps to reproduce
  • Expected vs actual behavior
  • Screenshots/logs if applicable
  • Device/OS/app version information

Feature Requests

Submit feature requests through GitHub Discussions with:

  • Clear description of the feature
  • Use case and benefits
  • Any relevant mockups or examples
  • Implementation considerations

πŸ“Š Analytics & Monitoring

Performance Monitoring

  • Mobile: Firebase Performance (iOS/Android)
  • Backend: DataDog/New Relic monitoring
  • Frontend: Web Vitals and user analytics

Privacy-Compliant Analytics

  • No personal data collection without explicit consent
  • Anonymized usage patterns for app improvement
  • Opt-out available in app settings
  • GDPR/CCPA compliant data handling

πŸ”’ Security

Security Features

  • End-to-end encryption for personal conversations
  • Local AI processing for sensitive content
  • Zero-knowledge architecture for private data
  • Regular security audits and penetration testing

Reporting Security Issues

Please report security vulnerabilities to security@keystoneai.com with:

  • Description of the vulnerability
  • Steps to reproduce
  • Potential impact assessment
  • Suggested remediation (if known)

Do not report security issues through public GitHub issues.

πŸ“ž Support

Community Support

Premium Support

Support Hours

  • Community Support: 24/7 via Discord and GitHub
  • Email Support: Monday-Friday, 9 AM - 6 PM EST
  • Enterprise Support: 24/7 for critical issues

πŸ“„ License

Proprietary License - All Rights Reserved

Β© 2024 Keystone AI, LLC. This software and associated documentation files are proprietary and confidential. Unauthorized copying, distribution, or modification is strictly prohibited.

Commercial Licensing

For commercial licensing inquiries, please contact licensing@keystoneai.com

Open Source Components

This project uses various open source libraries. See LICENSES.md for details on third-party licenses.


🌟 Built with Faith, Freedom, and Free Markets 🌟

Download iOS App β€’ Download Android App β€’ Try Web App

"Where Biblical Wisdom meets Constitutional Principles and Economic Freedom"

About

AI based on Conservative values, fundamentals

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors