a2ui-project / a2ui-project/a2ui

[Feature Request] Fragile Enforcement of JSON-only A2UI Output

Đang mở
#1,415 2 bình luận 0 reaction 0 người được giao Xem trên GitHub
component: agent_sdk P2 type: feature/enhancement
Ngôn ngữ chính
TypeScript
Star
16.4k
Fork
1.3k
Merge trung bình
2 ngày 13 giờ
Pull request đã merge (30 ngày)
134

Mô tả

I would suggest building in some prompt augmentation to the agent SDK to enforce proper A2UI messages. I don’t think you should be required to write something like `Your final output MUST be a a2ui UI JSON response`. Even with that, it doesn’t always work.

For example, my role description of `You are a helpful agent that helps find and book weekend activities. Your final output MUST be a a2ui UI JSON response` generated an A2UI validation failure.

However, something like this did work: `You are a powerful and intelligent agent that translates user requests into a stream of valid A2UI JSON messages. You must respond to the user's request using only the component and data schemas provided below. Do not add any conversational text or markdown outside of the designated component properties. Your entire response must be a valid JSON array of A2UI messages.`

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Hướng nghiên cứu

Look at the agent SDK's prompt construction logic, likely in the core agent or message handling modules. Examine how validation failures occur and where output formatting is enforced. Test with the provided prompt examples to understand the failure modes. The goal is to modify the SDK to automatically augment prompts to ensure JSON-only A2UI output without requiring explicit user instructions.

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

Đánh giá

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

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.