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

Feature: model-generated files (inline images) in chat/responses turns

Đang mở
#548 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

@abhiaiyer91 đang làm issue này rồi.

Từ ngày 17/10/2026.

  • #550 của @abhiaiyer91 — đang mở

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
35/100
Loại issue
Tính năng
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
typescript

Hướng nghiên cứu

Start by tracing the mocked responses, Gemini, Chat Completions, and Anthropic turn builders, especially where text responses and customToolCalls are handled. Add or update the response fixtures and stream-output tests to cover optional generated files, including the unsupported-error cases. The work is done when Responses emits an image_generation_call with base64 data, Gemini emits inlineData, and the other wire formats return the documented unsupported error; an open linked pull request indicates the work has already moved elsewhere.

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

Mô tả

Problem

Image generation and the Files API are mocked as separate endpoints, but there is no way to make a chat/responses model turn return a generated file (e.g. an inline image). Clients that surface model-generated files (AI SDK file stream parts) can't be tested through aimock.

Proposal

An optional files field on text / content+tool-call responses:

llm.on({ endpoint: 'responses' }, {
  content: 'Here is your chart.',
  files: [{ mediaType: 'image/png', data: '<base64>' }],
});

Emitted per wire format:

  • OpenAI Responses: an image_generation_call output item with result (base64)
  • Gemini: inlineData parts in the candidate content
  • Chat Completions / Anthropic: reject with a clear unsupported error (same pattern as customToolCalls)

Use case

Same as the citations request: Mastra's loop regression tests need to assert that model-generated files flow through to the stream and stored messages.

Ngôn ngữ chính
TypeScript
Star
979
Fork
84
Merge trung bình
1 ngày 5 giờ
Pull request đã merge (30 ngày)
58

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

  • Có Dockerfile hoặc tệp Docker Compose
  • Không có mẫu pull request
  • Không có hướng dẫn đóng góp

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 CopilotKit/aimock

Tất cả issue của CopilotKit/aimock

Issue tương tự

Thêm issue về TypeScript

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.