diff --git a/Sources/GoogleAI/Chat.swift b/Sources/GoogleAI/Chat.swift index 7f9f82f..57faaf0 100644 --- a/Sources/GoogleAI/Chat.swift +++ b/Sources/GoogleAI/Chat.swift @@ -83,7 +83,7 @@ public class Chat { // Make sure we inject the role into the content received. let toAdd = ModelContent(role: "model", parts: reply.parts) - // Append the request and succssful result to history, then return the value. + // Append the request and successful result to history, then return the value. await MainActor.run { self.history.append(contentsOf: newContent) self.history.append(toAdd) diff --git a/Sources/GoogleAI/GenerativeModel.swift b/Sources/GoogleAI/GenerativeModel.swift index 33d575e..e39b1bb 100644 --- a/Sources/GoogleAI/GenerativeModel.swift +++ b/Sources/GoogleAI/GenerativeModel.swift @@ -42,7 +42,7 @@ public final class GenerativeModel: @unchecked Sendable { /// Instructions that direct the model to behave a certain way. /// NOTE: This is not optional in the latest releases. - /// TODO: Remove optional system intructions. + /// TODO: Remove optional system instructions. let systemInstruction: ModelContent? /// Configuration parameters for sending requests to the backend. diff --git a/Sources/GoogleAI/ModelContent.swift b/Sources/GoogleAI/ModelContent.swift index 88f42c7..5112036 100644 --- a/Sources/GoogleAI/ModelContent.swift +++ b/Sources/GoogleAI/ModelContent.swift @@ -19,7 +19,7 @@ import Foundation /// may comprise multiple heterogeneous ``ModelContent/Part``s. @available(iOS 15.0, macOS 11.0, macCatalyst 15.0, *) public struct ModelContent: Equatable, Sendable { - /// A discrete piece of data in a media format intepretable by an AI model. Within a single value + /// A discrete piece of data in a media format interpretable by an AI model. Within a single value /// of ``Part``, different data types may not mix. public enum Part: Equatable, Sendable { /// Text value. diff --git a/Sources/GoogleAI/Safety.swift b/Sources/GoogleAI/Safety.swift index bdb143e..2de53cd 100644 --- a/Sources/GoogleAI/Safety.swift +++ b/Sources/GoogleAI/Safety.swift @@ -25,7 +25,7 @@ public struct SafetyRating: Equatable, Hashable, Sendable { /// The model-generated probability that a given piece of content falls under the harm category /// described in ``category``. This does not - /// indiciate the severity of harm for a piece of content. See ``HarmProbability`` for a list of + /// indicate the severity of harm for a piece of content. See ``HarmProbability`` for a list of /// possible values. public let probability: HarmProbability diff --git a/Tests/GoogleAITests/PartsRepresentableTests.swift b/Tests/GoogleAITests/PartsRepresentableTests.swift index 668db4e..120e7e5 100644 --- a/Tests/GoogleAITests/PartsRepresentableTests.swift +++ b/Tests/GoogleAITests/PartsRepresentableTests.swift @@ -73,7 +73,7 @@ final class PartsRepresentableTests: XCTestCase { return } } - XCTFail("Expected model content from invlaid image to error") + XCTFail("Expected model content from invalid image to error") } #if canImport(UIKit) @@ -97,7 +97,7 @@ final class PartsRepresentableTests: XCTestCase { return } } - XCTFail("Expected model content from invlaid image to error") + XCTFail("Expected model content from invalid image to error") } func testModelContentFromUIImageIsNotEmpty() throws { @@ -137,7 +137,7 @@ final class PartsRepresentableTests: XCTestCase { return } } - XCTFail("Expected model content from invlaid image to error") + XCTFail("Expected model content from invalid image to error") } #endif }