mirror of
https://wget.la/https://github.com/Wxw-Gu/WechatExplorer
synced 2026-08-21 21:47:00 +08:00
* fix(ai): 让严格执行`max_tokens`的API恢复工作,如DeepSeek - AI 请求优先使用当前模型配置的`Max Tokens`,并依次回退到供应商高级设置的`Max Tokens`和默认值 4096 - 透传`OpenAI-compatible`与`Anthropic`的结束原因,补充`preload`类型声明 - 群日报生成和修复遇到模型异常结束生成时终止处理,并针对token上限给出配置提示 - 优化 AI 未返回有效内容时的错误信息 - 统一行尾配置 Signed-off-by: longhuan1999 <2114467924@qq.com> * Update .gitignore --------- Signed-off-by: longhuan1999 <2114467924@qq.com> Co-authored-by: qingmao <84499436+Wxw-Gu@users.noreply.github.com>
39 lines
1.0 KiB
JavaScript
39 lines
1.0 KiB
JavaScript
import { defineConfig } from 'eslint/config'
|
|
import tseslint from '@electron-toolkit/eslint-config-ts'
|
|
import eslintConfigPrettier from '@electron-toolkit/eslint-config-prettier'
|
|
import eslintPluginReact from 'eslint-plugin-react'
|
|
import eslintPluginReactHooks from 'eslint-plugin-react-hooks'
|
|
import eslintPluginReactRefresh from 'eslint-plugin-react-refresh'
|
|
|
|
export default defineConfig(
|
|
{ ignores: ['**/node_modules', '**/dist', '**/out'] },
|
|
tseslint.configs.recommended,
|
|
eslintPluginReact.configs.flat.recommended,
|
|
eslintPluginReact.configs.flat['jsx-runtime'],
|
|
{
|
|
settings: {
|
|
react: {
|
|
version: 'detect'
|
|
}
|
|
}
|
|
},
|
|
{
|
|
files: ['**/*.{ts,tsx}'],
|
|
plugins: {
|
|
'react-hooks': eslintPluginReactHooks,
|
|
'react-refresh': eslintPluginReactRefresh
|
|
},
|
|
rules: {
|
|
'prettier/prettier': [
|
|
'error',
|
|
{
|
|
endOfLine: 'auto'
|
|
}
|
|
],
|
|
...eslintPluginReactHooks.configs.recommended.rules,
|
|
...eslintPluginReactRefresh.configs.vite.rules
|
|
}
|
|
},
|
|
eslintConfigPrettier
|
|
)
|