Remove config calls from internal functions and expose only at interf… - #31
Closed
nicoloesch wants to merge 1 commit into
Closed
Remove config calls from internal functions and expose only at interf…#31nicoloesch wants to merge 1 commit into
nicoloesch wants to merge 1 commit into
Conversation
Collaborator
Author
|
Closing in favor of absorbing this into #34. Depends on AustralianCancerDataNetwork/omop-emb#50, which is being absorbed the same way (see that PR). Merging this chain independently first would mean two breaking releases in quick succession instead of one. The config-boundary fixes here ( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Notes
Depends on
omop-embto pass: AustralianCancerDataNetwork/omop-emb#50. (The reason the typer fails).Requires version bump in
pyproject.tomlto 2.0 foromop-emb.Summary
OmopGraphConfig.get_config()/OmopEmbConfig.get_config()were being called deep inside graph-traversal functions and a dataclass field default instead of once at a caller-resolved boundary.find_shortest_paths,find_shortest_paths_batch,find_standard_paths(graph/paths.py) revertmax_depth/max_paths/max_conceptsto literal defaults, removingOmopGraphConfigfrom this module entirely.GroundingConstraints.max_depth(reasoning/grounding.py) was an unguardeddefault_factoryreachable with zero exception handling fromoaklib_interface/omop_implementation.py:314(an external OAK adapter entry point). Same fix: literal default instead of a config read.KnowledgeGraph.embproperty (graph/kg.py) updated for the newomop-embresolve_backend(backend_type, *, sqlite_path=...)signature, and its own config resolution pushed up toEmbeddingConfigurationconstruction rather than the property re-resolving on first access.