mirror of
https://github.com/vxcontrol/pentagi.git
synced 2026-07-21 08:15:23 -04:00
[PR #218] [MERGED] Quick fix for assistant mode #244
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/vxcontrol/pentagi/pull/218
Author: @asdek
Created: 3/19/2026
Status: ✅ Merged
Merged: 3/19/2026
Merged by: @asdek
Base:
master← Head:bug/quick_fix_assistant_mode📝 Commits (5)
bb50d10fix: enhance QA summarization logic to prevent double summarization of sectionsfa70b03feat: update model configurations for Anthropic and OpenAI providers852c48bfix: improve streaming log handling and cache updates41add52fix: textarea focus329a6fffix: empty flow assistant logs when no updates occur📊 Changes
13 files changed (+225 additions, -87 deletions)
View changed files
📝
backend/pkg/controller/aslog.go(+9 -1)📝
backend/pkg/csum/chain_summary.go(+24 -7)📝
backend/pkg/database/assistantlogs.sql.go(+10 -0)📝
backend/pkg/database/querier.go(+1 -0)📝
backend/pkg/providers/anthropic/config.yml(+11 -11)📝
backend/pkg/providers/openai/config.yml(+24 -24)📝
backend/pkg/providers/openai/models.yml(+28 -0)📝
backend/pkg/tools/executor.go(+1 -1)📝
backend/sqlc/models/assistantlogs.sql(+4 -0)📝
frontend/src/components/ui/input-group.tsx(+1 -1)📝
frontend/src/features/flows/flow-form.tsx(+17 -1)📝
frontend/src/lib/apollo.ts(+93 -39)📝
frontend/src/styles/index.css(+2 -2)📄 Description
Description of the Change
Problem
Multiple performance and quality issues affecting agent execution and UI responsiveness:
Empty Assistant Logs:
result(tool call JSON) without message chunksmessage="", polluting UI with blank entriesMemory Growth in Browser:
Subscription Cache Handling:
toReference(..., true)only created references to existing objectsOutdated Model Configurations:
QA Summarization Redundancy:
Minor UI Issue:
Solution
Backend - Empty Log Cleanup:
wasUpdatedflag inworkerMsgUpdaterto track if record received any content/thinking/result chunksDeleteFlowAssistantLogSQL query for cleanupFrontend - Memory Optimization:
toReference(...)without second parameterupdatestrategy to add missing objects to cache arraysFrontend - Streaming Performance:
data: {})createStreamingLinkwith conditionalobserver.next()callsModel Configuration Updates:
Summarization Improvements:
Textarea Fix:
Type of Change
Areas Affected
Testing and Verification
Test Configuration
Test Steps
assistantlogstableTest Results
assistantLogUpdateddisplay correctlySecurity Considerations
No Security Impact:
Performance Impact
Major Improvements:
Streaming Trade-off:
Documentation Updates
Deployment Notes
Database Migration:
DeleteFlowAssistantLog(sqlc-generated)Environment Variables:
Deployment Steps:
docker compose builddocker compose up -dCompatibility:
Checklist
Code Quality
go fmtandgo vet(for Go code)npm run lint(for TypeScript/JavaScript code)Security
Compatibility
Documentation
Additional Notes
Key Changes by Category
Critical Fixes
Empty Assistant Logs Cleanup (Commit
329a6ff):backend/pkg/controller/aslog.gowasUpdatedboolean flag inworkerMsgUpdatergoroutinewasUpdated == falseStreaming Memory Optimization (Commit
852c48b):frontend/src/lib/apollo.tsshouldEmitUpdatefunction andlastUpdateTimestampsMaptoReference(newItem)creates new objects only forassistantLogUpdatedwhen missingupdatestrategy to add new objects to arrays if not presentFont Loading Fix (Commit
852c48b):frontend/src/styles/index.cssFeature Updates
Model Configuration Enhancement (Commit
fa70b03):backend/pkg/providers/anthropic/config.yml,backend/pkg/providers/openai/config.yml,backend/pkg/providers/openai/models.ymlmax_tokenslimits for Anthropic models (better long-form output)QA Summarization Optimization (Commit
bb50d10):backend/pkg/csum/chain_summary.goTextarea Focus (Commit
41add52):🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.