-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtypes.ts
More file actions
214 lines (184 loc) · 5.84 KB
/
Copy pathtypes.ts
File metadata and controls
214 lines (184 loc) · 5.84 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
export interface User {
username: string;
createdAt: number;
}
export type GenerationLanguage = 'English' | 'Hebrew';
export const DEFAULT_GENERATION_LANGUAGE: GenerationLanguage = 'English';
export interface UserProfile {
content: string;
fileName: string;
}
export interface JobDetails {
title: string;
company: string;
description: string;
}
export interface InterviewQuestion {
question: string;
context: string; // Why this is being asked
suggestedAnswer: string; // Bullet points on how to answer
}
export interface EmailKit {
linkedInConnection: string;
followUpEmail: string;
}
export interface CompanyIntel {
keyValues: string[]; // 3 bullet points on values
recentInitiatives: string; // What are they building/doing now?
interviewTalkingPoints: string[]; // 3 things to mention to sound smart
cultureVibe: string; // "Fast paced", "Academic", etc.
}
export interface GeneratedAssets {
resumeHtml: string;
coverLetter?: string;
strategyStory?: string;
interviewPrep?: InterviewQuestion[];
emailKit?: EmailKit;
companyIntel?: CompanyIntel;
}
export interface GenerationOptions {
coverLetter: boolean;
strategy: boolean;
interviewPrep: boolean;
outreach: boolean;
}
export const GEMINI_MODEL_OPTIONS = [
{ id: 'gemini-3.1-pro-preview', label: 'Gemini 3.1 Pro Preview', supportsThinking: true, pricingNote: 'Preview, paid tier only on pricing page' },
{ id: 'gemini-3.1-flash-lite-preview', label: 'Gemini 3.1 Flash-Lite Preview', supportsThinking: true, pricingNote: 'Preview, cost-efficient' },
{ id: 'gemini-3-flash-preview', label: 'Gemini 3 Flash Preview', supportsThinking: true, pricingNote: 'Preview, frontier Flash model' },
{ id: 'gemini-2.5-pro', label: 'Gemini 2.5 Pro', supportsThinking: true, pricingNote: 'Stable, strong reasoning' },
{ id: 'gemini-2.5-flash', label: 'Gemini 2.5 Flash', supportsThinking: true, pricingNote: 'Stable, hybrid reasoning' },
{ id: 'gemini-2.5-flash-lite', label: 'Gemini 2.5 Flash-Lite', supportsThinking: true, pricingNote: 'Stable, lowest-cost 2.5 text model' },
{ id: 'gemini-2.0-flash', label: 'Gemini 2.0 Flash', supportsThinking: false, pricingNote: 'Deprecated June 1, 2026' },
{ id: 'gemini-2.0-flash-lite', label: 'Gemini 2.0 Flash-Lite', supportsThinking: false, pricingNote: 'Deprecated June 1, 2026' },
] as const;
export type GeminiModelId = typeof GEMINI_MODEL_OPTIONS[number]['id'];
export const DEFAULT_GEMINI_MODEL: GeminiModelId = 'gemini-2.5-pro';
export interface GeminiModelOption {
id: GeminiModelId;
label: string;
supportsThinking: boolean;
pricingNote: string;
}
export interface ModelSettings {
selectedModel: GeminiModelId;
}
export type ApplicationStatus = 'active' | 'rejected' | 'hired' | 'ghosted';
export interface RecruitmentStage {
id: string;
label: string; // e.g. "Phone Screen", "Technical"
completed: boolean;
current: boolean;
date?: string;
}
export interface ApplicationRecord {
id: string;
date: string;
title: string;
company: string;
// Saved Context for future generation
description: string;
profileContent: string;
language?: GenerationLanguage;
assets: GeneratedAssets;
overallStatus: ApplicationStatus;
stages: RecruitmentStage[];
}
export enum AppStatus {
IDLE = 'IDLE',
PROCESSING = 'PROCESSING',
COMPLETE = 'COMPLETE',
ERROR = 'ERROR'
}
export interface AppState {
status: AppStatus;
userProfile: UserProfile | null;
jobDetails: JobDetails;
results: GeneratedAssets | null;
error: string | null;
}
export interface UsageLog {
timestamp: string;
model: string;
inputTokens: number;
outputTokens: number;
totalTokens: number;
cost: number;
taskType: string;
}
export interface TokenStats {
totalTokens: number;
totalCost: number;
requestCount: number;
modelBreakdown: Record<string, { tokens: number; cost: number }>;
}
export type JobBoardSourceType = 'ats' | 'rss' | 'generic' | 'manual';
export type JobBoardListingStatus = 'new' | 'applied' | 'archived' | 'deleted' | 'processing' | 'excluded_by_advanced_matching' | 'saved' | 'ignored' | 'forged';
export type JobBoardScanState = 'idle' | 'scanning' | 'blocked' | 'login_required' | 'failed' | 'complete';
export type JobBoardJobType = 'remote' | 'hybrid' | 'onsite';
export type JobBoardLabel = 'Considering' | 'Submitted' | 'Interviewing' | 'Offer' | 'Rejected' | 'Ghosted';
export interface JobBoardSource {
id: string;
name: string;
url: string;
type: JobBoardSourceType;
enabled: boolean;
createdAt: string;
updatedAt: string;
lastScannedAt?: string;
lastScanState?: JobBoardScanState;
lastError?: string;
scrapeFailureCount?: number;
}
export interface JobBoardListing {
id: string;
sourceId: string;
sourceName: string;
externalUrl: string;
title: string;
company: string;
companyLogo?: string;
location?: string;
remote?: boolean;
jobType?: JobBoardJobType;
salary?: string;
tags?: string[];
labels?: JobBoardLabel[];
description?: string;
discoveredAt: string;
postedAt?: string;
status: JobBoardListingStatus;
fingerprint: string;
excludeReason?: string;
note?: string;
}
export interface JobBoardNote {
id: string;
listingId: string;
text: string;
files: string[];
createdAt: string;
updatedAt: string;
}
export interface JobBoardAdvancedMatchingConfig {
prompt: string;
blacklistedCompanies: string[];
}
export interface JobBoardSettings {
concurrency: number;
scrollTimes: number;
minDelayMs: number;
maxDelayMs: number;
persistBrowserSession: boolean;
autoScanIntervalMinutes?: number;
preventSleep?: boolean;
useNotifications?: boolean;
}
export interface JobBoardScanResult {
scannedSourceCount: number;
newListingCount: number;
updatedListingCount: number;
sources: JobBoardSource[];
listings: JobBoardListing[];
errors: Array<{ sourceId: string; sourceName: string; state: JobBoardScanState; message: string }>;
}