fix: resolve confirmed character hidden bug, remove online font dependency, improve UI/UX experience

This commit is contained in:
saturn
2026-03-21 14:35:32 +08:00
parent f364bbc9e4
commit a6ad11b9c4
42 changed files with 1189 additions and 553 deletions

View File

@@ -0,0 +1,24 @@
import { describe, expect, it } from 'vitest'
import { getPromptTemplate, PROMPT_IDS } from '@/lib/prompt-i18n'
describe('select prop prompt template', () => {
it('zh template restricts extraction to key story props and prefers omission when uncertain', () => {
const template = getPromptTemplate(PROMPT_IDS.NP_SELECT_PROP, 'zh')
expect(template).toContain('关键剧情道具资产分析师')
expect(template).toContain('宁缺毋滥')
expect(template).toContain('必须在剧情中承担明确功能')
expect(template).toContain('如果不确定它是否值得进入资产库,直接不输出')
expect(template).toContain('仅因外观具体、名词明确,不足以成为关键道具')
})
it('en template restricts extraction to key story props and prefers omission when uncertain', () => {
const template = getPromptTemplate(PROMPT_IDS.NP_SELECT_PROP, 'en')
expect(template).toContain('key story prop extractor')
expect(template).toContain('Be conservative')
expect(template).toContain('clear story function')
expect(template).toContain('If you are unsure whether it deserves an asset entry, do not output it')
expect(template).toContain('A specific-looking noun is not enough')
})
})