FirebaseAILogic Framework Reference
FirebaseAILogic Framework Reference
Structures
The following structures are available globally.
GenerateContentResponse
Declaration
Swift
public struct GenerateContentResponse : Sendable
extension GenerateContentResponse: Decodable
Candidate
Declaration
Swift
public struct Candidate : Sendable
extension Candidate: Decodable
CitationMetadata
Declaration
Swift
public struct CitationMetadata : Sendable
extension CitationMetadata: Decodable
Citation
Declaration
Swift
public struct Citation : Sendable, Equatable
extension Citation: Decodable
FinishReason
Declaration
Swift
public struct FinishReason : DecodableProtoEnum, Hashable, Sendable
PromptFeedback
Declaration
Swift
public struct PromptFeedback : Sendable
extension PromptFeedback: Decodable
GroundingMetadata
Declaration
Swift
public struct GroundingMetadata : Sendable, Equatable, Hashable
extension GroundingMetadata: Decodable
Segment
Declaration
Swift
public struct Segment : Sendable, Equatable, Hashable
extension Segment: Decodable
GenerationConfig
Declaration
Swift
public struct GenerationConfig : Sendable, Equatable
extension GenerationConfig: Encodable
extension GenerationConfig: GenerationOptionsRepresentable
RequestOptions
Declaration
Swift
public struct RequestOptions : Sendable, Hashable
extension RequestOptions: Equatable
ModalityTokenCount
Declaration
Swift
public struct ModalityTokenCount : Sendable
extension ModalityTokenCount: Decodable
ContentModality
Declaration
Swift
public struct ContentModality : DecodableProtoEnum, Hashable, Sendable
ModelContent
Declaration
Swift
public struct ModelContent : Equatable, Sendable
extension ModelContent: Codable
SafetyRating
Declaration
Swift
public struct SafetyRating : Equatable, Hashable, Sendable
extension SafetyRating: Decodable
SafetySetting
Declaration
Swift
public struct SafetySetting : Sendable, Hashable
extension SafetySetting: Encodable
HarmCategory
Declaration
Swift
public struct HarmCategory : CodableProtoEnum, Hashable, Sendable
FunctionDeclaration
Declaration
Swift
public struct FunctionDeclaration : Sendable
extension FunctionDeclaration: Encodable
GoogleSearch
Declaration
Swift
public struct GoogleSearch : Sendable
extension GoogleSearch: Encodable
Tool
Declaration
Swift
public struct Tool : Sendable
extension Tool: Encodable
FunctionCallingConfig
Declaration
Swift
public struct FunctionCallingConfig : Sendable
extension FunctionCallingConfig: Encodable
ToolConfig
Declaration
Swift
public struct ToolConfig : Sendable
extension ToolConfig: Encodable
RetrievalConfig
Declaration
Swift
public struct RetrievalConfig : Sendable, Encodable
CountTokensResponse
Declaration
Swift
public struct CountTokensResponse : Sendable
extension CountTokensResponse: Decodable
Backend
Declaration
Swift
public struct Backend
GeminiModel
Declaration
Swift
public struct GeminiModel
extension GeminiModel: FirebaseAI.LanguageModel
GeminiModelProvider
Declaration
Swift
public struct GeminiModelProvider : LanguageModelProvider
HybridModel
Declaration
Swift
public struct HybridModel : FirebaseAI.LanguageModel
HybridModelProvider
Declaration
Swift
public struct HybridModelProvider : LanguageModelProvider
ImageConfig
Declaration
Swift
public struct ImageConfig : Sendable, Equatable
extension ImageConfig: Encodable
ActivityDetectionConfig
Declaration
Swift
public struct ActivityDetectionConfig : Sendable
AudioTranscriptionConfig
Declaration
Swift
@available(watchOS, unavailable)
public struct AudioTranscriptionConfig : Sendable
SlidingWindow
Declaration
Swift
@available(watchOS, unavailable)
public struct SlidingWindow : Sendable
ContextWindowCompressionConfig
Declaration
Swift
@available(watchOS, unavailable)
public struct ContextWindowCompressionConfig : Sendable
LiveAudioTranscription
Declaration
Swift
@available(watchOS, unavailable)
public struct LiveAudioTranscription : Sendable
LiveGenerationConfig
Declaration
Swift
@available(watchOS, unavailable)
public struct LiveGenerationConfig : Sendable
LiveServerContent
Declaration
Swift
@available(watchOS, unavailable)
public struct LiveServerContent : Sendable
LiveServerGoingAwayNotice
Declaration
Swift
@available(watchOS, unavailable)
public struct LiveServerGoingAwayNotice : Sendable
LiveServerMessage
Declaration
Swift
@available(watchOS, unavailable)
public struct LiveServerMessage : Sendable
LiveServerToolCall
Declaration
Swift
@available(watchOS, unavailable)
public struct LiveServerToolCall : Sendable
LiveServerToolCallCancellation
Declaration
Swift
@available(watchOS, unavailable)
public struct LiveServerToolCallCancellation : Sendable
LiveSessionUnsupportedMessageError
Declaration
Swift
@available(watchOS, unavailable)
public struct LiveSessionUnsupportedMessageError : Error, Sendable, CustomNSError
LiveSessionLostConnectionError
Declaration
Swift
@available(watchOS, unavailable)
public struct LiveSessionLostConnectionError : Error, Sendable, CustomNSError
LiveSessionUnexpectedClosureError
Declaration
Swift
@available(watchOS, unavailable)
public struct LiveSessionUnexpectedClosureError : Error, Sendable, CustomNSError
LiveSessionSetupError
Declaration
Swift
@available(watchOS, unavailable)
public struct LiveSessionSetupError : Error, Sendable, CustomNSError
LiveSessionResumptionUpdate
Declaration
Swift
@available(watchOS, unavailable)
public struct LiveSessionResumptionUpdate : Sendable
RealtimeInputConfig
Declaration
Swift
public struct RealtimeInputConfig : Sendable
SessionResumptionConfig
Declaration
Swift
@available(watchOS, unavailable)
public struct SessionResumptionConfig : Sendable
_ModelSessionResponse
Declaration
Swift
public struct _ModelSessionResponse : Sendable
MultiSpeakerVoiceConfig
Declaration
Swift
public struct MultiSpeakerVoiceConfig : Sendable
TextPart
Declaration
Swift
public struct TextPart : Part
InlineDataPart
Declaration
Swift
public struct InlineDataPart : Part
FileDataPart
Declaration
Swift
public struct FileDataPart : Part
FunctionCallPart
Declaration
Swift
public struct FunctionCallPart : Part
FunctionResponsePart
Declaration
Swift
public struct FunctionResponsePart : Part
ExecutableCodePart
Declaration
Swift
public struct ExecutableCodePart : Part
CodeExecutionResultPart
Declaration
Swift
public struct CodeExecutionResultPart : Part
ResponseGenerationOptions
Declaration
Swift
public struct ResponseGenerationOptions : Sendable, Equatable
extension ResponseGenerationOptions: GenerationOptionsRepresentable
ResponseModality
Declaration
Swift
public struct ResponseModality : EncodableProtoEnum, Sendable, Equatable
SpeakerVoiceConfig
Declaration
Swift
public struct SpeakerVoiceConfig : Sendable
SpeechConfig
Declaration
Swift
public struct SpeechConfig : Sendable
TemplateToolConfig
Declaration
Swift
public struct TemplateToolConfig : Sendable, Encodable
ThinkingConfig
Declaration
Swift
public struct ThinkingConfig : Sendable, Equatable
extension ThinkingConfig: Encodable
CodeExecution
Declaration
Swift
public struct CodeExecution : Sendable, Encodable
GoogleMaps
Declaration
Swift
public struct GoogleMaps : Sendable, Encodable
GoogleMapsGroundingChunk
Declaration
Swift
public struct GoogleMapsGroundingChunk : Sendable, Equatable, Hashable, Decodable
URLContextMetadata
Declaration
Swift
public struct URLContextMetadata : Sendable, Hashable
extension URLContextMetadata: Decodable
URLMetadata
Declaration
Swift
public struct URLMetadata : Sendable, Hashable
extension URLMetadata: Decodable