# Latest Changes in Palmier Pro: AI Editing, Metal Rendering, and Vector Search

> Discover the latest Palmier Pro updates including AI editing, Metal rendering, and vector search. Built with Swift 6.2 and rigorously tested for peak performance.

- Repository: [Palmier/palmier-pro](https://github.com/palmier-io/palmier-pro)
- Tags: release-notes
- Published: 2026-06-23

---

**Palmier Pro's latest main branch update introduces AI-driven editing menus, Metal-accelerated video effects, and a vector-based search index, all built with Swift 6.2 and covered by extensive tests.**

Palmier Pro is an AI-native video editor for macOS built with **Swift 6.2**, **SwiftUI**, and **AVFoundation**. The latest changes in Palmier Pro (commit `ab0ca99…`) deliver high-impact updates that tighten the AI-editing workflow, modernize the rendering pipeline with custom Metal kernels, and extend the search system to support both visual and textual embeddings.

## AI-Enhanced Editing Menu in TimelineView

The `TimelineView` now exposes AI-driven actions through new SwiftUI extensions. Users can trigger operations like *"Generate Clip"* and *"Replace Audio"* directly from the timeline interface.

Implementation resides in **`Sources/PalmierPro/Timeline/TimelineView+AIEditMenu.swift`**. This file registers menu items, forwards requests to the central `Editor` object, and inserts resulting operations into the undo stack via `Editor.commit` calls.

```swift
// Trigger AI generation from a SwiftUI view
Button("Generate Clip") {
    timelineView.performAIEdits(.generateClip) { result in
        switch result {
        case .success(let newClip):
            print("Created clip \(newClip.id)")
        case .failure(let err):
            print("AI generation failed: \(err)")
        }
    }
}

```

## Metal-Accelerated Rendering Pipeline

The rendering pipeline now utilizes custom **Metal kernels** for real-time visual effects without CPU overhead. The plugin loader in **[`Plugins/MetalCIKernelPlugin/MetalCIKernelPlugin.swift`](https://github.com/palmier-io/palmier-pro/blob/main/Plugins/MetalCIKernelPlugin/MetalCIKernelPlugin.swift)** registers these kernels with Core Image, exposing them as `CIKernel` objects to Swift.

Key additions include:

- **`Metal/Levels.metal`** – Tone-mapping and exposure controls
- **`Metal/LUTTetra.metal`** – 3-D LUT application for color grading  
- **`Metal/Glow.metal`** – Optimized bloom and glow effects

```swift
import CoreImage

let ciImage = CIImage(contentsOf: videoFrameURL)!
let lutKernel = try! LUTTetraKernel.load()
let processed = lutKernel.apply(to: ciImage, parameters: ["intensity": 0.85])

```

## Vector-Based Search Index Refactor

The search subsystem has been rearchitected to support **visual and text embeddings** through a new coordinator pattern. This enables semantic search across video content using machine learning models stored under the `models/` directory.

Core components include:

- **[`Sources/PalmierPro/Search/SearchIndexCoordinator.swift`](https://github.com/palmier-io/palmier-pro/blob/main/Sources/PalmierPro/Search/SearchIndexCoordinator.swift)** – Orchestrates async indexing, updates, and query handling via `searchVisual(image:completion:)`
- **[`Sources/PalmierPro/Search/SearchIndexConfig.swift`](https://github.com/palmier-io/palmier-pro/blob/main/Sources/PalmierPro/Search/SearchIndexConfig.swift)** – Defines model paths and hyper-parameters for embedding generation

```swift
let queryImage = UIImage(named: "example.png")!
SearchIndexCoordinator.shared.searchVisual(image: queryImage) { results in
    for hit in results {
        print("Found clip \(hit.clipId) with similarity \(hit.score)")
    }
}

```

Tests in **[`Tests/PalmierProTests/Search/VisualSearchTests.swift`](https://github.com/palmier-io/palmier-pro/blob/main/Tests/PalmierProTests/Search/VisualSearchTests.swift)** verify end-to-end indexing, retrieval, and on-the-fly model downloads.

## Timeline Snap Engine and Geometry Improvements

The **`SnapEngine`** now supports magnetic snapping for clip boundaries and keyframes, improving precision during drag-and-drop edits. Updated geometry calculations live in **[`Sources/PalmierPro/Timeline/TimelineGeometry.swift`](https://github.com/palmier-io/palmier-pro/blob/main/Sources/PalmierPro/Timeline/TimelineGeometry.swift)**, while visual snap hints render through **[`Sources/PalmierPro/Timeline/SnapIndicatorOverlay.swift`](https://github.com/palmier-io/palmier-pro/blob/main/Sources/PalmierPro/Timeline/SnapIndicatorOverlay.swift)**.

## Unified Design System with AppTheme

All UI components now strictly reference **[`Sources/PalmierPro/UI/AppTheme.swift`](https://github.com/palmier-io/palmier-pro/blob/main/Sources/PalmierPro/UI/AppTheme.swift)** for design tokens. This eliminates hard-coded values for spacing, fonts, colors, and radii, enabling consistent theming across the SwiftUI and AppKit hybrid interface.

```swift
Text("Hello, Palmier")
    .font(.system(size: AppTheme.FontSize.display))
    .foregroundColor(AppTheme.Text.primary)
    .padding(AppTheme.Spacing.m)
    .background(AppTheme.Background.secondary)
    .cornerRadius(AppTheme.Radius.l)

```

## Additional Architecture Improvements

**Drag-and-Drop Fixes** – A documented macOS 26 issue with nested SwiftUI `onDrop` modifiers is resolved in **[`Sources/PalmierPro/MediaPanel/MediaTab/MediaPanelDropArea.swift`](https://github.com/palmier-io/palmier-pro/blob/main/Sources/PalmierPro/MediaPanel/MediaTab/MediaPanelDropArea.swift)** by enforcing native AppKit drop targets for parent areas while leaf nodes continue using SwiftUI drops.

**Audio Synchronization** – Faster correlation algorithms via `AudioSyncCorrelator`, tested in **[`Tests/PalmierProTests/Audio/AudioSyncCorrelatorTests.swift`](https://github.com/palmier-io/palmier-pro/blob/main/Tests/PalmierProTests/Audio/AudioSyncCorrelatorTests.swift)**.

**Caption Generation** – Automated text-to-speech and subtitle generation pipeline in **[`Sources/PalmierPro/Captions/CaptionBuilder.swift`](https://github.com/palmier-io/palmier-pro/blob/main/Sources/PalmierPro/Captions/CaptionBuilder.swift)**.

**Project I/O** – Round-trip serialization improvements through **[`Sources/PalmierPro/Media/ProjectDocumentIO.swift`](https://github.com/palmier-io/palmier-pro/blob/main/Sources/PalmierPro/Media/ProjectDocumentIO.swift)**.

**Export Updates** – Lottie and XML exporters refreshed in **[`Sources/PalmierPro/Export/LottieExport.swift`](https://github.com/palmier-io/palmier-pro/blob/main/Sources/PalmierPro/Export/LottieExport.swift)** for newer AVFoundation specifications.

**Concurrency Utilities** – Added `AsyncSemaphore` in **[`Sources/PalmierPro/Utilities/AsyncSemaphore.swift`](https://github.com/palmier-io/palmier-pro/blob/main/Sources/PalmierPro/Utilities/AsyncSemaphore.swift)** for async task throttling.

## Summary

- **AI Editing**: New `TimelineView+AIEditMenu.swift` provides SwiftUI extensions for AI-driven clip generation and audio replacement, integrated with the undo system
- **Metal Rendering**: Custom kernels (`Levels.metal`, `LUTTetra.metal`, `Glow.metal`) registered via [`MetalCIKernelPlugin.swift`](https://github.com/palmier-io/palmier-pro/blob/main/MetalCIKernelPlugin.swift) deliver GPU-accelerated effects
- **Vector Search**: [`SearchIndexCoordinator.swift`](https://github.com/palmier-io/palmier-pro/blob/main/SearchIndexCoordinator.swift) enables visual and text-based semantic search with configurable embedding models
- **Timeline UX**: Magnetic snapping through `SnapEngine` and unified design tokens via [`AppTheme.swift`](https://github.com/palmier-io/palmier-pro/blob/main/AppTheme.swift) improve editing precision and UI consistency

## Frequently Asked Questions

### What version of Swift does Palmier Pro require?

The latest changes require **Swift 6.2** and target macOS exclusively, utilizing modern concurrency features and SwiftUI/AppKit interoperability.

### How does Palmier Pro handle AI-generated content undo operations?

AI edits route through the central `Editor` object, which commits operations to the undo stack. The `TimelineView+AIEditMenu.swift` file implements this via `performAIEdits(_:completion:)`, ensuring all AI-generated clips support standard undo/redo functionality.

### Can third-party developers extend the Metal rendering pipeline?

Yes. The [`MetalCIKernelPlugin.swift`](https://github.com/palmier-io/palmier-pro/blob/main/MetalCIKernelPlugin.swift) loader dynamically registers Metal kernels as Core Image filters. Developers can add custom `.metal` files following the pattern established in `Levels.metal` or `LUTTetra.metal`, then wrap them in Swift classes conforming to the kernel protocol defined in [`Sources/PalmierPro/Rendering/EffectKernels.swift`](https://github.com/palmier-io/palmier-pro/blob/main/Sources/PalmierPro/Rendering/EffectKernels.swift).

### Where are the embedding models stored for the search feature?

Configuration in [`SearchIndexConfig.swift`](https://github.com/palmier-io/palmier-pro/blob/main/SearchIndexConfig.swift) references models located under the `models/` directory at the repository root. The system supports on-the-fly downloads and versioned model updates, with end-to-end functionality verified by [`VisualSearchTests.swift`](https://github.com/palmier-io/palmier-pro/blob/main/VisualSearchTests.swift).