Repository navigation
Added get_evidence() with the backend chosen from backend_database - #124
Conversation
* New exported generic get_evidence(); the INDRA method replaces .extract_evidence_text() and uses the backend's cogex_url * New R/backend-registry.R splits edges by backend_database and calls each group's default backend * filterSubnetworkByContext() and the four topic functions take backend = NULL * New test-evidence.R; the old evidence tests moved there and mocks now target .fetch_evidence() Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configuration
📒 Files selected for processing (21)
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe package adds ChangesEvidence retrieval API
Backend routing and workflows
Priority: ➖ Normal Estimated code review effort: 3 (Moderate) | ~25 minutes Change: Feature Sequence Diagram(s)sequenceDiagram
participant ContextAndTopicFunctions
participant fetch_evidence
participant BackendRegistry
participant get_evidence
participant IndraBackend
ContextAndTopicFunctions->>fetch_evidence: Pass edges and optional backend
fetch_evidence->>BackendRegistry: Resolve backend for edge groups
BackendRegistry->>get_evidence: Fetch evidence for each group
get_evidence->>IndraBackend: Dispatch evidence request
Merge Risk: ⚪ Minimal · up to No identified issue currently blocks merging. The live CoGEx evidence request has not been validated. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. I’m a rabbit with notes in my paws, Comment |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## devel #124 +/- ##
==========================================
+ Coverage 82.53% 85.23% +2.70%
==========================================
Files 21 22 +1
Lines 2496 2547 +51
==========================================
+ Hits 2060 2171 +111
+ Misses 436 376 -60 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Context and solution
Evidence lookup previously used an INDRA-specific extraction path. This change adds a
get_evidence()generic and moves evidence retrieval behind theNetworkBackendinterface. When callers do not supply a backend, the code selects one from each edge group’sbackend_database.Changes
get_evidence()and add a defaultNetworkBackendmethod.IndraBackendevidence retrieval from the CoGEx evidence endpoint. The method batches unique statement hashes and returns edge rows with evidence text and PMID.backend_databasewhen no backend is supplied and uses the registered default for each group.backendarguments tofilterSubnetworkByContext()and four topic functions.NEWS.mdand the relevant help files.Tests
test-evidence.Rcoverage for evidence retrieval, backend dispatch, input validation, and backend propagation to context and topic functions..fetch_evidence()instead of.extract_evidence_text().Coding guidelines