Skip to content

[Feat]: Implementation of Base Event-Driven Workflow #18

@smokeyScraper

Description

@smokeyScraper

🚀 Feature Request

Implement the foundational event-driven system and workflow architecture for the Devr.AI bots.

📌 Description

We need to establish the core event-driven architecture that will serve as the backbone for all platform integrations. This system should allow for modular testing of individual bot components before integrating them into the unified workflow.

🎯 Targets

1. Event Bus System

  • Define standardized event schema for cross-platform compatibility
    • Create base event class with common fields (platform, event_type, timestamp, actor)
    • Implement platform-specific event classes for GitHub, Discord, Slack, Discourse
  • Create event producers for each platform
  • Implement event consumers with appropriate routing logic
  • Implement event serialization/deserialization with proper error handling

2. Event Handler Implementation

  • Can be encapsulated as of now with a general class and base functions, later on to be extended as per individual bot's workflow which can be done via inheritance in individual bots.
    • IssueHandler - For GitHub issue events
    • PRHandler - For GitHub PR events
    • MessageHandler - For Discord/Slack messages
    • OnboardingHandler - For new contributor detection
    • FAQHandler - For knowledge-based questions
  • Create handler registry system for dynamic event routing
  • Fallback/Retry Mechanism

3. Vector DB Interactions

  • Create a VectorDBService class for Supabase vector operations
  • Implement EmbeddingGenerator service
  • Design caching mechanism for frequent queries

4. Analytics Data Collection Updates

  • Create event listeners for analytics events
    • Can be extended as per dashboard
  • Pipeline for aggregating and storing events/updates (Preferably will redirect to the dashboard config part)

5. Event Processing Pipeline

  • Implement EventEnricher service to add context to events
  • Create EventPrioritizer to determine processing order
  • Implement EventRouter to direct events to appropriate handlers
  • Design ProcessingPipeline class with middleware support

6. Configuration Management

  • Create configuration system for managing bot settings
  • Implement feature flags for gradual rollout
  • Add logging and monitoring hooks throughout the system

Initial start can be highly encapsulated with some tests of individual components preferably of directing/workflow

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions