fraim-framework 2.0.26 → 2.0.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/deploy-fraim.yml +1 -1
- package/dist/registry/scripts/build-scripts-generator.js +205 -0
- package/dist/registry/scripts/cleanup-branch.js +258 -0
- package/dist/registry/scripts/evaluate-code-quality.js +66 -0
- package/dist/registry/scripts/exec-with-timeout.js +142 -0
- package/dist/registry/scripts/fraim-config.js +61 -0
- package/dist/registry/scripts/generate-engagement-emails.js +630 -0
- package/dist/registry/scripts/generic-issues-api.js +100 -0
- package/dist/registry/scripts/newsletter-helpers.js +731 -0
- package/dist/registry/scripts/openapi-generator.js +664 -0
- package/dist/registry/scripts/performance/profile-server.js +390 -0
- package/dist/registry/scripts/run-thank-you-workflow.js +92 -0
- package/dist/registry/scripts/send-newsletter-simple.js +85 -0
- package/dist/registry/scripts/send-thank-you-emails.js +54 -0
- package/dist/registry/scripts/validate-openapi-limits.js +311 -0
- package/dist/registry/scripts/validate-test-coverage.js +262 -0
- package/dist/registry/scripts/verify-test-coverage.js +66 -0
- package/dist/src/cli/commands/init.js +14 -12
- package/dist/src/cli/commands/sync.js +19 -2
- package/dist/src/cli/fraim.js +24 -22
- package/dist/src/cli/setup/first-run.js +13 -6
- package/dist/src/fraim/config-loader.js +0 -8
- package/dist/src/fraim/db-service.js +26 -15
- package/dist/src/fraim/issues.js +67 -0
- package/dist/src/fraim/setup-wizard.js +1 -69
- package/dist/src/fraim/types.js +0 -11
- package/dist/src/fraim-mcp-server.js +272 -18
- package/dist/src/utils/git-utils.js +1 -1
- package/dist/src/utils/version-utils.js +32 -0
- package/dist/tests/debug-tools.js +79 -0
- package/dist/tests/esm-compat.js +11 -0
- package/dist/tests/test-chalk-esm-issue.js +159 -0
- package/dist/tests/test-chalk-real-world.js +265 -0
- package/dist/tests/test-chalk-regression.js +327 -0
- package/dist/tests/test-chalk-resolution-issue.js +304 -0
- package/dist/tests/test-cli.js +0 -2
- package/dist/tests/test-fraim-install-chalk-issue.js +254 -0
- package/dist/tests/test-fraim-issues.js +59 -0
- package/dist/tests/test-genericization.js +1 -3
- package/dist/tests/test-mcp-connection.js +166 -0
- package/dist/tests/test-mcp-issue-integration.js +144 -0
- package/dist/tests/test-mcp-lifecycle-methods.js +312 -0
- package/dist/tests/test-node-compatibility.js +71 -0
- package/dist/tests/test-npm-install.js +66 -0
- package/dist/tests/test-npm-resolution-diagnostic.js +140 -0
- package/dist/tests/test-session-rehydration.js +145 -0
- package/dist/tests/test-standalone.js +2 -8
- package/dist/tests/test-sync-version-update.js +93 -0
- package/dist/tests/test-telemetry.js +190 -0
- package/package.json +10 -8
- package/registry/agent-guardrails.md +62 -54
- package/registry/rules/agent-success-criteria.md +52 -0
- package/registry/rules/agent-testing-guidelines.md +502 -502
- package/registry/rules/communication.md +121 -121
- package/registry/rules/continuous-learning.md +54 -54
- package/registry/rules/ephemeral-execution.md +10 -5
- package/registry/rules/hitl-ppe-record-analysis.md +302 -302
- package/registry/rules/local-development.md +251 -251
- package/registry/rules/software-development-lifecycle.md +104 -104
- package/registry/rules/successful-debugging-patterns.md +482 -478
- package/registry/rules/telemetry.md +67 -0
- package/registry/scripts/build-scripts-generator.ts +216 -215
- package/registry/scripts/cleanup-branch.ts +303 -284
- package/registry/scripts/code-quality-check.sh +559 -559
- package/registry/scripts/detect-tautological-tests.sh +38 -38
- package/registry/scripts/evaluate-code-quality.ts +1 -1
- package/registry/scripts/generate-engagement-emails.ts +744 -744
- package/registry/scripts/generic-issues-api.ts +110 -150
- package/registry/scripts/newsletter-helpers.ts +874 -874
- package/registry/scripts/openapi-generator.ts +695 -693
- package/registry/scripts/performance/profile-server.ts +5 -3
- package/registry/scripts/prep-issue.sh +468 -455
- package/registry/scripts/validate-openapi-limits.ts +366 -365
- package/registry/scripts/validate-test-coverage.ts +280 -280
- package/registry/scripts/verify-pr-comments.sh +70 -70
- package/registry/scripts/verify-test-coverage.ts +1 -1
- package/registry/templates/bootstrap/ARCHITECTURE-TEMPLATE.md +53 -53
- package/registry/templates/evidence/Implementation-BugEvidence.md +85 -85
- package/registry/templates/evidence/Implementation-FeatureEvidence.md +120 -120
- package/registry/templates/marketing/HBR-ARTICLE-TEMPLATE.md +66 -0
- package/registry/workflows/bootstrap/create-architecture.md +2 -2
- package/registry/workflows/bootstrap/evaluate-code-quality.md +3 -3
- package/registry/workflows/bootstrap/verify-test-coverage.md +2 -2
- package/registry/workflows/customer-development/insight-analysis.md +156 -156
- package/registry/workflows/customer-development/interview-preparation.md +421 -421
- package/registry/workflows/customer-development/strategic-brainstorming.md +146 -146
- package/registry/workflows/customer-development/thank-customers.md +193 -191
- package/registry/workflows/customer-development/weekly-newsletter.md +362 -352
- package/registry/workflows/improve-fraim/contribute.md +32 -0
- package/registry/workflows/improve-fraim/file-issue.md +32 -0
- package/registry/workflows/marketing/hbr-article.md +73 -0
- package/registry/workflows/performance/analyze-performance.md +63 -59
- package/registry/workflows/product-building/design.md +3 -2
- package/registry/workflows/product-building/implement.md +4 -3
- package/registry/workflows/product-building/prep-issue.md +28 -17
- package/registry/workflows/product-building/resolve.md +3 -2
- package/registry/workflows/product-building/retrospect.md +3 -2
- package/registry/workflows/product-building/spec.md +5 -4
- package/registry/workflows/product-building/test.md +3 -2
- package/registry/workflows/quality-assurance/iterative-improvement-cycle.md +562 -562
- package/registry/workflows/replicate/website-discovery-analysis.md +3 -3
- package/registry/workflows/reviewer/review-implementation-vs-design-spec.md +632 -632
- package/registry/workflows/reviewer/review-implementation-vs-feature-spec.md +669 -669
- package/tsconfig.json +2 -1
|
@@ -1,191 +1,193 @@
|
|
|
1
|
-
# Thank Customers Workflow
|
|
2
|
-
|
|
3
|
-
## INTENT
|
|
4
|
-
To automatically generate and send personalized thank you emails to customers whose feedback has been implemented, strengthening customer relationships and encouraging continued engagement.
|
|
5
|
-
|
|
6
|
-
## PRINCIPLES
|
|
7
|
-
- **Personal Touch**: Ashley's voice, grateful tone, "Thank you for making me better..."
|
|
8
|
-
- **Voice & Pronouns**: Emails are written in first person from Ashley ("I", "me", "my"). When referring to Ashley in third person (outside the email body), use they/them pronouns. Avoid gendered pronouns for Ashley.
|
|
9
|
-
- **Customer-Focused**: No technical jargon or issue numbers in customer emails
|
|
10
|
-
- **Short and Sweet**: To the point, instructive, humble
|
|
11
|
-
- **Encourage more feedback**: ChatGPT (https://ashley-chat.wellnessatwork.me) is the best way
|
|
12
|
-
|
|
13
|
-
## WORKFLOW TRIGGER
|
|
14
|
-
**User triggers this workflow manually**:
|
|
15
|
-
- When customer issues are resolved and deployed
|
|
16
|
-
- User says: "Generate thank you emails for customers" or similar
|
|
17
|
-
|
|
18
|
-
## AI AGENT PROCESS
|
|
19
|
-
|
|
20
|
-
### Step 1: Issue Retrieval
|
|
21
|
-
**AI Agent calls function**:
|
|
22
|
-
```typescript
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
//
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
-
|
|
34
|
-
-
|
|
35
|
-
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
- Issue
|
|
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
|
-
|
|
1
|
+
# Thank Customers Workflow
|
|
2
|
+
|
|
3
|
+
## INTENT
|
|
4
|
+
To automatically generate and send personalized thank you emails to customers whose feedback has been implemented, strengthening customer relationships and encouraging continued engagement.
|
|
5
|
+
|
|
6
|
+
## PRINCIPLES
|
|
7
|
+
- **Personal Touch**: Ashley's voice, grateful tone, "Thank you for making me better..."
|
|
8
|
+
- **Voice & Pronouns**: Emails are written in first person from Ashley ("I", "me", "my"). When referring to Ashley in third person (outside the email body), use they/them pronouns. Avoid gendered pronouns for Ashley.
|
|
9
|
+
- **Customer-Focused**: No technical jargon or issue numbers in customer emails
|
|
10
|
+
- **Short and Sweet**: To the point, instructive, humble
|
|
11
|
+
- **Encourage more feedback**: ChatGPT (https://ashley-chat.wellnessatwork.me) is the best way
|
|
12
|
+
|
|
13
|
+
## WORKFLOW TRIGGER
|
|
14
|
+
**User triggers this workflow manually**:
|
|
15
|
+
- When customer issues are resolved and deployed
|
|
16
|
+
- User says: "Generate thank you emails for customers" or similar
|
|
17
|
+
|
|
18
|
+
## AI AGENT PROCESS
|
|
19
|
+
|
|
20
|
+
### Step 1: Issue Retrieval
|
|
21
|
+
**AI Agent calls function**:
|
|
22
|
+
```typescript
|
|
23
|
+
// Note: Retrieve script via get_fraim_file({ path: "scripts/generate-thank-you-emails.ts" }) and save to tmp/generate-thank-you-emails.ts
|
|
24
|
+
import { getResolvedIssues, findExecutiveByEmail, getAshleyEmailForExecutive } from './tmp/generate-thank-you-emails.ts';
|
|
25
|
+
|
|
26
|
+
// Get issues resolved since last thank-you date (automatic) or user-specified date
|
|
27
|
+
const resolvedIssues = await getResolvedIssues(); // Automatically uses latest thank-you date
|
|
28
|
+
// OR with explicit date:
|
|
29
|
+
const resolvedIssues = await getResolvedIssues('2025-10-29'); // Optional: user-specified date
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
**Note**: The `getResolvedIssues()` function automatically:
|
|
33
|
+
- Finds the most recent date from existing `thank-you-candidates-YYYY-MM-DD.json` files where emails were sent (status: "sent")
|
|
34
|
+
- Uses that date as the starting point to only fetch issues resolved AFTER that date
|
|
35
|
+
- If no thank-you files exist, falls back to last 14 days
|
|
36
|
+
- This ensures we never send duplicate thank-you emails for the same resolved issues
|
|
37
|
+
|
|
38
|
+
### Step 2: Customer Information Extraction
|
|
39
|
+
**AI Agent does intelligent extraction**:
|
|
40
|
+
1. **Go through each resolved issue**
|
|
41
|
+
2. **Extract customer email** from:
|
|
42
|
+
- Issue title format: `email@domain.com: summary`
|
|
43
|
+
- Issue body: look for email patterns
|
|
44
|
+
- If no email found, extract customer name and use database lookup
|
|
45
|
+
3. **Extract customer name** from:
|
|
46
|
+
- Issue title or body
|
|
47
|
+
- Previous thank-you notes
|
|
48
|
+
- Onboarding insights documents
|
|
49
|
+
|
|
50
|
+
### Step 3: Database Lookup
|
|
51
|
+
**AI Agent calls function for each customer**:
|
|
52
|
+
```typescript
|
|
53
|
+
// Look up executive by customer email
|
|
54
|
+
const executive = await findExecutiveByEmail(customerEmail);
|
|
55
|
+
|
|
56
|
+
// Get Ashley email address for this executive
|
|
57
|
+
const ashleyEmail = await getAshleyEmailForExecutive(executive.id);
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
### Step 4: Collate Issues by Customer
|
|
61
|
+
**AI Agent organizes data**:
|
|
62
|
+
- Group all resolved issues by customer email
|
|
63
|
+
- **Consolidate customers with multiple email addresses** by matching customer names (case-insensitive)
|
|
64
|
+
- When a customer has multiple emails, use the primary email from the database lookup
|
|
65
|
+
- Output customer list to console for verification
|
|
66
|
+
|
|
67
|
+
### Step 5: Generate Single Thank-You File
|
|
68
|
+
**AI Agent creates ONE file**:
|
|
69
|
+
- File: `docs/customer-development/thank-you-notes/thank-you-candidates-YYYY-MM-DD.json`
|
|
70
|
+
- Format: Structured JSON (not markdown) for easy parsing by mail sending script
|
|
71
|
+
- Contains ALL customers and their personalized emails
|
|
72
|
+
- **AI Agent writes the email content** - be creative, personal, and contextual!
|
|
73
|
+
- Follow principles: personal touch, customer-focused, short and sweet, encourage feedback
|
|
74
|
+
- **NO TECHNICAL JARGON**: Do not mention issue numbers, BAML, internal systems, or technical details
|
|
75
|
+
- **CUSTOMER EXPERIENCE FOCUS**: Describe what was broken from the user's perspective, what was fixed, and how they can verify it works
|
|
76
|
+
- **First-person Email Body**: Use "I" for actions Ashley took (e.g., "I fixed", "I now", "I will"), not "Ashley" or "she". Sign off as Ashley.
|
|
77
|
+
- Include `From:` field showing Ashley email from PPE (via `getAshleyEmailForExecutive()`)
|
|
78
|
+
|
|
79
|
+
**File format** (JSON):
|
|
80
|
+
```json
|
|
81
|
+
{
|
|
82
|
+
"metadata": {
|
|
83
|
+
"generatedOn": "2025-10-29T02:29:02.497Z",
|
|
84
|
+
"issuesResolvedSince": "2025-10-28",
|
|
85
|
+
"totalCustomers": 2,
|
|
86
|
+
"totalIssues": 3
|
|
87
|
+
},
|
|
88
|
+
"candidates": [
|
|
89
|
+
{
|
|
90
|
+
"customer": {
|
|
91
|
+
"name": "Olga Ivanova",
|
|
92
|
+
"email": "olga.ivanova@gmail.com"
|
|
93
|
+
},
|
|
94
|
+
"executive": {
|
|
95
|
+
"name": "Olga Ivanova",
|
|
96
|
+
"id": "exec-..."
|
|
97
|
+
},
|
|
98
|
+
"status": "pending",
|
|
99
|
+
"from": {
|
|
100
|
+
"displayName": "Ashley - Olga Ivanova's AI Executive Assistant",
|
|
101
|
+
"email": "ashley+olga@ashleycalendar.ai"
|
|
102
|
+
},
|
|
103
|
+
"to": "olga.ivanova@gmail.com",
|
|
104
|
+
"subject": "Thank you for your feedback - your issues have been addressed!",
|
|
105
|
+
"greeting": "Hi Olga,",
|
|
106
|
+
"opening": "Thank you for making me better! I wanted to personally reach out because your feedback helped us catch and fix an important bug.",
|
|
107
|
+
"improvements": [
|
|
108
|
+
{
|
|
109
|
+
"title": "Issue filing feature",
|
|
110
|
+
"description": "The issue filing feature is now working properly - when you ask me to file a bug or feature request through voice, I'll handle it correctly.",
|
|
111
|
+
"verification": "Try asking me to file a bug or feature request and it should work smoothly now."
|
|
112
|
+
}
|
|
113
|
+
],
|
|
114
|
+
"closing": "Your quick feedback saved you (and others) frustration down the line. That kind of real-time input makes all the difference as I'm learning."
|
|
115
|
+
}
|
|
116
|
+
]
|
|
117
|
+
}
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
**Note**: The structured format allows the HTML template to format each section beautifully:
|
|
121
|
+
- `greeting`: Personal greeting (e.g., "Hi Olga,")
|
|
122
|
+
- `opening`: Opening paragraph - thanks and context
|
|
123
|
+
- `improvements[]`: Array of improvements (title, description, optional verification step)
|
|
124
|
+
- `closing`: Closing paragraph - encouraging more feedback
|
|
125
|
+
|
|
126
|
+
The HTML template formats each section with appropriate styling.
|
|
127
|
+
|
|
128
|
+
### Step 6: User Review
|
|
129
|
+
**AI Agent**:
|
|
130
|
+
1. **Points user to the generated file**: `docs/customer-development/thank-you-notes/thank-you-candidates-YYYY-MM-DD.json`
|
|
131
|
+
2. **Requests review** and any edits needed (user can edit JSON directly)
|
|
132
|
+
3. **Waits for user approval** before proceeding
|
|
133
|
+
|
|
134
|
+
**Note**: Each email section includes a `From:` field showing the display name and email address that will be used when sending. The signature includes a humble note about ramping up, without displaying a generic email address.
|
|
135
|
+
|
|
136
|
+
### Step 7: Send Emails (Separate Command)
|
|
137
|
+
**When user says "Send the emails" or similar**:
|
|
138
|
+
|
|
139
|
+
**AI Agent calls function**:
|
|
140
|
+
```typescript
|
|
141
|
+
// Note: Retrieve script via get_fraim_file({ path: "scripts/generate-thank-you-emails.ts" }) and save to tmp/generate-thank-you-emails.ts
|
|
142
|
+
import { sendCustomerMail } from './tmp/generate-thank-you-emails.ts';
|
|
143
|
+
|
|
144
|
+
// Send emails from the candidates JSON file (all pending candidates)
|
|
145
|
+
await sendCustomerMail('docs/customer-development/thank-you-notes/thank-you-candidates-YYYY-MM-DD.json');
|
|
146
|
+
|
|
147
|
+
// OR send to a specific executive only (optional)
|
|
148
|
+
await sendCustomerMail('docs/customer-development/thank-you-notes/thank-you-candidates-YYYY-MM-DD.json', 'exec-1761011032377-q36j91sdl');
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
**Note**: The `sendCustomerMail` function parses JSON (not markdown) for easy, deterministic parsing.
|
|
152
|
+
|
|
153
|
+
**Function parameters**:
|
|
154
|
+
- `candidatesFilePath` (required): Path to the JSON candidates file
|
|
155
|
+
- `executiveId` (optional): If provided, only sends emails for candidates matching this executive ID. If omitted, sends to all pending candidates.
|
|
156
|
+
|
|
157
|
+
**This function will**:
|
|
158
|
+
- Parse the JSON candidates file
|
|
159
|
+
- If `executiveId` is provided, filter to only that executive's candidates
|
|
160
|
+
- For each candidate with `status: "pending"`, send email
|
|
161
|
+
- Use the `from` field (displayName and email) specified in JSON
|
|
162
|
+
- Use the `to`, `subject`, and `body` fields from JSON
|
|
163
|
+
- Update the JSON file after each send with status: `"sent"` or `"failed"`
|
|
164
|
+
- Skip candidates that already have status `"sent"` or `"failed"`
|
|
165
|
+
|
|
166
|
+
## REQUIRED FUNCTIONS IN SCRIPT
|
|
167
|
+
|
|
168
|
+
The script must provide these deterministic functions for AI agents to call:
|
|
169
|
+
|
|
170
|
+
```typescript
|
|
171
|
+
// Get resolved issues since a date
|
|
172
|
+
export async function getResolvedIssues(date: string): Promise<ResolvedIssue[]>
|
|
173
|
+
|
|
174
|
+
// Find executive by email in PPE database
|
|
175
|
+
export async function findExecutiveByEmail(email: string): Promise<Executive | null>
|
|
176
|
+
|
|
177
|
+
// Get Ashley email for executive from PPE database
|
|
178
|
+
export async function getAshleyEmailForExecutive(executiveId: string): Promise<string>
|
|
179
|
+
|
|
180
|
+
// Send emails from candidates file
|
|
181
|
+
// executiveId is optional - if provided, only sends to that executive; if omitted, sends to all pending
|
|
182
|
+
export async function sendCustomerMail(candidatesFilePath: string, executiveId?: string): Promise<void>
|
|
183
|
+
```
|
|
184
|
+
|
|
185
|
+
**Note**: The script provides ONLY data retrieval and sending. The AI agent does ALL intelligent work:
|
|
186
|
+
- Extracts customer info from issues (intelligent parsing)
|
|
187
|
+
- Writes personalized, creative email content (better than hardcoded templates!)
|
|
188
|
+
- Organizes and formats the candidates file
|
|
189
|
+
|
|
190
|
+
## WORKFLOW COMPLETION
|
|
191
|
+
|
|
192
|
+
**Generate workflow completes with**: Single candidates file ready for review
|
|
193
|
+
**Send workflow completes with**: All emails sent and file updated with status
|