A textual user interface (TUI) for profiling SPARQL queries in Stardog.
![image](https://private-user-images.githubusercontent.com/23270779/268162999-9ce48173-3354-4530-8247-62499aa1755f.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjI3MzE0MDUsIm5iZiI6MTcyMjczMTEwNSwicGF0aCI6Ii8yMzI3MDc3OS8yNjgxNjI5OTktOWNlNDgxNzMtMzM1NC00NTMwLTgyNDctNjI0OTlhYTE3NTVmLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MDQlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODA0VDAwMjUwNVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWQwZDRmNjVmNTlkMGEyZjc1ZmQ2YjU0NmQyY2FiYWEyM2QxZjA5MjMzOGM4ZjJmNzVlMGIyNzI1NGZmZThkZjMmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.0tg4BFghTOIhdyz9uNraayfZQNDC6VmxwvpI7MLVHVk)
Install sparql-profiler
CLI tool to launch the TUI:
❯ pip3 install --editable .
Check installation:
❯ sparql-profiler --help
Usage: sparql-profiler [OPTIONS] [QUERY]
Profiles the QUERY.
If both the query_file option and QUERY argument are provided, the QUERY
argument will take precedence.
If token is provided in addition to a username and password for
authentication, the token will take precedence.
Options:
-u, --username TEXT Stardog username (applicable only if token not
provided) [default: admin]
-p, --password TEXT Stardog password (applicable only if token not
provided) [default: admin]
-t, --token TEXT Auth JWT token (applicable only if username and
password are not provided)
-e, --endpoint TEXT Stardog endpoint [default:
http://localhost:5820; required]
-d, --database TEXT Stardog database [required]
-r, --reasoning Enables reasoning for the query to be profiled.
-f, --query_file FILENAME File containing query to profile
-h, --help Show this message and exit.
demo.mov
❯ sparql-profiler --help
Usage: sparql-profiler [OPTIONS] [QUERY]
Profiles the QUERY.
If both the query-file option and QUERY argument are provided, the QUERY argument
will take precedence.
If token is provided in addition to a username and password for
authentication, the token will take precedence.
Options:
-u, --username TEXT Stardog username (applicable only if token not
provided) [default: admin]
-p, --password TEXT Stardog password (applicable only if token not
provided) [default: admin]
-t, --token TEXT Auth JWT token (applicable only if username and
password are not provided)
-e, --endpoint TEXT Stardog endpoint [default:
http://localhost:5820; required]
-d, --database TEXT Stardog database [required]
-r, --reasoning Enables reasoning for the query to be profiled.
-f, --query_file FILENAME File containing query to profile
-h, --help Show this message and exit.