_CoreSpotlight_FoundationModels · IOS API REFERENCE
SpotlightSearchTool.Guide
struct · iOS 27.0+ · SDK 27.1
struct Guide
A type you use to offer guidance about what search capabillities to employ during a session.
Use this type to specify additional guidance about how you want the model to search your content. At
configuration time, configure an instance of this structure and assign it to the
``SpotlightSearchTool/Configuration/guide`` property of your configuration object. You use guidance
options primarily to limit the types of searches the model performs or to scope searches to specific
types of content. Adding guidance can help improve the efficiency of searches, especially if you
eliminate search techniques that don’t apply to your content.
The guidance for the model to use during a session.
Use this property to specify custom guidance for how to search your app’s content. The default
value of this property is ``SpotlightSearchTool/GuidanceLevel/complete``, which uses all available
search techniques and search all content types.
get · iOS 27.0+
format
TypeScript
get format(): SpotlightSearchTool_FormatLevel
Swift declaration
let format: SpotlightSearchTool.FormatLevel
The representation format for tool responses returned to the model.
Controls how search results are serialized in the model's context window.
Use ``FormatLevel/compact`` to reduce token consumption when
working with small-context models or long conversations.
A guide that includes only the search techniques specified by the given profile.
- Parameter profile: The set of search techniques and attributes the model may use.
A guide that searches only the specified content domain using a compact, on-device-friendly schema.
- Parameter domain: The content domain to focus on. Defaults to ``SpotlightSearchTool/ContentDomain/items``.
get · iOS 27.0+
complete
TypeScript
static get complete(): SpotlightSearchTool_Guide
Swift declaration
static var complete: SpotlightSearchTool.Guide { get }
A guide that uses all available search techniques.