diff --git a/package.json b/package.json index e0edccd..d20a818 100644 --- a/package.json +++ b/package.json @@ -120,6 +120,7 @@ "reconnecting-eventsource": "^1.6.4", "rehype-raw": "^7.0.0", "remark-gfm": "^4.0.0", + "remove-markdown": "^0.6.2", "shell-env": "^4.0.1", "simple-git": "^3.27.0", "smart-embed-model": "^1.0.7", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 72ad084..b27d8da 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -210,6 +210,9 @@ importers: remark-gfm: specifier: ^4.0.0 version: 4.0.1 + remove-markdown: + specifier: ^0.6.2 + version: 0.6.2 shell-env: specifier: ^4.0.1 version: 4.0.1 @@ -577,8 +580,8 @@ packages: '@codemirror/language@6.11.2': resolution: {integrity: sha512-p44TsNArL4IVXDTbapUmEkAlvWs2CFQbcfc0ymDsis1kH2wh0gcY96AS29c/vp2d0y2Tquk1EDSaawpzilUiAw==} - '@codemirror/language@https://codeload.github.com/lishid/cm-language/tar.gz/6c1c5f5b677f6f6503d1ca2ec47f62f6406cda67': - resolution: {tarball: https://codeload.github.com/lishid/cm-language/tar.gz/6c1c5f5b677f6f6503d1ca2ec47f62f6406cda67} + '@codemirror/language@git+https://git@github.com:lishid/cm-language.git#6c1c5f5b677f6f6503d1ca2ec47f62f6406cda67': + resolution: {commit: 6c1c5f5b677f6f6503d1ca2ec47f62f6406cda67, repo: git@github.com:lishid/cm-language.git, type: git} version: 6.10.8 '@codemirror/lint@0.20.3': @@ -5451,8 +5454,8 @@ packages: '@codemirror/state': ^6.0.0 '@codemirror/view': ^6.0.0 - obsidian@https://codeload.github.com/obsidianmd/obsidian-api/tar.gz/103ff76a0712a02dd0da28646b5a6b0ba6686d66: - resolution: {tarball: https://codeload.github.com/obsidianmd/obsidian-api/tar.gz/103ff76a0712a02dd0da28646b5a6b0ba6686d66} + obsidian@git+https://git@github.com:obsidianmd/obsidian-api.git#103ff76a0712a02dd0da28646b5a6b0ba6686d66: + resolution: {commit: 103ff76a0712a02dd0da28646b5a6b0ba6686d66, repo: git@github.com:obsidianmd/obsidian-api.git, type: git} version: 1.8.7 peerDependencies: '@codemirror/state': ^6.0.0 @@ -5921,6 +5924,9 @@ packages: remove-markdown@0.5.5: resolution: {integrity: sha512-lMR8tOtDqazFT6W2bZidoXwkptMdF3pCxpri0AEokHg0sZlC2GdoLqnoaxsEj1o7/BtXV1MKtT3YviA1t7rW7g==} + remove-markdown@0.6.2: + resolution: {integrity: sha512-EijDXJZbzpGbQBd852ViUzcqgpMujthM+SAEHiWCMcZonRbZ+xViWKLJA/vrwbDwYdxrs1aFDjpBhcGrZoJRGA==} + require-directory@2.1.1: resolution: {integrity: sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==} engines: {node: '>=0.10.0'} @@ -7083,7 +7089,7 @@ snapshots: '@lezer/lr': 1.4.2 style-mod: 4.1.2 - '@codemirror/language@https://codeload.github.com/lishid/cm-language/tar.gz/6c1c5f5b677f6f6503d1ca2ec47f62f6406cda67': + '@codemirror/language@git+https://git@github.com:lishid/cm-language.git#6c1c5f5b677f6f6503d1ca2ec47f62f6406cda67': dependencies: '@codemirror/state': 6.5.2 '@codemirror/view': 6.38.0 @@ -12598,7 +12604,7 @@ snapshots: obsidian-daily-notes-interface@0.8.4(@codemirror/state@6.5.2)(@codemirror/view@6.38.0): dependencies: - obsidian: https://codeload.github.com/obsidianmd/obsidian-api/tar.gz/103ff76a0712a02dd0da28646b5a6b0ba6686d66(@codemirror/state@6.5.2)(@codemirror/view@6.38.0) + obsidian: git+https://git@github.com:obsidianmd/obsidian-api.git#103ff76a0712a02dd0da28646b5a6b0ba6686d66(@codemirror/state@6.5.2)(@codemirror/view@6.38.0) tslib: 2.1.0 transitivePeerDependencies: - '@codemirror/state' @@ -12606,7 +12612,7 @@ snapshots: obsidian-dataview@0.5.68: dependencies: - '@codemirror/language': https://codeload.github.com/lishid/cm-language/tar.gz/6c1c5f5b677f6f6503d1ca2ec47f62f6406cda67 + '@codemirror/language': git+https://git@github.com:lishid/cm-language.git#6c1c5f5b677f6f6503d1ca2ec47f62f6406cda67 '@codemirror/state': 6.5.2 '@codemirror/view': 6.38.0 emoji-regex: 10.4.0 @@ -12625,7 +12631,7 @@ snapshots: '@types/codemirror': 5.60.8 moment: 2.29.4 - obsidian@https://codeload.github.com/obsidianmd/obsidian-api/tar.gz/103ff76a0712a02dd0da28646b5a6b0ba6686d66(@codemirror/state@6.5.2)(@codemirror/view@6.38.0): + obsidian@git+https://git@github.com:obsidianmd/obsidian-api.git#103ff76a0712a02dd0da28646b5a6b0ba6686d66(@codemirror/state@6.5.2)(@codemirror/view@6.38.0): dependencies: '@codemirror/state': 6.5.2 '@codemirror/view': 6.38.0 @@ -13233,6 +13239,8 @@ snapshots: remove-markdown@0.5.5: {} + remove-markdown@0.6.2: {} + require-directory@2.1.1: {} require-from-string@2.0.2: {} diff --git a/src/components/chat-view/SearchView.tsx b/src/components/chat-view/SearchView.tsx index 5a5751d..c012053 100644 --- a/src/components/chat-view/SearchView.tsx +++ b/src/components/chat-view/SearchView.tsx @@ -10,6 +10,7 @@ import { useTrans } from '../../contexts/TransContext' import { Workspace } from '../../database/json/workspace/types' import { WorkspaceManager } from '../../database/json/workspace/WorkspaceManager' import { SelectVector } from '../../database/schema' +import { t } from '../../lang/helpers' import { Mentionable } from '../../types/mentionable' import { getFilesWithTag } from '../../utils/glob-utils' import { openMarkdownFile } from '../../utils/obsidian' @@ -459,7 +460,7 @@ const SearchView = () => { h5: ({ children }) =>
为当前工作区的文件建立向量索引,提高搜索精度
+{t('semanticSearch.initializingDescription')}