slashvibe-mcp 0.2.9 → 0.3.13
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.
- package/README.md +1 -0
- package/analytics.js +107 -0
- package/auth-store.js +148 -0
- package/auto-update.js +130 -0
- package/bridges/bridge-monitor.js +388 -0
- package/bridges/discord-bot.js +431 -0
- package/bridges/farcaster.js +299 -0
- package/bridges/telegram.js +261 -0
- package/bridges/webhook-health.js +420 -0
- package/bridges/webhook-server.js +437 -0
- package/bridges/whatsapp.js +441 -0
- package/bridges/x-webhook.js +423 -0
- package/config.js +154 -5
- package/crypto.js +3 -8
- package/games/arcade.js +406 -0
- package/games/chess.js +451 -0
- package/games/colorguess.js +343 -0
- package/games/crossword-words.js +171 -0
- package/games/crossword.js +461 -0
- package/games/drawing.js +347 -0
- package/games/gameroulette.js +300 -0
- package/games/gamerouter.js +336 -0
- package/games/gamestatus.js +337 -0
- package/games/guessnumber.js +209 -0
- package/games/hangman.js +279 -0
- package/games/memory.js +338 -0
- package/games/multiplayer-tictactoe.js +389 -0
- package/games/pixelart.js +399 -0
- package/games/quickduel.js +354 -0
- package/games/riddle.js +371 -0
- package/games/rockpaperscissors.js +291 -0
- package/games/snake.js +406 -0
- package/games/storybuilder.js +343 -0
- package/games/tictactoe.js +345 -0
- package/games/twentyquestions.js +286 -0
- package/games/twotruths.js +207 -0
- package/games/werewolf.js +508 -0
- package/games/wordassociation.js +247 -0
- package/games/wordchain.js +135 -0
- package/index.js +105 -216
- package/intelligence/index.js +45 -0
- package/intelligence/infer.js +316 -0
- package/intelligence/interests.js +369 -0
- package/intelligence/patterns.js +651 -0
- package/intelligence/proactive.js +358 -0
- package/intelligence/serendipity.js +306 -0
- package/memory.js +166 -0
- package/notification-emitter.js +77 -0
- package/notify.js +102 -1
- package/package.json +21 -7
- package/prompts.js +1 -1
- package/protocol/index.js +161 -1
- package/setup.js +402 -0
- package/store/api.js +528 -82
- package/store/profiles.js +160 -12
- package/tools/_actions.js +463 -16
- package/tools/_deprecated/auto-suggest-connections.js +304 -0
- package/tools/_deprecated/bootstrap-skills.js +231 -0
- package/tools/_deprecated/bridge-dashboard.js +342 -0
- package/tools/_deprecated/bridge-health.js +400 -0
- package/tools/_deprecated/bridge-live.js +384 -0
- package/tools/_deprecated/bridges.js +383 -0
- package/tools/_deprecated/colorguess.js +281 -0
- package/tools/_deprecated/discover-insights.js +379 -0
- package/tools/_deprecated/discover-momentum.js +256 -0
- package/tools/_deprecated/discovery-analytics.js +345 -0
- package/tools/_deprecated/discovery-auto-suggest.js +275 -0
- package/tools/_deprecated/discovery-bootstrap.js +267 -0
- package/tools/_deprecated/discovery-daily.js +375 -0
- package/tools/_deprecated/discovery-dashboard.js +385 -0
- package/tools/_deprecated/discovery-digest.js +314 -0
- package/tools/_deprecated/discovery-hub.js +357 -0
- package/tools/_deprecated/discovery-insights.js +384 -0
- package/tools/_deprecated/discovery-momentum.js +281 -0
- package/tools/_deprecated/discovery-monitor.js +319 -0
- package/tools/_deprecated/discovery-proactive.js +300 -0
- package/tools/_deprecated/draw.js +317 -0
- package/tools/_deprecated/farcaster.js +307 -0
- package/tools/_deprecated/forget.js +119 -0
- package/tools/_deprecated/games-catalog.js +376 -0
- package/tools/_deprecated/games.js +313 -0
- package/tools/_deprecated/guessnumber.js +194 -0
- package/tools/_deprecated/hangman.js +129 -0
- package/tools/_deprecated/multiplayer-tictactoe.js +303 -0
- package/tools/_deprecated/recall.js +147 -0
- package/tools/_deprecated/remember.js +86 -0
- package/tools/_deprecated/riddle.js +240 -0
- package/tools/_deprecated/run-bootstrap.js +69 -0
- package/tools/_deprecated/skills-analytics.js +349 -0
- package/tools/_deprecated/skills-bootstrap.js +301 -0
- package/tools/_deprecated/skills-dashboard.js +268 -0
- package/tools/_deprecated/skills.js +380 -0
- package/tools/_deprecated/smart-intro.js +353 -0
- package/tools/_deprecated/storybuilder.js +331 -0
- package/tools/_deprecated/telegram-bot.js +183 -0
- package/tools/_deprecated/telegram-setup.js +214 -0
- package/tools/_deprecated/twentyquestions.js +143 -0
- package/tools/_discovery-enhanced.js +290 -0
- package/tools/_discovery.js +439 -0
- package/tools/_proactive-discovery.js +301 -0
- package/tools/_shared/index.js +64 -0
- package/tools/_shared.js +234 -0
- package/tools/_work-context.js +338 -0
- package/tools/_work-context.manual-test.js +199 -0
- package/tools/_work-context.test.js +260 -0
- package/tools/activity.js +220 -0
- package/tools/admin-inbox.js +218 -0
- package/tools/agent-treasury.js +288 -0
- package/tools/analytics.js +191 -0
- package/tools/approve.js +197 -0
- package/tools/arcade.js +173 -0
- package/tools/artifact-create.js +17 -11
- package/tools/artifact-view.js +31 -1
- package/tools/artifacts-price.js +47 -43
- package/tools/ask-expert.js +160 -0
- package/tools/available.js +120 -0
- package/tools/become-expert.js +150 -0
- package/tools/broadcast.js +286 -0
- package/tools/chat.js +202 -0
- package/tools/collaborative-drawing.js +286 -0
- package/tools/connection-status.js +178 -0
- package/tools/crossword.js +17 -1
- package/tools/discover.js +350 -34
- package/tools/dm.js +115 -73
- package/tools/drawing.js +1 -1
- package/tools/earnings.js +126 -0
- package/tools/echo.js +16 -0
- package/tools/feed.js +51 -7
- package/tools/follow.js +224 -0
- package/tools/friends.js +207 -0
- package/tools/game.js +2 -2
- package/tools/genesis.js +233 -0
- package/tools/gig-browse.js +206 -0
- package/tools/gig-complete.js +144 -0
- package/tools/handoff.js +7 -1
- package/tools/help.js +4 -4
- package/tools/idea.js +9 -2
- package/tools/inbox.js +334 -28
- package/tools/init.js +727 -36
- package/tools/invite.js +15 -4
- package/tools/l2-bridge.js +272 -0
- package/tools/l2-status.js +217 -0
- package/tools/l2.js +206 -0
- package/tools/migrate.js +156 -0
- package/tools/mint.js +377 -0
- package/tools/multiplayer-game.js +1 -1
- package/tools/notifications.js +415 -0
- package/tools/observe.js +200 -0
- package/tools/onboarding.js +147 -0
- package/tools/open.js +143 -12
- package/tools/party-game.js +2 -2
- package/tools/plan.js +225 -0
- package/tools/presence-agent.js +7 -0
- package/tools/proof-of-work.js +100 -104
- package/tools/pulse.js +218 -0
- package/tools/reply.js +166 -0
- package/tools/report.js +2 -2
- package/tools/reputation.js +175 -0
- package/tools/request.js +17 -3
- package/tools/schedule.js +367 -0
- package/tools/search-messages.js +123 -0
- package/tools/session.js +420 -0
- package/tools/session_price.js +128 -0
- package/tools/settings.js +126 -3
- package/tools/ship.js +31 -8
- package/tools/shipback.js +326 -0
- package/tools/smart-check.js +201 -0
- package/tools/social-processor.js +445 -0
- package/tools/solo-game.js +1 -1
- package/tools/start.js +335 -93
- package/tools/status.js +53 -6
- package/tools/stuck.js +297 -0
- package/tools/subscribe.js +148 -0
- package/tools/subscriptions.js +134 -0
- package/tools/suggest-tags.js +6 -8
- package/tools/tag-suggestions.js +257 -0
- package/tools/tip.js +193 -0
- package/tools/token.js +103 -0
- package/tools/update.js +1 -1
- package/tools/wallet.js +239 -186
- package/tools/watch.js +157 -0
- package/tools/webhook-test.js +388 -0
- package/tools/who.js +54 -3
- package/tools/withdraw.js +145 -0
- package/tools/work-summary.js +96 -0
- package/tools/workshop.js +327 -0
- package/tools/x-mentions.js +1 -1
- package/version.json +14 -3
- package/tools/artifacts-buy.js +0 -111
- package/tools/connect.js +0 -284
- package/tools/gigs-apply.js +0 -99
- package/tools/gigs-browse.js +0 -114
- package/tools/gigs-complete.js +0 -128
- package/tools/gigs-post.js +0 -140
- package/tools/live-off.js +0 -109
- package/tools/live-watch.js +0 -176
- package/tools/live.js +0 -128
- package/tools/sessions-browse.js +0 -105
- package/tools/whats-happening.js +0 -125
- /package/tools/{away.js → _deprecated/away.js} +0 -0
- /package/tools/{back.js → _deprecated/back.js} +0 -0
- /package/tools/{mute.js → _deprecated/mute.js} +0 -0
- /package/tools/{skills-exchange.js → _deprecated/skills-exchange.js} +0 -0
- /package/tools/{tictactoe.js → _deprecated/tictactoe.js} +0 -0
- /package/tools/{wordassociation.js → _deprecated/wordassociation.js} +0 -0
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* vibe forget — Delete thread memories
|
|
3
|
+
*
|
|
4
|
+
* Complete control over what's stored.
|
|
5
|
+
* Explicit deletion with confirmation.
|
|
6
|
+
*
|
|
7
|
+
* Usage:
|
|
8
|
+
* vibe forget @handle — Delete all memories about @handle
|
|
9
|
+
* vibe forget --all — Delete all memories (requires confirmation)
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
const config = require('../config');
|
|
13
|
+
const memory = require('../memory');
|
|
14
|
+
const fs = require('fs');
|
|
15
|
+
|
|
16
|
+
const definition = {
|
|
17
|
+
name: 'vibe_forget',
|
|
18
|
+
description: 'Delete thread memories. Removes all saved observations about a person.',
|
|
19
|
+
inputSchema: {
|
|
20
|
+
type: 'object',
|
|
21
|
+
properties: {
|
|
22
|
+
handle: {
|
|
23
|
+
type: 'string',
|
|
24
|
+
description: 'Who to forget memories about (e.g., @alex)'
|
|
25
|
+
},
|
|
26
|
+
all: {
|
|
27
|
+
type: 'boolean',
|
|
28
|
+
description: 'Delete ALL memories across all threads'
|
|
29
|
+
},
|
|
30
|
+
confirm: {
|
|
31
|
+
type: 'boolean',
|
|
32
|
+
description: 'Confirm deletion (required for --all)'
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
async function handler(args) {
|
|
39
|
+
if (!config.isInitialized()) {
|
|
40
|
+
return {
|
|
41
|
+
display: 'Run `vibe init` first to set your identity.'
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
const { all, confirm } = args;
|
|
46
|
+
let { handle } = args;
|
|
47
|
+
|
|
48
|
+
// Handle --all case
|
|
49
|
+
if (all) {
|
|
50
|
+
const threads = memory.listThreads();
|
|
51
|
+
|
|
52
|
+
if (threads.length === 0) {
|
|
53
|
+
return {
|
|
54
|
+
display: '## Memory — Empty\n\n_No memories to forget._'
|
|
55
|
+
};
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
if (!confirm) {
|
|
59
|
+
// Show what would be deleted and ask for confirmation
|
|
60
|
+
let output = `## Forget All Memories?\n\n`;
|
|
61
|
+
output += `This will delete:\n\n`;
|
|
62
|
+
|
|
63
|
+
let totalMemories = 0;
|
|
64
|
+
for (const thread of threads) {
|
|
65
|
+
output += `• @${thread.handle} — ${thread.count} ${thread.count === 1 ? 'memory' : 'memories'}\n`;
|
|
66
|
+
totalMemories += thread.count;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
output += `\n**Total:** ${totalMemories} memories across ${threads.length} threads\n\n`;
|
|
70
|
+
output += `---\n`;
|
|
71
|
+
output += `_To confirm: \`vibe forget --all --confirm\`_\n`;
|
|
72
|
+
output += `_This cannot be undone._`;
|
|
73
|
+
|
|
74
|
+
return { display: output };
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
// Actually delete all
|
|
78
|
+
let totalDeleted = 0;
|
|
79
|
+
for (const thread of threads) {
|
|
80
|
+
totalDeleted += memory.forget(thread.handle);
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
return {
|
|
84
|
+
display: `## Memory Cleared\n\n**Deleted:** ${totalDeleted} memories across ${threads.length} threads\n\n_Memory is now empty._`
|
|
85
|
+
};
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
// Handle specific thread
|
|
89
|
+
if (!handle) {
|
|
90
|
+
return {
|
|
91
|
+
display: 'Usage: `vibe forget @handle` or `vibe forget --all`\n\nView memories first: `vibe recall`'
|
|
92
|
+
};
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
// Clean handle
|
|
96
|
+
handle = handle.replace(/^@/, '').toLowerCase();
|
|
97
|
+
|
|
98
|
+
// Check if thread exists
|
|
99
|
+
const countBefore = memory.count(handle);
|
|
100
|
+
|
|
101
|
+
if (countBefore === 0) {
|
|
102
|
+
return {
|
|
103
|
+
display: `## Memory — @${handle}\n\n_No memories to forget._`
|
|
104
|
+
};
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
// Delete the thread
|
|
108
|
+
const deleted = memory.forget(handle);
|
|
109
|
+
|
|
110
|
+
let output = `## Memory Forgotten\n\n`;
|
|
111
|
+
output += `**Thread:** @${handle}\n`;
|
|
112
|
+
output += `**Deleted:** ${deleted} ${deleted === 1 ? 'memory' : 'memories'}\n\n`;
|
|
113
|
+
output += `---\n`;
|
|
114
|
+
output += `_Thread memories are gone. Start fresh with \`vibe remember @${handle} "..."\`_`;
|
|
115
|
+
|
|
116
|
+
return { display: output };
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
module.exports = { definition, handler };
|
|
@@ -0,0 +1,376 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* vibe games — Discover and launch all available games on /vibe
|
|
3
|
+
*
|
|
4
|
+
* Your one-stop shop for finding fun! Browse all games, get recommendations,
|
|
5
|
+
* and quick-launch your favorites.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
const config = require('../config');
|
|
9
|
+
const { requireInit } = require('./_shared');
|
|
10
|
+
|
|
11
|
+
const definition = {
|
|
12
|
+
name: 'vibe_games',
|
|
13
|
+
description: 'Discover all available games on /vibe. Browse catalog, get recommendations, quick-launch games.',
|
|
14
|
+
inputSchema: {
|
|
15
|
+
type: 'object',
|
|
16
|
+
properties: {
|
|
17
|
+
category: {
|
|
18
|
+
type: 'string',
|
|
19
|
+
description: 'Filter by game category',
|
|
20
|
+
enum: ['all', 'solo', 'multiplayer', 'collaborative', 'party', 'creative']
|
|
21
|
+
},
|
|
22
|
+
players: {
|
|
23
|
+
type: 'number',
|
|
24
|
+
description: 'Filter by number of players (1 for solo, 2+ for multiplayer)'
|
|
25
|
+
},
|
|
26
|
+
mood: {
|
|
27
|
+
type: 'string',
|
|
28
|
+
description: 'Get game recommendations based on your mood',
|
|
29
|
+
enum: ['competitive', 'creative', 'chill', 'brainy', 'social']
|
|
30
|
+
}
|
|
31
|
+
},
|
|
32
|
+
required: []
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
// Games catalog with all available games
|
|
37
|
+
const GAMES_CATALOG = {
|
|
38
|
+
// Solo Games
|
|
39
|
+
solo: [
|
|
40
|
+
{
|
|
41
|
+
name: '20 Questions',
|
|
42
|
+
command: 'vibe twenty-questions',
|
|
43
|
+
description: 'I think of something, you guess with yes/no questions',
|
|
44
|
+
emoji: '❓',
|
|
45
|
+
difficulty: 'medium',
|
|
46
|
+
playtime: '5-10 min',
|
|
47
|
+
tags: ['brainy', 'solo', 'guessing']
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
name: 'Riddles',
|
|
51
|
+
command: 'vibe riddle',
|
|
52
|
+
description: 'Challenge your mind with brain teasers across difficulty levels',
|
|
53
|
+
emoji: '🧩',
|
|
54
|
+
difficulty: 'varies',
|
|
55
|
+
playtime: '3-15 min',
|
|
56
|
+
tags: ['brainy', 'solo', 'puzzle']
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
name: 'Hangman',
|
|
60
|
+
command: 'vibe hangman',
|
|
61
|
+
description: 'Classic word guessing game - can you save the stick figure?',
|
|
62
|
+
emoji: '🎪',
|
|
63
|
+
difficulty: 'easy',
|
|
64
|
+
playtime: '5 min',
|
|
65
|
+
tags: ['casual', 'solo', 'word']
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
name: 'Number Guessing',
|
|
69
|
+
command: 'vibe guessnumber',
|
|
70
|
+
description: 'Guess my number between 1-100 with strategic hints',
|
|
71
|
+
emoji: '🔢',
|
|
72
|
+
difficulty: 'easy',
|
|
73
|
+
playtime: '3-5 min',
|
|
74
|
+
tags: ['casual', 'solo', 'logic']
|
|
75
|
+
}
|
|
76
|
+
],
|
|
77
|
+
|
|
78
|
+
// 1v1 Games
|
|
79
|
+
versus: [
|
|
80
|
+
{
|
|
81
|
+
name: 'Tic-Tac-Toe',
|
|
82
|
+
command: 'vibe game @friend',
|
|
83
|
+
description: 'Classic 3x3 grid strategy - get three in a row!',
|
|
84
|
+
emoji: '⭕',
|
|
85
|
+
players: 2,
|
|
86
|
+
difficulty: 'easy',
|
|
87
|
+
playtime: '2 min',
|
|
88
|
+
tags: ['competitive', '1v1', 'classic']
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
name: 'Chess',
|
|
92
|
+
command: 'vibe game @friend --game chess',
|
|
93
|
+
description: 'The timeless strategy game with full piece movement',
|
|
94
|
+
emoji: '♟️',
|
|
95
|
+
players: 2,
|
|
96
|
+
difficulty: 'hard',
|
|
97
|
+
playtime: '10-60 min',
|
|
98
|
+
tags: ['competitive', '1v1', 'strategy']
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
name: 'Rock Paper Scissors',
|
|
102
|
+
command: 'vibe rockpaperscissors @friend',
|
|
103
|
+
description: 'Quick decision game of chance and psychology',
|
|
104
|
+
emoji: '✂️',
|
|
105
|
+
players: 2,
|
|
106
|
+
difficulty: 'easy',
|
|
107
|
+
playtime: '1 min',
|
|
108
|
+
tags: ['competitive', '1v1', 'quick']
|
|
109
|
+
}
|
|
110
|
+
],
|
|
111
|
+
|
|
112
|
+
// Collaborative & Creative Games
|
|
113
|
+
collaborative: [
|
|
114
|
+
{
|
|
115
|
+
name: 'Collaborative Drawing',
|
|
116
|
+
command: 'vibe drawing --action start',
|
|
117
|
+
description: '🎨 Real-time shared canvas! Draw together with emojis and Unicode art',
|
|
118
|
+
emoji: '🎨',
|
|
119
|
+
players: '1-8',
|
|
120
|
+
difficulty: 'easy',
|
|
121
|
+
playtime: '10-30 min',
|
|
122
|
+
tags: ['creative', 'collaborative', 'art', 'realtime']
|
|
123
|
+
},
|
|
124
|
+
{
|
|
125
|
+
name: 'Story Builder',
|
|
126
|
+
command: 'vibe story-builder --action create',
|
|
127
|
+
description: '📖 Build stories together! Each person adds one sentence',
|
|
128
|
+
emoji: '📖',
|
|
129
|
+
players: '1-8',
|
|
130
|
+
difficulty: 'easy',
|
|
131
|
+
playtime: '15-30 min',
|
|
132
|
+
tags: ['creative', 'collaborative', 'writing', 'storytelling']
|
|
133
|
+
}
|
|
134
|
+
],
|
|
135
|
+
|
|
136
|
+
// Multiplayer Party Games
|
|
137
|
+
party: [
|
|
138
|
+
{
|
|
139
|
+
name: 'Word Association',
|
|
140
|
+
command: 'vibe multiplayer-game wordassociation --action create',
|
|
141
|
+
description: 'Say words that relate to the previous word. Build themes together!',
|
|
142
|
+
emoji: '💭',
|
|
143
|
+
players: '2-6',
|
|
144
|
+
difficulty: 'easy',
|
|
145
|
+
playtime: '10-20 min',
|
|
146
|
+
tags: ['social', 'party', 'word', 'creative']
|
|
147
|
+
},
|
|
148
|
+
{
|
|
149
|
+
name: 'Werewolf',
|
|
150
|
+
command: 'vibe werewolf --action create',
|
|
151
|
+
description: 'Social deduction party game - find the werewolves!',
|
|
152
|
+
emoji: '🐺',
|
|
153
|
+
players: '5-12',
|
|
154
|
+
difficulty: 'medium',
|
|
155
|
+
playtime: '20-45 min',
|
|
156
|
+
tags: ['social', 'party', 'deduction', 'strategy']
|
|
157
|
+
},
|
|
158
|
+
{
|
|
159
|
+
name: 'Two Truths and a Lie',
|
|
160
|
+
command: 'vibe twotruths',
|
|
161
|
+
description: 'Share facts about yourself - others guess which is the lie',
|
|
162
|
+
emoji: '🤥',
|
|
163
|
+
players: '3+',
|
|
164
|
+
difficulty: 'easy',
|
|
165
|
+
playtime: '10-20 min',
|
|
166
|
+
tags: ['social', 'party', 'icebreaker']
|
|
167
|
+
}
|
|
168
|
+
]
|
|
169
|
+
};
|
|
170
|
+
|
|
171
|
+
// Mood-based game recommendations
|
|
172
|
+
const MOOD_RECOMMENDATIONS = {
|
|
173
|
+
competitive: ['Chess', 'Tic-Tac-Toe', 'Rock Paper Scissors', 'Werewolf'],
|
|
174
|
+
creative: ['Collaborative Drawing', 'Story Builder', 'Word Association'],
|
|
175
|
+
chill: ['20 Questions', 'Hangman', 'Number Guessing', 'Two Truths and a Lie'],
|
|
176
|
+
brainy: ['Riddles', '20 Questions', 'Chess', 'Werewolf'],
|
|
177
|
+
social: ['Word Association', 'Story Builder', 'Werewolf', 'Two Truths and a Lie', 'Collaborative Drawing']
|
|
178
|
+
};
|
|
179
|
+
|
|
180
|
+
// Quick stats about the game ecosystem
|
|
181
|
+
function getGameStats() {
|
|
182
|
+
const allGames = Object.values(GAMES_CATALOG).flat();
|
|
183
|
+
const totalGames = allGames.length;
|
|
184
|
+
|
|
185
|
+
const byCategory = {};
|
|
186
|
+
const byPlayers = { solo: 0, duo: 0, party: 0 };
|
|
187
|
+
|
|
188
|
+
Object.entries(GAMES_CATALOG).forEach(([category, games]) => {
|
|
189
|
+
byCategory[category] = games.length;
|
|
190
|
+
});
|
|
191
|
+
|
|
192
|
+
allGames.forEach(game => {
|
|
193
|
+
if (!game.players || game.players === 1) {
|
|
194
|
+
byPlayers.solo++;
|
|
195
|
+
} else if (game.players === 2) {
|
|
196
|
+
byPlayers.duo++;
|
|
197
|
+
} else {
|
|
198
|
+
byPlayers.party++;
|
|
199
|
+
}
|
|
200
|
+
});
|
|
201
|
+
|
|
202
|
+
return { totalGames, byCategory, byPlayers };
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
// Format games display
|
|
206
|
+
function formatGamesDisplay(games, title, showCommands = true) {
|
|
207
|
+
if (games.length === 0) {
|
|
208
|
+
return `**${title}**\nNo games found matching your criteria.`;
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
let display = `## ${title}\n\n`;
|
|
212
|
+
|
|
213
|
+
for (const game of games) {
|
|
214
|
+
display += `### ${game.emoji} ${game.name}\n`;
|
|
215
|
+
display += `${game.description}\n\n`;
|
|
216
|
+
|
|
217
|
+
// Game details
|
|
218
|
+
const details = [];
|
|
219
|
+
if (game.players) details.push(`👥 ${game.players} players`);
|
|
220
|
+
if (game.difficulty) details.push(`🎯 ${game.difficulty}`);
|
|
221
|
+
if (game.playtime) details.push(`⏱️ ${game.playtime}`);
|
|
222
|
+
|
|
223
|
+
if (details.length > 0) {
|
|
224
|
+
display += `**Details:** ${details.join(' • ')}\n`;
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
if (showCommands) {
|
|
228
|
+
display += `**Play:** \`${game.command}\`\n\n`;
|
|
229
|
+
} else {
|
|
230
|
+
display += '\n';
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
return display;
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
// Get games by category
|
|
238
|
+
function getGamesByCategory(category) {
|
|
239
|
+
if (category === 'all') {
|
|
240
|
+
return Object.values(GAMES_CATALOG).flat();
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
const categoryMap = {
|
|
244
|
+
'solo': 'solo',
|
|
245
|
+
'multiplayer': ['versus', 'party'],
|
|
246
|
+
'collaborative': 'collaborative',
|
|
247
|
+
'party': 'party',
|
|
248
|
+
'creative': 'collaborative' // Alias for collaborative
|
|
249
|
+
};
|
|
250
|
+
|
|
251
|
+
const targetCategories = Array.isArray(categoryMap[category]) ?
|
|
252
|
+
categoryMap[category] : [categoryMap[category]];
|
|
253
|
+
|
|
254
|
+
const games = [];
|
|
255
|
+
for (const cat of targetCategories) {
|
|
256
|
+
if (GAMES_CATALOG[cat]) {
|
|
257
|
+
games.push(...GAMES_CATALOG[cat]);
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
return games;
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
// Get games by player count
|
|
265
|
+
function getGamesByPlayers(playerCount) {
|
|
266
|
+
const allGames = Object.values(GAMES_CATALOG).flat();
|
|
267
|
+
|
|
268
|
+
return allGames.filter(game => {
|
|
269
|
+
if (!game.players) return playerCount === 1; // Solo games
|
|
270
|
+
|
|
271
|
+
const players = game.players;
|
|
272
|
+
|
|
273
|
+
// Handle ranges like "2-6" or "3+"
|
|
274
|
+
if (typeof players === 'string') {
|
|
275
|
+
if (players.includes('-')) {
|
|
276
|
+
const [min, max] = players.split('-').map(n => parseInt(n));
|
|
277
|
+
return playerCount >= min && playerCount <= max;
|
|
278
|
+
} else if (players.includes('+')) {
|
|
279
|
+
const min = parseInt(players.replace('+', ''));
|
|
280
|
+
return playerCount >= min;
|
|
281
|
+
}
|
|
282
|
+
return parseInt(players) === playerCount;
|
|
283
|
+
}
|
|
284
|
+
|
|
285
|
+
return players === playerCount;
|
|
286
|
+
});
|
|
287
|
+
}
|
|
288
|
+
|
|
289
|
+
// Get mood-based recommendations
|
|
290
|
+
function getMoodRecommendations(mood) {
|
|
291
|
+
const gameNames = MOOD_RECOMMENDATIONS[mood] || [];
|
|
292
|
+
const allGames = Object.values(GAMES_CATALOG).flat();
|
|
293
|
+
|
|
294
|
+
return allGames.filter(game => gameNames.includes(game.name));
|
|
295
|
+
}
|
|
296
|
+
|
|
297
|
+
async function handler(args) {
|
|
298
|
+
const initCheck = requireInit();
|
|
299
|
+
if (initCheck) return initCheck;
|
|
300
|
+
|
|
301
|
+
const { category = 'all', players, mood } = args;
|
|
302
|
+
|
|
303
|
+
// Handle mood-based recommendations
|
|
304
|
+
if (mood) {
|
|
305
|
+
const games = getMoodRecommendations(mood);
|
|
306
|
+
const title = `🎮 Games for ${mood.toUpperCase()} mood`;
|
|
307
|
+
return {
|
|
308
|
+
display: formatGamesDisplay(games, title)
|
|
309
|
+
};
|
|
310
|
+
}
|
|
311
|
+
|
|
312
|
+
// Handle player count filter
|
|
313
|
+
if (players) {
|
|
314
|
+
const games = getGamesByPlayers(players);
|
|
315
|
+
const title = `🎮 Games for ${players} player${players !== 1 ? 's' : ''}`;
|
|
316
|
+
return {
|
|
317
|
+
display: formatGamesDisplay(games, title)
|
|
318
|
+
};
|
|
319
|
+
}
|
|
320
|
+
|
|
321
|
+
// Handle category filter
|
|
322
|
+
if (category && category !== 'all') {
|
|
323
|
+
const games = getGamesByCategory(category);
|
|
324
|
+
const title = `🎮 ${category.toUpperCase()} Games`;
|
|
325
|
+
return {
|
|
326
|
+
display: formatGamesDisplay(games, title)
|
|
327
|
+
};
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
// Show full catalog (default)
|
|
331
|
+
const stats = getGameStats();
|
|
332
|
+
|
|
333
|
+
let display = `# 🎮 /vibe Games Catalog\n\n`;
|
|
334
|
+
display += `Welcome to the /vibe games arcade! We have **${stats.totalGames} games** across multiple categories.\n\n`;
|
|
335
|
+
|
|
336
|
+
// Quick stats
|
|
337
|
+
display += `**Quick Browse:**\n`;
|
|
338
|
+
display += `• 🎯 \`vibe games --category solo\` - ${stats.byCategory.solo} solo games\n`;
|
|
339
|
+
display += `• ⚔️ \`vibe games --category versus\` - 1v1 competitive games\n`;
|
|
340
|
+
display += `• 🎨 \`vibe games --category collaborative\` - Create together\n`;
|
|
341
|
+
display += `• 🎉 \`vibe games --category party\` - Group fun\n\n`;
|
|
342
|
+
|
|
343
|
+
display += `**By Mood:**\n`;
|
|
344
|
+
display += `• 🏆 \`vibe games --mood competitive\` - Ready to win\n`;
|
|
345
|
+
display += `• 🎨 \`vibe games --mood creative\` - Make something cool\n`;
|
|
346
|
+
display += `• 😌 \`vibe games --mood chill\` - Relaxed fun\n`;
|
|
347
|
+
display += `• 🧠 \`vibe games --mood brainy\` - Mental challenge\n`;
|
|
348
|
+
display += `• 👥 \`vibe games --mood social\` - Connect with others\n\n`;
|
|
349
|
+
|
|
350
|
+
display += `**By Players:**\n`;
|
|
351
|
+
display += `• \`vibe games --players 1\` - Solo adventures\n`;
|
|
352
|
+
display += `• \`vibe games --players 2\` - Perfect for pairs\n`;
|
|
353
|
+
display += `• \`vibe games --players 4\` - Small group games\n\n`;
|
|
354
|
+
|
|
355
|
+
// Highlight featured games
|
|
356
|
+
display += `## ⭐ Featured Games\n\n`;
|
|
357
|
+
|
|
358
|
+
const featured = [
|
|
359
|
+
GAMES_CATALOG.collaborative[0], // Drawing
|
|
360
|
+
GAMES_CATALOG.party[0], // Word Association
|
|
361
|
+
GAMES_CATALOG.versus[1], // Chess
|
|
362
|
+
GAMES_CATALOG.solo[0] // 20 Questions
|
|
363
|
+
];
|
|
364
|
+
|
|
365
|
+
for (const game of featured) {
|
|
366
|
+
display += `**${game.emoji} ${game.name}** - ${game.description}\n`;
|
|
367
|
+
display += `▸ \`${game.command}\`\n\n`;
|
|
368
|
+
}
|
|
369
|
+
|
|
370
|
+
display += `💡 **Tip:** Many games work great for icebreakers, team building, or just having fun with friends!\n\n`;
|
|
371
|
+
display += `Use \`vibe games --category all\` to see the complete catalog with details.`;
|
|
372
|
+
|
|
373
|
+
return { display };
|
|
374
|
+
}
|
|
375
|
+
|
|
376
|
+
module.exports = { definition, handler };
|