@demind-inc/core 1.7.72 → 1.7.74
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/models/RichContext.d.ts +12 -10
- package/dist/types.d.ts +2 -16
- package/lib/models/RichContext.ts +19 -11
- package/lib/types.ts +2 -17
- package/package.json +1 -1
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { MealType, MealFoodAmount, MetricMealDetailMacros, MetricMealDetailMicros } from "./Metrics";
|
|
1
2
|
export type SignalSource = "location" | "weather" | "energy" | "sleep" | "screen_time" | "commute" | "menstrual_cycle" | "steps" | "medication" | (string & {});
|
|
2
3
|
export interface Location {
|
|
3
4
|
name: string;
|
|
@@ -84,6 +85,16 @@ export interface Action {
|
|
|
84
85
|
action_type: ActionType;
|
|
85
86
|
payload: ActionPayload;
|
|
86
87
|
}
|
|
88
|
+
export interface MealSuggestionPayload {
|
|
89
|
+
type: MealType;
|
|
90
|
+
title?: string;
|
|
91
|
+
description?: string;
|
|
92
|
+
food_items?: MealFoodAmount[];
|
|
93
|
+
macros?: MetricMealDetailMacros;
|
|
94
|
+
micros?: MetricMealDetailMicros;
|
|
95
|
+
start_time?: string;
|
|
96
|
+
end_time?: string;
|
|
97
|
+
}
|
|
87
98
|
export type ContentType = "workout_plan" | "checklist" | "find_location" | "meal_suggestion" | "transit_route" | "journal_prompts" | "audio_player" | "energy_summary" | "sleep_summary" | "metric_bar" | "meal_plan_week" | (string & {});
|
|
88
99
|
export type ContentPayload = {
|
|
89
100
|
plan_title: string;
|
|
@@ -100,16 +111,7 @@ export type ContentPayload = {
|
|
|
100
111
|
text: string;
|
|
101
112
|
done: boolean;
|
|
102
113
|
}[];
|
|
103
|
-
} | {
|
|
104
|
-
venue_name: string;
|
|
105
|
-
dish_name: string;
|
|
106
|
-
dish_tags: string[];
|
|
107
|
-
kcal: number | null;
|
|
108
|
-
image_url: string | null;
|
|
109
|
-
price: number | null;
|
|
110
|
-
rating: number | null;
|
|
111
|
-
menu_url: string | null;
|
|
112
|
-
} | {
|
|
114
|
+
} | MealSuggestionPayload | {
|
|
113
115
|
origin: string;
|
|
114
116
|
destination: string;
|
|
115
117
|
depart_by: string;
|
package/dist/types.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CalendarEvent,
|
|
1
|
+
import { CalendarEvent, CalendarRoutineFrom, CalendarTaskFrom, EMASatisfaction, EnergyFeedbackType, EventCategorySet, MealType, MetricActivity, MetricHRValueSet, MetricMealDetail, MetricMealSummary, MetricStressValueSet, PhaseStartEndSet, MealSuggestionPayload, RichContext, RoutineActivity, NapDetail, SleepDetail, TaskItem, TaskPriority, TodoAppFrom } from "./models";
|
|
2
2
|
export type SupportedTerraProvidersType = "FITBIT" | "OURA" | "GARMIN" | "WHOOP" | "ULTRAHUMAN" | "STRAVA" | "MYFITNESSPAL";
|
|
3
3
|
export type SupportedTerraSDKType = "APPLE" | "GOOGLE_FIT" | "SAMSUNG_HEALTH" | "FREESTYLE_LIBRE";
|
|
4
4
|
export type CircadianPhase = "default" | "wakeup_low" | "wakeup_normal" | "morning_high" | "morning_normal" | "morning_low" | "evening_high" | "evening_low" | "evening_normal";
|
|
@@ -42,8 +42,6 @@ export interface ScheduledAction {
|
|
|
42
42
|
priority?: TaskPriority;
|
|
43
43
|
actionType?: ScheduledActionType;
|
|
44
44
|
richContext?: RichContext | null;
|
|
45
|
-
recurrence?: CalendarEventRecurrence;
|
|
46
|
-
seriesId?: string;
|
|
47
45
|
}
|
|
48
46
|
export interface ScheduledActionOptions {
|
|
49
47
|
startDate: string;
|
|
@@ -154,24 +152,12 @@ export interface ChatAdjustmentChangeWrapper<T> {
|
|
|
154
152
|
before?: Partial<T>;
|
|
155
153
|
after?: Partial<T>;
|
|
156
154
|
}
|
|
157
|
-
export interface MealContentItem {
|
|
158
|
-
name: string;
|
|
159
|
-
portion?: string;
|
|
160
|
-
reason?: string;
|
|
161
|
-
}
|
|
162
|
-
export interface MealContent {
|
|
163
|
-
title: string;
|
|
164
|
-
rationale: string;
|
|
165
|
-
suggested_items: MealContentItem[];
|
|
166
|
-
macro_focus?: Record<string, number>;
|
|
167
|
-
micro_focus?: string[];
|
|
168
|
-
}
|
|
169
155
|
export interface ChatAdjustmentMeal {
|
|
170
156
|
mealType: MealType;
|
|
171
157
|
startTime: string;
|
|
172
158
|
endTime: string;
|
|
173
159
|
description?: string;
|
|
174
|
-
mealContent?:
|
|
160
|
+
mealContent?: MealSuggestionPayload;
|
|
175
161
|
}
|
|
176
162
|
export interface ChatAdjustmentSleep {
|
|
177
163
|
sleepTime: string;
|
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
import type {
|
|
2
|
+
MealType,
|
|
3
|
+
MealFoodAmount,
|
|
4
|
+
MetricMealDetailMacros,
|
|
5
|
+
MetricMealDetailMicros,
|
|
6
|
+
} from "./Metrics";
|
|
7
|
+
|
|
1
8
|
export type SignalSource =
|
|
2
9
|
| "location"
|
|
3
10
|
| "weather"
|
|
@@ -137,6 +144,17 @@ export interface Action {
|
|
|
137
144
|
payload: ActionPayload;
|
|
138
145
|
}
|
|
139
146
|
|
|
147
|
+
export interface MealSuggestionPayload {
|
|
148
|
+
type: MealType;
|
|
149
|
+
title?: string;
|
|
150
|
+
description?: string;
|
|
151
|
+
food_items?: MealFoodAmount[];
|
|
152
|
+
macros?: MetricMealDetailMacros;
|
|
153
|
+
micros?: MetricMealDetailMicros;
|
|
154
|
+
start_time?: string;
|
|
155
|
+
end_time?: string;
|
|
156
|
+
}
|
|
157
|
+
|
|
140
158
|
export type ContentType =
|
|
141
159
|
| "workout_plan"
|
|
142
160
|
| "checklist"
|
|
@@ -168,17 +186,7 @@ export type ContentPayload =
|
|
|
168
186
|
label: string | null;
|
|
169
187
|
items: { text: string; done: boolean }[];
|
|
170
188
|
}
|
|
171
|
-
|
|
|
172
|
-
// meal_suggestion
|
|
173
|
-
venue_name: string;
|
|
174
|
-
dish_name: string;
|
|
175
|
-
dish_tags: string[];
|
|
176
|
-
kcal: number | null;
|
|
177
|
-
image_url: string | null;
|
|
178
|
-
price: number | null;
|
|
179
|
-
rating: number | null;
|
|
180
|
-
menu_url: string | null;
|
|
181
|
-
}
|
|
189
|
+
| MealSuggestionPayload
|
|
182
190
|
| {
|
|
183
191
|
// transit_route
|
|
184
192
|
origin: string;
|
package/lib/types.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import {
|
|
2
2
|
CalendarEvent,
|
|
3
|
-
CalendarEventRecurrence,
|
|
4
3
|
CalendarRoutineFrom,
|
|
5
4
|
CalendarTaskFrom,
|
|
6
5
|
EMASatisfaction,
|
|
@@ -13,6 +12,7 @@ import {
|
|
|
13
12
|
MetricMealSummary,
|
|
14
13
|
MetricStressValueSet,
|
|
15
14
|
PhaseStartEndSet,
|
|
15
|
+
MealSuggestionPayload,
|
|
16
16
|
RichContext,
|
|
17
17
|
RoutineActivity,
|
|
18
18
|
NapDetail,
|
|
@@ -102,8 +102,6 @@ export interface ScheduledAction {
|
|
|
102
102
|
priority?: TaskPriority;
|
|
103
103
|
actionType?: ScheduledActionType;
|
|
104
104
|
richContext?: RichContext | null;
|
|
105
|
-
recurrence?: CalendarEventRecurrence;
|
|
106
|
-
seriesId?: string;
|
|
107
105
|
}
|
|
108
106
|
|
|
109
107
|
export interface ScheduledActionOptions {
|
|
@@ -264,26 +262,13 @@ export interface ChatAdjustmentChangeWrapper<T> {
|
|
|
264
262
|
after?: Partial<T>;
|
|
265
263
|
}
|
|
266
264
|
|
|
267
|
-
export interface MealContentItem {
|
|
268
|
-
name: string;
|
|
269
|
-
portion?: string;
|
|
270
|
-
reason?: string;
|
|
271
|
-
}
|
|
272
|
-
|
|
273
|
-
export interface MealContent {
|
|
274
|
-
title: string;
|
|
275
|
-
rationale: string;
|
|
276
|
-
suggested_items: MealContentItem[];
|
|
277
|
-
macro_focus?: Record<string, number>;
|
|
278
|
-
micro_focus?: string[];
|
|
279
|
-
}
|
|
280
265
|
|
|
281
266
|
export interface ChatAdjustmentMeal {
|
|
282
267
|
mealType: MealType;
|
|
283
268
|
startTime: string; // ISO string
|
|
284
269
|
endTime: string; // ISO string
|
|
285
270
|
description?: string;
|
|
286
|
-
mealContent?:
|
|
271
|
+
mealContent?: MealSuggestionPayload;
|
|
287
272
|
}
|
|
288
273
|
|
|
289
274
|
export interface ChatAdjustmentSleep {
|