-
Notifications
You must be signed in to change notification settings - Fork 0
Feat/conditional probabilities #139
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR introduces conditional probabilities functionality by separating outcome probabilities from outcomes and adding support for conditional probability relationships based on parent options and outcomes.
- Removes the
probability
field from theOutcome
model and creates a newOutcomeProbability
entity - Adds support for conditional probabilities with parent-child relationships between outcomes and options
- Updates tests and services to work with the new probability model
Reviewed Changes
Copilot reviewed 18 out of 18 changed files in this pull request and generated 2 comments.
Show a summary per file
File | Description |
---|---|
src/models/outcome.py | Removes probability field from Outcome model |
src/models/outcome_probability.py | Adds new OutcomeProbability model with parent relationships |
src/models/uncertainty.py | Adds outcome_probabilities relationship |
src/dtos/outcome_probability_dtos.py | Creates DTOs for outcome probability data transfer |
src/dtos/uncertainty_dtos.py | Updates uncertainty DTOs to include outcome probabilities |
src/dtos/outcome_dtos.py | Removes probability field from outcome DTOs |
src/repositories/outcome_probability_repository.py | Adds repository for outcome probability operations |
src/repositories/uncertainty_repository.py | Updates to handle outcome probabilities |
src/repositories/outcome_repository.py | Removes probability field handling |
src/repositories/query_extensions.py | Adds loading for outcome probability relationships |
src/services/pyagrum_solver.py | Updates solver to work with conditional probabilities |
src/services/solver_service.py | Adds NotImplementedError for conditional probabilities |
src/seed_database.py | Updates seed data to use new probability model |
tests/ | Updates all tests to work with new conditional probability structure |
alembic/versions/58dceead9599_conditional_prob.py | Database migration for conditional probabilities |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work 👍
Migration is missing, will be performed after other pull requests are migrated and merged