Skip to content

Commit

Permalink
支持通用对话
Browse files Browse the repository at this point in the history
  • Loading branch information
classfang committed Apr 24, 2024
1 parent c08c149 commit f0ddc62
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 11 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"@electron-toolkit/utils": "^3.0.0",
"@langchain/redis": "^0.0.3",
"electron-store": "^8.2.0",
"langchain": "^0.1.34",
"langchain": "^0.1.35",
"mammoth": "^1.7.1",
"officeparser": "^4.0.8",
"pdf-parse": "^1.1.1",
Expand Down Expand Up @@ -62,7 +62,7 @@
"dayjs": "^1.11.10",
"electron": "^30.0.1",
"electron-builder": "^24.13.3",
"electron-vite": "^2.1.0",
"electron-vite": "^2.2.0",
"eslint": "^8.57.0",
"eslint-plugin-vue": "^9.25.0",
"gpt-tokenizer": "^2.1.2",
Expand Down
5 changes: 4 additions & 1 deletion src/renderer/src/store/assistant.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
import i18n from '@renderer/i18n'
import { defaultAssistant } from '@renderer/utils/big-model/base-util'
import { nowTimestamp } from '@renderer/utils/date-util'
import { randomUUID } from '@renderer/utils/id-util'
import { copyObj } from '@renderer/utils/object-util'
import { defineStore } from 'pinia'

const { t } = i18n.global

export const useAssistantStore = defineStore({
id: 'assistant',
state: () => ({
Expand All @@ -23,7 +26,7 @@ export const useAssistantStore = defineStore({
virtualAssistantList: [
{
...copyObj(defaultAssistant),
name: '',
name: t('assistantList.newChat'),
id: randomUUID(),
createTime: nowTimestamp(),
lastUpdateTime: nowTimestamp(),
Expand Down
16 changes: 8 additions & 8 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2717,10 +2717,10 @@ electron-to-chromium@^1.4.601:
resolved "https://registry.npmmirror.com/electron-to-chromium/-/electron-to-chromium-1.4.617.tgz#3b0dde6c54e5f0f26db75ce6c6ae751e5df4bf75"
integrity sha512-sYNE3QxcDS4ANW1k4S/wWYMXjCVcFSOX3Bg8jpuMFaXt/x8JCmp0R1Xe1ZXDX4WXnSRBf+GJ/3eGWicUuQq5cg==

electron-vite@^2.1.0:
version "2.1.0"
resolved "https://registry.npmmirror.com/electron-vite/-/electron-vite-2.1.0.tgz#33908c3b9c90bcab5c5f4c0f6c483263303cc5aa"
integrity sha512-DjToUW6q3ILoW79b1yBywC6LubnOw5Axr2zo9cHMlYf00zAO8oVzrCcqinJQTTbJLvqCuVcBzuICMl5MYshUnQ==
electron-vite@^2.2.0:
version "2.2.0"
resolved "https://registry.npmmirror.com/electron-vite/-/electron-vite-2.2.0.tgz#52976a71606afce2b2cf2b7489547db6bc3a1ea1"
integrity sha512-WvE8KlZTiay9uWqBRvnYuxg2JqIicaNqaz9qFvsZkIae2/FmqZC5jctziyduCuuwVxqJG0Sjh8RlTwSn8xcCoQ==
dependencies:
"@babel/core" "^7.23.5"
"@babel/plugin-transform-arrow-functions" "^7.23.3"
Expand Down Expand Up @@ -3868,10 +3868,10 @@ kuler@^2.0.0:
resolved "https://registry.npmmirror.com/kuler/-/kuler-2.0.0.tgz#e2c570a3800388fb44407e851531c1d670b061b3"
integrity sha512-Xq9nH7KlWZmXAtodXDDRE7vs6DU1gTU8zYDHDiWLSip45Egwq3plLHzPn27NgvzL2r1LMPC1vdqh98sQxtqj4A==

langchain@^0.1.34:
version "0.1.34"
resolved "https://registry.npmmirror.com/langchain/-/langchain-0.1.34.tgz#3c28a6bde69c5f4ac3931376d34187de0e44e43a"
integrity sha512-4TVH2mzhITrLPOeyfGucfqo1+360DJMl4+ItG56ApxVY1krO4hV0EkqcRLAxW06W6sIue8mIU70WbyhBYH68Ug==
langchain@^0.1.35:
version "0.1.35"
resolved "https://registry.npmmirror.com/langchain/-/langchain-0.1.35.tgz#6ee22c140201597d7983f3f12c75a3c6f16cbc0c"
integrity sha512-wTaTNzaAPb/umcoWxFupc0QGsEJvPB6pRE8Ecy8v4CCsn/a5O6QpfRylvJKXXWoxGG8BI4L3G+HjsXCDUNxVrQ==
dependencies:
"@anthropic-ai/sdk" "^0.9.1"
"@langchain/community" "~0.0.47"
Expand Down

0 comments on commit f0ddc62

Please sign in to comment.