498f407585
Introduce optional Apple account-backed credits with scoped gateway access while preserving local and BYOK paths. Refresh assistant behavior, tests, privacy disclosures, docs, and the website for the 2.0 experience.
17 lines
475 B
Swift
17 lines
475 B
Swift
// ManagedGatewayScopePolicy.swift
|
|
// OSGKeyboard · Shared
|
|
//
|
|
// Computes the smallest grant needed by the currently enabled managed paths.
|
|
|
|
import Foundation
|
|
|
|
public enum ManagedGatewayScopePolicy {
|
|
public static func scopes(engineMode: String) -> Set<ManagedGatewayCapability> {
|
|
var scopes: Set<ManagedGatewayCapability> = [.polish, .assistant, .agent]
|
|
if engineMode == "cloud" {
|
|
scopes.insert(.asr)
|
|
}
|
|
return scopes
|
|
}
|
|
}
|