- 新增 backend 服务 (Express + TypeScript) - 前端表单提交改为调用后端 API - DeepSeek 增强分析结果,本地规则作为 fallback - Docker 双容器部署:web (Nginx) + backend - Nginx 反向代理 /api 到后端服务 - 本地开发支持 Vite 代理 + backend:dev 脚本 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
60 lines
1.3 KiB
TypeScript
60 lines
1.3 KiB
TypeScript
export interface UserInput {
|
|
birthDate: string;
|
|
birthTime: string;
|
|
gender: 'male' | 'female';
|
|
birthPlace: string;
|
|
}
|
|
|
|
export interface FortuneProfile {
|
|
wuxing: 'wood' | 'fire' | 'earth' | 'metal' | 'water';
|
|
wuxingLabel: string;
|
|
personality: string[];
|
|
strengths: string[];
|
|
weaknesses: string[];
|
|
developmentRhythm: 'stable' | 'growth' | 'breakthrough' | 'accumulation';
|
|
}
|
|
|
|
export interface CompanyRecommendation {
|
|
type: string;
|
|
matchScore: number;
|
|
reasons: string[];
|
|
suitableFor: string[];
|
|
notSuitableFor: string[];
|
|
stageAdvice: string;
|
|
}
|
|
|
|
export interface JobRecommendation {
|
|
category: string;
|
|
matchScore: number;
|
|
reasons: string[];
|
|
suitableWorkStyle: string[];
|
|
notSuitableFor: string[];
|
|
}
|
|
|
|
export interface StageAdvice {
|
|
overall: string;
|
|
careerDirection: string;
|
|
jobChangeTiming: string;
|
|
platformPreference: string;
|
|
keyObservations: string[];
|
|
}
|
|
|
|
export interface FortuneResult {
|
|
profile: FortuneProfile;
|
|
companyRecommendations: CompanyRecommendation[];
|
|
jobRecommendations: JobRecommendation[];
|
|
stageAdvice: StageAdvice;
|
|
}
|
|
|
|
export interface FortuneAnalyzeMeta {
|
|
provider: 'deepseek';
|
|
model: string;
|
|
fallbackUsed: boolean;
|
|
}
|
|
|
|
export interface FortuneAnalyzeResponse {
|
|
success: boolean;
|
|
data: FortuneResult;
|
|
meta: FortuneAnalyzeMeta;
|
|
}
|