Skip to content
This repository has been archived by the owner on Mar 16, 2024. It is now read-only.

Enhancement of Database architecture across the application #272

Open
7 tasks
emrgnt-cmplxty opened this issue Jul 21, 2023 · 0 comments
Open
7 tasks

Enhancement of Database architecture across the application #272

emrgnt-cmplxty opened this issue Jul 21, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@emrgnt-cmplxty
Copy link
Owner

Sure, here's an example of how this task could look like in a GitHub issue:


Summary

This issue is about enhancing our current system architecture and database design. We need to consider a few factors for improvement including the decoupling of databases, transaction handling, database schema changes, task & evaluation workflow integration, and using dependency injection for databases.

Description

We currently use three databases:

  1. AutomataAgentTaskDatabase - tracks all tasks.
  2. OpenAIAutomataConversationDatabase - stores all interactions for a session.
  3. EvalResultWriter - records evaluation results.

These databases are connected using a common session_id.

Tasks

  • Decouple Databases: Investigate if the databases need to be decoupled into separate services to avoid potential bottlenecks or single points of failure and to allow each service to scale independently.

  • Transactions and Consistency: Implement mechanisms for handling transactions across databases and consider the level of consistency required between them.

  • Database Schema Changes: Plan for potential database schema changes that could include adding new fields, changing data types, or restructuring databases.

  • Task & Evaluation Workflow Integration: Ensure smooth integration of the task-oriented workflow with the evaluation harness. Consider using event-driven architecture or a job queue.

  • Dependency Injection for Databases: Make code more flexible and testable by using dependency injection for databases, as noted in the OpenAIAutomataConversationDatabase class.

  • Unit Testing and Mocking: Continue focusing on unit tests for individual components and use mocking to isolate dependencies. Ensure coverage of edge cases and expected workflows.

  • Data Backup and Recovery: Define a strategy for backing up data and recovering from data loss or corruption. Consider replication if the data is critical.

Acceptance Criteria

  • The system is enhanced based on the tasks defined above.
  • All changes have comprehensive unit test coverage.
  • The application functions as expected and all existing functionality is unaffected by these changes.

Remember to assign the issue to the relevant team member(s) and add appropriate labels, in this case "Enhancement". You might also want to link to any relevant milestones or projects.

@emrgnt-cmplxty emrgnt-cmplxty added the enhancement New feature or request label Jul 21, 2023
@emrgnt-cmplxty emrgnt-cmplxty changed the title Consider Database architecture across the application Enhancement of Database architecture across the application Jul 21, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant