Client#tools/#list_tools built Tool objects without an annotations field even though the server includes annotations in every tools/list response. Add the reader and pass the raw hash through, mirroring how output_schema is already handled.
17 lines
446 B
Ruby
17 lines
446 B
Ruby
# frozen_string_literal: true
|
|
|
|
module MCP
|
|
class Client
|
|
class Tool
|
|
attr_reader :name, :description, :input_schema, :output_schema, :annotations
|
|
|
|
def initialize(name:, description:, input_schema:, output_schema: nil, annotations: nil)
|
|
@name = name
|
|
@description = description
|
|
@input_schema = input_schema
|
|
@output_schema = output_schema
|
|
@annotations = annotations
|
|
end
|
|
end
|
|
end
|
|
end
|