Skip to content

Latest commit

 

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 

Repository files navigation

Vibe Chat iOS App

Vibe Chat is a sophisticated iOS application that provides an intuitive interface for AI-powered conversations using the GROQ API. The app features a modern SwiftUI interface with support for multiple AI models and secure API key management.

Features

  • 🚀 Multiple AI Models: Support for various GROQ models including:

    • LLaMA 3.1 8B Instant
    • LLaMA 3.3 70B Versatile
    • LLaMA Guard 4 12B
    • GPT OSS 120B/20B
    • Whisper Large V3/V3 Turbo
  • 🔒 Secure API Key Management:

    • Secure storage of GROQ API keys in iOS Keychain
    • API key validation with proper format checking
    • Easy key management through settings
  • 💬 Advanced Chat Interface:

    • Real-time messaging
    • Support for text-based conversations
    • Model switching during conversations
    • Clean, iOS-native design
    • Message history management
  • 🎨 Modern UI/UX:

    • iOS-native design patterns
    • Smooth animations and transitions
    • Custom navigation system
    • Responsive layout
    • Dark/Light mode support

Project Structure

VibeChat/
├── Vibe/
│   ├── VibeApp.swift         # Main app entry point
│   ├── ContentView.swift     # Welcome screen and main navigation
│   ├── ChatbotView.swift     # Chat interface implementation
│   ├── GroqClient.swift      # GROQ API integration
│   └── Keychain.swift        # Secure API key storage
└── Assets.xcassets/          # App images and resources

Key Components

VibeApp.swift

  • Main application entry point
  • Configures navigation bar appearance
  • Sets up the initial app state

ContentView.swift

  • Welcome screen implementation
  • Features overview
  • Navigation to chat interface
  • API key setup flow

ChatbotView.swift

  • Main chat interface
  • Model selection
  • Message management
  • Real-time interaction with AI

GroqClient.swift

  • GROQ API integration
  • Network request handling
  • Response parsing
  • Error management

Keychain.swift

  • Secure API key storage
  • Key validation
  • Keychain interaction methods

Technical Details

API Integration

The app uses the GROQ API for AI model interactions. API requests are structured as follows:

{
    "model": "<selected-model>",
    "messages": [
        {"role": "system", "content": "<system-message>"},
        {"role": "user", "content": "<user-message>"}
    ],
    "temperature": 0.7,
    "max_tokens": 800
}

Security

  • API keys are stored securely in the iOS Keychain
  • Keys are validated for proper format (must start with "gsk_")
  • Secure error handling for API and keychain operations

UI/UX Features

  • Custom navigation bar with model selection
  • Animated welcome screen with feature cards
  • Real-time chat interface with typing indicators
  • Model switching during active conversations
  • Settings management for API keys and preferences

Requirements

  • iOS 14.0 or later
  • Xcode 13.0 or later
  • Swift 5.5 or later
  • Valid GROQ API key

Getting Started

  1. Clone the repository
  2. Open Vibe.xcodeproj in Xcode
  3. Build and run the project
  4. On first launch, enter your GROQ API key
  5. Start chatting with the AI!

API Key Setup

  1. Obtain a GROQ API key from GROQ's website
  2. Launch the app
  3. Enter the API key when prompted
  4. The key will be securely stored for future use

Error Handling

The app handles various error scenarios:

  • Missing or invalid API keys
  • Network connection issues
  • API response errors
  • Model availability issues

Contributing

This project follows standard iOS development practices. When contributing:

  1. Fork the repository
  2. Create a feature branch
  3. Submit a pull request

About

Vibe Chat is a sophisticated iOS application that provides an intuitive interface for AI-powered conversations using the GROQ API. The app features a modern SwiftUI interface with support for multiple AI models and secure API key management.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages