@shin1ohno/sage 0.2.4 → 0.3.0
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.
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Calendar Service
|
|
3
|
-
* macOS
|
|
3
|
+
* macOS EventKit integration via AppleScriptObjC
|
|
4
4
|
* Requirements: 6.1-6.9
|
|
5
5
|
*
|
|
6
|
-
* 現行実装: macOS
|
|
6
|
+
* 現行実装: macOS EventKit経由(AppleScriptObjCを使用)
|
|
7
|
+
* - EventKitは繰り返しイベントを個々の発生(occurrence)に自動展開
|
|
8
|
+
* - Calendar.appのネイティブAppleScriptでは不可能な機能を提供
|
|
7
9
|
* 将来対応予定: iOS/iPadOS ネイティブ統合(Claude Skills APIがデバイスAPIへのアクセスを提供した時点)
|
|
8
10
|
*/
|
|
9
11
|
/**
|
|
@@ -16,7 +18,7 @@ export interface CalendarPlatformInfo {
|
|
|
16
18
|
requiresPermission: boolean;
|
|
17
19
|
hasNativeAccess: boolean;
|
|
18
20
|
}
|
|
19
|
-
export type CalendarMethod = 'native' | '
|
|
21
|
+
export type CalendarMethod = 'native' | 'eventkit' | 'caldav' | 'ical_url' | 'manual_input' | 'outlook';
|
|
20
22
|
/**
|
|
21
23
|
* Calendar event
|
|
22
24
|
*/
|
|
@@ -94,18 +96,26 @@ export declare class CalendarService {
|
|
|
94
96
|
*/
|
|
95
97
|
private fetchNativeEvents;
|
|
96
98
|
/**
|
|
97
|
-
* Fetch events via
|
|
99
|
+
* Fetch events via EventKit (macOS)
|
|
100
|
+
* Uses AppleScriptObjC to access EventKit framework
|
|
98
101
|
* Requirement: 6.3
|
|
99
102
|
*/
|
|
100
|
-
private
|
|
103
|
+
private fetchEventKitEvents;
|
|
101
104
|
/**
|
|
102
|
-
*
|
|
105
|
+
* Parse ISO 8601 date string into components
|
|
103
106
|
*/
|
|
104
|
-
private
|
|
107
|
+
private parseDateComponents;
|
|
105
108
|
/**
|
|
106
|
-
*
|
|
109
|
+
* Build AppleScriptObjC script for fetching events using EventKit
|
|
110
|
+
* Note: Uses EventKit framework to properly handle recurring events
|
|
111
|
+
* EventKit expands recurring events into individual occurrences, unlike Calendar.app's native AppleScript
|
|
107
112
|
*/
|
|
108
|
-
|
|
113
|
+
private buildEventKitScript;
|
|
114
|
+
/**
|
|
115
|
+
* Parse EventKit result into events
|
|
116
|
+
* Format: title|start|end|id|isAllDay
|
|
117
|
+
*/
|
|
118
|
+
parseEventKitResult(output: string): CalendarEvent[];
|
|
109
119
|
/**
|
|
110
120
|
* Find available slots from events
|
|
111
121
|
* Requirement: 6.4, 6.7
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"calendar-service.d.ts","sourceRoot":"","sources":["../../src/integrations/calendar-service.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"calendar-service.d.ts","sourceRoot":"","sources":["../../src/integrations/calendar-service.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAiBH;;GAEG;AACH,MAAM,WAAW,oBAAoB;IACnC,QAAQ,EAAE,KAAK,GAAG,QAAQ,GAAG,OAAO,GAAG,KAAK,GAAG,SAAS,CAAC;IACzD,gBAAgB,EAAE,cAAc,EAAE,CAAC;IACnC,iBAAiB,EAAE,cAAc,CAAC;IAClC,kBAAkB,EAAE,OAAO,CAAC;IAC5B,eAAe,EAAE,OAAO,CAAC;CAC1B;AAED,MAAM,MAAM,cAAc,GAAG,QAAQ,GAAG,UAAU,GAAG,QAAQ,GAAG,UAAU,GAAG,cAAc,GAAG,SAAS,CAAC;AAExG;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,EAAE,MAAM,CAAC;IACZ,QAAQ,EAAE,OAAO,CAAC;IAClB,MAAM,EAAE,MAAM,CAAC;CAChB;AAED;;G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ACH,OAAO,CAAC,mBAAmB;IA8D3B;;;OAGG;IACH,mBAAmB,CAAC,MAAM,EAAE,MAAM,GAAG,aAAa,EAAE;IAyBpD;;;OAGG;IACH,4BAA4B,CAC1B,MAAM,EAAE,aAAa,EAAE,EACvB,YAAY,EAAE,MAAM,EACpB,YAAY,EAAE,YAAY,EAC1B,IAAI,EAAE,MAAM,GACX,aAAa,EAAE;IAuElB;;;OAGG;IACH,oBAAoB,CAClB,IAAI,EAAE,aAAa,EACnB,MAAM,EAAE,cAAc,GACrB,aAAa;IA0BhB;;;OAGG;IACH,yBAAyB,CAAC,SAAS,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM;CActE"}
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Calendar Service
|
|
3
|
-
* macOS
|
|
3
|
+
* macOS EventKit integration via AppleScriptObjC
|
|
4
4
|
* Requirements: 6.1-6.9
|
|
5
5
|
*
|
|
6
|
-
* 現行実装: macOS
|
|
6
|
+
* 現行実装: macOS EventKit経由(AppleScriptObjCを使用)
|
|
7
|
+
* - EventKitは繰り返しイベントを個々の発生(occurrence)に自動展開
|
|
8
|
+
* - Calendar.appのネイティブAppleScriptでは不可能な機能を提供
|
|
7
9
|
* 将来対応予定: iOS/iPadOS ネイティブ統合(Claude Skills APIがデバイスAPIへのアクセスを提供した時点)
|
|
8
10
|
*/
|
|
9
11
|
import { retryWithBackoff, isRetryableError } from '../utils/retry.js';
|
|
@@ -31,8 +33,8 @@ export class CalendarService {
|
|
|
31
33
|
if (typeof process !== 'undefined' && process.platform === 'darwin') {
|
|
32
34
|
return {
|
|
33
35
|
platform: 'macos',
|
|
34
|
-
availableMethods: ['
|
|
35
|
-
recommendedMethod: '
|
|
36
|
+
availableMethods: ['eventkit', 'caldav'],
|
|
37
|
+
recommendedMethod: 'eventkit',
|
|
36
38
|
requiresPermission: true,
|
|
37
39
|
hasNativeAccess: true,
|
|
38
40
|
};
|
|
@@ -91,8 +93,8 @@ export class CalendarService {
|
|
|
91
93
|
switch (platform.recommendedMethod) {
|
|
92
94
|
case 'native':
|
|
93
95
|
return this.fetchNativeEvents(startDate, endDate);
|
|
94
|
-
case '
|
|
95
|
-
return this.
|
|
96
|
+
case 'eventkit':
|
|
97
|
+
return this.fetchEventKitEvents(startDate, endDate);
|
|
96
98
|
case 'manual_input':
|
|
97
99
|
default:
|
|
98
100
|
return [];
|
|
@@ -111,58 +113,115 @@ export class CalendarService {
|
|
|
111
113
|
return [];
|
|
112
114
|
}
|
|
113
115
|
/**
|
|
114
|
-
* Fetch events via
|
|
116
|
+
* Fetch events via EventKit (macOS)
|
|
117
|
+
* Uses AppleScriptObjC to access EventKit framework
|
|
115
118
|
* Requirement: 6.3
|
|
116
119
|
*/
|
|
117
|
-
async
|
|
120
|
+
async fetchEventKitEvents(startDate, endDate) {
|
|
118
121
|
try {
|
|
119
|
-
// Lazy load run-applescript
|
|
122
|
+
// Lazy load run-applescript (used to execute AppleScriptObjC with EventKit)
|
|
120
123
|
if (!this.runAppleScript) {
|
|
121
124
|
const module = await import('run-applescript');
|
|
122
125
|
this.runAppleScript = module.runAppleScript;
|
|
123
126
|
}
|
|
124
|
-
const script = this.
|
|
125
|
-
// Use retry with exponential backoff for
|
|
127
|
+
const script = this.buildEventKitScript(startDate, endDate);
|
|
128
|
+
// Use retry with exponential backoff for EventKit execution
|
|
126
129
|
const result = await retryWithBackoff(async () => {
|
|
127
130
|
return await this.runAppleScript(script);
|
|
128
131
|
}, {
|
|
129
132
|
...RETRY_OPTIONS,
|
|
130
133
|
onRetry: (error, attempt) => {
|
|
131
|
-
console.error(`
|
|
134
|
+
console.error(`EventKit Calendar retry attempt ${attempt}: ${error.message}`);
|
|
132
135
|
},
|
|
133
136
|
});
|
|
134
|
-
return this.
|
|
137
|
+
return this.parseEventKitResult(result);
|
|
135
138
|
}
|
|
136
139
|
catch (error) {
|
|
137
|
-
console.error('
|
|
140
|
+
console.error('EventKit カレンダーエラー:', error);
|
|
138
141
|
return [];
|
|
139
142
|
}
|
|
140
143
|
}
|
|
141
144
|
/**
|
|
142
|
-
*
|
|
145
|
+
* Parse ISO 8601 date string into components
|
|
143
146
|
*/
|
|
144
|
-
|
|
147
|
+
parseDateComponents(dateStr) {
|
|
148
|
+
const date = new Date(dateStr);
|
|
149
|
+
return {
|
|
150
|
+
year: date.getFullYear(),
|
|
151
|
+
month: date.getMonth() + 1,
|
|
152
|
+
day: date.getDate(),
|
|
153
|
+
};
|
|
154
|
+
}
|
|
155
|
+
/**
|
|
156
|
+
* Build AppleScriptObjC script for fetching events using EventKit
|
|
157
|
+
* Note: Uses EventKit framework to properly handle recurring events
|
|
158
|
+
* EventKit expands recurring events into individual occurrences, unlike Calendar.app's native AppleScript
|
|
159
|
+
*/
|
|
160
|
+
buildEventKitScript(startDate, endDate) {
|
|
161
|
+
const start = this.parseDateComponents(startDate);
|
|
162
|
+
const end = this.parseDateComponents(endDate);
|
|
145
163
|
return `
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
164
|
+
use AppleScript version "2.7"
|
|
165
|
+
use framework "Foundation"
|
|
166
|
+
use framework "EventKit"
|
|
167
|
+
use scripting additions
|
|
168
|
+
|
|
169
|
+
-- Build start date
|
|
170
|
+
set startDate to current date
|
|
171
|
+
set year of startDate to ${start.year}
|
|
172
|
+
set month of startDate to ${start.month}
|
|
173
|
+
set day of startDate to ${start.day}
|
|
174
|
+
set hours of startDate to 0
|
|
175
|
+
set minutes of startDate to 0
|
|
176
|
+
set seconds of startDate to 0
|
|
177
|
+
|
|
178
|
+
-- Build end date (end of day)
|
|
179
|
+
set endDate to current date
|
|
180
|
+
set year of endDate to ${end.year}
|
|
181
|
+
set month of endDate to ${end.month}
|
|
182
|
+
set day of endDate to ${end.day}
|
|
183
|
+
set hours of endDate to 23
|
|
184
|
+
set minutes of endDate to 59
|
|
185
|
+
set seconds of endDate to 59
|
|
186
|
+
|
|
187
|
+
-- Create EventKit store
|
|
188
|
+
set theStore to current application's EKEventStore's alloc()'s init()
|
|
189
|
+
|
|
190
|
+
-- Request calendar access (synchronously wait for completion)
|
|
191
|
+
set accessGranted to false
|
|
192
|
+
theStore's requestFullAccessToEventsWithCompletion:(missing value)
|
|
193
|
+
delay 0.5
|
|
194
|
+
|
|
195
|
+
-- Convert AppleScript dates to NSDate
|
|
196
|
+
set startNSDate to current application's NSDate's dateWithTimeIntervalSince1970:((startDate - (date "Thursday, January 1, 1970 at 9:00:00")) / 1)
|
|
197
|
+
set endNSDate to current application's NSDate's dateWithTimeIntervalSince1970:((endDate - (date "Thursday, January 1, 1970 at 9:00:00")) / 1)
|
|
198
|
+
|
|
199
|
+
-- Create predicate for events in date range (all calendars)
|
|
200
|
+
set thePredicate to theStore's predicateForEventsWithStartDate:startNSDate endDate:endNSDate calendars:(missing value)
|
|
201
|
+
|
|
202
|
+
-- Fetch events (EventKit automatically expands recurring events into occurrences)
|
|
203
|
+
set theEvents to theStore's eventsMatchingPredicate:thePredicate
|
|
204
|
+
|
|
205
|
+
-- Build result string
|
|
206
|
+
set eventList to ""
|
|
207
|
+
repeat with anEvent in theEvents
|
|
208
|
+
set eventTitle to (anEvent's title()) as text
|
|
209
|
+
set eventStart to (anEvent's startDate()) as date
|
|
210
|
+
set eventEnd to (anEvent's endDate()) as date
|
|
211
|
+
set eventId to (anEvent's eventIdentifier()) as text
|
|
212
|
+
set isAllDay to (anEvent's isAllDay()) as boolean
|
|
150
213
|
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
set eventInfo to (summary of evt) & "|" & (start date of evt as string) & "|" & (end date of evt as string) & "|" & (uid of evt)
|
|
155
|
-
set eventList to eventList & eventInfo & linefeed
|
|
156
|
-
end repeat
|
|
157
|
-
end repeat
|
|
214
|
+
set eventInfo to eventTitle & "|" & (eventStart as string) & "|" & (eventEnd as string) & "|" & eventId & "|" & (isAllDay as string)
|
|
215
|
+
set eventList to eventList & eventInfo & linefeed
|
|
216
|
+
end repeat
|
|
158
217
|
|
|
159
|
-
|
|
160
|
-
end tell`;
|
|
218
|
+
return eventList`;
|
|
161
219
|
}
|
|
162
220
|
/**
|
|
163
|
-
* Parse
|
|
221
|
+
* Parse EventKit result into events
|
|
222
|
+
* Format: title|start|end|id|isAllDay
|
|
164
223
|
*/
|
|
165
|
-
|
|
224
|
+
parseEventKitResult(output) {
|
|
166
225
|
if (!output || output.trim() === '') {
|
|
167
226
|
return [];
|
|
168
227
|
}
|
|
@@ -176,8 +235,8 @@ end tell`;
|
|
|
176
235
|
title: parts[0],
|
|
177
236
|
start: parts[1],
|
|
178
237
|
end: parts[2],
|
|
179
|
-
isAllDay: false,
|
|
180
|
-
source: '
|
|
238
|
+
isAllDay: parts.length >= 5 ? parts[4].toLowerCase() === 'true' : false,
|
|
239
|
+
source: 'eventkit',
|
|
181
240
|
});
|
|
182
241
|
}
|
|
183
242
|
}
|
|
@@ -225,7 +284,7 @@ end tell`;
|
|
|
225
284
|
reason: `${Math.floor(gapMinutes)}分の空き時間`,
|
|
226
285
|
conflicts: [],
|
|
227
286
|
dayType: 'normal',
|
|
228
|
-
source: '
|
|
287
|
+
source: 'eventkit',
|
|
229
288
|
});
|
|
230
289
|
}
|
|
231
290
|
currentTime = event.end > currentTime ? event.end : currentTime;
|
|
@@ -241,7 +300,7 @@ end tell`;
|
|
|
241
300
|
reason: `${Math.floor(remainingMinutes)}分の空き時間`,
|
|
242
301
|
conflicts: [],
|
|
243
302
|
dayType: 'normal',
|
|
244
|
-
source: '
|
|
303
|
+
source: 'eventkit',
|
|
245
304
|
});
|
|
246
305
|
}
|
|
247
306
|
return slots;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"calendar-service.js","sourceRoot":"","sources":["../../src/integrations/calendar-service.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"calendar-service.js","sourceRoot":"","sources":["../../src/integrations/calendar-service.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,O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IAED;;;OAGG;IACH,yBAAyB,CAAC,SAAiB,EAAE,OAAe;QAC1D,OAAO;;MAEL,SAAS,MAAM,OAAO;;;;;;;;;iCASK,CAAC;IAChC,CAAC;CACF"}
|
package/manifest.json
CHANGED
|
@@ -1,26 +1,22 @@
|
|
|
1
1
|
{
|
|
2
2
|
"manifest_version": "0.2",
|
|
3
|
-
"
|
|
4
|
-
"
|
|
3
|
+
"name": "sage",
|
|
4
|
+
"display_name": "sage - AI Task Manager",
|
|
5
|
+
"version": "0.3.0",
|
|
5
6
|
"description": "AI Task Management Assistant for Claude. Analyze tasks, set priorities, manage reminders, and integrate with Apple Reminders, Notion, and Calendar.",
|
|
6
|
-
"version": "0.2.4",
|
|
7
7
|
"author": {
|
|
8
|
-
"name": "shin1ohno"
|
|
8
|
+
"name": "shin1ohno",
|
|
9
|
+
"url": "https://github.com/shin1ohno"
|
|
9
10
|
},
|
|
10
|
-
"website": "https://github.com/shin1ohno/sage",
|
|
11
11
|
"server": {
|
|
12
12
|
"type": "node",
|
|
13
|
-
"entry_point": "dist/index.js"
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
13
|
+
"entry_point": "dist/index.js",
|
|
14
|
+
"mcp_config": {
|
|
15
|
+
"command": "node",
|
|
16
|
+
"args": ["${__dirname}/dist/index.js"],
|
|
17
|
+
"env": {}
|
|
18
|
+
}
|
|
19
19
|
},
|
|
20
|
-
"permissions": [
|
|
21
|
-
"filesystem.read",
|
|
22
|
-
"filesystem.write"
|
|
23
|
-
],
|
|
24
20
|
"tools": [
|
|
25
21
|
{
|
|
26
22
|
"name": "check_setup_status",
|
|
@@ -66,9 +62,5 @@
|
|
|
66
62
|
"name": "update_task_status",
|
|
67
63
|
"description": "Update the status of a task and optionally sync across sources."
|
|
68
64
|
}
|
|
69
|
-
]
|
|
70
|
-
"update": {
|
|
71
|
-
"type": "github_release",
|
|
72
|
-
"repo": "shin1ohno/sage"
|
|
73
|
-
}
|
|
65
|
+
]
|
|
74
66
|
}
|