https://github.com/alephdata/followthemoney-store
Fragment storage/database layer for FollowTheMoney entities
https://github.com/alephdata/followthemoney-store
Last synced: 10 months ago
JSON representation
Fragment storage/database layer for FollowTheMoney entities
- Host: GitHub
- URL: https://github.com/alephdata/followthemoney-store
- Owner: alephdata
- License: mit
- Created: 2018-11-28T05:16:40.000Z (over 7 years ago)
- Default Branch: main
- Last Pushed: 2024-07-26T01:12:24.000Z (over 1 year ago)
- Last Synced: 2025-05-07T03:03:34.456Z (10 months ago)
- Language: Python
- Homepage:
- Size: 148 KB
- Stars: 10
- Watchers: 4
- Forks: 2
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# followthemoney-store
This library provides methods to store, fetch and list entities formatted as
`followthemoney` data as datasets stored in a SQL backend.
## Usage
### Command-line usage
```bash
# Insert a bunch of FtM entities into a store:
$ cat ftm-entities.ijson | ftm store write -d my_dataset
# Re-create the entities in aggregated form:
$ ftm store iterate -d my_dataset | alephclient write-entities -f my_dataset
```
If you don't want to keep the balkhash dataset generated above, there's a
shortcut that combines the write and iterate functions:
```bash
$ cat ftm-entities.ijson | ftm store aggregate | alephclient write-entities -f my_dataset
```
### Python Library
```python
from ftmstore import Dataset
dataset = Dataset("US-OFAC")
dataset.put(entity, fragment='1')
```