tolara-scout-mcp 0.1.0 → 0.1.2

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 (3) hide show
  1. package/README.md +1 -1
  2. package/dist/index.js +232 -11
  3. package/package.json +2 -2
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Tolara Scout MCP
2
2
 
3
- Search every open US product manager job from Claude, Cursor or any
3
+ Search open US product manager jobs from Claude, Cursor or any
4
4
  [MCP](https://modelcontextprotocol.io) client. It reads
5
5
  [Tolara Scout](https://gabethegeek.github.io/tolara-atlas/)'s public data,
6
6
  refreshed every night from each company's own careers site: 3,000+ roles at
package/dist/index.js CHANGED
@@ -165,6 +165,211 @@ function payRankShort(rank) {
165
165
  return "Middle of the range";
166
166
  }
167
167
 
168
+ // ../server/ingestion/locationParser.ts
169
+ var US_STATE_NAMES = {
170
+ alabama: "AL",
171
+ alaska: "AK",
172
+ arizona: "AZ",
173
+ arkansas: "AR",
174
+ california: "CA",
175
+ colorado: "CO",
176
+ connecticut: "CT",
177
+ delaware: "DE",
178
+ "district of columbia": "DC",
179
+ florida: "FL",
180
+ georgia: "GA",
181
+ hawaii: "HI",
182
+ idaho: "ID",
183
+ illinois: "IL",
184
+ indiana: "IN",
185
+ iowa: "IA",
186
+ kansas: "KS",
187
+ kentucky: "KY",
188
+ louisiana: "LA",
189
+ maine: "ME",
190
+ maryland: "MD",
191
+ massachusetts: "MA",
192
+ michigan: "MI",
193
+ minnesota: "MN",
194
+ mississippi: "MS",
195
+ missouri: "MO",
196
+ montana: "MT",
197
+ nebraska: "NE",
198
+ nevada: "NV",
199
+ "new hampshire": "NH",
200
+ "new jersey": "NJ",
201
+ "new mexico": "NM",
202
+ "new york": "NY",
203
+ "north carolina": "NC",
204
+ "north dakota": "ND",
205
+ ohio: "OH",
206
+ oklahoma: "OK",
207
+ oregon: "OR",
208
+ pennsylvania: "PA",
209
+ "rhode island": "RI",
210
+ "south carolina": "SC",
211
+ "south dakota": "SD",
212
+ tennessee: "TN",
213
+ texas: "TX",
214
+ utah: "UT",
215
+ vermont: "VT",
216
+ virginia: "VA",
217
+ washington: "WA",
218
+ "west virginia": "WV",
219
+ wisconsin: "WI",
220
+ wyoming: "WY"
221
+ };
222
+ var US_STATE_ABBREVS = new Set(Object.values(US_STATE_NAMES));
223
+ var NON_US_COUNTRIES = [
224
+ "france",
225
+ "spain",
226
+ "germany",
227
+ "italy",
228
+ "portugal",
229
+ "netherlands",
230
+ "belgium",
231
+ "switzerland",
232
+ "austria",
233
+ "poland",
234
+ "ireland",
235
+ "sweden",
236
+ "norway",
237
+ "denmark",
238
+ "finland",
239
+ "iceland",
240
+ "united kingdom",
241
+ "scotland",
242
+ "wales",
243
+ "northern ireland",
244
+ "india",
245
+ "singapore",
246
+ "japan",
247
+ "china",
248
+ "hong kong",
249
+ "taiwan",
250
+ "australia",
251
+ "new zealand",
252
+ "canada",
253
+ "mexico",
254
+ "brazil",
255
+ "argentina",
256
+ "chile",
257
+ "colombia",
258
+ "peru",
259
+ "uruguay",
260
+ "south africa",
261
+ "israel",
262
+ "united arab emirates",
263
+ "philippines",
264
+ "vietnam",
265
+ "indonesia",
266
+ "malaysia",
267
+ "thailand",
268
+ "south korea",
269
+ "pakistan",
270
+ "bangladesh",
271
+ "saudi arabia",
272
+ "qatar",
273
+ "romania",
274
+ "ukraine",
275
+ "czech republic",
276
+ "czechia",
277
+ "hungary",
278
+ "greece",
279
+ "turkey",
280
+ "egypt",
281
+ "nigeria",
282
+ "kenya",
283
+ "luxembourg",
284
+ "estonia",
285
+ "latvia",
286
+ "lithuania",
287
+ "croatia",
288
+ "serbia",
289
+ "bulgaria"
290
+ ];
291
+ var NON_US_REGIONS = ["emea", "apac", "latam", "uk & ireland", "uk&i", "nordics", "benelux"];
292
+ var NON_US_CITIES = [
293
+ "paris",
294
+ "barcelona",
295
+ "madrid",
296
+ "berlin",
297
+ "munich",
298
+ "hamburg",
299
+ "frankfurt",
300
+ "amsterdam",
301
+ "rotterdam",
302
+ "dublin",
303
+ "london",
304
+ "manchester",
305
+ "edinburgh",
306
+ "toronto",
307
+ "vancouver",
308
+ "montreal",
309
+ "ottawa",
310
+ "sydney",
311
+ "melbourne",
312
+ "brisbane",
313
+ "auckland",
314
+ "wellington",
315
+ "tokyo",
316
+ "osaka",
317
+ "bangalore",
318
+ "bengaluru",
319
+ "mumbai",
320
+ "delhi",
321
+ "hyderabad",
322
+ "pune",
323
+ "chennai",
324
+ "gurgaon",
325
+ "gurugram",
326
+ "tel aviv",
327
+ "warsaw",
328
+ "krakow",
329
+ "prague",
330
+ "lisbon",
331
+ "porto",
332
+ "milan",
333
+ "rome",
334
+ "turin",
335
+ "stockholm",
336
+ "copenhagen",
337
+ "oslo",
338
+ "helsinki",
339
+ "zurich",
340
+ "geneva",
341
+ "basel",
342
+ "vienna",
343
+ "brussels",
344
+ "sao paulo",
345
+ "s\xE3o paulo",
346
+ "mexico city",
347
+ "bogota",
348
+ "bogot\xE1",
349
+ "buenos aires",
350
+ "santiago",
351
+ "lima",
352
+ "cape town",
353
+ "johannesburg",
354
+ "nairobi",
355
+ "lagos",
356
+ "dubai",
357
+ "abu dhabi",
358
+ "seoul",
359
+ "shanghai",
360
+ "beijing",
361
+ "shenzhen",
362
+ "kuala lumpur",
363
+ "jakarta",
364
+ "manila",
365
+ "bangkok",
366
+ "ho chi minh"
367
+ ];
368
+ var NON_US_PATTERN = new RegExp(
369
+ `\\b(?:${[...NON_US_COUNTRIES, ...NON_US_REGIONS, ...NON_US_CITIES].join("|")})\\b`,
370
+ "i"
371
+ );
372
+
168
373
  // ../src/landingStats.ts
169
374
  var METRO_CITIES = {
170
375
  bay: {
@@ -312,6 +517,23 @@ function index(data) {
312
517
  indexFor = { data, rows, byId, payRank: buildPayRanker(data.pins, data.remoteCompanies) };
313
518
  return indexFor;
314
519
  }
520
+ var STATE_CODES = new Set(Object.values(US_STATE_NAMES));
521
+ var escapeRe = (s) => s.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
522
+ function placeMatcher(location) {
523
+ const where = (location ?? "").trim().toLowerCase().replace(/\s+/g, " ");
524
+ if (!where) return null;
525
+ const code = where.length === 2 && STATE_CODES.has(where.toUpperCase()) ? where.toUpperCase() : US_STATE_NAMES[where];
526
+ const words = new RegExp(`(^|[^a-z0-9])${escapeRe(where)}($|[^a-z0-9])`);
527
+ return (city, state) => {
528
+ if (code && (state ?? "").toUpperCase() === code) return true;
529
+ if (code && where.length === 2) return false;
530
+ return words.test([city, state].filter(Boolean).join(", ").toLowerCase());
531
+ };
532
+ }
533
+ var splitPlace = (place) => {
534
+ const i = place.lastIndexOf(", ");
535
+ return i < 0 ? [place, null] : [place.slice(0, i), place.slice(i + 2)];
536
+ };
315
537
  function rolePageUrl(companySlug, roleId, title) {
316
538
  return `${SITE_URL}/companies/${companySlug}/${roleId}-${slugify(title) || "role"}/`;
317
539
  }
@@ -376,15 +598,14 @@ async function matchingRows(args, now) {
376
598
  const f = filtersFrom(args);
377
599
  const categoryOf = data.companyCategories ?? {};
378
600
  const words = (args.query ?? "").toLowerCase().split(/\s+/).filter(Boolean);
379
- const where = (args.location ?? "").toLowerCase().trim();
601
+ const remoteOnly = (args.location ?? "").trim().toLowerCase() === "remote";
602
+ const place = remoteOnly ? null : placeMatcher(args.location);
380
603
  const hits = rows.filter((r) => {
381
604
  if (company && r.companySlug !== company.slug) return false;
382
605
  if (f.industry && (categoryOf[r.companySlug] ?? "other") !== f.industry) return false;
383
606
  if (!roleMatches(r.role, f, now)) return false;
384
- if (where) {
385
- const inCity = r.cities.some((c) => c.toLowerCase().includes(where));
386
- if (!inCity && !(where === "remote" && r.remote)) return false;
387
- }
607
+ if (remoteOnly && !r.remote) return false;
608
+ if (place && !r.cities.some((c) => place(...splitPlace(c)))) return false;
388
609
  return words.every((w) => r.searchText.includes(w));
389
610
  });
390
611
  return { data, payRank, hits, note: company && company.name.toLowerCase() !== args.company.trim().toLowerCase() ? `Showing ${company.name}.` : void 0 };
@@ -467,11 +688,11 @@ async function whatsNew(args, now = Date.now()) {
467
688
  const limit = Math.min(Math.max(args.limit ?? 30, 1), 50);
468
689
  const company = args.company ? await resolveCompanySlug(data, args.company) : null;
469
690
  const words = (args.query ?? "").toLowerCase().split(/\s+/).filter(Boolean);
470
- const where = (args.location ?? "").toLowerCase().trim();
691
+ const place = (args.location ?? "").trim().toLowerCase() === "remote" ? null : placeMatcher(args.location);
471
692
  const closed = data.changes.closedRoles.filter((r) => {
472
693
  if (Date.parse(r.closedAt) < since) return false;
473
694
  if (company && r.companySlug !== company.slug) return false;
474
- if (where && where !== "remote" && ![r.city, r.state].filter(Boolean).join(", ").toLowerCase().includes(where)) return false;
695
+ if (place && !place(r.city, r.state)) return false;
475
696
  const text = `${r.title} ${r.companyName} ${r.city ?? ""} ${r.state ?? ""}`.toLowerCase();
476
697
  return words.every((w) => text.includes(w));
477
698
  });
@@ -516,15 +737,15 @@ async function overview(now = Date.now()) {
516
737
 
517
738
  // src/index.ts
518
739
  var server = new McpServer(
519
- { name: "tolara-scout", version: "0.1.0" },
740
+ { name: "tolara-scout", version: "0.1.2" },
520
741
  {
521
- instructions: "Tolara Scout tracks every open product manager role in the US, read daily from each company's own careers site. Use search_roles to find roles, get_role for one role's details, get_company for a company's roles and hiring trend, and whats_new for roles that opened or closed recently (good for a daily digest). Salaries are only what the posting states, never estimates. A 'possible ghost job' has been open 90+ days, or reposted and still open after 45. Always give the user the apply_url or tolara_url for roles you mention."
742
+ instructions: "Tolara Scout tracks open product manager roles at about 900 US companies, read daily from each company's own careers site. It covers the companies it follows, not every PM job in the US, so say 'roles Tolara tracks' rather than 'all PM jobs'. Use search_roles to find roles, get_role for one role's details, get_company for a company's roles and hiring trend, and whats_new for roles that opened or closed recently (good for a daily digest). Salaries are only what the posting states, never estimates. A 'possible ghost job' has been open 90+ days, or reposted and still open after 45. Always give the user the apply_url or tolara_url for roles you mention."
522
743
  }
523
744
  );
524
745
  var filterShape = {
525
746
  query: z.string().optional().describe('Words that must all appear in the title, company or city, e.g. "growth", "AI platform"'),
526
747
  company: z.string().optional().describe('A company name, e.g. "Stripe" or "Capital One"'),
527
- location: z.string().optional().describe('A city or state as written in "Austin, TX", e.g. "New York" or "CA"; "remote" matches remote roles'),
748
+ location: z.string().optional().describe('A city ("New York", "Austin, TX") or a state code or name ("VA", "Virginia"); "remote" matches remote roles'),
528
749
  levels: z.array(z.enum(SENIORITY_TIERS)).optional().describe("Seniority levels to include; leave out for all"),
529
750
  min_salary: z.number().int().positive().optional().describe("Yearly USD floor. Only roles that post a band can match, compared against the top of the band"),
530
751
  remote: z.enum(["any", "remote", "in-office"]).optional().describe("Remote roles only, in-office only, or any (default)"),
@@ -587,7 +808,7 @@ server.registerTool(
587
808
  "tolara_overview",
588
809
  {
589
810
  title: "Tolara Scout overview",
590
- description: "Totals for the whole PM job market Tolara tracks: roles by level, top cities, remote count, ghost jobs, and the industry ids search_roles accepts.",
811
+ description: "Totals for the PM roles Tolara tracks: roles by level, top cities, remote count, ghost jobs, and the industry ids search_roles accepts.",
591
812
  inputSchema: {},
592
813
  annotations: READ_ONLY
593
814
  },
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "tolara-scout-mcp",
3
- "version": "0.1.0",
4
- "description": "Search every open US product manager job from Claude, Cursor or any MCP client. Data from Tolara Scout, updated daily.",
3
+ "version": "0.1.2",
4
+ "description": "Search open US product manager jobs from Claude, Cursor or any MCP client. Data from Tolara Scout, updated daily.",
5
5
  "type": "module",
6
6
  "bin": {
7
7
  "tolara-scout-mcp": "dist/index.js"