Project structure and setup instructions.
This section demonstrates how to test the core RDF functionality in this project, including generating RDF data and querying it via the API.
Use the ETL script to convert your data to RDF (Turtle format):
python etl/to_rdf.pyThis will create or update RDF files in the rdf/ directory.
Run the FastAPI server:
uvicorn app.main:app --reloadThe API will be available at: http://localhost:8001
You can test the RDF query endpoint (example):
curl -X POST "http://localhost:8000/api/v1/impact/query" \
-H "Content-Type: application/json" \
-d '{"query": "SELECT ?s ?p ?o WHERE { ?s ?p ?o } LIMIT 10"}'Replace the query as needed for your use case.
For more details, see the code in app/clients/graphdb_client.py, app/sparql/impact_queries.py, and app/utils/sparql_utils.py.