Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

[Client] Fill elicitation defaults when accepting (SEP-1034)

Đang mở
#328 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
72/100
Loại issue
Tính năng
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Ít trao đổi
Công nghệ
php
Lĩnh vực
api

Hướng nghiên cứu

Bắt đầu với ElicitationSchema và năm loại định nghĩa schema cung cấp các giá trị mặc định, sau đó kiểm tra tests/Conformance/client.php và scenario elicitation-sep1034-client-defaults. Thêm coverage kiểm thử unit cho extractDefaults và cập nhật ví dụ để sử dụng helper; hoàn tất khi cả năm loại đều được bao phủ và scenario Conformance chạy thành công.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Client enhancement improves spec compliance Schema

Context

SEP-1034 adds client-side default handling for elicitation/create. When a client accepts an elicitation request without explicit field values, the response content should be auto-populated from default fields declared in the request's requestedSchema. Schemas already expose default on StringSchemaDefinition, NumberSchemaDefinition, EnumSchemaDefinition, TitledEnumSchemaDefinition, and BooleanSchemaDefinition.

Scope

  • Add helper ElicitationSchema::extractDefaults(): array<string, mixed> returning a field => default map for all properties that declare one.
  • Document the helper as the canonical "accept-with-defaults" path; update the example in tests/Conformance/client.php to use it for elicitation-sep1034-client-defaults.
  • Optional convenience: ElicitResult::accepted(ElicitationSchema $schema) factory that pre-fills defaults.

Conformance scenarios unblocked

elicitation-sep1034-client-defaults.

Dependencies

Independent.

Acceptance

  • Unit test on ElicitationSchema::extractDefaults covering all 5 definition types.
  • Conformance: scenario passes (after #328 wiring lands, see below).

cc @soyuka

Ngôn ngữ chính
PHP
Star
1.6k
Fork
173
Merge trung bình
19 giờ 19 phút
Pull request đã merge (30 ngày)
8

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của modelcontextprotocol/php-sdk

Tất cả issue của modelcontextprotocol/php-sdk

Issue tương tự

Thêm issue về PHP

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.