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

tui3: trailing task and done events in turn demote settled assistant answer to raw plain workingProse

Đang mở
#1,565 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ó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
65/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
go
Lĩnh vực
cli, frontend

Hướng nghiên cứu

Read deriveWorkfolds and workEntry in internal/tui3/workfold.go, then trace assistantRows in internal/tui3/render.go, focusing on entryDone and entryTask near turn boundaries. Confirm the fix preserves intermediate rolling summaries while ensuring the terminal assistant entry reaches settledMarkdown and retains markdown rendering when asynchronous events follow it.

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

Mô tả

area:chat bug sev:serious
Problem

In the TUI chat surface (internal/tui3), settled final assistant answers frequently fail to convert into rendered markdown answers, staying trapped as unformatted plain text with raw markdown syntax (###, **bold**, backticks) indented as step narration under previous disclosure nodes instead of standing as clean rolling answers.

This is especially prominent in manager and team turns, but also occurs in standard chats whenever background tasks, worker notifications, or tool events land near the turn boundary.

Root Cause Analysis in Code
  1. workEntry in internal/tui3/workfold.go (lines 525–533):
    When classifying whether an assistant entry e is working narration (demoted = true) or a settled answer, workEntry falls through to a forward scan:

    for at := i + 1; at < len(es) && es[at].turn == e.turn; at++ {
        if groupBreaks(&es[at]) {
            return false
        }
        ...
        if es[at].kind != entryDivider && es[at].kind != entryNote && !entryWithdrawn(&es[at]) {
            return true
        }
    }
    

    When background task completions (entryDone, e.g. ✖ ◆ manager permissions · incomplete · 34s) or task status entries (entryTask) append to the current turn after the assistant finishes speaking, workEntry treats them as subsequent non-divider/non-note work and sets es[i].demoted = true.

  2. assistantRows in internal/tui3/render.go (lines 1372–1385):

    if e.demoted {
        e.feet = nil
        text := e.text
        if e.capHead && e.capCut > 0 && e.capCut <= len(text) {
            text = text[e.capCut:]
        }
        return append(tags, a.workingProse(text, width)...)
    }
    if e.settled {
        return append(tags, a.settledMarkdown(at, e, width)...)
    }
    

    Because e.demoted was set to true, the assistant block never enters settledMarkdown. It routes to workingProse, which performs raw plain-text line-wrapping with zero markdown formatting.

  3. Missing workfold certification in deriveWorkfolds (workfold.go:264–316):
    In manager turns or turns where blocked triggers (such as team_send, entrySeam, or asks), no workfold is constructed for the turn (folds map has no entry for the turn). Without a certifying f.answer == i in a workfold, the forward loop in workEntry runs and is tripped by entryDone / entryTask.

Expected Behavior
  • When nothing is clicked in the transcript, intermediate steps collapse into clean rolling summary lines (▸ headline ... duration), and the assistant's terminal answer renders below them through settledMarkdown with full markdown formatting.
  • Asynchronous task completion cards (entryDone), notifications, and background events appended to the turn must not demote the assistant's final response into intermediate working prose.

Drafted with CodeAF

Ngôn ngữ chính
Go
Star
115
Fork
14
Merge trung bình
9 giờ 35 phút
Pull request đã merge (30 ngày)
752

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

Chúng tôi chưa kiểm tra các tệp thiết lập môi trường của dự án này. Hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.

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 Agent-Field/CodeAF

Tất cả issue của Agent-Field/CodeAF

Issue tương tự

Thêm issue về Go

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.