50c 2.9.0 → 2.10.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.
@@ -62,6 +62,27 @@ async function roadmapDelete(id) {
62
62
  return apiRequest('POST', '/tools/roadmap_delete', { id });
63
63
  }
64
64
 
65
+ // Beacon Context Tools (PRO tier) - context management & compression
66
+ async function beaconScan(messages, query = null) {
67
+ return apiRequest('POST', '/tools/beacon_scan', { messages, query });
68
+ }
69
+
70
+ async function beaconCompress(messages, target_ratio = 0.5, preserve_recent = 2) {
71
+ return apiRequest('POST', '/tools/beacon_compress', { messages, target_ratio, preserve_recent });
72
+ }
73
+
74
+ async function beaconExtract(messages, extract_type = 'all') {
75
+ return apiRequest('POST', '/tools/beacon_extract', { messages, extract_type });
76
+ }
77
+
78
+ async function beaconFocus(messages, query) {
79
+ return apiRequest('POST', '/tools/beacon_focus', { messages, query });
80
+ }
81
+
82
+ async function beaconRank(messages) {
83
+ return apiRequest('POST', '/tools/beacon_rank', { messages });
84
+ }
85
+
65
86
  // Tool definitions - STARTER tier ($29/mo)
66
87
  const BEACON_TOOLS = [
67
88
  {
@@ -245,6 +266,77 @@ const BEACON_TOOLS = [
245
266
  },
246
267
  cost: 0,
247
268
  tier: 'free'
269
+ },
270
+ // Beacon Context Tools - PRO tier
271
+ {
272
+ name: 'beacon_scan',
273
+ description: 'Analyze context health - token zones, redundancy, info density. $0.01',
274
+ inputSchema: {
275
+ type: 'object',
276
+ properties: {
277
+ messages: { type: 'array', items: { type: 'string' }, description: 'Conversation messages to analyze' },
278
+ query: { type: 'string', description: 'Optional: focus query for relevance scoring' }
279
+ },
280
+ required: ['messages']
281
+ },
282
+ cost: 0.01,
283
+ tier: 'pro'
284
+ },
285
+ {
286
+ name: 'beacon_compress',
287
+ description: 'Compress conversation by removing low-value messages. $0.02',
288
+ inputSchema: {
289
+ type: 'object',
290
+ properties: {
291
+ messages: { type: 'array', items: { type: 'string' }, description: 'Messages to compress' },
292
+ target_ratio: { type: 'number', description: 'Target compression ratio (default 0.5)', default: 0.5 },
293
+ preserve_recent: { type: 'number', description: 'Recent messages to always keep (default 2)', default: 2 }
294
+ },
295
+ required: ['messages']
296
+ },
297
+ cost: 0.02,
298
+ tier: 'pro'
299
+ },
300
+ {
301
+ name: 'beacon_extract',
302
+ description: 'Extract key entities, decisions, questions from context. $0.02',
303
+ inputSchema: {
304
+ type: 'object',
305
+ properties: {
306
+ messages: { type: 'array', items: { type: 'string' }, description: 'Messages to extract from' },
307
+ extract_type: { type: 'string', enum: ['all', 'decisions', 'entities', 'questions', 'errors'], default: 'all' }
308
+ },
309
+ required: ['messages']
310
+ },
311
+ cost: 0.02,
312
+ tier: 'pro'
313
+ },
314
+ {
315
+ name: 'beacon_focus',
316
+ description: 'Filter messages by relevance to a query. $0.02',
317
+ inputSchema: {
318
+ type: 'object',
319
+ properties: {
320
+ messages: { type: 'array', items: { type: 'string' }, description: 'Messages to filter' },
321
+ query: { type: 'string', description: 'Query to focus on' }
322
+ },
323
+ required: ['messages', 'query']
324
+ },
325
+ cost: 0.02,
326
+ tier: 'pro'
327
+ },
328
+ {
329
+ name: 'beacon_rank',
330
+ description: 'Rank messages by information value. $0.01',
331
+ inputSchema: {
332
+ type: 'object',
333
+ properties: {
334
+ messages: { type: 'array', items: { type: 'string' }, description: 'Messages to rank' }
335
+ },
336
+ required: ['messages']
337
+ },
338
+ cost: 0.01,
339
+ tier: 'pro'
248
340
  }
249
341
  ];
250
342
 
@@ -280,6 +372,17 @@ async function handleTool(name, args) {
280
372
  return await roadmapUpdate(args.id, args);
281
373
  case 'roadmap_delete':
282
374
  return await roadmapDelete(args.id);
375
+ // Beacon context tools
376
+ case 'beacon_scan':
377
+ return await beaconScan(args.messages, args.query);
378
+ case 'beacon_compress':
379
+ return await beaconCompress(args.messages, args.target_ratio, args.preserve_recent);
380
+ case 'beacon_extract':
381
+ return await beaconExtract(args.messages, args.extract_type);
382
+ case 'beacon_focus':
383
+ return await beaconFocus(args.messages, args.query);
384
+ case 'beacon_rank':
385
+ return await beaconRank(args.messages);
283
386
  default:
284
387
  return { error: `Unknown beacon tool: ${name}` };
285
388
  }
@@ -305,6 +408,13 @@ module.exports = {
305
408
  roadmapList,
306
409
  roadmapUpdate,
307
410
  roadmapDelete,
411
+ beaconScan,
412
+ beaconCompress,
413
+ beaconExtract,
414
+ beaconFocus,
415
+ beaconRank,
308
416
  // Export roadmap tools separately for FREE tier
309
- ROADMAP_TOOLS: BEACON_TOOLS.filter(t => t.name.startsWith('roadmap_'))
417
+ ROADMAP_TOOLS: BEACON_TOOLS.filter(t => t.name.startsWith('roadmap_')),
418
+ // Export context tools separately for PRO tier
419
+ CONTEXT_TOOLS: BEACON_TOOLS.filter(t => t.name.startsWith('beacon_'))
310
420
  };
package/lib/packs.js CHANGED
@@ -36,10 +36,10 @@ const PACKS = {
36
36
  // === STARTER TIER ($29/mo) ===
37
37
  beacon: {
38
38
  name: 'beacon',
39
- description: 'Consumer tools - hints, roast, naming, pricing',
40
- tools: 10,
39
+ description: 'Ideation + context compression - hints, roast, scan, compress',
40
+ tools: 19,
41
41
  tier: 'starter',
42
- highlights: ['hints', 'roast', 'quick_vibe', 'name_it', 'compute']
42
+ highlights: ['hints', 'roast', 'beacon_scan', 'beacon_compress', 'compute']
43
43
  },
44
44
 
45
45
  // === PRO TIER ($99/mo) ===
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "50c",
3
- "version": "2.9.0",
4
- "description": "AI toolkit with init/doctor CLI. One install, 117+ tools.",
3
+ "version": "2.10.0",
4
+ "description": "AI toolkit with beacon context compression. 137+ tools.",
5
5
  "main": "lib/index.js",
6
6
  "bin": {
7
7
  "50c": "./bin/50c.js"