Skip to content

feat: comprehensive enhancements across thinking-chain, AOS, proxy, and UX#216

Open
guyu233 wants to merge 16 commits into
leookun:mainfrom
guyu233:codex/aos-autonomous-evolution
Open

feat: comprehensive enhancements across thinking-chain, AOS, proxy, and UX#216
guyu233 wants to merge 16 commits into
leookun:mainfrom
guyu233:codex/aos-autonomous-evolution

Conversation

@guyu233

@guyu233 guyu233 commented Jul 23, 2026

Copy link
Copy Markdown

Summary

This PR bundles several independent enhancements developed across multiple work sessions.

Thinking Chain Display & Leak Prevention

  • Extend openAIThinkTagParser to support ... tags (Qwen/GLM compat)
  • Add delta.reasoning field alias for OpenAI chat completions (proxy/gateway compat)
  • Add reasoning_content field to OpenAI Responses streaming events
  • Pin signature/encrypted-content non-leak invariants with unit tests
  • Document known raw-content leak (tagless reasoning flows as TextDelta)
  • Add per-provider thinking chain reference doc (THINKING.md)

AOS Reasoning Text Leak Fix

  • Fix: CallAdapter now filters by ModelEventKindTextDelta — reasoning text no longer contaminates AOS/MOA final output
  • Unit test: TestCallAdapterExcludesReasoningText

Outbound Proxy Support

  • Add SetManualProxy to netproxy (manual > env > system priority)
  • Add OutboundProxyConfig to config YAML + NormalizeConfig
  • Wire proxy apply on startup and config change via user-config:changed
  • Add outbound proxy UI in Home.vue settings panel
  • Tests: TestSetManualProxy, TestSetManualProxyOverridesEnv

UX Improvements

  • Fix cursor:activity Wails event type mismatch (string → map[string]string)
  • Fix callback overwrite: onCursorActivity changed from single slot to multi-callback slice
  • Fill OpenModelConfigWindow to open config directory
  • Add 'open config folder' button in ModelConfig.vue provider view
  • Fix deleteModelAdapterAt to also update providers[].models
  • Fix multi-key model fetching in AddProviderModal and ModelConfig
  • Add collapsible multi-key management dropdown in ProviderCard

Quality

  • 14 new test files covering netproxy, virtualmodel, forwarder, bridge
  • go vet clean across all modules
  • Full test suite passes (0 failures)
  • Frontend build passes

guyu233 and others added 16 commits July 12, 2026 23:49
工程审计修复 8 项问题:
- bridge/pet.go: 修复 RWMutex 双重释放导致运行时 panic
- app/runner.go: 注册缺失的 pet:state-changed 事件类型
- pet/manifest.go: 修复 os.Open 后无 defer Close 导致文件句柄泄漏
- runtime/local_runtime.go: 修复 context.Background() 丢弃调用方 ctx
- client/observer.go: 修复 context.Background() 丢弃调用方 ctx
- app/runner.go: refreshAdAsync goroutine 添加 10s 超时保护
- pet/engine.go: Stop() 中 goroutine 超时后仍阻塞,改用 context.WithTimeout
- backend/forwarder/actor.go: scheduleStreamTimer goroutine 发送消息无超时保护

新增 internal/pet/ 桌宠引擎(动画调度、行为系统、状态机、Manifest、窗口管理)

编译验证: go build ./... 通过
- 新增六大 Runtime 骨架: context/cache/optimize/memory/embedding/tool/telemetry
- 新增 Virtual Model (MOA) 框架: manager/resolver/moa provider/channel bridge
- Forwarder 集成 optimize runtime + cost summary
- 配置类型扩展: optimization/embedding/memory/virtualmodel 配置
- 前端新增 VirtualModels 视图 + 路由 + appState
- 新增 ADR 001-009 架构决策记录
- 新增研究笔记: MoA/AutoGen/LangGraph/MemGPT/AIOS
- 清理测试输出文件和无用文档
Replace the bare '会话统计' header title in HomeMetricsCard with a flex-wrap
grid of 4 shortcut cards (Model Config, Cache Dashboard, Telemetry Dashboard,
Virtual Models). Removes all stale ad-related code from Home.vue and wires
card clicks to router.push().

- HomeMetricsCard.vue: add SHORTCUT_CARDS array, navigate emit, dark-theme
  card styling with hover + keyboard accessibility (Enter/Space)
- Home.vue: add handleNavigateShortcut(path), remove getAdRuntime /
  AD_UPDATED_EVENT / syncAdRuntimeQuietly / homeAds references, wire
  @Navigate listener on <HomeMetricsCard>
- router/index.js: add /cache-dashboard and /telemetry-dashboard routes
  (required for shortcut card navigation); also adds /tool-management,
  /plugins, /workflows routes

Fills the empty space above the usage metrics grid that was left after the
ad system was removed.

Plan: .omo/plans/fill-home-ad-space.md
- New views: CacheDashboard, TelemetryDashboard, ToolManagement, Plugins, WorkflowEditor
- New components: AddProviderModal, AosConfig, ProviderCard
- Split appState into configPersistence/modelAdapter/modelAdapterTest/serviceState/utils modules
- New services: pluginApi, workflowApi; new util: providerGroup
- Remove replaced AdModelProvider and unused scaffold assets
…nd UX

## Thinking Chain Display & Leak Prevention
- Extend openAIThinkTagParser to support <thought>...</thought> tags (Qwen/GLM)
- Add delta.reasoning field alias for OpenAI chat completions
- Add reasoning_content field to OpenAI Responses streaming events
- Pin signature/encrypted-content non-leak invariants with unit tests
- Document known raw-content leak (tagless reasoning flows as TextDelta)
- Add per-provider thinking chain reference doc (THINKING.md)

## AOS Fixes
- Fix reasoning text leak: CallAdapter now filters by ModelEventKindTextDelta
  (thinking/reasoning text no longer contaminates AOS/MOA final output)
- Add unit test: TestCallAdapterExcludesReasoningText

## Outbound Proxy Support
- Add SetManualProxy to netproxy package (highest priority over env/system)
- Add OutboundProxyConfig to config YAML + NormalizeConfig
- Wire proxy apply on startup and config change via user-config:changed
- Add outbound proxy UI in Home.vue settings panel
- Add unit tests: TestSetManualProxy, TestSetManualProxyOverridesEnv

## UX Improvements
- Fix cursor:activity event type mismatch (string -> map[string]string)
- Fix callback overwrite: onCursorActivity changed from single slot to slice
- Fill OpenModelConfigWindow to open config directory
- Add 'open config folder' button in ModelConfig.vue provider view
- Fix deleteModelAdapterAt to also update providers[].models
- Fix multi-key model fetching in AddProviderModal and ModelConfig
- Add collapsible multi-key management in ProviderCard with dropdown

## Code Quality
- go vet clean across all modules
- Full test suite passes (0 failures)
- Frontend build passes
@leookun

leookun commented Jul 27, 2026

Copy link
Copy Markdown
Owner

感谢您的贡献~ 不过这个提交是包含了很多东西 400+file change,导致办法直接合并过来...

@guyu233

guyu233 commented Jul 27, 2026

Copy link
Copy Markdown
Author

感谢您的贡献~ 不过这个提交是包含了很多东西 400+file change,导致办法直接合并过来...

那我分功能提交

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants