Initial commit: AI chat assistant with workflow chat, workspace, and profile tabs
Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
65
constants/index.uts
Normal file
65
constants/index.uts
Normal file
@@ -0,0 +1,65 @@
|
||||
/**
|
||||
* AI Chat Assistant — Constants
|
||||
*/
|
||||
|
||||
import type { WorkflowDef } from '@/types/index'
|
||||
|
||||
// Workflow definitions
|
||||
export const WORKFLOWS: WorkflowDef[] = [
|
||||
{
|
||||
id: 'general',
|
||||
name: '通用对话',
|
||||
icon: '💬',
|
||||
description: '自由提问,获取AI智能回答',
|
||||
color: '#6c5ce7',
|
||||
},
|
||||
{
|
||||
id: 'code',
|
||||
name: '代码助手',
|
||||
icon: '💻',
|
||||
description: '编程问题解答、代码生成与调试',
|
||||
color: '#00b894',
|
||||
},
|
||||
{
|
||||
id: 'document',
|
||||
name: '文档写作',
|
||||
icon: '📝',
|
||||
description: '文章撰写、润色与总结',
|
||||
color: '#fdcb6e',
|
||||
},
|
||||
{
|
||||
id: 'data',
|
||||
name: '数据分析',
|
||||
icon: '📊',
|
||||
description: '数据处理、图表解读与洞察分析',
|
||||
color: '#e17055',
|
||||
},
|
||||
{
|
||||
id: 'creative',
|
||||
name: '创意生成',
|
||||
icon: '✨',
|
||||
description: '头脑风暴、创意点子与方案策划',
|
||||
color: '#a29bfe',
|
||||
},
|
||||
]
|
||||
|
||||
// Storage keys
|
||||
export const STORAGE_KEYS = {
|
||||
CONVERSATIONS: 'asst_conversations',
|
||||
WORKSPACE: 'asst_workspace',
|
||||
ACTIVE_CONVERSATION_ID: 'asst_active_conv_id',
|
||||
ACTIVE_WORKFLOW_ID: 'asst_workflow_id',
|
||||
} as const
|
||||
|
||||
// App settings
|
||||
export const MOCK_AI_DELAY_MS = 1500
|
||||
export const MAX_INPUT_LENGTH = 2000
|
||||
export const APP_NAME = 'AI助手'
|
||||
export const APP_SUBTITLE = '智能工作助手'
|
||||
|
||||
// Generate a simple unique ID
|
||||
export function generateId(): string {
|
||||
const timestamp = Date.now().toString(36)
|
||||
const random = Math.floor(Math.random() * 100000).toString(36)
|
||||
return `${timestamp}${random}`
|
||||
}
|
||||
Reference in New Issue
Block a user