Skip to content

rebase the upstream 0609 - #94

Closed
SWangHash wants to merge 150 commits into
mainfrom
skill_open
Closed

SWangHash wants to merge 150 commits into
mainfrom
skill_open

Conversation

@SWangHash

Copy link
Copy Markdown
Owner

Summary

Fixes #

Type and Areas

Type:

Areas:

Motivation / Impact

Verification

Reviewer Notes

Checklist

  • This PR is focused and does not include secrets, temporary prompts, generated scratch files, or unrelated artifacts.
  • Relevant verification is recorded above, or skipped checks are explained.
  • User-facing strings, docs, and locales are updated where applicable.

ococl and others added 30 commits May 30, 2026 22:42
…fix cache

- snapshot turn-level skill and subagent listings to preserve the first-turn prompt baseline
- inject incremental skill and agent listing updates into user input instead of rebuilding cached prefixes
- persist and recover skill-agent snapshots across restore and rollback flows to keep prompt state consistent
- replace prompt-envelope reminder wrapping with explicit prepended reminder messages across coordinator, scheduler, goal mode, cron, /btw, init_agents_md, and session_message flows
- add InternalReminderKind metadata and constructors so reminder messages can be classified, persisted, and filtered consistently, including fork-subagent and goal-continuation paths
- persist a listing-baseline rebuild cutoff in session metadata and lazily strip stale skill/agent listing diff reminders when restoring or rolling back older context snapshots
- teach fallback compression to drop transient reminder kinds and update related tests after removing legacy envelope-based expectations
…prompt cache reuse

- document session-level prompt cache reuse strategy and persistence
- document reuse across branching, /btw, fork_context, mode switching, and compression
- clarify current per-turn tool-manifest cache-miss gap and a possible future direction
- make hidden /btw child sessions clone the parent prompt cache on creation
fix(core): handle bare markdown fences
fix(web-ui): persist right panel width across window minimize/restore
Add a Write Tool Mode selector under Settings -> Session Permissions -> Tool execution.
Persist ai.write_tool_mode from the frontend config layer, refresh mode-dependent UI
after updates, and add search keywords plus localized copy for the new setting.
- split DeepSeek Anthropic reasoning handling from native Claude adaptive logic
- omit thinking and output_config in default mode
- send output_config.effort only when DeepSeek thinking is enabled
- drop budget_tokens for DeepSeek Anthropic requests
- fallback adaptive mode to enabled for DeepSeek Anthropic models
- add focused tests for default, disabled, enabled, and adaptive DeepSeek paths
fix(skills): fix deletion of user-level skills in remote workspace context
…fication

fix(web-ui): unify startup overlay
Replace verification-subagent goal mode with Codex-style /goal thread goals
managed via create_goal, update_goal, and get_goal tools, with UI strip,
dialogs, auto-continuation, and token budget tracking across core and web-ui.
wsp1911 and others added 26 commits June 7, 2026 17:48
Add a configurable terminal panel position preference with right-side as the default
and bottom-panel support for terminal tabs only. Route terminal creation to the
configured panel, add a dedicated bottom terminal canvas, persist bottom panel
height, and expose the setting in Basics config.

Also persist terminal_panel_position through the backend config schema so the
preference survives app restart.
Remove the PowerShell Core recommendation and shell integration warnings from
the Basics terminal settings. These hints are no longer relevant now that agent
commands no longer depend on controlling the real user terminal.
perf: replace full-state subscriptions with selector-based subscriptions
Move local flashgrep workspace search service ownership into services-integrations behind the workspace-search feature while keeping bitfun-core as the compatibility facade for config/bootstrap hooks and legacy error mapping.

Move tool-call truncation recovery presentation into tool contracts and update boundary checks plus plan docs for the remaining remote search/tool orchestration work.
Set CREATE_NO_WINDOW on local tty=false ExecCommand pipe processes so Windows
release builds do not flash a console window when spawning shell commands.
feat(controlhub): enhance controlhub browser
- stop remapping links by shared display text in Markdown renderer
- recover missing href values from source positions for Windows paths and computer links
- add focused regression coverage for duplicate README.md links with sample paths
- Add a remote file delivery helper that centralizes when `computer://` links are required and how user-facing file links are generated.
- Inject a remote-only internal reminder for mobile and bot submissions so downloadable artifacts are referenced with `computer://`.
- Make CreatePlan and DeepResearch choose user-facing links based on the remote delivery channel instead of hard-coding `computer://`.
- Update agent prompts to prefer normal workspace-relative markdown links by default and clarify file reference formatting rules.
- Let desktop markdown links open editor-supported `computer://` files in the built-in editor while still revealing unsupported files in the file manager.
- Add focused tests for remote file delivery link selection, DeepResearch report link expansion, and desktop markdown file-link routing.
Add a shared slash-command matcher and route ChatInput slash-command
checks through exact token matching instead of loose prefix matching.

This keeps ACP session gating intact while fixing false positives like
`/btwextra`, `/usage2`, `/compactor`, `/reload-skills-now`, and `/goals`
being treated as built-in commands. It also aligns the send button,
picker normalization, Enter-key submission, and /btw argument stripping
with the same matching rules.

Adapted from the contribution in GCWing#1023.

Co-authored-by: jarvis24young <749843026@qq.com>
collectRunningBackgroundSubagents was called on every FlowChatStore change, doing a full O(sessions*turns*rounds*items) scan. Added a snapshot key computed from subagent session IDs and statuses; only runs the full scan when the snapshot differs from last known state.
turnSummaries useMemo previously rebuilt every entry via filter+map on every dialogTurns change. Now uses a turnId-keyed cache: stable turns reuse their cached title (avoiding resolveLocalCommandHeaderTitle i18n lookups), only new/changed turns compute from scratch. Cache cleared on session change.
perf: guard repeated scans and cache stable computations in ModernFlowChatContainer
ResizeObserver and MutationObserver each triggered 6 individual schedule calls per event. Now both go through scheduleObserverBatch which deduplicates to a single rAF callback per frame. MutationObserver also skips when not isProcessing.
The RAF follow loop now stops when document.hidden (tab in background) and restarts via visibilitychange listener when the page becomes visible again. This avoids unnecessary 60fps CPU consumption when the user is not looking at the tab.
The history overlay polling calls isTurnTextRenderedInViewport() up to 120 times (nearly 2 seconds). Reduced to 30 attempts (~500ms) which is still sufficient for typical content paint latency.
- make local ExecCommand follow the configured default terminal shell
- restrict Windows agent command shells to pwsh, powershell, and bash
- fall back from cmd to PowerShell for local agent command execution
- update settings copy to explain the actual shell used for agent commands
perf: reduce RAF callback volume in VirtualMessageList event system
Move provider-neutral DeepReview task execution shaping, DeepResearch citation renumbering, and prompt environment facts into bitfun-agent-runtime while keeping core as the compatibility and IO adapter boundary.

Update boundary checks and execution plans to separate completed provider-neutral M10 work from remaining concrete workflow and side-effect migrations.
@SWangHash

Copy link
Copy Markdown
Owner Author

close

@SWangHash SWangHash closed this Jun 16, 2026
@SWangHash
SWangHash deleted the skill_open branch July 24, 2026 03:26
SWangHash pushed a commit that referenced this pull request Sep 2, 2026
fix(review): export markdown reports on HarmonyOS

Created-by: guantw
Commit-by: guantw
Merged-by: SWangHash
Description: ## Summary

Fix HarmonyOS review Markdown export when browser download APIs are unavailable.

- Route review report exports through a shared save-text helper that prefers browser downloads and falls back to the host save dialog.
- Add the desktop save command and register it across remote-workspace and peer-device command boundaries.
- Bridge the HarmonyOS save dialog result to ArkTS file persistence while preserving browser behavior on supported surfaces.
- Add regression coverage for review export actions, the System API, and the save helper.

Fixes #120

## Type and Areas

Type: Bug fix

Areas: Web UI, desktop/Tauri, HarmonyOS, peer-device and remote-workspace adapters

## Motivation / Impact

HarmonyOS WebView does not provide the browser download path used by review report export, so Markdown reports could not be saved. This change falls back to the host file dialog and writes the selected file through the platform adapter without changing the normal browser download path.

## Verification

- `pnpm --dir src/web-ui exec vitest run src/flow_chat/tool-cards/CodeReviewReportExportActions.test.tsx src/infrastructure/api/service-api/SystemAPI.test.ts src/infrastructure/services/infra/saveTextFileWithDialog.test.ts` — 17 tests passed in 3 files.
- `pnpm run type-check:web` — passed.
- `git show --check --oneline 802a37a` — passed.
- Rust schema/build verification was attempted but did not complete in this worktree: the Linux rustup installation has no configured toolchain, while the available Windows Cargo reports that the current `main` lockfile would need an update under `--locked`. `Cargo.lock` was intentionally left unchanged.

## Reviewer Notes

- This ports the functional change from #94 onto `main` at `40f4fee26`.
- `main` already provides `tauri-plugin-dialog` globally, so this branch does not duplicate the release-branch manifest or lockfile changes.
- The save dialog remains controller-local in Peer Device Mode and is explicitly `LocalOnly` for remote workspaces.
- No live HarmonyOS device, remote-workspace, remote-control, peer-device, or detached-dispatch end-to-end run was performed.

## Checklist

- [x] This PR is focused and does not include secrets, temporary prompts, generated scratch files, or unrelated artifacts.
- [x] Relevant verification is recorded above, or skipped checks are explained.
- [x] User-facing strings, docs, and locales are updated where applicable.

See merge request: OpenHarmonyPCDeveloper/BitFun!102
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.

9 participants