Make Tool.description optional (#160)

* Make Tool.description optional

* Make description parameter in Tool initializer optional
This commit is contained in:
Mattt 2025-09-07 04:24:38 -07:00 • committed by GitHub
commit ac90e679cd
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -12,7 +12,7 @@ public struct Tool: Hashable, Codable, Sendable {
/// The tool name
public let name: String
/// The tool description
public let description: String
public let description: String?
/// The tool input schema
public let inputSchema: Value
@ -85,7 +85,7 @@ public struct Tool: Hashable, Codable, Sendable {
/// Initialize a tool with a name, description, input schema, and annotations
public init(
name: String,
description: String,
description: String?,
inputSchema: Value,
annotations: Annotations = nil
) {