First product
This commit is contained in:
parent
778da9e2fc
commit
4433d7d2c4
157 changed files with 23975 additions and 0 deletions
17
app/web/deps.py
Normal file
17
app/web/deps.py
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
from __future__ import annotations
|
||||
|
||||
from fastapi import Depends
|
||||
|
||||
from app.services import ingestion as ingestion_service
|
||||
from app.services import scholar_source as scholar_source_service
|
||||
|
||||
|
||||
def get_scholar_source() -> scholar_source_service.ScholarSource:
|
||||
return scholar_source_service.LiveScholarSource()
|
||||
|
||||
|
||||
def get_ingestion_service(
|
||||
source: scholar_source_service.ScholarSource = Depends(get_scholar_source),
|
||||
) -> ingestion_service.ScholarIngestionService:
|
||||
return ingestion_service.ScholarIngestionService(source=source)
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue