Skip to content

Commit

Permalink
remove dependency for FunctionCalling
Browse files Browse the repository at this point in the history
  • Loading branch information
fumito-ito committed Oct 30, 2024
1 parent 4efab18 commit 264a2b8
Show file tree
Hide file tree
Showing 9 changed files with 17 additions and 346 deletions.
54 changes: 0 additions & 54 deletions Package.resolved
Original file line number Diff line number Diff line change
@@ -1,59 +1,5 @@
{
"pins" : [
{
"identity" : "documentationcomment",
"kind" : "remoteSourceControl",
"location" : "https://github.com/fumito-ito/DocumentationComment.git",
"state" : {
"revision" : "90d3c5b9cccddb202c8adb99138733c868d7b082",
"version" : "0.0.6"
}
},
{
"identity" : "functioncalling",
"kind" : "remoteSourceControl",
"location" : "https://github.com/fumito-ito/FunctionCalling",
"state" : {
"revision" : "24c07c25d57a66b0e34af8d1ffb1192c2b1313a3",
"version" : "0.4.0"
}
},
{
"identity" : "grmustache.swift",
"kind" : "remoteSourceControl",
"location" : "https://github.com/groue/GRMustache.swift",
"state" : {
"revision" : "c4ee40ef49ae523b06fa470b8d27185ec027330d",
"version" : "5.0.1"
}
},
{
"identity" : "swift-cmark",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-cmark.git",
"state" : {
"revision" : "3ccff77b2dc5b96b77db3da0d68d28068593fa53",
"version" : "0.5.0"
}
},
{
"identity" : "swift-markdown",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-markdown.git",
"state" : {
"revision" : "8f79cb175981458a0a27e76cb42fee8e17b1a993",
"version" : "0.5.0"
}
},
{
"identity" : "swift-syntax",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-syntax.git",
"state" : {
"revision" : "0687f71944021d616d34d922343dcef086855920",
"version" : "600.0.1"
}
},
{
"identity" : "swiftyjsonlines",
"kind" : "remoteSourceControl",
Expand Down
2 changes: 0 additions & 2 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ let package = Package(
targets: ["AnthropicSwiftSDK"]),
],
dependencies: [
.package(url: "https://github.com/fumito-ito/FunctionCalling", from: "0.4.0"),
.package(url: "https://github.com/fumito-ito/SwiftyJSONLines.git", from: "0.0.3")
],
targets: [
Expand All @@ -25,7 +24,6 @@ let package = Package(
.target(
name: "AnthropicSwiftSDK",
dependencies: [
.product(name: "FunctionCalling", package: "FunctionCalling"),
.product(name: "SwiftyJSONLines", package: "SwiftyJSONLines")
]
),
Expand Down
8 changes: 3 additions & 5 deletions Sources/AnthropicSwiftSDK/Entity/Batch/BatchParameter.swift
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@
// Created by 伊藤史 on 2024/10/18.
//

import FunctionCalling

public struct BatchParameter {
/// Input messages.
public let messages: [Message]
Expand Down Expand Up @@ -38,7 +36,7 @@ public struct BatchParameter {
/// Only sample from the top K options for each subsequent token.
public let topK: Int?
/// Definitions of tools that the model may use.
public let toolContainer: ToolContainer?
public let tools: [Tool]?
/// How the model should use the provided tools. The model can use a specific tool, any available tool, or decide by itself.
public let toolChoice: ToolChoice

Expand All @@ -52,7 +50,7 @@ public struct BatchParameter {
temperature: Double? = nil,
topP: Double? = nil,
topK: Int? = nil,
toolContainer: ToolContainer? = nil,
tools: [Tool]? = nil,
toolChoice: ToolChoice = .auto
) {
self.messages = messages
Expand All @@ -64,7 +62,7 @@ public struct BatchParameter {
self.temperature = temperature
self.topP = topP
self.topK = topK
self.toolContainer = toolContainer
self.tools = tools
self.toolChoice = toolChoice
}
}
1 change: 0 additions & 1 deletion Sources/AnthropicSwiftSDK/MessageBatches.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
//

import Foundation
import FunctionCalling
import SwiftyJSONLines

/// A class responsible for managing message batches in the Anthropic API.
Expand Down
Loading

0 comments on commit 264a2b8

Please sign in to comment.