@awell-health/awell-extensions 2.0.208 → 2.0.210
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/dist/extensions/awell/v1/actions/updatePatient/config/fields.d.ts +12 -0
- package/dist/extensions/awell/v1/actions/updatePatient/config/fields.js +22 -0
- package/dist/extensions/awell/v1/actions/updatePatient/config/fields.js.map +1 -1
- package/dist/extensions/awell/v1/actions/updatePatient/config/getTimezones.d.ts +5 -0
- package/dist/extensions/awell/v1/actions/updatePatient/config/getTimezones.js +12 -0
- package/dist/extensions/awell/v1/actions/updatePatient/config/getTimezones.js.map +1 -0
- package/dist/extensions/awell/v1/actions/updatePatient/updatePatient.js +2 -1
- package/dist/extensions/awell/v1/actions/updatePatient/updatePatient.js.map +1 -1
- package/dist/extensions/awell/v1/gql/graphql.d.ts +1 -0
- package/dist/extensions/awell/v1/gql/graphql.js.map +1 -1
- package/dist/extensions/calDotCom/actions/createBooking/config/fields.d.ts +2 -2
- package/dist/extensions/calDotCom/schema.d.ts +22 -22
- package/dist/extensions/markdown.json +1 -1
- package/dist/extensions/shelly/actions/index.d.ts +7 -0
- package/dist/extensions/shelly/actions/summarizeForm/config/fields.d.ts +10 -0
- package/dist/extensions/shelly/actions/summarizeForm/config/fields.js +8 -2
- package/dist/extensions/shelly/actions/summarizeForm/config/fields.js.map +1 -1
- package/dist/extensions/shelly/actions/summarizeForm/summarizeForm.js +21 -4
- package/dist/extensions/shelly/actions/summarizeForm/summarizeForm.js.map +1 -1
- package/dist/extensions/shelly/lib/getFormResponseText/getFormResponseText.js +6 -6
- package/dist/extensions/shelly/lib/getFormResponseText/getFormResponseText.js.map +1 -1
- package/dist/extensions/shelly/lib/summarizeFormWithLLM/prompt.d.ts +2 -2
- package/dist/extensions/shelly/lib/summarizeFormWithLLM/prompt.js +6 -0
- package/dist/extensions/shelly/lib/summarizeFormWithLLM/prompt.js.map +1 -1
- package/dist/extensions/shelly/lib/summarizeFormWithLLM/summarizeFormWithLLM.d.ts +3 -1
- package/dist/extensions/shelly/lib/summarizeFormWithLLM/summarizeFormWithLLM.js +3 -1
- package/dist/extensions/shelly/lib/summarizeFormWithLLM/summarizeFormWithLLM.js.map +1 -1
- package/package.json +1 -1
@@ -105,6 +105,15 @@ export declare const fields: {
|
|
105
105
|
type: FieldType.STRING;
|
106
106
|
required: false;
|
107
107
|
};
|
108
|
+
patientTimzone: {
|
109
|
+
id: string;
|
110
|
+
label: string;
|
111
|
+
type: FieldType.STRING;
|
112
|
+
required: false;
|
113
|
+
options: {
|
114
|
+
dropdownOptions: import("./getTimezones").OptionProps[];
|
115
|
+
};
|
116
|
+
};
|
108
117
|
};
|
109
118
|
export declare const FieldsValidationSchema: z.ZodObject<{
|
110
119
|
patientCode: z.ZodOptional<z.ZodString>;
|
@@ -122,6 +131,7 @@ export declare const FieldsValidationSchema: z.ZodObject<{
|
|
122
131
|
preferredLanguage: z.ZodOptional<z.ZodString>;
|
123
132
|
sex: z.ZodOptional<z.ZodEffects<z.ZodEnum<[Sex.Female, Sex.Male, Sex.NotKnown]>, Sex, unknown>>;
|
124
133
|
nationalRegistryNumber: z.ZodOptional<z.ZodString>;
|
134
|
+
patientTimzone: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
|
125
135
|
}, "strip", z.ZodTypeAny, {
|
126
136
|
firstName?: string | undefined;
|
127
137
|
lastName?: string | undefined;
|
@@ -138,6 +148,7 @@ export declare const FieldsValidationSchema: z.ZodObject<{
|
|
138
148
|
street?: string | undefined;
|
139
149
|
zip?: string | undefined;
|
140
150
|
nationalRegistryNumber?: string | undefined;
|
151
|
+
patientTimzone?: string | undefined;
|
141
152
|
}, {
|
142
153
|
firstName?: string | undefined;
|
143
154
|
lastName?: string | undefined;
|
@@ -154,4 +165,5 @@ export declare const FieldsValidationSchema: z.ZodObject<{
|
|
154
165
|
street?: string | undefined;
|
155
166
|
zip?: string | undefined;
|
156
167
|
nationalRegistryNumber?: string | undefined;
|
168
|
+
patientTimzone?: string | undefined;
|
157
169
|
}>;
|
@@ -6,6 +6,7 @@ const zod_1 = require("zod");
|
|
6
6
|
const date_fns_1 = require("date-fns");
|
7
7
|
const graphql_1 = require("../../../gql/graphql");
|
8
8
|
const extensions_core_2 = require("@awell-health/extensions-core");
|
9
|
+
const getTimezones_1 = require("./getTimezones");
|
9
10
|
const SexEnum = zod_1.z.enum([graphql_1.Sex.Female, graphql_1.Sex.Male, graphql_1.Sex.NotKnown]);
|
10
11
|
exports.fields = {
|
11
12
|
patientCode: {
|
@@ -112,6 +113,15 @@ exports.fields = {
|
|
112
113
|
type: extensions_core_1.FieldType.STRING,
|
113
114
|
required: false,
|
114
115
|
},
|
116
|
+
patientTimzone: {
|
117
|
+
id: 'patientTimzone',
|
118
|
+
label: 'Patient timezone',
|
119
|
+
type: extensions_core_1.FieldType.STRING,
|
120
|
+
required: false,
|
121
|
+
options: {
|
122
|
+
dropdownOptions: (0, getTimezones_1.getTimezoneOptions)(),
|
123
|
+
},
|
124
|
+
},
|
115
125
|
};
|
116
126
|
exports.FieldsValidationSchema = zod_1.z.object({
|
117
127
|
patientCode: zod_1.z.optional(zod_1.z.string().trim().nonempty()),
|
@@ -129,5 +139,17 @@ exports.FieldsValidationSchema = zod_1.z.object({
|
|
129
139
|
preferredLanguage: zod_1.z.optional(zod_1.z.string().trim()),
|
130
140
|
sex: zod_1.z.optional(zod_1.z.preprocess((v) => String(v).toUpperCase(), SexEnum)),
|
131
141
|
nationalRegistryNumber: zod_1.z.string().trim().optional(),
|
142
|
+
patientTimzone: zod_1.z.optional(zod_1.z
|
143
|
+
.string()
|
144
|
+
.trim()
|
145
|
+
.refine((tz) => {
|
146
|
+
try {
|
147
|
+
return (Intl.DateTimeFormat(undefined, { timeZone: tz }).resolvedOptions()
|
148
|
+
.timeZone === tz);
|
149
|
+
}
|
150
|
+
catch (_a) {
|
151
|
+
return false;
|
152
|
+
}
|
153
|
+
}, 'Invalid timezone. Must be a valid IANA timezone format')),
|
132
154
|
});
|
133
155
|
//# sourceMappingURL=fields.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"fields.js","sourceRoot":"","sources":["../../../../../../../extensions/awell/v1/actions/updatePatient/config/fields.ts"],"names":[],"mappings":";;;AAAA,mEAIsC;AACtC,6BAAwC;AACxC,uCAAoC;AACpC,kDAA0C;AAC1C,mEAAiF;
|
1
|
+
{"version":3,"file":"fields.js","sourceRoot":"","sources":["../../../../../../../extensions/awell/v1/actions/updatePatient/config/fields.ts"],"names":[],"mappings":";;;AAAA,mEAIsC;AACtC,6BAAwC;AACxC,uCAAoC;AACpC,kDAA0C;AAC1C,mEAAiF;AACjF,iDAAmD;AAEnD,MAAM,OAAO,GAAG,OAAC,CAAC,IAAI,CAAC,CAAC,aAAG,CAAC,MAAM,EAAE,aAAG,CAAC,IAAI,EAAE,aAAG,CAAC,QAAQ,CAAC,CAAC,CAAA;AAE/C,QAAA,MAAM,GAAG;IACpB,WAAW,EAAE;QACX,EAAE,EAAE,aAAa;QACjB,KAAK,EAAE,cAAc;QACrB,IAAI,EAAE,2BAAS,CAAC,MAAM;QACtB,QAAQ,EAAE,KAAK;KAChB;IACD,SAAS,EAAE;QACT,EAAE,EAAE,WAAW;QACf,KAAK,EAAE,YAAY;QACnB,IAAI,EAAE,2BAAS,CAAC,MAAM;QACtB,QAAQ,EAAE,KAAK;KAChB;IACD,QAAQ,EAAE;QACR,EAAE,EAAE,UAAU;QACd,KAAK,EAAE,WAAW;QAClB,IAAI,EAAE,2BAAS,CAAC,MAAM;QACtB,QAAQ,EAAE,KAAK;KAChB;IACD,KAAK,EAAE;QACL,EAAE,EAAE,OAAO;QACX,KAAK,EAAE,OAAO;QACd,IAAI,EAAE,2BAAS,CAAC,MAAM;QACtB;;;WAGG;QACH,gCAAgC;QAChC,QAAQ,EAAE,KAAK;KAChB;IACD,SAAS,EAAE;QACT,EAAE,EAAE,WAAW;QACf,KAAK,EAAE,YAAY;QACnB,IAAI,EAAE,2BAAS,CA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M,CAAC;YACP,OAAO,KAAK,CAAA;QACd,CAAC;IACH,CAAC,EAAE,wDAAwD,CAAC,CAC/D;CACgD,CAAC,CAAA"}
|
@@ -0,0 +1,12 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.getTimezoneOptions = void 0;
|
4
|
+
const getTimezoneOptions = () => {
|
5
|
+
const tz = new Intl.DateTimeFormat().resolvedOptions().timeZone;
|
6
|
+
return [tz].map((timezone) => ({
|
7
|
+
label: timezone,
|
8
|
+
value: timezone,
|
9
|
+
}));
|
10
|
+
};
|
11
|
+
exports.getTimezoneOptions = getTimezoneOptions;
|
12
|
+
//# sourceMappingURL=getTimezones.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"getTimezones.js","sourceRoot":"","sources":["../../../../../../../extensions/awell/v1/actions/updatePatient/config/getTimezones.ts"],"names":[],"mappings":";;;AAKO,MAAM,kBAAkB,GAAG,GAAkB,EAAE;IACpD,MAAM,EAAE,GAAG,IAAI,IAAI,CAAC,cAAc,EAAE,CAAC,eAAe,EAAE,CAAC,QAAQ,CAAA;IAC/D,OAAO,CAAC,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,QAAgB,EAAE,EAAE,CAAC,CAAC;QACrC,KAAK,EAAE,QAAQ;QACf,KAAK,EAAE,QAAQ;KAChB,CAAC,CAAC,CAAA;AACL,CAAC,CAAA;AANY,QAAA,kBAAkB,sBAM9B"}
|
@@ -16,7 +16,7 @@ exports.updatePatient = {
|
|
16
16
|
fields: config_1.fields,
|
17
17
|
previewable: false,
|
18
18
|
onEvent: async ({ payload, onComplete, helpers }) => {
|
19
|
-
const { fields: { patientCode, firstName, lastName, birthDate, email, phone, mobilePhone, street, state, country, city, zip, preferredLanguage, sex, nationalRegistryNumber, }, patient: { id: patientId }, } = (0, extensions_core_1.validate)({
|
19
|
+
const { fields: { patientCode, firstName, lastName, birthDate, email, phone, mobilePhone, street, state, country, city, zip, preferredLanguage, sex, nationalRegistryNumber, patientTimzone, }, patient: { id: patientId }, } = (0, extensions_core_1.validate)({
|
20
20
|
schema: zod_1.z.object({
|
21
21
|
fields: config_1.FieldsValidationSchema,
|
22
22
|
patient: config_1.PatientValidationSchema,
|
@@ -76,6 +76,7 @@ exports.updatePatient = {
|
|
76
76
|
preferred_language: preferredLanguage,
|
77
77
|
sex,
|
78
78
|
national_registry_number: nationalRegistryNumber,
|
79
|
+
patient_timezone: patientTimzone,
|
79
80
|
},
|
80
81
|
});
|
81
82
|
await onComplete();
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"updatePatient.js","sourceRoot":"","sources":["../../../../../../extensions/awell/v1/actions/updatePatient/updatePatient.ts"],"names":[],"mappings":";;;;;;AAEA,mEAAkE;AAClE,qCAIiB;AACjB,6BAAuB;AACvB,kEAAyC;AAE5B,QAAA,aAAa,GAA2C;IACnE,GAAG,EAAE,eAAe;IACpB,QAAQ,EAAE,0BAAQ,CAAC,QAAQ;IAC3B,KAAK,EAAE,gBAAgB;IACvB,WAAW,EAAE,2CAA2C;IACxD,MAAM,EAAN,eAAM;IACN,WAAW,EAAE,KAAK;IAClB,OAAO,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,EAAiB,EAAE;QACjE,MAAM,EACJ,MAAM,EAAE,EACN,WAAW,EACX,SAAS,EACT,QAAQ,EACR,SAAS,EACT,KAAK,EACL,KAAK,EACL,WAAW,EACX,MAAM,EACN,KAAK,EACL,OAAO,EACP,IAAI,EACJ,GAAG,EACH,iBAAiB,EACjB,GAAG,EACH,sBAAsB,
|
1
|
+
{"version":3,"file":"updatePatient.js","sourceRoot":"","sources":["../../../../../../extensions/awell/v1/actions/updatePatient/updatePatient.ts"],"names":[],"mappings":";;;;;;AAEA,mEAAkE;AAClE,qCAIiB;AACjB,6BAAuB;AACvB,kEAAyC;AAE5B,QAAA,aAAa,GAA2C;IACnE,GAAG,EAAE,eAAe;IACpB,Q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QACN,KAAK;QAEL,MAAM,GAAG,CAAC,aAAa,CAAC;YACtB,UAAU,EAAE,SAAS;YACrB,OAAO,EAAE;gBACP,YAAY,EAAE,WAAW;gBACzB,UAAU,EAAE,SAAS;gBACrB,SAAS,EAAE,QAAQ;gBACnB,UAAU,EAAE,SAAS;gBACrB,KAAK;gBACL,KAAK;gBACL,YAAY,EAAE,WAAW;gBACzB,OAAO,EAAE;oBACP,MAAM;oBACN,KAAK;oBACL,OAAO;oBACP,IAAI;oBACJ,GAAG;iBACJ;gBACD,kBAAkB,EAAE,iBAAiB;gBACrC,GAAG;gBACH,wBAAwB,EAAE,sBAAsB;gBAChD,gBAAgB,EAAE,cAAc;aACjC;SACF,CAAC,CAAA;QAEF,MAAM,UAAU,EAAE,CAAA;IACpB,CAAC;CACF,CAAA"}
|
@@ -1195,6 +1195,7 @@ export type PatientProfileInput = {
|
|
1195
1195
|
preferred_language?: InputMaybe<Scalars['String']['input']>;
|
1196
1196
|
/** Sex code as defined by ISO standard IEC_5218, 0 - NOT_KNOWN, 1 - MALE, 2 - FEMALE */
|
1197
1197
|
sex?: InputMaybe<Sex>;
|
1198
|
+
patient_timezone?: InputMaybe<Scalars['String']['input']>;
|
1198
1199
|
};
|
1199
1200
|
export type PatientsPayload = PaginationAndSortingPayload & {
|
1200
1201
|
__typename?: 'PatientsPayload';
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"graphql.js","sourceRoot":"","sources":["../../../../../extensions/awell/v1/gql/graphql.ts"],"names":[],"mappings":";;;
|
1
|
+
{"version":3,"file":"graphql.js","sourceRoot":"","sources":["../../../../../extensions/awell/v1/gql/graphql.ts"],"names":[],"mappings":";;;AAsCA,IAAY,UAUX;AAVD,WAAY,UAAU;IACpB,kCAAoB,CAAA;IACpB,iDAAmC,CAAA;IACnC,yCAA2B,CAAA;IAC3B,qCAAuB,CAAA;IACvB,4CAA8B,CAAA;IAC9B,2BAAa,CAAA;IACb,iCAAmB,CAAA;IACnB,+BAAiB,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.ZodUnion<[z.ZodOptional<z.ZodString>, z.ZodEffects<z.ZodLiteral<"">, undefined, "">]>;
|
111
111
|
status: z.ZodUnion<[z.ZodOptional<z.ZodEnum<["ACCEPTED", "PENDING", "CANCELLED", "REJECTED"]>>, z.ZodEffects<z.ZodLiteral<"">, undefined, "">]>;
|
112
112
|
}, "strip", z.ZodTypeAny, {
|
113
|
-
language: string;
|
114
113
|
timeZone: string;
|
114
|
+
language: string;
|
115
115
|
eventTypeId: number;
|
116
116
|
responses: {
|
117
117
|
name: string;
|
@@ -127,8 +127,8 @@ export declare const FieldsValidationSchema: z.ZodObject<{
|
|
127
127
|
end?: string | undefined;
|
128
128
|
recurringEventId?: number | undefined;
|
129
129
|
}, {
|
130
|
-
language: string;
|
131
130
|
timeZone: string;
|
131
|
+
language: string;
|
132
132
|
eventTypeId: number;
|
133
133
|
responses: string;
|
134
134
|
start: Date;
|
@@ -13,13 +13,13 @@ declare const UserSchema: z.ZodObject<{
|
|
13
13
|
locale: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
14
14
|
}, "strip", z.ZodTypeAny, {
|
15
15
|
email: string;
|
16
|
-
name: string;
|
17
16
|
timeZone: string;
|
17
|
+
name: string;
|
18
18
|
locale?: string | null | undefined;
|
19
19
|
}, {
|
20
20
|
email: string;
|
21
|
-
name: string;
|
22
21
|
timeZone: string;
|
22
|
+
name: string;
|
23
23
|
locale?: string | null | undefined;
|
24
24
|
}>;
|
25
25
|
export type User = z.infer<typeof UserSchema>;
|
@@ -39,13 +39,13 @@ export declare const BookingSchema: z.ZodObject<{
|
|
39
39
|
locale: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
40
40
|
}, "strip", z.ZodTypeAny, {
|
41
41
|
email: string;
|
42
|
-
name: string;
|
43
42
|
timeZone: string;
|
43
|
+
name: string;
|
44
44
|
locale?: string | null | undefined;
|
45
45
|
}, {
|
46
46
|
email: string;
|
47
|
-
name: string;
|
48
47
|
timeZone: string;
|
48
|
+
name: string;
|
49
49
|
locale?: string | null | undefined;
|
50
50
|
}>;
|
51
51
|
attendees: z.ZodArray<z.ZodObject<{
|
@@ -55,13 +55,13 @@ export declare const BookingSchema: z.ZodObject<{
|
|
55
55
|
locale: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
56
56
|
}, "strip", z.ZodTypeAny, {
|
57
57
|
email: string;
|
58
|
-
name: string;
|
59
58
|
timeZone: string;
|
59
|
+
name: string;
|
60
60
|
locale?: string | null | undefined;
|
61
61
|
}, {
|
62
62
|
email: string;
|
63
|
-
name: string;
|
64
63
|
timeZone: string;
|
64
|
+
name: string;
|
65
65
|
locale?: string | null | undefined;
|
66
66
|
}>, "many">;
|
67
67
|
metadata: z.ZodObject<{
|
@@ -110,8 +110,8 @@ export declare const BookingSchema: z.ZodObject<{
|
|
110
110
|
};
|
111
111
|
user: {
|
112
112
|
email: string;
|
113
|
-
name: string;
|
114
113
|
timeZone: string;
|
114
|
+
name: string;
|
115
115
|
locale?: string | null | undefined;
|
116
116
|
};
|
117
117
|
eventTypeId: number;
|
@@ -119,8 +119,8 @@ export declare const BookingSchema: z.ZodObject<{
|
|
119
119
|
uid: string;
|
120
120
|
attendees: {
|
121
121
|
email: string;
|
122
|
-
name: string;
|
123
122
|
timeZone: string;
|
123
|
+
name: string;
|
124
124
|
locale?: string | null | undefined;
|
125
125
|
}[];
|
126
126
|
responses?: {
|
@@ -142,8 +142,8 @@ export declare const BookingSchema: z.ZodObject<{
|
|
142
142
|
};
|
143
143
|
user: {
|
144
144
|
email: string;
|
145
|
-
name: string;
|
146
145
|
timeZone: string;
|
146
|
+
name: string;
|
147
147
|
locale?: string | null | undefined;
|
148
148
|
};
|
149
149
|
eventTypeId: number;
|
@@ -151,8 +151,8 @@ export declare const BookingSchema: z.ZodObject<{
|
|
151
151
|
uid: string;
|
152
152
|
attendees: {
|
153
153
|
email: string;
|
154
|
-
name: string;
|
155
154
|
timeZone: string;
|
155
|
+
name: string;
|
156
156
|
locale?: string | null | undefined;
|
157
157
|
}[];
|
158
158
|
responses?: {
|
@@ -181,13 +181,13 @@ export declare const GetBookingResponseSchema: z.ZodObject<{
|
|
181
181
|
locale: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
182
182
|
}, "strip", z.ZodTypeAny, {
|
183
183
|
email: string;
|
184
|
-
name: string;
|
185
184
|
timeZone: string;
|
185
|
+
name: string;
|
186
186
|
locale?: string | null | undefined;
|
187
187
|
}, {
|
188
188
|
email: string;
|
189
|
-
name: string;
|
190
189
|
timeZone: string;
|
190
|
+
name: string;
|
191
191
|
locale?: string | null | undefined;
|
192
192
|
}>;
|
193
193
|
attendees: z.ZodArray<z.ZodObject<{
|
@@ -197,13 +197,13 @@ export declare const GetBookingResponseSchema: z.ZodObject<{
|
|
197
197
|
locale: z.ZodNullable<z.ZodOptional<z.ZodString>>;
|
198
198
|
}, "strip", z.ZodTypeAny, {
|
199
199
|
email: string;
|
200
|
-
name: string;
|
201
200
|
timeZone: string;
|
201
|
+
name: string;
|
202
202
|
locale?: string | null | undefined;
|
203
203
|
}, {
|
204
204
|
email: string;
|
205
|
-
name: string;
|
206
205
|
timeZone: string;
|
206
|
+
name: string;
|
207
207
|
locale?: string | null | undefined;
|
208
208
|
}>, "many">;
|
209
209
|
metadata: z.ZodObject<{
|
@@ -252,8 +252,8 @@ export declare const GetBookingResponseSchema: z.ZodObject<{
|
|
252
252
|
};
|
253
253
|
user: {
|
254
254
|
email: string;
|
255
|
-
name: string;
|
256
255
|
timeZone: string;
|
256
|
+
name: string;
|
257
257
|
locale?: string | null | undefined;
|
258
258
|
};
|
259
259
|
eventTypeId: number;
|
@@ -261,8 +261,8 @@ export declare const GetBookingResponseSchema: z.ZodObject<{
|
|
261
261
|
uid: string;
|
262
262
|
attendees: {
|
263
263
|
email: string;
|
264
|
-
name: string;
|
265
264
|
timeZone: string;
|
265
|
+
name: string;
|
266
266
|
locale?: string | null | undefined;
|
267
267
|
}[];
|
268
268
|
responses?: {
|
@@ -284,8 +284,8 @@ export declare const GetBookingResponseSchema: z.ZodObject<{
|
|
284
284
|
};
|
285
285
|
user: {
|
286
286
|
email: string;
|
287
|
-
name: string;
|
288
287
|
timeZone: string;
|
288
|
+
name: string;
|
289
289
|
locale?: string | null | undefined;
|
290
290
|
};
|
291
291
|
eventTypeId: number;
|
@@ -293,8 +293,8 @@ export declare const GetBookingResponseSchema: z.ZodObject<{
|
|
293
293
|
uid: string;
|
294
294
|
attendees: {
|
295
295
|
email: string;
|
296
|
-
name: string;
|
297
296
|
timeZone: string;
|
297
|
+
name: string;
|
298
298
|
locale?: string | null | undefined;
|
299
299
|
}[];
|
300
300
|
responses?: {
|
@@ -318,8 +318,8 @@ export declare const GetBookingResponseSchema: z.ZodObject<{
|
|
318
318
|
};
|
319
319
|
user: {
|
320
320
|
email: string;
|
321
|
-
name: string;
|
322
321
|
timeZone: string;
|
322
|
+
name: string;
|
323
323
|
locale?: string | null | undefined;
|
324
324
|
};
|
325
325
|
eventTypeId: number;
|
@@ -327,8 +327,8 @@ export declare const GetBookingResponseSchema: z.ZodObject<{
|
|
327
327
|
uid: string;
|
328
328
|
attendees: {
|
329
329
|
email: string;
|
330
|
-
name: string;
|
331
330
|
timeZone: string;
|
331
|
+
name: string;
|
332
332
|
locale?: string | null | undefined;
|
333
333
|
}[];
|
334
334
|
responses?: {
|
@@ -352,8 +352,8 @@ export declare const GetBookingResponseSchema: z.ZodObject<{
|
|
352
352
|
};
|
353
353
|
user: {
|
354
354
|
email: string;
|
355
|
-
name: string;
|
356
355
|
timeZone: string;
|
356
|
+
name: string;
|
357
357
|
locale?: string | null | undefined;
|
358
358
|
};
|
359
359
|
eventTypeId: number;
|
@@ -361,8 +361,8 @@ export declare const GetBookingResponseSchema: z.ZodObject<{
|
|
361
361
|
uid: string;
|
362
362
|
attendees: {
|
363
363
|
email: string;
|
364
|
-
name: string;
|
365
364
|
timeZone: string;
|
365
|
+
name: string;
|
366
366
|
locale?: string | null | undefined;
|
367
367
|
}[];
|
368
368
|
responses?: {
|
@@ -152,7 +152,7 @@
|
|
152
152
|
"changelog": "# Salesforce changelog"
|
153
153
|
},
|
154
154
|
"shelly": {
|
155
|
-
"readme": "---\ntitle: Shelly\ndescription: Library of AI-powered actions\n---\n\n# Shelly\n\nShelly is a library of AI-powered actions for enhancing workflow automation and data processing. It
|
155
|
+
"readme": "---\ntitle: Shelly\ndescription: Library of AI-powered actions\n---\n\n# Shelly\n\nShelly is a library of AI-powered actions for enhancing workflow automation and data processing. It leverages advanced language models and specialized APIs to provide intelligent automation capabilities.\n\n## Actions\n\n### Categorize Message\nUses AI to classify messages into predefined categories.\n\n- Analyzes message content using LLM\n- Matches against provided categories\n- Provides explanation for the categorization\n\nFeatures:\n- Supports custom category lists\n- Handles multiple languages\n- Returns \"None\" if no category matches\n- Includes detailed explanation of the classification\n\n### Generate Message\nCreates personalized messages using AI.\n\n- Takes communication objective and context\n- Generates appropriate message content\n- Formats according to stakeholder needs\n\nFeatures:\n- Customizable tone and style\n- Multi-language support\n- Personalization based on recipient data\n- Context-aware message generation\n\n### Medication From Image\nExtracts structured medication information from images.\n\n- Processes uploaded medication images\n- Uses specialized API for text extraction\n- Returns structured medication data\n\nFeatures:\n- Extracts medication names, dosages, and instructions\n- Supports various image formats\n- Returns both structured data and text summary\n- Includes error handling for unclear images\n\n### Review Medication Extraction\nAllows stakeholders to review and validate extracted medication information.\n\n- Displays extracted medication data\n- Provides interface for validation\n- Captures reviewer feedback\n\nFeatures:\n- Side-by-side image and data comparison\n- Validation workflow\n- Support for corrections and annotations\n\n### Summarize Care Flow\nProvides an AI-generated summary of the entire care flow progress.\n\n- Collects all relevant care flow data\n- Analyzes activities and outcomes\n- Generates a comprehensive summary\n\nFeatures:\n- Customizable for different stakeholders (e.g., clinicians, patients)\n- Optional focus areas through additional instructions\n- Includes relevant context and disclaimers\n\n### Summarize Form\nUses AI to generate concise summaries of form responses.\n\n- Retrieves the latest form data from the current step\n- Processes form responses with an LLM\n- Generates a structured summary in the specified format\n\nFeatures:\n- Supports bullet-point or paragraph format\n- Customizable language selection\n- Optional additional instructions for focused summaries\n- Includes context-aware disclaimers\n\n### Summarize Forms in Step\nSimilar to summarizeForm but processes all forms within a step.\n\nFeatures:\n- Combines data from multiple forms\n- Maintains context between form responses\n- Same formatting options as single form summaries\n\n### Summarize Track Outcome\nGenerates comprehensive summaries of track activities and outcomes.\n\n- Analyzes track data and activities\n- Identifies key outcomes and decisions\n- Creates structured summary\n\nFeatures:\n- Customizable focus areas\n- Support for specific outcome analysis\n- Flexible formatting options\n- Context-aware summaries",
|
156
156
|
"changelog": "# Shelly changelog"
|
157
157
|
},
|
158
158
|
"stripe": {
|
@@ -107,6 +107,13 @@ declare const actions: {
|
|
107
107
|
type: import("@awell-health/extensions-core").FieldType.STRING;
|
108
108
|
required: false;
|
109
109
|
};
|
110
|
+
additionalInstructions: {
|
111
|
+
id: string;
|
112
|
+
label: string;
|
113
|
+
description: string;
|
114
|
+
type: import("@awell-health/extensions-core").FieldType.TEXT;
|
115
|
+
required: false;
|
116
|
+
};
|
110
117
|
}, Record<string, never>, "summary">;
|
111
118
|
summarizeFormsInStep: import("@awell-health/extensions-core").Action<{
|
112
119
|
summaryFormat: {
|
@@ -25,14 +25,24 @@ export declare const fields: {
|
|
25
25
|
type: FieldType.STRING;
|
26
26
|
required: false;
|
27
27
|
};
|
28
|
+
additionalInstructions: {
|
29
|
+
id: string;
|
30
|
+
label: string;
|
31
|
+
description: string;
|
32
|
+
type: FieldType.TEXT;
|
33
|
+
required: false;
|
34
|
+
};
|
28
35
|
};
|
29
36
|
export declare const FieldsValidationSchema: z.ZodObject<{
|
30
37
|
summaryFormat: z.ZodEffects<z.ZodDefault<z.ZodOptional<z.ZodEnum<[SummaryFormatEnum.BULLET_POINTS, SummaryFormatEnum.TEXT_PARAGRAPH]>>>, SummaryFormatEnum, SummaryFormatEnum | undefined>;
|
31
38
|
language: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
39
|
+
additionalInstructions: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
32
40
|
}, "strip", z.ZodTypeAny, {
|
33
41
|
language: string;
|
42
|
+
additionalInstructions: string;
|
34
43
|
summaryFormat: SummaryFormatEnum;
|
35
44
|
}, {
|
36
45
|
language?: string | undefined;
|
46
|
+
additionalInstructions?: string | undefined;
|
37
47
|
summaryFormat?: SummaryFormatEnum | undefined;
|
38
48
|
}>;
|
@@ -6,13 +6,11 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.FieldsValidationSchema = exports.fields = exports.SummaryFormatEnum = void 0;
|
7
7
|
const extensions_core_1 = require("@awell-health/extensions-core");
|
8
8
|
const zod_1 = __importDefault(require("zod"));
|
9
|
-
// Step 1: Define the enum
|
10
9
|
var SummaryFormatEnum;
|
11
10
|
(function (SummaryFormatEnum) {
|
12
11
|
SummaryFormatEnum["BULLET_POINTS"] = "Bullet-points";
|
13
12
|
SummaryFormatEnum["TEXT_PARAGRAPH"] = "Text paragraph";
|
14
13
|
})(SummaryFormatEnum || (exports.SummaryFormatEnum = SummaryFormatEnum = {}));
|
15
|
-
// Step 2: Define the fields object
|
16
14
|
exports.fields = {
|
17
15
|
summaryFormat: {
|
18
16
|
id: 'summaryFormat',
|
@@ -34,6 +32,13 @@ exports.fields = {
|
|
34
32
|
type: extensions_core_1.FieldType.STRING,
|
35
33
|
required: false,
|
36
34
|
},
|
35
|
+
additionalInstructions: {
|
36
|
+
id: 'additionalInstructions',
|
37
|
+
label: 'Additional Instructions',
|
38
|
+
description: '[Optional] Specify additional instructions for the AI to generate the form summary. You can include details about: specific questions to focus on, desired level of detail, information to emphasize or exclude, etc.',
|
39
|
+
type: extensions_core_1.FieldType.TEXT,
|
40
|
+
required: false,
|
41
|
+
},
|
37
42
|
};
|
38
43
|
// Step 3: Define the validation schema using zod
|
39
44
|
exports.FieldsValidationSchema = zod_1.default.object({
|
@@ -45,5 +50,6 @@ exports.FieldsValidationSchema = zod_1.default.object({
|
|
45
50
|
? value
|
46
51
|
: SummaryFormatEnum.BULLET_POINTS),
|
47
52
|
language: zod_1.default.string().optional().default('Default'),
|
53
|
+
additionalInstructions: zod_1.default.string().optional().default('No additional instructions'),
|
48
54
|
});
|
49
55
|
//# sourceMappingURL=fields.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"fields.js","sourceRoot":"","sources":["../../../../../../extensions/shelly/actions/summarizeForm/config/fields.ts"],"names":[],"mappings":";;;;;;AAAA,mEAAqE;AACrE,8CAAwC;AAExC,
|
1
|
+
{"version":3,"file":"fields.js","sourceRoot":"","sources":["../../../../../../extensions/shelly/actions/summarizeForm/config/fields.ts"],"names":[],"mappings":";;;;;;AAAA,mEAAqE;AACrE,8CAAwC;AAExC,IAAY,iBAGX;AAHD,WAAY,iBAAiB;IAC3B,oDAA+B,CAAA;IAC/B,sDAAiC,CAAA;AACnC,CAAC,EAHW,iBAAiB,iCAAjB,iBAAiB,QAG5B;AAEY,QAAA,MAAM,GAAG;IACpB,aAAa,EAAE;QACb,EAAE,EAAE,eAAe;QACnB,KAAK,EAAE,gBAAgB;QACvB,WAAW,EACT,+GAA+G;QACjH,IAAI,EAAE,2BAAS,CAAC,MAAM;QACtB,QAAQ,EAAE,KAAK;QACf,OAAO,EAAE;YACP,eAAe,EAAE,MAAM,CAAC,MAAM,CAAC,iBAAiB,CAAC,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC;gBACjE,KAAK,EAAE,MAAM;gBACb,KAAK,EAAE,MAAM;aACd,CAAC,CAAC;SACJ;KACF;IACD,QAAQ,EAAE;QACR,EAAE,EAAE,UAAU;QACd,KAAK,EAAE,UAAU;QACjB,WAAW,EACT,iFAAiF;QACnF,IAAI,EAAE,2BAAS,CAAC,MAAM;QACtB,QAAQ,EAAE,KAAK;KAChB;IACD,sBAAsB,EAAE;QACtB,EAAE,EAAE,wBAAwB;QAC5B,KAAK,EAAE,yBAAyB;QAChC,WAAW,EACT,uNAAuN;QACzN,IAAI,EAAE,2BAAS,CAAC,IAAI;QACpB,QAAQ,EAAE,KAAK;KAChB;CAC8B,CAAA;AAEjC,iDAAiD;AACpC,QAAA,sBAAsB,GAAG,aAAC,CAAC,MAAM,CAAC;IAC7C,aAAa,EAAE,aAAC;SACb,IAAI,CAAC,CAAC,iBAAiB,CAAC,aAAa,EAAE,iBAAiB,CAAC,cAAc,CAAC,CAAC;SACzE,QAAQ,EAAE;SACV,OAAO,CAAC,iBAAiB,CAAC,aAAa,CAAC;SACxC,SAAS,CAAC,CAAC,KAAK,EAAE,EAAE,CACnB,MAAM,CAAC,MAAM,CAAC,iBAAiB,CAAC,CAAC,QAAQ,CAAC,KAA0B,CAAC;QACnE,CAAC,CAAC,KAAK;QACP,CAAC,CAAC,iBAAiB,CAAC,aAAa,CACpC;IACH,QAAQ,EAAE,aAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,OAAO,CAAC,SAAS,CAAC;IAClD,sBAAsB,EAAE,aAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,OAAO,CAAC,4BAA4B,CAAC;CAClC,CAAC,CAAA"}
|
@@ -9,7 +9,6 @@ const config_1 = require("./config");
|
|
9
9
|
const getFormResponseText_1 = require("../../lib/getFormResponseText");
|
10
10
|
const awell_1 = require("../../../../src/lib/awell");
|
11
11
|
const utils_1 = require("../../../../src/utils");
|
12
|
-
const constants_2 = require("../../lib/constants");
|
13
12
|
/**
|
14
13
|
* Awell Action: Form Summarization
|
15
14
|
*
|
@@ -28,8 +27,9 @@ exports.summarizeForm = {
|
|
28
27
|
previewable: false,
|
29
28
|
dataPoints: config_1.dataPoints,
|
30
29
|
onEvent: async ({ payload, onComplete, onError, helpers }) => {
|
30
|
+
var _a, _b, _c, _d, _e, _f;
|
31
31
|
// 1. Validate input fields
|
32
|
-
const { summaryFormat, language } = config_1.FieldsValidationSchema.parse(payload.fields);
|
32
|
+
const { summaryFormat, language, additionalInstructions } = config_1.FieldsValidationSchema.parse(payload.fields);
|
33
33
|
// 2. Initialize OpenAI model with metadata
|
34
34
|
const { model, metadata, callbacks } = await (0, createOpenAIModel_1.createOpenAIModel)({
|
35
35
|
settings: {}, // we use built-in API key for OpenAI
|
@@ -38,9 +38,25 @@ exports.summarizeForm = {
|
|
38
38
|
modelType: constants_1.OPENAI_MODELS.GPT4o,
|
39
39
|
hideDataForTracing: true, // Hide input and output data when tracing
|
40
40
|
});
|
41
|
+
const awellSdk = await helpers.awellSdk();
|
42
|
+
// Get pathway details for the disclaimer
|
43
|
+
const pathwayDetails = await awellSdk.orchestration.query({
|
44
|
+
pathway: {
|
45
|
+
__args: {
|
46
|
+
id: payload.pathway.id,
|
47
|
+
},
|
48
|
+
code: true,
|
49
|
+
success: true,
|
50
|
+
pathway: {
|
51
|
+
id: true,
|
52
|
+
title: true,
|
53
|
+
pathway_definition_id: true,
|
54
|
+
},
|
55
|
+
},
|
56
|
+
});
|
41
57
|
// 3. Get form data
|
42
58
|
const { formDefinition, formResponse } = await (0, awell_1.getLatestFormInCurrentStep)({
|
43
|
-
awellSdk
|
59
|
+
awellSdk,
|
44
60
|
pathwayId: payload.pathway.id,
|
45
61
|
activityId: payload.activity.id,
|
46
62
|
});
|
@@ -54,7 +70,8 @@ exports.summarizeForm = {
|
|
54
70
|
formData,
|
55
71
|
summaryFormat,
|
56
72
|
language,
|
57
|
-
disclaimerMessage:
|
73
|
+
disclaimerMessage: `Important Notice: The content provided is an AI-generated summary of form responses in Care Flow "${(_c = (_b = (_a = pathwayDetails.pathway) === null || _a === void 0 ? void 0 : _a.pathway) === null || _b === void 0 ? void 0 : _b.title) !== null && _c !== void 0 ? _c : 'Unknown'}" (ID: ${(_f = (_e = (_d = pathwayDetails.pathway) === null || _d === void 0 ? void 0 : _d.pathway) === null || _e === void 0 ? void 0 : _e.pathway_definition_id) !== null && _f !== void 0 ? _f : 'Unknown'}).`,
|
74
|
+
additionalInstructions,
|
58
75
|
metadata,
|
59
76
|
callbacks,
|
60
77
|
});
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"summarizeForm.js","sourceRoot":"","sources":["../../../../../extensions/shelly/actions/summarizeForm/summarizeForm.ts"],"names":[],"mappings":";;;AAAA,mEAAqE;AACrE,yEAAqE;AACrE,wFAAoF;AACpF,wEAAwE;AACxE,qCAAqE;AACrE,uEAAmE;AACnE,qDAAsE;AACtE,iDAAsD;
|
1
|
+
{"version":3,"file":"summarizeForm.js","sourceRoot":"","sources":["../../../../../extensions/shelly/actions/summarizeForm/summarizeForm.ts"],"names":[],"mappings":";;;AAAA,mEAAqE;AACrE,yEAAqE;AACrE,wFAAoF;AACpF,wEAAwE;AACxE,qCAAqE;AACrE,uEAAmE;AACnE,qDAAsE;AACtE,iDAAsD;AAEtD;;;;;;;;GAQG;AACU,QAAA,aAAa,GAItB;IACF,GAAG,EAAE,eAAe;IACpB,QAAQ,EAAE,0BAAQ,CAAC,QAAQ;IAC3B,KAAK,EAAE,gBAAgB;IACvB,WAAW,EAAE,0DAA0D;IACvE,MAAM,EAAN,eAAM;IACN,WAAW,EAAE,KAAK;IAClB,UAAU,EAAV,mBAAU;IAEV,OAAO,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,OAAO,EAAE,EAAiB,EAAE;;QAC1E,2BAA2B;QAC3B,MAAM,EAAE,aAAa,EAAE,QAAQ,EAAE,sBAAsB,EAAE,GAAG,+BAAsB,CAAC,KAAK,CACtF,OAAO,CAAC,MAAM,CACf,CAAA;QAED,2CAA2C;QAC3C,MAAM,EAAE,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,GAAG,MAAM,IAAA,qCAAiB,EAAC;YAC7D,QAAQ,EAAE,EAAE,EAAE,qCAAqC;YACnD,OAAO;YACP,OAAO;YACP,SAAS,EAAE,yBAAa,CAAC,KAAK;YAC9B,kBAAkB,EAAE,IAAI,EAAE,0CAA0C;SACrE,CAAC,CAAA;QAEF,MAAM,QAAQ,GAAG,MAAM,OAAO,CAAC,QAAQ,EAAE,CAAA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
|
@@ -71,12 +71,12 @@ exports.getFormTitle = getFormTitle;
|
|
71
71
|
const getFormResponseText = (opts) => {
|
72
72
|
const formAnswers = [];
|
73
73
|
const omittedFormAnswers = [];
|
74
|
-
opts.
|
75
|
-
const
|
76
|
-
if (
|
74
|
+
opts.formDefinition.questions.forEach((questionDefinition) => {
|
75
|
+
const questionResponse = opts.formResponse.answers.find((a) => a.question_id === questionDefinition.id);
|
76
|
+
if (questionResponse === undefined) {
|
77
77
|
omittedFormAnswers.push({
|
78
|
-
questionId:
|
79
|
-
reason: 'No corresponding
|
78
|
+
questionId: questionDefinition.id,
|
79
|
+
reason: 'No corresponding answer found in the form response',
|
80
80
|
});
|
81
81
|
return;
|
82
82
|
}
|
@@ -87,7 +87,7 @@ const getFormResponseText = (opts) => {
|
|
87
87
|
catch (error) {
|
88
88
|
const errorMessage = error instanceof Error ? error.message : 'Unknown error';
|
89
89
|
omittedFormAnswers.push({
|
90
|
-
questionId:
|
90
|
+
questionId: questionDefinition.id,
|
91
91
|
reason: `Error processing answer: ${errorMessage}`,
|
92
92
|
});
|
93
93
|
}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"getFormResponseText.js","sourceRoot":"","sources":["../../../../../extensions/shelly/lib/getFormResponseText/getFormResponseText.ts"],"names":[],"mappings":";;;AAOA,MAAM,gBAAgB,GAAG,CAAC,MAAc,EAAU,EAAE;IAClD,IAAI,MAAM,KAAK,GAAG;QAAE,OAAO,YAAY,CAAA;IAEvC,IAAI,MAAM,KAAK,GAAG;QAAE,OAAO,aAAa,CAAA;IAExC,OAAO,iBAAiB,CAAA;AAC1B,CAAC,CAAA;AAED,MAAM,qBAAqB,GAAG,CAC5B,kBAA4B,EAC5B,gBAAwB,EAChB,EAAE;;IACV,MAAM,WAAW,GAAG,gBAAgB,CAAC,KAAK,CAAA;IAC1C,MAAM,aAAa,GAAG,MAAA,kBAAkB,CAAC,OAAO,mCAAI,EAAE,CAAA;IAEtD,MAAM,gBAAgB,GAAG,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QACtE,KAAK,YAAY;YACf,OAAO,gBAAgB,CAAC,WAAW,MAAM,CAAC,gBAAgB,CAAC,KAAK,CAAC,EAAE,CAAC,CAAA;QACtE,KAAK,WAAW;YACd,OAAO,gBAAgB,CAAC,WAAW,MAAM,CAAC,gBAAgB,CAAC,KAAK,CAAC,EAAE,CAAC,CAAA;QACtE;YACE,OAAO,gBAAgB,CAAC,WAAW,MAAM,CAAC,gBAAgB,CAAC,KAAK,CAAC,EAAE,CAAC,CAAA;IACxE,CAAC;AACH,CAAC,CAAA;AAOM,MAAM,YAAY,GAAG,CAAC,IAE5B,EAAU,EAAE;IACX,OAAO,IAAI,CAAC,cAAc,CAAC,KAAK,CAAA;AAClC,CAAC,CAAA;AAJY,QAAA,YAAY,gBAIxB;AAEM,MAAM,mBAAmB,GAAG,CAAC,IAGnC,EAGC,EAAE;IACF,MAAM,WAAW,GAAa,EAAE,CAAA;IAChC,MAAM,kBAAkB,GAAwB,EAAE,CAAA;IAElD,IAAI,CAAC,
|
1
|
+
{"version":3,"file":"getFormResponseText.js","sourceRoot":"","sources":["../../../../../extensions/shelly/lib/getFormResponseText/getFormResponseText.ts"],"names":[],"mappings":";;;AAOA,MAAM,gBAAgB,GAAG,CAAC,MAAc,EAAU,EAAE;IAClD,IAAI,MAAM,KAAK,GAAG;QAAE,OAAO,YAAY,CAAA;IAEvC,IAAI,MAAM,KAAK,GAAG;QAAE,OAAO,aAAa,CAAA;IAExC,OAAO,iBAAiB,CAAA;AAC1B,CAAC,CAAA;AAED,MAAM,qBAAqB,GAAG,CAC5B,kBAA4B,EAC5B,gBAAwB,EAChB,EAAE;;IACV,MAAM,WAAW,GAAG,gBAAgB,CAAC,KAAK,CAAA;IAC1C,MAAM,aAAa,GAAG,MAAA,kBAAkB,CAAC,OAAO,mCAAI,EAAE,CAAA;IAEtD,MAAM,gBAAgB,GAAG,aAAa,aAAb,aAAa,uBAAb,aAAa,CAClC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE;QACf,O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7B,kBAAkB,EAAE,iBAAiB;KACtC,CAAC;AACJ,CAAC,CAAC;AApCW,QAAA,uBAAuB,2BAoClC"}
|
@@ -1,3 +1,3 @@
|
|
1
1
|
import { ChatPromptTemplate } from '@langchain/core/prompts';
|
2
|
-
export declare const systemPromptBulletPoints: ChatPromptTemplate<import("@langchain/core/prompts").ParamsFromFString<"\n You are an assistant tasked with summarizing forms completed by patients. Each form contains a title, questions, answers, possibly answer labels and answer options. Your objective is to create a concise summary of the patient's responses, tailored for a team of clinicians involved in patient care. The summary must cover all patient questions and provide an easy-to-review overview.\n\n First, write the disclaimer message \"{disclaimerMessage}\" in specified language: {language}, following these rules:\n - If specified language is Default or not specified: translate all parts of {disclaimerMessage} into the language of the form. If you cannot determine language use English.\n - If specified language is other than Default (French, Spanish, bosnian, ...): translate all parts of {disclaimerMessage} into specified language: {language} It is critical that the entire disclaimer message is written in the same language as specified language: {language}.\n For example if the disclaimer message is \"Important Notice: The content provided is an AI-generated summary.\" and specified language is Spanish, the disclaimer message in Spanish would be \"Aviso Importante: El contenido proporcionado es un resumen generado por IA de las respuestas del formulario\".\n If the specified language is French than the same disclaimer message should be: \"Avis Important : Le contenu fourni est un résumé généré par IA des réponses du formulaire\"\n Then add two new lines after the disclaimer message.\n\n Then adhere strictly to these step-by-step instructions:\n 1. **Begin the summary with the form title if available.**\n - Use title as is without alteration. Format is as title. \n - Then add an empty line for separation. \n\n - *For example:*\n - **General Health Questionnaire**\n - *Empty Line*\n \n 2. **Identify all questions and their corresponding answers.**\n\n 3. **Structure the summary using bullet points in clear and correct Markdown format:**\n\n - Use the format: `• **Question** - Answer`\n - **Ensure the answer is informative:**\n - For multiple-choice questions where the raw answer may be a code (e.g., 0, 1) that lacks meaning on its own, use the associated **answer label** instead.\n - For other questions, use the raw answer if it is clear and informative.\n\n 4. **Enhance conciseness and readability:**\n\n - **Shorten lengthy questions and answers to their essential meaning for easier inspection, while preserving all essential context.**\n - *For example:*\n - **Before**: \"Can you describe the nature of your back pain?\"\n - **After**: \"Nature of back pain\"\n - **Before**: \"Please list any medications you are currently taking, including dosages and frequency.\"\n - **After**: \"Current medications (dosage and frequency)\"\n - **Before**: \"Have you experienced any side effects from your current treatment in the last 3 months?\"\n - **After**: \"Side effects from current treatment in the last 3 months\"\n - **Avoid omitting any key information** that might alter the meaning. It is critical to preserve all time frames (e.g., \"last week,\" \"yesterday\") and specific details (e.g., \"right leg,\" \"morning\").\n\n 5. **If there are multiple forms provided, add a new line and proceed with the next form.**\n\n **Important Notes:**\n\n - Absolutely refrain from making any suggestions, interpretations, or provide additional comments.\n\n **Style and Format Guidelines:**\n\n - Use **professional and informative language**, avoiding colloquialisms and overly technical terms.\n - Ensure the summary is **clear**, **concise**, and **easy to read**.\n\n **Language:**\n\n - It is critical to summarize in the language specified below. If Default or not specified, use the language of the form.\n\n **Specified Language:**\n\n {language}\n\n ---\n\n **Content to Summarize:**\n\n {input}\n">, any>;
|
3
|
-
export declare const systemPromptTextParagraph: ChatPromptTemplate<import("@langchain/core/prompts").ParamsFromFString<"\n You are an assistant tasked with summarizing forms completed by patients. Each form contains a title, questions, answers, answer labels, and possible answer options. Your objective is to create a concise summary of the patient's responses, tailored for a team of clinicians involved in patient care. The summary must provide an easy-to-review overview.\n\n First, write the disclaimer message \"{disclaimerMessage}\" in specified language: {language}, following these rules:\n - If specified language is Default or not specified: translate all parts of {disclaimerMessage} into the language of the form. If you cannot determine language use English.\n - If specified language is other than Default (French, Spanish, bosnian, ...): translate all parts of {disclaimerMessage} into specified language: {language} It is critical that the entire disclaimer message is written in the same language as specified language: {language}.\n For example if the disclaimer message is \"Important Notice: The content provided is an AI-generated summary.\" and specified language is Spanish, the disclaimer message in Spanish would be \"Aviso Importante: El contenido proporcionado es un resumen generado por IA de las respuestas del formulario\".\n If the specified language is French than the same disclaimer message should be: \"Avis Important : Le contenu fourni est un résumé généré par IA des réponses du formulaire\"\n Then add two new lines after the disclaimer message.\n \n Then adhere strictly to these step-by-step instructions:\n\n 1. **Begin the summary with the form title if available.**\n - Use title as is without alteration. Format is as title. \n - Then add an empty line for separation. \n\n - *For example:*\n - **General Health Questionnaire**\n - *Empty Line*\n\n 2. **Identify all questions and their corresponding answers.**\n\n 3. **Compose the summary as an informative, easy-to-read paragraph:**\n\n - Cover all important aspects of the patient's responses.\n - Ensure the summary is **concise** and **to the point** while preserving all essential information.\n - **Write everything in one paragraph**, maintaining a logical flow of information.\n - For multiple-choice questions where the raw answer may be a code (e.g., 0, 1) that lacks meaning on its own, use the associated **answer label** instead. \n\n\n **Important Notes:**\n\n - Do not make any conclusions, suggestions, interpretations, or provide additional comments. Only summarize the information provided in the form.\n\n **Style and Format Guidelines:**\n\n - Use **professional and informative language**, avoiding colloquialisms and overly technical terms.\n - Ensure the summary is **clear**, **concise**, and **easy to read**.\n\n **Language:**\n\n - It is critical to summarize in the language specified below. If Default or not specified, use the language of the form.\n\n **Specified Language:**\n\n {language}\n\n ---\n\n **Content to Summarize:**\n\n {input}\n">, any>;
|
2
|
+
export declare const systemPromptBulletPoints: ChatPromptTemplate<import("@langchain/core/prompts").ParamsFromFString<"\n You are an assistant tasked with summarizing forms completed by patients. Each form contains a title, questions, answers, possibly answer labels and answer options. Your objective is to create a concise summary of the patient's responses, tailored for a team of clinicians involved in patient care. The summary must cover all patient questions and provide an easy-to-review overview.\n\n First, write the disclaimer message \"{disclaimerMessage}\" in specified language: {language}, following these rules:\n - If specified language is Default or not specified: translate all parts of {disclaimerMessage} into the language of the form. If you cannot determine language use English.\n - If specified language is other than Default (French, Spanish, bosnian, ...): translate all parts of {disclaimerMessage} into specified language: {language} It is critical that the entire disclaimer message is written in the same language as specified language: {language}.\n For example if the disclaimer message is \"Important Notice: The content provided is an AI-generated summary.\" and specified language is Spanish, the disclaimer message in Spanish would be \"Aviso Importante: El contenido proporcionado es un resumen generado por IA de las respuestas del formulario\".\n If the specified language is French than the same disclaimer message should be: \"Avis Important : Le contenu fourni est un résumé généré par IA des réponses du formulaire\"\n Then add two new lines after the disclaimer message.\n\n Then adhere strictly to these step-by-step instructions:\n 1. **Begin the summary with the form title if available.**\n - Use title as is without alteration. Format is as title. \n - Then add an empty line for separation. \n\n - *For example:*\n - **General Health Questionnaire**\n - *Empty Line*\n \n 2. **Identify all questions and their corresponding answers.**\n\n 3. **Structure the summary using bullet points in clear and correct Markdown format:**\n\n - Use the format: `• **Question** - Answer`\n - **Ensure the answer is informative:**\n - For multiple-choice questions where the raw answer may be a code (e.g., 0, 1) that lacks meaning on its own, use the associated **answer label** instead.\n - For other questions, use the raw answer if it is clear and informative.\n\n 4. **Enhance conciseness and readability:**\n\n - **Shorten lengthy questions and answers to their essential meaning for easier inspection, while preserving all essential context.**\n - *For example:*\n - **Before**: \"Can you describe the nature of your back pain?\"\n - **After**: \"Nature of back pain\"\n - **Before**: \"Please list any medications you are currently taking, including dosages and frequency.\"\n - **After**: \"Current medications (dosage and frequency)\"\n - **Before**: \"Have you experienced any side effects from your current treatment in the last 3 months?\"\n - **After**: \"Side effects from current treatment in the last 3 months\"\n - **Avoid omitting any key information** that might alter the meaning. It is critical to preserve all time frames (e.g., \"last week,\" \"yesterday\") and specific details (e.g., \"right leg,\" \"morning\").\n\n 5. **If there are multiple forms provided, add a new line and proceed with the next form.**\n\n **Important Notes:**\n\n - Absolutely refrain from making any suggestions, interpretations, or provide additional comments.\n\n **Style and Format Guidelines:**\n\n - Use **professional and informative language**, avoiding colloquialisms and overly technical terms.\n - Ensure the summary is **clear**, **concise**, and **easy to read**.\n\n **Language:**\n\n - It is critical to summarize in the language specified below. If Default or not specified, use the language of the form.\n\n **Specified Language:**\n\n {language}\n\n **Additional Instructions:**\n {additionalInstructions}\n\n ---\n\n **Content to Summarize:**\n\n {input}\n">, any>;
|
3
|
+
export declare const systemPromptTextParagraph: ChatPromptTemplate<import("@langchain/core/prompts").ParamsFromFString<"\n You are an assistant tasked with summarizing forms completed by patients. Each form contains a title, questions, answers, answer labels, and possible answer options. Your objective is to create a concise summary of the patient's responses, tailored for a team of clinicians involved in patient care. The summary must provide an easy-to-review overview.\n\n First, write the disclaimer message \"{disclaimerMessage}\" in specified language: {language}, following these rules:\n - If specified language is Default or not specified: translate all parts of {disclaimerMessage} into the language of the form. If you cannot determine language use English.\n - If specified language is other than Default (French, Spanish, bosnian, ...): translate all parts of {disclaimerMessage} into specified language: {language} It is critical that the entire disclaimer message is written in the same language as specified language: {language}.\n For example if the disclaimer message is \"Important Notice: The content provided is an AI-generated summary.\" and specified language is Spanish, the disclaimer message in Spanish would be \"Aviso Importante: El contenido proporcionado es un resumen generado por IA de las respuestas del formulario\".\n If the specified language is French than the same disclaimer message should be: \"Avis Important : Le contenu fourni est un résumé généré par IA des réponses du formulaire\"\n Then add two new lines after the disclaimer message.\n \n Then adhere strictly to these step-by-step instructions:\n\n 1. **Begin the summary with the form title if available.**\n - Use title as is without alteration. Format is as title. \n - Then add an empty line for separation. \n\n - *For example:*\n - **General Health Questionnaire**\n - *Empty Line*\n\n 2. **Identify all questions and their corresponding answers.**\n\n 3. **Compose the summary as an informative, easy-to-read paragraph:**\n\n - Cover all important aspects of the patient's responses.\n - Ensure the summary is **concise** and **to the point** while preserving all essential information.\n - **Write everything in one paragraph**, maintaining a logical flow of information.\n - For multiple-choice questions where the raw answer may be a code (e.g., 0, 1) that lacks meaning on its own, use the associated **answer label** instead. \n\n\n **Important Notes:**\n\n - Do not make any conclusions, suggestions, interpretations, or provide additional comments. Only summarize the information provided in the form.\n\n **Style and Format Guidelines:**\n\n - Use **professional and informative language**, avoiding colloquialisms and overly technical terms.\n - Ensure the summary is **clear**, **concise**, and **easy to read**.\n\n **Language:**\n\n - It is critical to summarize in the language specified below. If Default or not specified, use the language of the form.\n\n **Specified Language:**\n\n {language}\n\n **Additional Instructions:**\n {additionalInstructions}\n\n ---\n\n **Content to Summarize:**\n\n {input}\n">, any>;
|
@@ -61,6 +61,9 @@ exports.systemPromptBulletPoints = prompts_1.ChatPromptTemplate.fromTemplate(`
|
|
61
61
|
|
62
62
|
{language}
|
63
63
|
|
64
|
+
**Additional Instructions:**
|
65
|
+
{additionalInstructions}
|
66
|
+
|
64
67
|
---
|
65
68
|
|
66
69
|
**Content to Summarize:**
|
@@ -114,6 +117,9 @@ exports.systemPromptTextParagraph = prompts_1.ChatPromptTemplate.fromTemplate(`
|
|
114
117
|
|
115
118
|
{language}
|
116
119
|
|
120
|
+
**Additional Instructions:**
|
121
|
+
{additionalInstructions}
|
122
|
+
|
117
123
|
---
|
118
124
|
|
119
125
|
**Content to Summarize:**
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"prompt.js","sourceRoot":"","sources":["../../../../../extensions/shelly/lib/summarizeFormWithLLM/prompt.ts"],"names":[],"mappings":";;;AAAA,qDAA4D;AAE/C,QAAA,wBAAwB,GAAG,4BAAkB,CAAC,YAAY,CAAC
|
1
|
+
{"version":3,"file":"prompt.js","sourceRoot":"","sources":["../../../../../extensions/shelly/lib/summarizeFormWithLLM/prompt.ts"],"names":[],"mappings":";;;AAAA,qDAA4D;AAE/C,QAAA,wBAAwB,GAAG,4BAAkB,CAAC,YAAY,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAmEvE,CAAC,CAAA;AAEW,QAAA,yBAAyB,GAAG,4BAAkB,CAAC,YAAY,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAuDxE,CAAC,CAAA"}
|
@@ -15,15 +15,17 @@ import type { BaseCallbackHandler } from "@langchain/core/callbacks/base";
|
|
15
15
|
* summaryFormat: "Bullet-points",
|
16
16
|
* language: "English",
|
17
17
|
* disclaimerMessage: "AI generated...",
|
18
|
+
* additionalInstructions: "Focus on medication details",
|
18
19
|
* metadata: { ... }
|
19
20
|
* })
|
20
21
|
*/
|
21
|
-
export declare const summarizeFormWithLLM: ({ model, formData, summaryFormat, language, disclaimerMessage, metadata, callbacks, }: {
|
22
|
+
export declare const summarizeFormWithLLM: ({ model, formData, summaryFormat, language, disclaimerMessage, additionalInstructions, metadata, callbacks, }: {
|
22
23
|
model: ChatOpenAI;
|
23
24
|
formData: string;
|
24
25
|
summaryFormat: string;
|
25
26
|
language: string;
|
26
27
|
disclaimerMessage: string;
|
28
|
+
additionalInstructions?: string;
|
27
29
|
metadata: AIActionMetadata;
|
28
30
|
callbacks?: BaseCallbackHandler[];
|
29
31
|
}) => Promise<string>;
|
@@ -16,10 +16,11 @@ const prompt_1 = require("./prompt");
|
|
16
16
|
* summaryFormat: "Bullet-points",
|
17
17
|
* language: "English",
|
18
18
|
* disclaimerMessage: "AI generated...",
|
19
|
+
* additionalInstructions: "Focus on medication details",
|
19
20
|
* metadata: { ... }
|
20
21
|
* })
|
21
22
|
*/
|
22
|
-
const summarizeFormWithLLM = async ({ model, formData, summaryFormat, language, disclaimerMessage, metadata, callbacks, }) => {
|
23
|
+
const summarizeFormWithLLM = async ({ model, formData, summaryFormat, language, disclaimerMessage, additionalInstructions, metadata, callbacks, }) => {
|
23
24
|
const systemPrompt = summaryFormat === 'Bullet-points' ? prompt_1.systemPromptBulletPoints :
|
24
25
|
summaryFormat === 'Text paragraph' ? prompt_1.systemPromptTextParagraph :
|
25
26
|
prompt_1.systemPromptBulletPoints; // Default to bullet points if unknown format
|
@@ -27,6 +28,7 @@ const summarizeFormWithLLM = async ({ model, formData, summaryFormat, language,
|
|
27
28
|
language,
|
28
29
|
input: formData,
|
29
30
|
disclaimerMessage,
|
31
|
+
additionalInstructions: additionalInstructions !== null && additionalInstructions !== void 0 ? additionalInstructions : 'No additional instructions',
|
30
32
|
});
|
31
33
|
try {
|
32
34
|
const result = await model.invoke(prompt, {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"summarizeFormWithLLM.js","sourceRoot":"","sources":["../../../../../extensions/shelly/lib/summarizeFormWithLLM/summarizeFormWithLLM.ts"],"names":[],"mappings":";;;AAAA,qCAA8E;AAK9E
|
1
|
+
{"version":3,"file":"summarizeFormWithLLM.js","sourceRoot":"","sources":["../../../../../extensions/shelly/lib/summarizeFormWithLLM/summarizeFormWithLLM.ts"],"names":[],"mappings":";;;AAAA,qCAA8E;AAK9E;;;;;;;;;;;;;;;;;GAiBG;AACI,MAAM,oBAAoB,GAAG,KAAK,EAAE,EACzC,KAAK,EACL,QAAQ,EACR,aAAa,EACb,QAAQ,EACR,iBAAiB,EACjB,sBAAsB,EACtB,QAAQ,EACR,SAAS,GAUV,EAAmB,EAAE;IACpB,MAAM,YAAY,GAAG,aAAa,KAAK,eAAe,CAAC,CAAC,CAAC,iCAAwB,CAAC,CAAC;QAC/D,aAAa,KAAK,gBAAgB,CAAC,CAAC,CAAC,kCAAyB,CAAC,CAAC;YAChE,iCAAwB,CAAA,CAAC,6CAA6C;IAE1F,MAAM,MAAM,GAAG,MAAM,YAAY,CAAC,MAAM,CAAC;QACvC,QAAQ;QACR,KAAK,EAAE,QAAQ;QACf,iBAAiB;QACjB,sBAAsB,EAAE,sBAAsB,aAAtB,sBAAsB,cAAtB,sBAAsB,GAAI,4BAA4B;KAC/E,CAAC,CAAA;IAEF,IAAI,CAAC;QACH,MAAM,MAAM,GAAG,MAAM,KAAK,CAAC,MAAM,CAC/B,MAAM,EACN;YACE,QAAQ;YACR,OAAO,EAAE,qBAAqB;YAC9B,SAAS;SACV,CACF,CAAA;QAED,OAAO,MAAM,CAAC,OAAiB,CAAA;IACjC,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,MAAM,IAAI,KAAK,CAAC,iCAAiC,CAAC,CAAA;IACpD,CAAC;AACH,CAAC,CAAA;AA5CY,QAAA,oBAAoB,wBA4ChC"}
|