feat(context): reasoning-thread continuity, L3 doc filtering, and gate hardening
Threads reasoning_content across inference calls and journal renders, filters markdown noise out of L3 repo-knowledge retrieval, adds PlanLinter H3 checks, and tightens filesystem tool output/dir-listing behavior surfaced by prior live QA (see project_readloop_campaign memory).
This commit is contained in:
@@ -153,16 +153,34 @@ func (m *Model) applyServer(msg protocol.ServerMessage) {
|
||||
s.Tools = nil
|
||||
s.StageTokensUsed = 0
|
||||
s.addEvent(msg.OccurredAt, "StageStarted", msg.StageID)
|
||||
for i := range s.PlanStages {
|
||||
if s.PlanStages[i].ID == msg.StageID {
|
||||
s.PlanStages[i].Status = PlanRunning
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
case protocol.TypeStageCompleted:
|
||||
if s := m.session(msg.SessionID); s != nil {
|
||||
s.CurrentStage = ""
|
||||
s.addEvent(msg.OccurredAt, "StageCompleted", msg.StageID)
|
||||
for i := range s.PlanStages {
|
||||
if s.PlanStages[i].ID == msg.StageID {
|
||||
s.PlanStages[i].Status = PlanCompleted
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
case protocol.TypeStageFailed:
|
||||
if s := m.session(msg.SessionID); s != nil {
|
||||
s.CurrentStage = ""
|
||||
s.addEvent(msg.OccurredAt, "StageFailed", msg.StageID)
|
||||
for i := range s.PlanStages {
|
||||
if s.PlanStages[i].ID == msg.StageID {
|
||||
s.PlanStages[i].Status = PlanFailed
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
case protocol.TypeInferenceStarted:
|
||||
if s := m.session(msg.SessionID); s != nil {
|
||||
@@ -303,6 +321,11 @@ func (m *Model) applyServer(msg protocol.ServerMessage) {
|
||||
if s := m.session(msg.SessionID); s != nil {
|
||||
s.addEvent(nowMillis(), "PlanLocked", strings.Join(msg.StageIDs, " → "))
|
||||
s.LastOutput = "plan locked: " + strings.Join(msg.StageIDs, " → ")
|
||||
s.PlanGoal = msg.Content
|
||||
s.PlanStages = make([]PlanStage, 0, len(msg.StageIDs))
|
||||
for _, id := range msg.StageIDs {
|
||||
s.PlanStages = append(s.PlanStages, PlanStage{ID: id, Status: PlanPending})
|
||||
}
|
||||
}
|
||||
case protocol.TypeWorkspaceBound:
|
||||
if s := m.session(msg.SessionID); s != nil {
|
||||
|
||||
Reference in New Issue
Block a user