SwiftclassSensitiveContentAnalysisML

class SensitiveContentAnalysisML.PromptRewriter

Members 10

  1. funcstatic parseRawResponse(String) throws -> [String]
  2. deinitdeinit
  3. fieldlet logger: os.Logger
  4. fieldlet model: SensitiveContentAnalysisML.AFMModel
  5. fieldlet signposter: os.OSSignposter
  6. funcrewrite(promptStyle: SensitiveContentAnalysisML.PromptRewriter.PromptStyle, text: String, maxNumberOfResults: Int?, randomSeed: Int?) async throws -> [String]
  7. funcrewrite(text: String, maxNumberOfResults: Int?, randomSeed: Int?) async throws -> [String]
  8. funcrewriteInternal(promptStyle: SensitiveContentAnalysisML.PromptRewriter.PromptStyle, text: String, maxNumberOfResults: Int?, randomSeed: Int?, temperature: Double?) async throws -> [String]
  9. initSensitiveContentAnalysisML.PromptRewriter.__allocating_init(modelManagerServicesUseCaseID: String, onBehalfOf: Int?) throws -> SensitiveContentAnalysisML.PromptRewriter
  10. initSensitiveContentAnalysisML.PromptRewriter.__allocating_init(modelManagerServicesUseCaseID: String, locale: Foundation.Locale, onBehalfOf: Int?) throws -> SensitiveContentAnalysisML.PromptRewriter
class PromptRewriter {
    enum PromptStyle {
        case genmoji
        case variety
        case imagePlayground
        case reducedPHR
        case personalizedGenmoji
        case personalizedVariety
    }
    struct ParseJSONError {
        enum CodingKeys {}
    }
    let logger: os.Logger
    let model: SensitiveContentAnalysisML.AFMModel
    let signposter: os.OSSignposter

    init(modelManagerServicesUseCaseID: Swift.String, onBehalfOf: Swift.Int?) throws
    init(modelManagerServicesUseCaseID: Swift.String, locale: Foundation.Locale, onBehalfOf: Swift.Int?) throws

    final func rewriteInternal(promptStyle: SensitiveContentAnalysisML.PromptRewriter.PromptStyle, text: Swift.String, maxNumberOfResults: Swift.Int?, randomSeed: Swift.Int?, temperature: Swift.Double?) async throws -> [Swift.String]
    final func rewrite(promptStyle: SensitiveContentAnalysisML.PromptRewriter.PromptStyle, text: Swift.String, maxNumberOfResults: Swift.Int?, randomSeed: Swift.Int?) async throws -> [Swift.String]
    final func rewrite(text: Swift.String, maxNumberOfResults: Swift.Int?, randomSeed: Swift.Int?) async throws -> [Swift.String]

    static func parseRawResponse(_: Swift.String) throws -> [Swift.String]

    deinit
}