@dataresearchcenter/ftm-assets
v0.0.3
Published
javascript fetching logic for ftm-assets
Readme
ftm-assets
Resolve assets (currently images) related to FollowTheMoney entities.
Get images based on qid
cat entities.ftm.json | ftm-assets load-entitiesRun api server
uvicorn --port 8000 ftm_assets.api:app --workers 4Get asset metadata
For images:
curl https://localhost:8000/img/<entity_id>{
"id": "<entity_id>",
"url": "...",
"alt": "...",
"attribution": {
"author": "...",
"license": "...",
}
}Run as an OpenAleph worker service
pip install ftm-assets[openaleph]To ingreate ftm-assets into the OpenAleph ecosystem as a worker that processes entities, start the worker queue like this:
PROCRASTINATE_APP=ftm_assets.tasks.app procrastinate worker -q ftm-assetsTo defer tasks from other places, use ftm-assets as queue name and ftm_assets.tasks.resolve_image as the task identifier.
Docker
Run the queue worker with changing the entrypoint to procrastinate:
docker run ghcr.io/dataresearchcenter/ftm-asstets --entrypoint procrastinate worker -q ftm-assetsLicense and Copyright
ftm-assets, (C) 2025 Data and Research Center – DARC
ftm-assets is licensed under the AGPLv3 or later license.
