@cyanheads/astronomy-mcp-server 0.4.3 → 0.5.1

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.
Files changed (55) hide show
  1. package/AGENTS.md +28 -15
  2. package/CLAUDE.md +28 -15
  3. package/Dockerfile +11 -4
  4. package/README.md +24 -11
  5. package/changelog/0.5.x/0.5.0.md +29 -0
  6. package/changelog/0.5.x/0.5.1.md +35 -0
  7. package/changelog/template.md +10 -3
  8. package/dist/index.js +2 -0
  9. package/dist/index.js.map +1 -1
  10. package/dist/mcp-server/prompts/definitions/stargazing-plan.prompt.d.ts +4 -2
  11. package/dist/mcp-server/prompts/definitions/stargazing-plan.prompt.d.ts.map +1 -1
  12. package/dist/mcp-server/prompts/definitions/stargazing-plan.prompt.js +8 -5
  13. package/dist/mcp-server/prompts/definitions/stargazing-plan.prompt.js.map +1 -1
  14. package/dist/mcp-server/tools/definitions/find-events.tool.d.ts +43 -9
  15. package/dist/mcp-server/tools/definitions/find-events.tool.d.ts.map +1 -1
  16. package/dist/mcp-server/tools/definitions/find-events.tool.js +134 -23
  17. package/dist/mcp-server/tools/definitions/find-events.tool.js.map +1 -1
  18. package/dist/mcp-server/tools/definitions/get-ephemeris.tool.d.ts +18 -0
  19. package/dist/mcp-server/tools/definitions/get-ephemeris.tool.d.ts.map +1 -1
  20. package/dist/mcp-server/tools/definitions/get-ephemeris.tool.js +27 -6
  21. package/dist/mcp-server/tools/definitions/get-ephemeris.tool.js.map +1 -1
  22. package/dist/mcp-server/tools/definitions/get-rise-set.tool.d.ts +20 -8
  23. package/dist/mcp-server/tools/definitions/get-rise-set.tool.d.ts.map +1 -1
  24. package/dist/mcp-server/tools/definitions/get-rise-set.tool.js +49 -12
  25. package/dist/mcp-server/tools/definitions/get-rise-set.tool.js.map +1 -1
  26. package/dist/mcp-server/tools/definitions/get-sky-position.tool.d.ts.map +1 -1
  27. package/dist/mcp-server/tools/definitions/get-sky-position.tool.js +3 -1
  28. package/dist/mcp-server/tools/definitions/get-sky-position.tool.js.map +1 -1
  29. package/dist/mcp-server/tools/definitions/list-visible.tool.js +1 -1
  30. package/dist/mcp-server/tools/definitions/list-visible.tool.js.map +1 -1
  31. package/dist/services/ephemeris/ephemeris-service.d.ts +32 -8
  32. package/dist/services/ephemeris/ephemeris-service.d.ts.map +1 -1
  33. package/dist/services/ephemeris/ephemeris-service.js +192 -35
  34. package/dist/services/ephemeris/ephemeris-service.js.map +1 -1
  35. package/dist/services/ephemeris/meteor-showers.d.ts +49 -0
  36. package/dist/services/ephemeris/meteor-showers.d.ts.map +1 -0
  37. package/dist/services/ephemeris/meteor-showers.js +122 -0
  38. package/dist/services/ephemeris/meteor-showers.js.map +1 -0
  39. package/dist/services/ephemeris/star-catalog.d.ts +6 -8
  40. package/dist/services/ephemeris/star-catalog.d.ts.map +1 -1
  41. package/dist/services/ephemeris/star-catalog.js +7 -4
  42. package/dist/services/ephemeris/star-catalog.js.map +1 -1
  43. package/dist/services/ephemeris/types.d.ts +46 -4
  44. package/dist/services/ephemeris/types.d.ts.map +1 -1
  45. package/dist/services/ephemeris/types.js +2 -1
  46. package/dist/services/ephemeris/types.js.map +1 -1
  47. package/dist/services/horizons/horizons-service.d.ts +8 -4
  48. package/dist/services/horizons/horizons-service.d.ts.map +1 -1
  49. package/dist/services/horizons/horizons-service.js +38 -7
  50. package/dist/services/horizons/horizons-service.js.map +1 -1
  51. package/dist/services/horizons/types.d.ts +14 -1
  52. package/dist/services/horizons/types.d.ts.map +1 -1
  53. package/package.json +11 -10
  54. package/server.json +3 -3
  55. package/skills/astronomy-guide/SKILL.md +62 -0
@@ -1,14 +1,16 @@
1
1
  /**
2
- * @fileoverview astronomy_find_events — consolidated forward search for nine event
2
+ * @fileoverview astronomy_find_events — consolidated forward search for ten event
3
3
  * classes under one `event` enum. Both eclipse classes take an optional observer:
4
4
  * solar eclipses are global without one and local with one, and lunar eclipses gain
5
- * the Moon's altitude at each contact. Every other class is geocentric; `body2` turns a
6
- * conjunction with the Sun into one of two bodies. Every search stops at the end of the
7
- * supported span, with a notice when that cuts a list short, and serves at most
8
- * `EVENTS_PER_CALL` events per call with a notice naming the `start` and `count` that
9
- * continue.
5
+ * the Moon's altitude at each contact. meteor_shower returns the maxima of the nine
6
+ * major showers in the bundled IMO table, and an observer adds the radiant's and the
7
+ * Sun's altitude at each. Every other class is geocentric; `body2` turns a conjunction
8
+ * with the Sun into one of two bodies. Every search stops at the end of the supported
9
+ * span, with a notice when that cuts a list short, and serves at most `EVENTS_PER_CALL`
10
+ * events per call with a notice naming the `start` and `count` that continue.
10
11
  * Validation gates fail fast when an event needs a body that was not supplied, when an
11
- * eclipse observer is half-specified, or when the body has no such event.
12
+ * observer is half-specified on a class that takes one, or when the body has no such
13
+ * event.
12
14
  * @module mcp-server/tools/definitions/find-events.tool
13
15
  */
14
16
  import { z } from '@cyanheads/mcp-ts-core';
@@ -20,6 +22,7 @@ export declare const FindEventsOutput: z.ZodObject<{
20
22
  equinox: "equinox";
21
23
  lunar_eclipse: "lunar_eclipse";
22
24
  max_elongation: "max_elongation";
25
+ meteor_shower: "meteor_shower";
23
26
  moon_quarter: "moon_quarter";
24
27
  opposition: "opposition";
25
28
  perigee_apogee: "perigee_apogee";
@@ -33,6 +36,7 @@ export declare const FindEventsOutput: z.ZodObject<{
33
36
  local_visible: z.ZodOptional<z.ZodBoolean>;
34
37
  contact_altitudes_degrees: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNullable<z.ZodNumber>>>;
35
38
  contacts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNullable<z.ZodString>>>;
39
+ contacts_local: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNullable<z.ZodString>>>;
36
40
  peak_latitude_degrees: z.ZodOptional<z.ZodNumber>;
37
41
  peak_longitude_degrees: z.ZodOptional<z.ZodNumber>;
38
42
  which: z.ZodOptional<z.ZodEnum<{
@@ -67,6 +71,16 @@ export declare const FindEventsOutput: z.ZodObject<{
67
71
  }>>;
68
72
  distance_km: z.ZodOptional<z.ZodNumber>;
69
73
  distance_au: z.ZodOptional<z.ZodNumber>;
74
+ shower: z.ZodOptional<z.ZodString>;
75
+ shower_code: z.ZodOptional<z.ZodString>;
76
+ zhr: z.ZodOptional<z.ZodNumber>;
77
+ radiant_ra_hours: z.ZodOptional<z.ZodNumber>;
78
+ radiant_dec_degrees: z.ZodOptional<z.ZodNumber>;
79
+ activity_start_date: z.ZodOptional<z.ZodString>;
80
+ activity_end_date: z.ZodOptional<z.ZodString>;
81
+ moon_illuminated_fraction: z.ZodOptional<z.ZodNumber>;
82
+ radiant_altitude_degrees: z.ZodOptional<z.ZodNumber>;
83
+ sun_altitude_degrees: z.ZodOptional<z.ZodNumber>;
70
84
  }, z.core.$strip>>;
71
85
  }, z.core.$strip>;
72
86
  export type FindEventsOutputType = z.infer<typeof FindEventsOutput>;
@@ -76,6 +90,7 @@ export declare const findEventsTool: import("@cyanheads/mcp-ts-core").ToolDefini
76
90
  equinox: "equinox";
77
91
  lunar_eclipse: "lunar_eclipse";
78
92
  max_elongation: "max_elongation";
93
+ meteor_shower: "meteor_shower";
79
94
  moon_quarter: "moon_quarter";
80
95
  opposition: "opposition";
81
96
  perigee_apogee: "perigee_apogee";
@@ -108,6 +123,7 @@ export declare const findEventsTool: import("@cyanheads/mcp-ts-core").ToolDefini
108
123
  uranus: "uranus";
109
124
  venus: "venus";
110
125
  }>>;
126
+ shower: z.ZodOptional<z.ZodString>;
111
127
  latitude: z.ZodOptional<z.ZodNumber>;
112
128
  longitude: z.ZodOptional<z.ZodNumber>;
113
129
  elevation: z.ZodDefault<z.ZodNumber>;
@@ -119,6 +135,7 @@ export declare const findEventsTool: import("@cyanheads/mcp-ts-core").ToolDefini
119
135
  equinox: "equinox";
120
136
  lunar_eclipse: "lunar_eclipse";
121
137
  max_elongation: "max_elongation";
138
+ meteor_shower: "meteor_shower";
122
139
  moon_quarter: "moon_quarter";
123
140
  opposition: "opposition";
124
141
  perigee_apogee: "perigee_apogee";
@@ -132,6 +149,7 @@ export declare const findEventsTool: import("@cyanheads/mcp-ts-core").ToolDefini
132
149
  local_visible: z.ZodOptional<z.ZodBoolean>;
133
150
  contact_altitudes_degrees: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNullable<z.ZodNumber>>>;
134
151
  contacts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNullable<z.ZodString>>>;
152
+ contacts_local: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNullable<z.ZodString>>>;
135
153
  peak_latitude_degrees: z.ZodOptional<z.ZodNumber>;
136
154
  peak_longitude_degrees: z.ZodOptional<z.ZodNumber>;
137
155
  which: z.ZodOptional<z.ZodEnum<{
@@ -166,12 +184,28 @@ export declare const findEventsTool: import("@cyanheads/mcp-ts-core").ToolDefini
166
184
  }>>;
167
185
  distance_km: z.ZodOptional<z.ZodNumber>;
168
186
  distance_au: z.ZodOptional<z.ZodNumber>;
187
+ shower: z.ZodOptional<z.ZodString>;
188
+ shower_code: z.ZodOptional<z.ZodString>;
189
+ zhr: z.ZodOptional<z.ZodNumber>;
190
+ radiant_ra_hours: z.ZodOptional<z.ZodNumber>;
191
+ radiant_dec_degrees: z.ZodOptional<z.ZodNumber>;
192
+ activity_start_date: z.ZodOptional<z.ZodString>;
193
+ activity_end_date: z.ZodOptional<z.ZodString>;
194
+ moon_illuminated_fraction: z.ZodOptional<z.ZodNumber>;
195
+ radiant_altitude_degrees: z.ZodOptional<z.ZodNumber>;
196
+ sun_altitude_degrees: z.ZodOptional<z.ZodNumber>;
169
197
  }, z.core.$strip>>;
170
198
  }, z.core.$strip>, readonly [{
171
199
  readonly reason: "incomplete_observer";
172
200
  readonly code: JsonRpcErrorCode.InvalidParams;
173
- readonly when: "A solar_eclipse or lunar_eclipse was requested with only one of latitude and longitude.";
174
- readonly recovery: "Supply latitude and longitude together for local eclipse circumstances, or omit both for global ones.";
201
+ readonly when: "A solar_eclipse, lunar_eclipse, or meteor_shower was requested with only one of latitude and longitude.";
202
+ readonly recovery: "Supply latitude and longitude together for local circumstances, or omit both to search without an observer.";
203
+ }, {
204
+ readonly reason: "shower_not_found";
205
+ readonly code: JsonRpcErrorCode.NotFound;
206
+ readonly when: "The `shower` value names none of the nine showers in the bundled table.";
207
+ readonly recovery: "Pick a shower from the table this error lists, by its IMO code or name (e.g. \"GEM\", \"Geminids\", \"eta Aquariids\"). A shower outside the table cannot be searched.";
208
+ readonly thrownBy: "service";
175
209
  }, {
176
210
  readonly reason: "body_required";
177
211
  readonly code: JsonRpcErrorCode.InvalidParams;
@@ -1 +1 @@
1
- {"version":3,"file":"find-events.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/find-events.tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AA2CjE,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA0H3B,CAAC;AAEH,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAEpE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAgSzB,CAAC"}
1
+ {"version":3,"file":"find-events.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/find-events.tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAkDjE,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA8L3B,CAAC;AAEH,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAEpE,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA0VzB,CAAC"}
@@ -1,14 +1,16 @@
1
1
  /**
2
- * @fileoverview astronomy_find_events — consolidated forward search for nine event
2
+ * @fileoverview astronomy_find_events — consolidated forward search for ten event
3
3
  * classes under one `event` enum. Both eclipse classes take an optional observer:
4
4
  * solar eclipses are global without one and local with one, and lunar eclipses gain
5
- * the Moon's altitude at each contact. Every other class is geocentric; `body2` turns a
6
- * conjunction with the Sun into one of two bodies. Every search stops at the end of the
7
- * supported span, with a notice when that cuts a list short, and serves at most
8
- * `EVENTS_PER_CALL` events per call with a notice naming the `start` and `count` that
9
- * continue.
5
+ * the Moon's altitude at each contact. meteor_shower returns the maxima of the nine
6
+ * major showers in the bundled IMO table, and an observer adds the radiant's and the
7
+ * Sun's altitude at each. Every other class is geocentric; `body2` turns a conjunction
8
+ * with the Sun into one of two bodies. Every search stops at the end of the supported
9
+ * span, with a notice when that cuts a list short, and serves at most `EVENTS_PER_CALL`
10
+ * events per call with a notice naming the `start` and `count` that continue.
10
11
  * Validation gates fail fast when an event needs a body that was not supplied, when an
11
- * eclipse observer is half-specified, or when the body has no such event.
12
+ * observer is half-specified on a class that takes one, or when the body has no such
13
+ * event.
12
14
  * @module mcp-server/tools/definitions/find-events.tool
13
15
  */
14
16
  import { tool, z } from '@cyanheads/mcp-ts-core';
@@ -41,14 +43,22 @@ const BODY_EVENTS = new Set([
41
43
  'max_elongation',
42
44
  'perigee_apogee',
43
45
  ]);
44
- /** The event classes whose records an observer changes, and that resume ten days on. */
46
+ /** The eclipse classes, which resume ten days on. */
45
47
  const ECLIPSE_EVENTS = new Set(['solar_eclipse', 'lunar_eclipse']);
48
+ /**
49
+ * The event classes whose records an observer changes, where a lone coordinate fails
50
+ * `incomplete_observer`. Kept apart from `ECLIPSE_EVENTS`: meteor showers resume an hour
51
+ * on, since the Geminids and Ursids peak eight days apart and a ten-day step skips one.
52
+ */
53
+ const OBSERVER_EVENTS = new Set([...ECLIPSE_EVENTS, 'meteor_shower']);
46
54
  export const FindEventsOutput = z.object({
47
55
  events: z
48
56
  .array(z
49
57
  .object({
50
58
  event: z.enum(EVENT_NAMES).describe('The event class this record belongs to.'),
51
- time_utc: z.string().describe('Time of the event (peak, for eclipses) in ISO 8601 UTC.'),
59
+ time_utc: z
60
+ .string()
61
+ .describe('Time of the event in ISO 8601 UTC: the peak for an eclipse, the maximum for a meteor shower.'),
52
62
  time_local: z
53
63
  .string()
54
64
  .optional()
@@ -74,6 +84,10 @@ export const FindEventsOutput = z.object({
74
84
  .record(z.string(), z.string().nullable())
75
85
  .optional()
76
86
  .describe('Eclipse contact times in ISO 8601 UTC keyed by phase (e.g. partial_begin_utc, peak_utc); a phase that does not occur is null. A global solar eclipse carries peak_utc only.'),
87
+ contacts_local: z
88
+ .record(z.string(), z.string().nullable())
89
+ .optional()
90
+ .describe("The contacts in observer-local time, keyed as in contacts with _local for _utc (e.g. partial_begin_local, peak_local) and null where contacts is null. Each carries whole seconds and the zone's offset at that contact's own instant, so contacts either side of a daylight-saving change carry different offsets. Present only when a timezone was supplied, exactly when time_local is."),
77
91
  peak_latitude_degrees: z
78
92
  .number()
79
93
  .optional()
@@ -126,20 +140,60 @@ export const FindEventsOutput = z.object({
126
140
  .number()
127
141
  .optional()
128
142
  .describe('Center-to-center distance at the apsis in astronomical units. Present for perigee_apogee.'),
143
+ shower: z
144
+ .string()
145
+ .optional()
146
+ .describe('The meteor shower\'s IMO name, e.g. "Geminids". Present for meteor_shower.'),
147
+ shower_code: z
148
+ .string()
149
+ .optional()
150
+ .describe('The meteor shower\'s IMO three-letter code, e.g. "GEM" — the form the `shower` input takes. Present for meteor_shower.'),
151
+ zhr: z
152
+ .number()
153
+ .optional()
154
+ .describe('Zenithal hourly rate at the maximum, as the calendar lists it: the meteors one observer would see in an hour under a dark, clear sky with the radiant overhead. An observed rate is usually lower. Present for meteor_shower.'),
155
+ radiant_ra_hours: z
156
+ .number()
157
+ .optional()
158
+ .describe('Right ascension of the radiant at the maximum in sidereal hours, J2000. Present for meteor_shower.'),
159
+ radiant_dec_degrees: z
160
+ .number()
161
+ .optional()
162
+ .describe('Declination of the radiant at the maximum in degrees, J2000. Present for meteor_shower.'),
163
+ activity_start_date: z
164
+ .string()
165
+ .optional()
166
+ .describe('UTC date (YYYY-MM-DD) the shower becomes active before this maximum; it can fall in the previous year, as for the Quadrantids. Present for meteor_shower.'),
167
+ activity_end_date: z
168
+ .string()
169
+ .optional()
170
+ .describe('UTC date (YYYY-MM-DD) the shower stops being active after this maximum. Present for meteor_shower.'),
171
+ moon_illuminated_fraction: z
172
+ .number()
173
+ .optional()
174
+ .describe("The Moon's illuminated fraction at the maximum, 0 to 1. Geocentric: it does not say whether the Moon is above the horizon, which astronomy_get_rise_set for the moon answers across the night. Present for meteor_shower."),
175
+ radiant_altitude_degrees: z
176
+ .number()
177
+ .optional()
178
+ .describe("Apparent altitude in degrees of the radiant, precessed to the date, above the observer's horizon at the maximum. Negative means below it. Present for meteor_shower when latitude/longitude are supplied."),
179
+ sun_altitude_degrees: z
180
+ .number()
181
+ .optional()
182
+ .describe("Apparent altitude in degrees of the Sun above the observer's horizon at the maximum; a maximum can fall in daylight. Present for meteor_shower when latitude/longitude are supplied."),
129
183
  })
130
184
  .describe('One event occurrence; which detail fields are present depends on the event class.'))
131
185
  .describe('The next occurrences of the requested event class, in chronological order.'),
132
186
  });
133
187
  export const findEventsTool = tool('astronomy_find_events', {
134
188
  title: 'astronomy-mcp-server: find sky events',
135
- description: "Search forward from a start time for the next occurrences of one sky-event class, selected by the `event` enum: solar_eclipse, lunar_eclipse, equinox, solstice, moon_quarter, opposition, conjunction, max_elongation, or perigee_apogee. Both eclipse classes take an optional observer (latitude and longitude together). solar_eclipse without one returns global eclipses — kind, peak time, obscuration, and for a total or annular eclipse the latitude/longitude where it is greatest; with one it returns only eclipses visible from that point, with local contact times, `local_visible`, and the Sun's altitude at each contact. lunar_eclipse returns geocentric contact times, the same instants everywhere on Earth; an observer adds `local_visible` and the Moon's altitude at each contact. Every other class is geocentric and ignores a location. The body-relative events (opposition, conjunction, max_elongation, perigee_apogee) require a `body`: opposition applies to the superior planets (mars through pluto), conjunction to any planet, max_elongation to mercury and venus, and perigee_apogee to the moon (perigee/apogee), earth, or a planet (perihelion/aphelion). conjunction with `body` alone is that planet's conjunction with the Sun. Add `body2` for a conjunction of two bodies — the Moon or a planet with another: the instant they share one ecliptic longitude seen from Earth's center, with their `separation_degrees` at that instant. That separation is not always their closest approach, since two planets can pass closer days or weeks away, and listings that time conjunctions by right ascension differ by hours, or by days for slow pairs. Returns the next `count` occurrences (default 1), up to 20 per call: a larger `count`, up to 200, returns the first 20 and a notice naming the exact `start` and `count` that continue the series. Searches stop at the end of 2100, the close of the supported span; when that leaves fewer than `count`, a notice says so. Start defaults to now; pass an IANA `timezone` for observer-local timestamps.",
189
+ description: "Search forward from a start time for the next occurrences of one sky-event class, selected by the `event` enum: solar_eclipse, lunar_eclipse, equinox, solstice, moon_quarter, opposition, conjunction, max_elongation, perigee_apogee, or meteor_shower. Both eclipse classes and meteor_shower take an optional observer (latitude and longitude together). solar_eclipse without one returns global eclipses — kind, peak time, obscuration, and for a total or annular eclipse the latitude/longitude where it is greatest; with one it returns only eclipses visible from that point, with local contact times, `local_visible`, and the Sun's altitude at each contact. lunar_eclipse returns geocentric contact times, the same instants everywhere on Earth; an observer adds `local_visible` and the Moon's altitude at each contact. meteor_shower returns the maxima of nine major annual showers from a table bundled from the IMO Meteor Shower Calendar — ZHR, J2000 radiant, activity dates, and the Moon's geocentric illuminated fraction at each; an observer adds the radiant's and the Sun's altitude at the maximum, which can fall in daylight. The maxima are the calendar's nominal ones, with no outburst predictions. `shower` narrows the search to one shower by IMO code or name. A shower counts when its maximum is at or after start, so one past its maximum but still active needs an earlier start. Every other class is geocentric and ignores a location. The body-relative events (opposition, conjunction, max_elongation, perigee_apogee) require a `body`: opposition applies to the superior planets (mars through pluto), conjunction to any planet, max_elongation to mercury and venus, and perigee_apogee to the moon (perigee/apogee), earth, or a planet (perihelion/aphelion). conjunction with `body` alone is that planet's conjunction with the Sun. Add `body2` for a conjunction of two bodies — the Moon or a planet with another: the instant they share one ecliptic longitude seen from Earth's center, with their `separation_degrees` at that instant. That separation is not always their closest approach, since two planets can pass closer days or weeks away, and listings that time conjunctions by right ascension differ by hours, or by days for slow pairs. Returns the next `count` occurrences (default 1), up to 20 per call: a larger `count`, up to 200, returns the first 20 and a notice naming the exact `start` and `count` that continue the series. Searches stop at the end of 2100, the close of the supported span; when that leaves fewer than `count`, a notice says so. Start defaults to now; pass an IANA `timezone` for observer-local timestamps, eclipse contacts included.",
136
190
  annotations: { readOnlyHint: true, openWorldHint: false, idempotentHint: true },
137
191
  input: z.object({
138
192
  event: z.enum(EVENT_NAMES).describe('Which class of event to search for.'),
139
193
  start: z
140
194
  .string()
141
195
  .optional()
142
- .describe('Search start as an ISO 8601 UTC string, e.g. "2024-01-01T00:00:00Z". Eclipses are included when their peak is at or after start; earlier contacts may still be returned. Defaults to now. A value with no zone designator is read as UTC, not the local zone of the server process.'),
196
+ .describe('Search start as an ISO 8601 UTC string, e.g. "2024-01-01T00:00:00Z". Eclipses and meteor showers are included when their peak is at or after start; earlier eclipse contacts and activity dates may still be returned. Defaults to now. A value with no zone designator is read as UTC, not the local zone of the server process.'),
143
197
  count: z
144
198
  .number()
145
199
  .int()
@@ -155,18 +209,22 @@ export const findEventsTool = tool('astronomy_find_events', {
155
209
  .enum(PAIR_BODY_NAMES)
156
210
  .optional()
157
211
  .describe('Second body for a conjunction of two bodies: the Moon or a planet, different from `body`. Accepted only with event "conjunction", where it replaces the conjunction of `body` with the Sun by the conjunction of `body` and `body2` in ecliptic longitude seen from Earth\'s center. For the Moon meeting the Sun, search moon_quarter for the new moon.'),
212
+ shower: z
213
+ .string()
214
+ .optional()
215
+ .describe('One meteor shower for event "meteor_shower", by IMO code or name, case-insensitive, with a Greek letter spelled out or written as a symbol: "GEM", "Geminids", "eta Aquariids", or "η-Aquariids". Omit it for all nine showers. Ignored by every other event.'),
158
216
  latitude: z
159
217
  .number()
160
218
  .min(-90)
161
219
  .max(90)
162
220
  .optional()
163
- .describe('Observer latitude in decimal degrees, supplied together with longitude. Optional for solar_eclipse and lunar_eclipse, where it adds local circumstances; omit both for a global solar search. Ignored by every other event.'),
221
+ .describe('Observer latitude in decimal degrees, supplied together with longitude. Optional for solar_eclipse, lunar_eclipse, and meteor_shower, where it adds local circumstances; omit both for a global solar search. Ignored by every other event.'),
164
222
  longitude: z
165
223
  .number()
166
224
  .min(-180)
167
225
  .max(180)
168
226
  .optional()
169
- .describe('Observer longitude in decimal degrees, supplied together with latitude. Optional for solar_eclipse and lunar_eclipse; ignored by every other event.'),
227
+ .describe('Observer longitude in decimal degrees, supplied together with latitude. Optional for solar_eclipse, lunar_eclipse, and meteor_shower; ignored by every other event.'),
170
228
  elevation: z
171
229
  .number()
172
230
  .default(0)
@@ -194,8 +252,16 @@ export const findEventsTool = tool('astronomy_find_events', {
194
252
  {
195
253
  reason: 'incomplete_observer',
196
254
  code: JsonRpcErrorCode.InvalidParams,
197
- when: 'A solar_eclipse or lunar_eclipse was requested with only one of latitude and longitude.',
198
- recovery: 'Supply latitude and longitude together for local eclipse circumstances, or omit both for global ones.',
255
+ when: 'A solar_eclipse, lunar_eclipse, or meteor_shower was requested with only one of latitude and longitude.',
256
+ recovery: 'Supply latitude and longitude together for local circumstances, or omit both to search without an observer.',
257
+ },
258
+ {
259
+ reason: 'shower_not_found',
260
+ code: JsonRpcErrorCode.NotFound,
261
+ when: 'The `shower` value names none of the nine showers in the bundled table.',
262
+ // Verbatim the hint EphemerisService throws with where the shower lookup misses.
263
+ recovery: 'Pick a shower from the table this error lists, by its IMO code or name (e.g. "GEM", "Geminids", "eta Aquariids"). A shower outside the table cannot be searched.',
264
+ thrownBy: 'service',
199
265
  },
200
266
  {
201
267
  reason: 'body_required',
@@ -252,11 +318,11 @@ export const findEventsTool = tool('astronomy_find_events', {
252
318
  const hasLongitude = typeof input.longitude === 'number';
253
319
  const hasObserver = hasLatitude && hasLongitude;
254
320
  /**
255
- * An eclipse with half an observer would silently answer a different question — the
256
- * global search — than the local one the caller reached for. Other classes ignore a
257
- * location entirely, so a lone coordinate there changes nothing and passes.
321
+ * A class an observer changes, given half an observer, would silently answer a different
322
+ * question — the search without one — than the local one the caller reached for. Other
323
+ * classes ignore a location entirely, so a lone coordinate there changes nothing and passes.
258
324
  */
259
- if (ECLIPSE_EVENTS.has(input.event) && hasLatitude !== hasLongitude) {
325
+ if (OBSERVER_EVENTS.has(input.event) && hasLatitude !== hasLongitude) {
260
326
  throw ctx.fail('incomplete_observer', `Observer ${hasLatitude ? 'latitude' : 'longitude'} was supplied without ${hasLatitude ? 'longitude' : 'latitude'}.`);
261
327
  }
262
328
  if (BODY_EVENTS.has(input.event) && !input.body) {
@@ -275,6 +341,7 @@ export const findEventsTool = tool('astronomy_find_events', {
275
341
  count: served,
276
342
  ...(input.body ? { body: input.body } : {}),
277
343
  ...(input.body2 ? { body2: input.body2 } : {}),
344
+ ...(input.shower?.trim() ? { shower: input.shower } : {}),
278
345
  ...(observer ? { observer } : {}),
279
346
  ...(timezone ? { timezone } : {}),
280
347
  });
@@ -321,6 +388,7 @@ export const findEventsTool = tool('astronomy_find_events', {
321
388
  ? { contact_altitudes_degrees: r.contactAltitudesDegrees }
322
389
  : {}),
323
390
  ...(r.contacts ? { contacts: r.contacts } : {}),
391
+ ...(r.contactsLocal ? { contacts_local: r.contactsLocal } : {}),
324
392
  ...(r.peakLatitudeDegrees !== undefined
325
393
  ? { peak_latitude_degrees: r.peakLatitudeDegrees }
326
394
  : {}),
@@ -338,6 +406,22 @@ export const findEventsTool = tool('astronomy_find_events', {
338
406
  ...(r.apsisKind ? { apsis_kind: r.apsisKind } : {}),
339
407
  ...(r.distanceKm !== undefined ? { distance_km: r.distanceKm } : {}),
340
408
  ...(r.distanceAu !== undefined ? { distance_au: r.distanceAu } : {}),
409
+ ...(r.shower ? { shower: r.shower } : {}),
410
+ ...(r.showerCode ? { shower_code: r.showerCode } : {}),
411
+ ...(r.zhr !== undefined ? { zhr: r.zhr } : {}),
412
+ ...(r.radiantRaHours !== undefined ? { radiant_ra_hours: r.radiantRaHours } : {}),
413
+ ...(r.radiantDecDegrees !== undefined ? { radiant_dec_degrees: r.radiantDecDegrees } : {}),
414
+ ...(r.activityStartDate ? { activity_start_date: r.activityStartDate } : {}),
415
+ ...(r.activityEndDate ? { activity_end_date: r.activityEndDate } : {}),
416
+ ...(r.moonIlluminatedFraction !== undefined
417
+ ? { moon_illuminated_fraction: r.moonIlluminatedFraction }
418
+ : {}),
419
+ ...(r.radiantAltitudeDegrees !== undefined
420
+ ? { radiant_altitude_degrees: r.radiantAltitudeDegrees }
421
+ : {}),
422
+ ...(r.sunAltitudeDegrees !== undefined
423
+ ? { sun_altitude_degrees: r.sunAltitudeDegrees }
424
+ : {}),
341
425
  })),
342
426
  };
343
427
  return out;
@@ -353,6 +437,10 @@ export const findEventsTool = tool('astronomy_find_events', {
353
437
  headline += ` (${e.quarter})`;
354
438
  if (e.body)
355
439
  headline += ` — ${e.body}${e.body2 ? ` and ${e.body2}` : ''}`;
440
+ if (e.shower)
441
+ headline += ` — ${e.shower}`;
442
+ if (e.shower_code)
443
+ headline += ` (${e.shower_code})`;
356
444
  lines.push(headline);
357
445
  lines.push(`time_utc: ${e.time_utc}${e.time_local ? ` | time_local: ${e.time_local}` : ''}`);
358
446
  if (e.kind)
@@ -377,15 +465,38 @@ export const findEventsTool = tool('astronomy_find_events', {
377
465
  lines.push(`**Distance:** ${num(e.distance_km, 0, ' km')}`);
378
466
  if (e.distance_au !== undefined)
379
467
  lines.push(`**Distance:** ${sig(e.distance_au, 6, ' AU')}`);
468
+ if (e.zhr !== undefined)
469
+ lines.push(`**ZHR:** ${e.zhr}`);
470
+ const radiant = [
471
+ e.radiant_ra_hours !== undefined ? `RA ${num(e.radiant_ra_hours, 2, 'h')}` : '',
472
+ e.radiant_dec_degrees !== undefined ? `Dec ${num(e.radiant_dec_degrees, 1, '°')}` : '',
473
+ ].filter(Boolean);
474
+ if (radiant.length > 0)
475
+ lines.push(`**Radiant (J2000):** ${radiant.join(', ')}`);
476
+ if (e.activity_start_date && e.activity_end_date)
477
+ lines.push(`**Activity:** ${e.activity_start_date} to ${e.activity_end_date}`);
478
+ if (e.moon_illuminated_fraction !== undefined)
479
+ lines.push(`**Moon illuminated:** ${pct(e.moon_illuminated_fraction, 1)}`);
480
+ if (e.radiant_altitude_degrees !== undefined)
481
+ lines.push(`**Radiant altitude:** ${num(e.radiant_altitude_degrees, 1, '°')}`);
482
+ if (e.sun_altitude_degrees !== undefined)
483
+ lines.push(`**Sun altitude:** ${num(e.sun_altitude_degrees, 1, '°')}`);
484
+ /**
485
+ * A phase the eclipse never reaches renders as `none`, the null both records carry.
486
+ * Each local time is paired with its UTC contact by phase name.
487
+ */
380
488
  if (e.contacts) {
381
- const parts = Object.entries(e.contacts)
382
- .filter(([, v]) => v !== null)
383
- .map(([k, v]) => `${k.replace(/_utc$/, '')} ${v}`);
489
+ const local = new Map(Object.entries(e.contacts_local ?? {}).map(([k, v]) => [k.replace(/_local$/, ''), v]));
490
+ const parts = Object.entries(e.contacts).map(([k, utc]) => {
491
+ const phase = k.replace(/_utc$/, '');
492
+ const at = local.get(phase);
493
+ return `${phase} ${utc ?? 'none'}${at ? ` (local ${at})` : ''}`;
494
+ });
384
495
  if (parts.length > 0)
385
496
  lines.push(`**Contacts:** ${parts.join(', ')}`);
386
497
  }
387
498
  if (e.contact_altitudes_degrees) {
388
- const parts = Object.entries(e.contact_altitudes_degrees).flatMap(([phase, altitude]) => altitude === null ? [] : [`${phase} ${num(altitude, 1, '°')}`]);
499
+ const parts = Object.entries(e.contact_altitudes_degrees).map(([phase, altitude]) => `${phase} ${altitude === null ? 'none' : num(altitude, 1, '°')}`);
389
500
  if (parts.length > 0)
390
501
  lines.push(`**Contact altitudes:** ${parts.join(', ')}`);
391
502
  }
@@ -1 +1 @@
1
- {"version":3,"file":"find-events.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/find-events.tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AACjE,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AAC5D,OAAO,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,MAAM,sCAAsC,CAAC;AACrE,OAAO,EAAE,mBAAmB,EAAE,cAAc,EAAE,MAAM,2CAA2C,CAAC;AAChG,OAAO,EACL,gBAAgB,EAChB,WAAW,EAEX,eAAe,GAChB,MAAM,+BAA+B,CAAC;AAEvC,2FAA2F;AAC3F,MAAM,eAAe,GAAG,EAAE,CAAC;AAE3B,4DAA4D;AAC5D,MAAM,oBAAoB,GAAG,GAAG,CAAC;AAEjC;;;;;GAKG;AACH,MAAM,gBAAgB,GAAG,SAAS,CAAC;AAEnC;;;;;GAKG;AACH,MAAM,wBAAwB,GAAG,EAAE,GAAG,UAAU,CAAC;AAEjD,MAAM,WAAW,GAAG,IAAI,GAAG,CAAY;IACrC,YAAY;IACZ,aAAa;IACb,gBAAgB;IAChB,gBAAgB;CACjB,CAAC,CAAC;AAEH,wFAAwF;A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
17
  magnitude: z.ZodNullable<z.ZodNumber>;
18
+ constellation: z.ZodObject<{
19
+ abbreviation: z.ZodString;
20
+ name: z.ZodString;
21
+ }, z.core.$strip>;
22
+ sun_elongation_degrees: z.ZodNullable<z.ZodNumber>;
23
+ visibility: z.ZodNullable<z.ZodEnum<{
24
+ evening: "evening";
25
+ morning: "morning";
26
+ }>>;
18
27
  altitude_degrees: z.ZodOptional<z.ZodNumber>;
19
28
  azimuth_degrees: z.ZodOptional<z.ZodNumber>;
20
29
  }, z.core.$strip>>;
@@ -37,6 +46,15 @@ export declare const getEphemerisTool: import("@cyanheads/mcp-ts-core").ToolDefi
37
46
  dec_degrees: z.ZodNumber;
38
47
  distance_au: z.ZodNumber;
39
48
  magnitude: z.ZodNullable<z.ZodNumber>;
49
+ constellation: z.ZodObject<{
50
+ abbreviation: z.ZodString;
51
+ name: z.ZodString;
52
+ }, z.core.$strip>;
53
+ sun_elongation_degrees: z.ZodNullable<z.ZodNumber>;
54
+ visibility: z.ZodNullable<z.ZodEnum<{
55
+ evening: "evening";
56
+ morning: "morning";
57
+ }>>;
40
58
  altitude_degrees: z.ZodOptional<z.ZodNumber>;
41
59
  azimuth_degrees: z.ZodOptional<z.ZodNumber>;
42
60
  }, z.core.$strip>>;
@@ -1 +1 @@
1
- {"version":3,"file":"get-ephemeris.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/get-ephemeris.tool.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAwIjE,eAAO,MAAM,eAAe;;;;;;;;;;;;iBAoC1B,CAAC;AAEH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AAElE,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA2a3B,CAAC"}
1
+ {"version":3,"file":"get-ephemeris.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/get-ephemeris.tool.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAyIjE,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;iBA6D1B,CAAC;AAEH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AAElE,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAqb3B,CAAC"}
@@ -7,6 +7,7 @@
7
7
  import { tool, z } from '@cyanheads/mcp-ts-core';
8
8
  import { JsonRpcErrorCode } from '@cyanheads/mcp-ts-core/errors';
9
9
  import { escapeMarkdownInline } from '@cyanheads/mcp-ts-core/utils';
10
+ import { SkyPositionOutput } from './get-sky-position.tool.js';
10
11
  import { num, sig } from '../format-numbers.js';
11
12
  import { parseIsoInstant } from '../../../services/ephemeris/iso-time.js';
12
13
  import { getHorizonsService } from '../../../services/horizons/horizons-service.js';
@@ -135,13 +136,26 @@ export const EphemerisOutput = z.object({
135
136
  .array(z
136
137
  .object({
137
138
  time_utc: z.string().describe('Step instant in ISO 8601 UTC.'),
138
- ra_hours: z.number().describe('Right ascension in sidereal hours [0,24).'),
139
- dec_degrees: z.number().describe('Declination in degrees [-90,90].'),
139
+ ra_hours: z
140
+ .number()
141
+ .describe('Right ascension in sidereal hours [0,24), astrometric ICRF (J2000) as JPL Horizons reports it — the frame of modern star charts, not the apparent of-date right ascension astronomy_get_sky_position returns. The two differ by precession, nutation, and aberration, a gap that grows with distance from the year 2000.'),
142
+ dec_degrees: z
143
+ .number()
144
+ .describe('Declination in degrees [-90,90], astrometric ICRF (J2000), the same frame as ra_hours.'),
140
145
  distance_au: z.number().describe('Observer-to-body distance in astronomical units.'),
141
146
  magnitude: z
142
147
  .number()
143
148
  .nullable()
144
149
  .describe('Apparent magnitude, or null when Horizons omits it for this body.'),
150
+ constellation: SkyPositionOutput.shape.constellation.describe("The constellation the body falls within at this step, found from the row's own ra_hours and dec_degrees."),
151
+ sun_elongation_degrees: z
152
+ .number()
153
+ .nullable()
154
+ .describe("Angular distance from the Sun in degrees [0,180], the Sun-observer-target (S-O-T) angle JPL Horizons reports, seen from the observer when latitude and longitude are supplied and from Earth's center otherwise. 0 for the Sun itself. Null when Horizons supplies no value for the row."),
155
+ visibility: z
156
+ .enum(['morning', 'evening'])
157
+ .nullable()
158
+ .describe("Whether the body sits in the morning or evening sky, from the /r code Horizons prints beside S-O-T: morning when the body leads the Sun (/L — it rises and sets before the Sun), evening when it trails (/T — it rises and sets after). Null when Horizons reports it aligned with the Sun's center (/?), as for the Sun itself, or prints no code. Horizons judges lead and trail by Earth's daily rotation, so for a body nearly opposite the Sun this can differ from the ecliptic-longitude rule astronomy_find_events uses for max_elongation."),
145
159
  altitude_degrees: z
146
160
  .number()
147
161
  .optional()
@@ -151,12 +165,12 @@ export const EphemerisOutput = z.object({
151
165
  .optional()
152
166
  .describe('Azimuth in degrees (0=N, 90=E, 180=S, 270=W). Present only when an observer was supplied.'),
153
167
  })
154
- .describe('One ephemeris step: position and, with an observer, alt/az.'))
168
+ .describe('One ephemeris step: position, constellation, angle from the Sun, and, with an observer, alt/az.'))
155
169
  .describe('Time-series of positions, one per step, in chronological order.'),
156
170
  });
157
171
  export const getEphemerisTool = tool('astronomy_get_ephemeris', {
158
172
  title: 'astronomy-mcp-server: get small-body ephemeris',
159
- description: 'Fetch a time-series ephemeris for a small body (asteroid or comet) or spacecraft from JPL Horizons — RA/Dec, distance, and apparent magnitude over a span, optionally with observer-relative altitude/azimuth. This covers objects the in-process major-body set cannot. The designation is passed to Horizons verbatim, so it must be in a form Horizons resolves to a single record: a numbered asteroid takes a trailing-semicolon record lookup (e.g. "433;" for Eros, "1;" for Ceres), and a periodic comet takes the DES + closest-apparition form (e.g. "DES=1P;CAP" for Halley). Spacecraft take their negative SPK-ID. Anything else goes through the Horizons name search: a bare name matching nothing (e.g. "433 Eros") or several records (e.g. "1P/Halley") is rejected, but one matching a single object succeeds even when that object is not the one meant — "Eros" resolves to Kerberos, a moon of Pluto — so compare `target_name`, the object Horizons resolved, with the one intended. A major-body name matching several bodies (e.g. "Mars") is rejected with the ID number of each body it matched — pass one, such as "499" for the planet. `start` and `stop` are ISO 8601 UTC dates in the Gregorian calendar, extended before 1582, in years 0100 through 9999; `stop` must not be before `start`, and a `stop` equal to `start` returns the single row at that instant. `step` is a count plus a unit of m, h, d, mo, or y, such as "1d", "1h", or "10m". Supplying observer latitude/longitude yields topocentric coordinates and adds alt/az — supply both or neither. This is a gated, network-backed extension (JPL Horizons is keyless but rate-limited and best-effort); large spans truncate inline at 200 rows, and the truncation notice names the exact `start` to resume from — one step past the last row returned, because Horizons includes the start instant in its output — so re-calling from there continues the series without repeating a sample. Splitting the range into smaller adjacent spans works too; keep the same step either way so no sample is lost.',
173
+ description: 'Fetch a time-series ephemeris for a small body (asteroid or comet) or spacecraft from JPL Horizons — RA/Dec, distance, apparent magnitude, the constellation, and the angle from the Sun with its morning or evening side over a span, optionally with observer-relative altitude/azimuth. RA/Dec are astrometric ICRF (J2000), the frame of modern star charts, so they differ from the apparent of-date values astronomy_get_sky_position returns by precession, nutation, and aberration — a gap that grows with distance from the year 2000. This covers objects the in-process major-body set cannot. The designation is passed to Horizons verbatim, so it must be in a form Horizons resolves to a single record: a numbered asteroid takes a trailing-semicolon record lookup (e.g. "433;" for Eros, "1;" for Ceres), and a periodic comet takes the DES + closest-apparition form (e.g. "DES=1P;CAP" for Halley). Spacecraft take their negative SPK-ID. Anything else goes through the Horizons name search: a bare name matching nothing (e.g. "433 Eros") or several records (e.g. "1P/Halley") is rejected, but one matching a single object succeeds even when that object is not the one meant — "Eros" resolves to Kerberos, a moon of Pluto — so compare `target_name`, the object Horizons resolved, with the one intended. A major-body name matching several bodies (e.g. "Mars") is rejected with the ID number of each body it matched — pass one, such as "499" for the planet. `start` and `stop` are ISO 8601 UTC dates in the Gregorian calendar, extended before 1582, in years 0100 through 9999; `stop` must not be before `start`, and a `stop` equal to `start` returns the single row at that instant. `step` is a count plus a unit of m, h, d, mo, or y, such as "1d", "1h", or "10m". Supplying observer latitude/longitude yields topocentric coordinates and adds alt/az — supply both or neither. This is a gated, network-backed extension (JPL Horizons is keyless but rate-limited and best-effort); large spans truncate inline at 200 rows, and the truncation notice names the exact `start` to resume from — one step past the last row returned, because Horizons includes the start instant in its output — so re-calling from there continues the series without repeating a sample. Splitting the range into smaller adjacent spans works too; keep the same step either way so no sample is lost.',
160
174
  annotations: { readOnlyHint: true, openWorldHint: true, idempotentHint: true },
161
175
  input: z.object({
162
176
  designation: z
@@ -478,6 +492,9 @@ export const getEphemerisTool = tool('astronomy_get_ephemeris', {
478
492
  dec_degrees: p.decDegrees,
479
493
  distance_au: p.distanceAu,
480
494
  magnitude: p.magnitude,
495
+ constellation: p.constellation,
496
+ sun_elongation_degrees: p.sunElongationDegrees,
497
+ visibility: p.visibility,
481
498
  ...(p.altitudeDegrees !== undefined ? { altitude_degrees: p.altitudeDegrees } : {}),
482
499
  ...(p.azimuthDegrees !== undefined ? { azimuth_degrees: p.azimuthDegrees } : {}),
483
500
  })),
@@ -489,12 +506,16 @@ export const getEphemerisTool = tool('astronomy_get_ephemeris', {
489
506
  const target = r.target_name
490
507
  ? ` (Horizons target: ${escapeMarkdownInline(r.target_name)})`
491
508
  : '';
492
- lines.push(`## ${escapeMarkdownInline(r.designation)}${target} — ${r.points.length} points`);
509
+ const count = r.points.length === 1 ? '1 point' : `${r.points.length} points`;
510
+ // The frame applies to every row, so the header states it once.
511
+ lines.push(`## ${escapeMarkdownInline(r.designation)}${target} — ${count} · RA/Dec astrometric ICRF (J2000)`);
493
512
  for (const p of r.points) {
494
513
  const altAz = p.altitude_degrees === undefined
495
514
  ? ''
496
515
  : `, alt ${num(p.altitude_degrees, 1, '°')}, az ${p.azimuth_degrees === undefined ? 'n/a' : num(p.azimuth_degrees, 1, '°')}`;
497
- lines.push(`- ${p.time_utc}: RA ${num(p.ra_hours, 4, ' h')}, Dec ${num(p.dec_degrees, 4, '°')}, ${sig(p.distance_au, 6, ' AU')}, mag ${p.magnitude === null ? 'n/a' : num(p.magnitude, 1)}${altAz}`);
516
+ const elongation = p.sun_elongation_degrees === null ? 'n/a' : num(p.sun_elongation_degrees, 1, '°');
517
+ const side = p.visibility === null ? '' : ` ${p.visibility}`;
518
+ lines.push(`- ${p.time_utc}: RA ${num(p.ra_hours, 4, ' h')}, Dec ${num(p.dec_degrees, 4, '°')}, ${sig(p.distance_au, 6, ' AU')}, mag ${p.magnitude === null ? 'n/a' : num(p.magnitude, 1)}, ${p.constellation.name} (${p.constellation.abbreviation}), elong ${elongation}${side}${altAz}`);
498
519
  }
499
520
  return [{ type: 'text', text: lines.join('\n') }];
500
521
  },