bbsbot 2026-02-08
Major module decomposition splits bot.py, trading.py, orientation.py, and ai_strategy.py into focused sub-packages
259 files · 11,035+ · 4,379-

Module decomposition

9 files changed
  • __init__.py Orientation package replacing monolithic orientation.py
  • detection.py Orientation detection logic extracted
  • knowledge.py Orientation knowledge base extracted
  • layers.py Orientation layers extracted
  • models.py Orientation data models extracted
  • parsing.py Orientation screen parsing extracted
  • bot_core.py Core bot logic extracted from bot.py
  • bot_navigation.py Navigation logic extracted from bot.py
  • bot_twerk.py Twerk strategy logic extracted from bot.py
  • Split orientation.py (1273 lines) into orientation/ package: detection.py, knowledge.py, layers.py, models.py, parsing.py decouple internal
    5 files
    • detection.py
    • knowledge.py
    • layers.py
    • models.py
    • parsing.py
  • Split ai_strategy.py (882 lines) into strategies/ai/: decision_maker.py, feedback_loop.py, goals.py, orchestration.py, validator.py decouple internal
    1 file
    • ai_strategy.py
  • Split trading.py (884 lines) into trading/: execution.py, navigation.py, operations.py, parsers.py, validation.py decouple internal
    1 file
    • operations.py
  • Split bot.py (823 lines) into: bot_core.py, bot_navigation.py, bot_twerk.py decouple internal
    3 files
    • bot_core.py
    • bot_navigation.py
    • bot_twerk.py

Game-specific MCP tools

3 files changed
  • mcp_tools.py MCP tools with --tools flag for granular registration
  • mcp_tools_control.py Bot control MCP endpoints
  • mcp_tools_session.py Session management MCP endpoints
  • Implemented --tools flag for granular MCP tool registration (replacing --game) interface behavioral
    1 file
    • mcp_tools.py
  • Added game filtering so only relevant tools are exposed to MCP clients interface internal
    1 file
    • mcp_tools.py
  • Created proxy tools for simplified BBS tool access (twbot_debug) interface internal
    1 file
    • mcp_tools.py
  • Added MCP tools for session management (mcp_tools_session.py) and control (mcp_tools_control.py) interface internal
    2 files
    • mcp_tools_session.py
    • mcp_tools_control.py
  • Comprehensive documentation for game-specific MCP tools specify internal
    1 file
    • mcp_tools.py

Terminal spy/hijack

2 files changed
  • term_routes.py Terminal routes API for remote terminal access
  • app.py Swarm terminal bridge connecting dashboard to bot terminals
  • Added terminal routes API (api/term_routes.py) for remote terminal access interface behavioral
    1 file
    • term_routes.py
  • Implemented swarm terminal bridge for connecting dashboard to bot terminals interface behavioral
    1 file
    • app.py
  • Added terminal spy mode for observing live bot sessions instantiate internal
    1 file
    • term_routes.py

Dashboard improvements

1 file changed
  • swarm_routes.py Swarm API with spawn controls and config dropdown

Session and worker reliability

5 files changed
  • session.py Session creation bottleneck fix
  • session_manager.py Session manager hardening
  • login.py Login loop bug fix and LLM diagnostics
  • __init__.py Stuck bot analyzer module
  • stuck_bot_analyzer.py Diagnostics for tracking and resolving stuck bots
  • Fixed critical session creation bottleneck causing bot timeouts remediate behavioral
    1 file
    • session.py
  • Fixed orientation polling loop bottleneck causing mid-run disconnections remediate behavioral
    1 file
    • layers.py
  • Fixed login loop bug, credits tracking, and added LLM diagnostics remediate behavioral
    1 file
    • login.py
  • Fixed turns_max being set to 0 on completion remediate internal
    1 file
    • bot_core.py
  • Fixed dashboard spawn config dropdown for non-existent directories remediate behavioral
    1 file
    • swarm_routes.py
1 file changed
  • stuck_bot_analyzer.py Stuck bot analyzer for diagnosing stalled bots
  • Added stuck bot analyzer module instantiate internal
    1 file
    • stuck_bot_analyzer.py
  • Added AI strategy demo configs (swarm_demo_ai) specify internal
    1 file
    • stuck_bot_analyzer.py
  • Added diagnostic JSON files for tracking bot issues qualify internal
    1 file
    • stuck_bot_analyzer.py

Bot status enhancements

2 files changed
  • bot_core.py Improved bot status with ID, activity, and auto-detect turns
  • rules.json Corporate Listings prompt pattern and menu screen detection added
  • Improved bot status dashboard: show ID, Activity, auto-detect turns instantiate behavioral
    1 file
    • bot_core.py
  • Added Corporate Listings prompt pattern and menu screen detection instantiate behavioral
    1 file
    • rules.json
  • Added hijack indicator to dashboard and bot status tracking instantiate behavioral
    1 file
    • swarm_routes.py
  • Debounce dashboard table updates to prevent button click failures harden behavioral
    1 file
    • swarm_routes.py