feat: connect conversations with Magic Notes
Let users retain useful assistant replies or complete conversations without leaving their chat workflow. Preview and edit captured text, choose an existing note or atomically create a note with its first entry, and return to the source conversation or message from saved records. Add an application-scoped Notes workbar tab with title/body search and quick text appends. Preserve drafts across conversation switches and guard closing, replacement and disabling. Schema 48 stores optional source metadata without rewriting file-backed bodies; source deletion retains the saved note. Older clients cannot reopen an upgraded database without a pre-upgrade backup. Release note: 可将助手回答或完整会话预览、编辑后加入魔法笔记,并从笔记返回原会话或消息。右侧快速笔记支持搜索和追加文字,切换会话保留草稿;采集本身不调用模型,保存后自动评论仍遵循已有设置。 Validation: isolated HEAD-based candidate passed 22 files / 930 focused tests, plus 20 gateway tests after including its create-result fixture adjustment. Real Electron App/preload/IPC/SQLite acceptance passed for all 502 historical messages, exact-entry/source navigation, native keyboard input in a 214px panel, reopen and source-deletion retention, with zero capture model calls. Repository lint and web TypeScript passed. Cached whitespace and secret-pattern checks passed; native-client changes and unrelated IPC extraction are excluded. Validation limits: the isolated source tree reuses installed node_modules, where a parallel task upgraded DSH from the committed 0.1.2-rc.1 to 0.1.7-rc.2. Full typecheck reports 14 DSH errors in three unchanged files; the full-suite attempt with --bail=1 also fails in deepseek-harness-host.test.ts. These are not all-green repository or release-package results. Earlier execution-time full suite failures and fixture repairs remain recorded in the feature progress doc.
This commit is contained in:
@@ -156,6 +156,8 @@ import type {
|
||||
MagicNoteAnalysisStreamEvent,
|
||||
MagicNoteDraftAnalysis,
|
||||
MagicNoteDetail,
|
||||
MagicNoteCreateResult,
|
||||
MagicNoteSummary,
|
||||
MagicNoteEntryCreateResult,
|
||||
MagicNotesSnapshot,
|
||||
MagicTodoItem,
|
||||
@@ -1625,6 +1627,8 @@ const desktopApi: DesktopApi = {
|
||||
}
|
||||
},
|
||||
magicNotes: {
|
||||
search: (input) =>
|
||||
ipcRenderer.invoke(ipcChannels.magicNotesSearch, input) as Promise<MagicNoteSummary[]>,
|
||||
list: () =>
|
||||
ipcRenderer.invoke(
|
||||
ipcChannels.magicNotesList
|
||||
@@ -1637,7 +1641,7 @@ const desktopApi: DesktopApi = {
|
||||
ipcRenderer.invoke(
|
||||
ipcChannels.magicNotesCreate,
|
||||
input
|
||||
) as Promise<MagicNoteDetail>,
|
||||
) as Promise<MagicNoteCreateResult>,
|
||||
update: (input) =>
|
||||
ipcRenderer.invoke(
|
||||
ipcChannels.magicNotesUpdate,
|
||||
|
||||
Reference in New Issue
Block a user