Skip to content

Commit

Permalink
Update package
Browse files Browse the repository at this point in the history
  • Loading branch information
vmanot committed Mar 7, 2024
1 parent a0b63cb commit bea295d
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,8 @@ extension PromptLiteral.StringInterpolation.Component: Codable {
self.payload = try container.decode(Payload.self, forKey: .payload)
self.context = try container.decodeIfPresent(PromptLiteralContext.self, forKey: .context) ?? .init()
} catch {
runtimeIssue(error)

if let payload = try? Payload(from: decoder) {
self.payload = payload
self.context = .init()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ public protocol PromptLiteralContextKey<Value>: HadeanIdentifiable, Heterogeneou
static var defaultValue: Value { get }
}

@RuntimeDiscoverable
public struct PromptLiteralContext: Codable, HashEquatable, @unchecked Sendable {
public enum _Error: Error {
case badMerge
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,12 +122,12 @@ public enum _PromptMatterRoleConstraints: Codable, Hashable, Sendable, ThrowingM
}

extension PromptLiteralContext {
@RuntimeDiscoverable
@HadeanIdentifier("bijoz-nipoh-rakuh-fudum")
struct PromptMatterRoleKey: PromptLiteralContextKey {
typealias Value = _PromptMatterRoleConstraints?
@RuntimeDiscoverable
public struct PromptMatterRoleKey: PromptLiteralContextKey {
public typealias Value = _PromptMatterRoleConstraints?

static let defaultValue: Value = nil
public static let defaultValue: Value = nil
}

public var role: _PromptMatterRoleConstraints? {
Expand All @@ -140,7 +140,8 @@ extension PromptLiteralContext {
}

extension PromptLiteralContext {
@HadeanIdentifier("rajil-pagik-tibah-jibod")
@HadeanIdentifier("sugam-bokij-kutur-narim")
@RuntimeDiscoverable
struct ModelIdentifierKey: PromptLiteralContextKey {
typealias Value = _MLModelIdentifierScope?

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ extension OpenAI.APIClient: _TaskDependenciesExporting {

extension OpenAI.APIClient: LLMRequestHandling {
private var _debugPrintCompletions: Bool {
false
true
}

public var _availableModels: [_MLModelIdentifier]? {
Expand Down

0 comments on commit bea295d

Please sign in to comment.