Spaces:
Configuration error
Configuration error
File size: 4,108 Bytes
5bd9932 36f2866 5bd9932 36f2866 5bd9932 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 |
export const SEARCH_NEARBY_TOOL = {
name: "search_nearby",
description: "搜尋附近的地點",
inputSchema: {
type: "object",
properties: {
center: {
type: "object",
properties: {
value: { type: "string", description: "地址、地標名稱或經緯度座標(經緯度座標格式: lat,lng)" },
isCoordinates: { type: "boolean", description: "是否為經緯度座標", default: false },
},
required: ["value"],
description: "搜尋中心點",
},
keyword: {
type: "string",
description: "搜尋關鍵字(例如:餐廳、咖啡廳)",
},
radius: {
type: "number",
description: "搜尋半徑(公尺)",
default: 1000,
},
openNow: {
type: "boolean",
description: "是否只顯示營業中的地點",
default: false,
},
minRating: {
type: "number",
description: "最低評分要求(0-5)",
minimum: 0,
maximum: 5,
},
},
required: ["center"],
},
};
export const GEOCODE_TOOL = {
name: "maps_geocode",
description: "將地址轉換為座標",
inputSchema: {
type: "object",
properties: {
address: {
type: "string",
description: "要轉換的地址或地標名稱",
},
},
required: ["address"],
},
};
export const REVERSE_GEOCODE_TOOL = {
name: "maps_reverse_geocode",
description: "將座標轉換為地址",
inputSchema: {
type: "object",
properties: {
latitude: {
type: "number",
description: "緯度",
},
longitude: {
type: "number",
description: "經度",
},
},
required: ["latitude", "longitude"],
},
};
export const DISTANCE_MATRIX_TOOL = {
name: "maps_distance_matrix",
description: "計算多個起點和終點之間的距離和時間",
inputSchema: {
type: "object",
properties: {
origins: {
type: "array",
items: {
type: "string",
},
description: "起點地址或座標列表",
},
destinations: {
type: "array",
items: {
type: "string",
},
description: "終點地址或座標列表",
},
mode: {
type: "string",
enum: ["driving", "walking", "bicycling", "transit"],
description: "交通模式",
default: "driving",
},
},
required: ["origins", "destinations"],
},
};
export const DIRECTIONS_TOOL = {
name: "maps_directions",
description: "獲取兩點之間的路線指引",
inputSchema: {
type: "object",
properties: {
origin: {
type: "string",
description: "起點地址或座標",
},
destination: {
type: "string",
description: "終點地址或座標",
},
mode: {
type: "string",
enum: ["driving", "walking", "bicycling", "transit"],
description: "交通模式",
default: "driving",
},
},
required: ["origin", "destination"],
},
};
export const ELEVATION_TOOL = {
name: "maps_elevation",
description: "獲取位置的海拔數據",
inputSchema: {
type: "object",
properties: {
locations: {
type: "array",
items: {
type: "object",
properties: {
latitude: {
type: "number",
description: "緯度",
},
longitude: {
type: "number",
description: "經度",
},
},
required: ["latitude", "longitude"],
},
description: "要獲取海拔數據的位置列表",
},
},
required: ["locations"],
},
};
export const GET_PLACE_DETAILS_TOOL = {
name: "get_place_details",
description: "獲取特定地點的詳細資訊",
inputSchema: {
type: "object",
properties: {
placeId: {
type: "string",
description: "Google Maps 地點 ID",
},
},
required: ["placeId"],
},
};
|