GraphScope NeuG for python
Project description
The python binding API for NeuG
Building the Wheel
Develop
To build a wheel for the local environment, run:
source ~/.neug_env
cd tools/python_bind
export DEBUG=1
python3 -m pip install -r requirements.txt
python3 -m pip install -r requirements_dev.txt
python3 setup.py build_ext
python3 setup.py bdist_wheel
python3 -m pip install dist/*
Distribution
To build wheels for all supported Python versions on this platform, use the following commands:
python3 -m pip install cibuildwheel
cd ${ROOT_DIR}
cibuildwheel ./tools/python_bind --output-dir wheelhouse
Development Mode Setup
In development mode, wheels are not built or installed. Instead, the required dynamic library is built and copied to tools/python_bind/build. Any changes made to the Python codebase will take effect immediately, allowing for seamless reloading of files.
make develop
# run tests
python3 -m pytest tests/test_a.py
or
python3 setup.py build_ext --inplace --build-temp=build
Neug CLI
The Neug CLI tool provides an interactive shell for querying and managing NeuG database. It supports both local and remote database connections, Cypher query execution, and result formatting.
Installation
neug-cli is included in neug package.
pip install neug
After installation, you can verify that neug-cli is installed correctly by running:
neug-cli --version
This should display:
neug-cli, version 0.1.1
Usage
Overview
The neug-cli tool allows you to interact with the Neug database in both local and remote modes. To view the basic usage, run:
neug-cli --help
This displays:
Usage: neug-cli [OPTIONS] COMMAND [ARGS]...
Neug CLI Tool.
Options:
--version Show the version and exit.
--help Show this message and exit.
Commands:
connect Connect to a remote database.
open Open a local database.
Start the Shell by Opening a Local Database
To open a local Neug database, specify the database path when starting the CLI. By default, the database is opened in read-write mode, and changes are persisted to disk when the shell exits. If the specified directory does not exist, it will be created automatically.
To open the database in read-only mode, use the --readonly or -r option.
neug-cli open <path-to-db> -m [read-only|read-write]
--mode,-m: Specify mode of database.
Start the Shell by Connecting to a Remote Database
To connect to a remote Neug server, specify the server URI when starting the CLI. You can optionally provide a username, password, and query timeout. Note that remote connection support is under development.
neug-cli connect <host:port> [--timeout <seconds>]
--timeout: Connection timeout in seconds (default: 300).
Interactive Shell Commands
Once you start the shell, you can execute Cypher queries and use various interactive commands:
- Enter Cypher queries directly to execute them.
- Use
:helpto display this help message. - Use
:quitor press Ctrl+C to leave the shell. - Use
:max_rows <number>to set the maximum number of rows to display for query results. - Use
:ui <endpoint>to start a web ui service. - Multi-line commands are supported. Use ';' at the end to execute.
- Command history is supported; use the up/down arrow keys to navigate previous commands.
Example
neug-cli open /tmp/modern_graph
This will open embedded Neug database at /tmp/modern_graph in rw mode by default, and start the shell. Then you can execute Cypher queries directly:
Welcome to the Neug shell. Type :help for usage hints.
neug > MATCH (n:person) RETURN n;
+-------------------------------------------------------+
| n |
+=======================================================+
| {_ID: 0, _LABEL: person, id: 1, name: marko, age: 29} |
+-------------------------------------------------------+
| {_ID: 1, _LABEL: person, id: 2, name: vadas, age: 27} |
+-------------------------------------------------------+
| {_ID: 2, _LABEL: person, id: 4, name: josh, age: 32} |
+-------------------------------------------------------+
| {_ID: 3, _LABEL: person, id: 6, name: peter, age: 35} |
+-------------------------------------------------------+
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file neug-0.1.1-cp314-cp314t-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.
File metadata
- Download URL: neug-0.1.1-cp314-cp314t-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
- Upload date:
- Size: 24.5 MB
- Tags: CPython 3.14t, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fc8fde92144c2bb0edc0420ff1535ff9daf12c9e6b8117daf6cc7720588978af
|
|
| MD5 |
595940ae89e986f50eee09d49f81a039
|
|
| BLAKE2b-256 |
c9bd24e0b0f03161400e28911f158edcab4b35f5768a6b25455c9d6638dac294
|
File details
Details for the file neug-0.1.1-cp314-cp314t-manylinux2014_aarch64.manylinux_2_17_aarch64.whl.
File metadata
- Download URL: neug-0.1.1-cp314-cp314t-manylinux2014_aarch64.manylinux_2_17_aarch64.whl
- Upload date:
- Size: 22.8 MB
- Tags: CPython 3.14t, manylinux: glibc 2.17+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5943570a13d6361ad9691944b921477b297cec9b379bab502c4de8c779894f83
|
|
| MD5 |
c62d9dcbf5e26e690b7fb340c09b98a0
|
|
| BLAKE2b-256 |
c9b9c5ae98b270e32dc04aba2c487eb5496775a2f9a2a4002fce214e848826ac
|
File details
Details for the file neug-0.1.1-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.
File metadata
- Download URL: neug-0.1.1-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
- Upload date:
- Size: 24.5 MB
- Tags: CPython 3.14, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f2c188c6aa580da41aad46cdf9e30464b851c503c4af1b97b47ad2572c6b9683
|
|
| MD5 |
4f2dc7771757416265b324559011f084
|
|
| BLAKE2b-256 |
37d7eda468ac7da57d6a00ed058f2655b6ea2d604905b3fde1b658effae90699
|
File details
Details for the file neug-0.1.1-cp314-cp314-manylinux2014_aarch64.manylinux_2_17_aarch64.whl.
File metadata
- Download URL: neug-0.1.1-cp314-cp314-manylinux2014_aarch64.manylinux_2_17_aarch64.whl
- Upload date:
- Size: 22.8 MB
- Tags: CPython 3.14, manylinux: glibc 2.17+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
95bb25fbf10c85c07ac173acc214388c180c7d6da59a6f065dbc3962fa52e2de
|
|
| MD5 |
929918f234c9e9ec6f909b2563749f35
|
|
| BLAKE2b-256 |
b3e3e557f3f316ee34e8b97fac3d293df5ab0f96e1116b37c6e2cb8675f5ade7
|
File details
Details for the file neug-0.1.1-cp314-cp314-macosx_11_0_arm64.whl.
File metadata
- Download URL: neug-0.1.1-cp314-cp314-macosx_11_0_arm64.whl
- Upload date:
- Size: 33.8 MB
- Tags: CPython 3.14, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f0ba920dee04944ce739c67cb2262ea4c31b2614fa740942cb944c4c81ca910c
|
|
| MD5 |
407156e77a668152ccb6d0a7581e5c2c
|
|
| BLAKE2b-256 |
f79adf45965929a5164ecd4bc14a67ccfbf0135c08c4877a72b5c8a4adf8fd86
|
File details
Details for the file neug-0.1.1-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.
File metadata
- Download URL: neug-0.1.1-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
- Upload date:
- Size: 24.5 MB
- Tags: CPython 3.13, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8f8cc42d84ceed0cb2cfe86528a6f5f48a1395b52f6af35c07af832e5282ba79
|
|
| MD5 |
d6c60863f65d2095fb41161e3d8d0b7a
|
|
| BLAKE2b-256 |
330188499cd4d07b10a2c9af859f36be05c147c05349b71de51b351e222ee5b1
|
File details
Details for the file neug-0.1.1-cp313-cp313-manylinux2014_aarch64.manylinux_2_17_aarch64.whl.
File metadata
- Download URL: neug-0.1.1-cp313-cp313-manylinux2014_aarch64.manylinux_2_17_aarch64.whl
- Upload date:
- Size: 22.8 MB
- Tags: CPython 3.13, manylinux: glibc 2.17+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
69684d8d5e8410784b1e903b3e81386dd4fe41f578257943b20a898538609a77
|
|
| MD5 |
6ceee221e69ab170977f0cae355441ac
|
|
| BLAKE2b-256 |
ff247a9c4c5c0b55dad04e4604bcc95683ff17bdae1ec47575d46821f7c28543
|
File details
Details for the file neug-0.1.1-cp313-cp313-macosx_11_0_arm64.whl.
File metadata
- Download URL: neug-0.1.1-cp313-cp313-macosx_11_0_arm64.whl
- Upload date:
- Size: 33.8 MB
- Tags: CPython 3.13, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
58919f7a11279e41d36d551b8a49fc216d6ecb983168f9269eb9226f677c298d
|
|
| MD5 |
fd5b789b2995b405cce979e337536236
|
|
| BLAKE2b-256 |
38c8aa7c3f422738ac0cc39b0da070f858941af68a3024ba1b6cb6ce016f9662
|
File details
Details for the file neug-0.1.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.
File metadata
- Download URL: neug-0.1.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
- Upload date:
- Size: 24.5 MB
- Tags: CPython 3.12, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
74e87e3e1b13fae5bb1a559a916a1bfcfb35e3d214bdeb2bad5dcb065fd1a08a
|
|
| MD5 |
84b131996d9239a0232c023ee5b0cee6
|
|
| BLAKE2b-256 |
a2c228313d7c53e4b000eeef7b188236b2f6ffab2f1179d23bc5b0fa59c2fc1a
|
File details
Details for the file neug-0.1.1-cp312-cp312-manylinux2014_aarch64.manylinux_2_17_aarch64.whl.
File metadata
- Download URL: neug-0.1.1-cp312-cp312-manylinux2014_aarch64.manylinux_2_17_aarch64.whl
- Upload date:
- Size: 22.8 MB
- Tags: CPython 3.12, manylinux: glibc 2.17+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c79bca12d0d2377fd76156413517730eea5a7d3ed9cfd0dc9f5ee7c6683cf383
|
|
| MD5 |
a58e46b2d166ae67e3e648944be6ad65
|
|
| BLAKE2b-256 |
3bc947500562b9ee69ebf88b1f5f23c8b1b9ef50f2c586b6f6c78da1527f62bb
|
File details
Details for the file neug-0.1.1-cp312-cp312-macosx_11_0_arm64.whl.
File metadata
- Download URL: neug-0.1.1-cp312-cp312-macosx_11_0_arm64.whl
- Upload date:
- Size: 33.8 MB
- Tags: CPython 3.12, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
04e8014c1ece527381318a1bee1e789b1cd86e932378148d4e148af46199fd70
|
|
| MD5 |
8eaf89a764874b993d3b2e9aa6cc194e
|
|
| BLAKE2b-256 |
d200673970556418980b2901a022a6fafc51b6abb680b000d064937429185361
|
File details
Details for the file neug-0.1.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.
File metadata
- Download URL: neug-0.1.1-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
- Upload date:
- Size: 24.5 MB
- Tags: CPython 3.11, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1eb73070c51907518d614f804f38ca21308e8af40d7a1ebdf1ce980b527c5750
|
|
| MD5 |
fd961c4fd39053d11f82ac74d9ad2dff
|
|
| BLAKE2b-256 |
ae104c263a7ce38f38fa8a51717cdc523caddd4bd4b20858337e5ed430911ecf
|
File details
Details for the file neug-0.1.1-cp311-cp311-manylinux2014_aarch64.manylinux_2_17_aarch64.whl.
File metadata
- Download URL: neug-0.1.1-cp311-cp311-manylinux2014_aarch64.manylinux_2_17_aarch64.whl
- Upload date:
- Size: 22.8 MB
- Tags: CPython 3.11, manylinux: glibc 2.17+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
97f305b0de519a68935574d526f6f698d7649c7f9dc99c72fe342afd9036411e
|
|
| MD5 |
7a6ed63723af75798ae5dd8cbf3c0d1a
|
|
| BLAKE2b-256 |
848a113df8e406c77fe70b414db1256a443465e1efc04453b16598812c79536f
|
File details
Details for the file neug-0.1.1-cp311-cp311-macosx_11_0_arm64.whl.
File metadata
- Download URL: neug-0.1.1-cp311-cp311-macosx_11_0_arm64.whl
- Upload date:
- Size: 33.8 MB
- Tags: CPython 3.11, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b6bf237b924a00753f207e42d4b6c71a5d24f40ac26f0f261c4d0c24d5d018bf
|
|
| MD5 |
bca8b1d972c5bc6c0944325e3a954f94
|
|
| BLAKE2b-256 |
41e36580c4b76ac79ffcdcb268c5dbefa8f4094425de4854398ebb3fdda11f29
|
File details
Details for the file neug-0.1.1-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.
File metadata
- Download URL: neug-0.1.1-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
- Upload date:
- Size: 24.5 MB
- Tags: CPython 3.10, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3f61ccc39b0b9f9cffac31ac1bc42702b41d2d139e221fc1a4923e1e7ec79298
|
|
| MD5 |
bd8e62cbefd20112f700d02597c22986
|
|
| BLAKE2b-256 |
d4d98b3abba5501281182109351a40f6bdd8f7b721f664b5247fc52f143ad1c9
|
File details
Details for the file neug-0.1.1-cp310-cp310-manylinux2014_aarch64.manylinux_2_17_aarch64.whl.
File metadata
- Download URL: neug-0.1.1-cp310-cp310-manylinux2014_aarch64.manylinux_2_17_aarch64.whl
- Upload date:
- Size: 22.8 MB
- Tags: CPython 3.10, manylinux: glibc 2.17+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
620d4480d68cac052d4d85b6757df9f11541cab46898b2903bf90b77e55c823d
|
|
| MD5 |
6777cd95d65770f2e81abacfefa07170
|
|
| BLAKE2b-256 |
1ffa5208d4bdbe2d4383a5784649a9697f77f9ea064e521de38db679f9fe977f
|
File details
Details for the file neug-0.1.1-cp310-cp310-macosx_11_0_arm64.whl.
File metadata
- Download URL: neug-0.1.1-cp310-cp310-macosx_11_0_arm64.whl
- Upload date:
- Size: 33.8 MB
- Tags: CPython 3.10, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
52473f5d28ef0246372363d50c9b4b49ebce6d3315b0ed0ac8a22ca6fdcac54b
|
|
| MD5 |
6a230b2c41aab524ce734edac1076e4c
|
|
| BLAKE2b-256 |
b66b5a978ee7db607b8c55290905913e0e3d76b24046d5a35b6f9334b21d9ef8
|
File details
Details for the file neug-0.1.1-cp39-cp39-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.
File metadata
- Download URL: neug-0.1.1-cp39-cp39-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
- Upload date:
- Size: 24.5 MB
- Tags: CPython 3.9, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
453f889d4a0b455da70490a3185d7a66a6ed9d3f885a3ab15799b3f7cf26429b
|
|
| MD5 |
cf247e2ec54f0d17109d4b5eac4aff41
|
|
| BLAKE2b-256 |
fafb9acb0923449b3a17f6ae810bc150c168484c095eb0691cacfc312148d7fc
|
File details
Details for the file neug-0.1.1-cp39-cp39-manylinux2014_aarch64.manylinux_2_17_aarch64.whl.
File metadata
- Download URL: neug-0.1.1-cp39-cp39-manylinux2014_aarch64.manylinux_2_17_aarch64.whl
- Upload date:
- Size: 22.8 MB
- Tags: CPython 3.9, manylinux: glibc 2.17+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
509645aade44632e4a1fa86fc792dcc57a165dc9182a4345239bb8464248b3f6
|
|
| MD5 |
9bed61805c926a011c294a8827438936
|
|
| BLAKE2b-256 |
9df3b02dc02e6f93f500bbb33da500e53681578c80cd563b0347054b92d73190
|
File details
Details for the file neug-0.1.1-cp39-cp39-macosx_11_0_arm64.whl.
File metadata
- Download URL: neug-0.1.1-cp39-cp39-macosx_11_0_arm64.whl
- Upload date:
- Size: 33.8 MB
- Tags: CPython 3.9, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
76d04285cb58d731b575bd7bf89feb6b1d83fca6d1abe9a7133e7178f546f308
|
|
| MD5 |
bbadbde44cb8e82c8dae53848a72d8cb
|
|
| BLAKE2b-256 |
41b82f5a0d88fdaaa174cf3d594ddcfd0dc3be8ea6c4070d5c1e3246fa6e119d
|
File details
Details for the file neug-0.1.1-cp38-cp38-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.
File metadata
- Download URL: neug-0.1.1-cp38-cp38-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
- Upload date:
- Size: 24.5 MB
- Tags: CPython 3.8, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
24de47836ccba06806848bde895b3ca355d66cfda3b625a93f894757c2d88da0
|
|
| MD5 |
ba90e54f223b7f3e436d4a2c012bf7b5
|
|
| BLAKE2b-256 |
cd7b5cdf39fef1796594b7872e2eaf33104848e18981af1ebc1c3d908e4997e6
|
File details
Details for the file neug-0.1.1-cp38-cp38-manylinux2014_aarch64.manylinux_2_17_aarch64.whl.
File metadata
- Download URL: neug-0.1.1-cp38-cp38-manylinux2014_aarch64.manylinux_2_17_aarch64.whl
- Upload date:
- Size: 22.8 MB
- Tags: CPython 3.8, manylinux: glibc 2.17+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
84444633ed0c9ffff2f222824223cfc2aaec4ce71eb0b1c58bd14d88ca56ea80
|
|
| MD5 |
74fc235084f880b1f1949e0c9abdff42
|
|
| BLAKE2b-256 |
de0126e768601914bb2d916f932e7986a8b923d0ea083be36eeeef266e6a7fe9
|
File details
Details for the file neug-0.1.1-cp38-cp38-macosx_11_0_arm64.whl.
File metadata
- Download URL: neug-0.1.1-cp38-cp38-macosx_11_0_arm64.whl
- Upload date:
- Size: 33.8 MB
- Tags: CPython 3.8, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ac692ae651050e30da6a009b176d650752df2a6b871897618a8e9722736ab924
|
|
| MD5 |
c02113f77e0e199626224b1d11c01372
|
|
| BLAKE2b-256 |
5fee8cc63a63b7ebe81072b6a56ffe266840b88e79f63f7cd3c6dac672465576
|