{ "info": { "author": "Aaron M. Hosford", "author_email": "hosford42@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "License :: OSI Approved :: MIT License", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3 :: Only", "Topic :: Database :: Front-Ends", "Topic :: Scientific/Engineering :: Information Analysis", "Topic :: Scientific/Engineering :: Interface Engine/Protocol Translator", "Topic :: Scientific/Engineering :: Mathematics" ], "description": "Vert\n====\n\n*Universal Graph Interface for Python*\n\nAbout\n-----\n\nVert is a Python package which attempts to provide a standardized\ninterface for graphs. It does so by separating the graph into two\nseparate layers of abstraction:\n\n- The graph store: This is where the graph is actually stored and\n represented. It may be a graph database, another graph library's data\n structure, or one of vert's built-in graph store objects.\n- The graph interface: This is where you, the programmer, can access\n the graph via an intuitive object-oriented interface using familiar\n data types such as Graph, Vertex, and Edge.\n\nBecause vert is structured along these distinct layers of abstraction,\nit is possible to write code that utilizes and operates on a graph\nwithout regard for the underlying storage mechanisms. Storage mechanisms\ncan be freely swapped out for each other at the point where the graph\nobject is initialized, and, aside from differences in performance and\npersistence, the rest of your code will never know the difference.\nSupport for new graph storage mechanisms can be added simply by creating\na class that supports the GraphStore interface. This means you never\nhave to worry about vendor lock-in, and updating your code to use the\nlatest technology is as simple as a one-line change.\n\nCopyright/License\n-----------------\n\nAll content copyright 2017 Aaron M. Hosford. Use of this software is\ngoverned by the MIT license. See LICENSE.txt for the full license\nagreement.\n\nPackage Structure\n-----------------\n\n- **test\\_vert**: Unit tests for vert\n\n - **test\\_stores**: Unit tests for vert.stores\n\n - **\\_\\_init\\_\\_.py**: Empty placeholder.\n - **\\_base.py**: Contains base class for vert.stores test cases.\n - **test\\_dbm.py**: Unit tests for vert.stores.dbm.\n - **test\\_memory.py**: Unit tests for vert.stores.memory.\n\n - **\\_\\_init\\_\\_.py**: Empty placeholder.\n\n- **vert**: The package root\n\n - **stores**: Subpackage containing implementations of various graph\n stores that the vert package supports out of the box.\n\n - **\\_\\_init\\_\\_.py**: Empty placeholder.\n - **base.py**: Defines the GraphStore interface that all graph\n stores have to implement. The GraphStore interface hides the\n implementation details for each graph store, providing a\n consistent, albeit clunky, means of accessing and modifying the\n contents of a graph.\n - **dbm.py**: Defines DBMGraphStore, a DBM-backed persistent\n graph store.\n - **memory.py**: Defines the MemoryGraphStore, a non-persistent,\n memory-only graph store.\n\n - **\\_\\_init\\_\\_.py**: Exports the publicly visible symbols for the\n vert package. Nothing is actually defined in this module.\n - **graphs.py**: Defines the Graph, Vertex, and Edge, classes, along\n with other supporting infrastructure. This module's classes\n transform the clunky interface provided by GraphStore into a\n convenient and versatile object-oriented interface designed to\n make it easy to work with graphs in a consistent manner regardless\n of how the underlying storage mechanisms work.\n\nExamples\n--------\n\nNon-Persistent\n^^^^^^^^^^^^^^\n\n::\n\n from vert import Graph\n\n with Graph() as g:\n dog = g.vertices['dog'].add()\n cat = g.vertices['cat'].add()\n edge = g.edges['dog', 'cat']\n print(edge.exists) # False\n edge.add()\n print(edge.exists) # True\n edge.labels.add('chases')\n print('chases' in edge.labels) # True\n\n with Graph() as g:\n edge = g.edges['dog', 'cat']\n print(edge.exists) # False\n\nDBM-Backed Persistence\n^^^^^^^^^^^^^^^^^^^^^^\n\n::\n\n from vert import Graph\n\n with Graph('test.db') as g:\n dog = g.vertices['dog'].add()\n cat = g.vertices['cat'].add()\n edge = g.edges['dog', 'cat']\n print(edge.exists) # False\n edge.add()\n print(edge.exists) # True\n edge.labels.add('chases')\n print('chases' in edge.labels) # True\n\n with Graph('test.db') as g:\n edge = g.edges['dog', 'cat']\n print(edge.exists) # Still true\n print('chases' in edge.labels) # Still true\n\nDefining Your Own Storage Mechanism\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\n::\n\n from vert import Graph, GraphStore\n\n class MyGraphStore(GraphStore):\n # Implement each of GraphStore's abstract methods here\n ...\n\n with Graph(MyGraphStore(...)) as g:\n # Now the graph consults your back end for storage and retrieval\n ...\n\nTODO:\n-----\n\n- Test cases for undirected edges.\n- Add separately installable graph stores for neo4j, tinkerpop,\n networkx, sqlite, and other back ends.\n- Add an example for creating a third-party module to provide support\n for new kinds of graph stores.\n- Add algorithms such as path finding and pattern matching. Whenever\n possible, these should be implemented by the graph store, rather than\n at the interface level. By having the interface classes inspect the\n graph store for the method before calling it, it should be possible\n to fall back on a slower default client-side implementation when the\n store does not provide one. An alternate approach would be to add the\n methods to the GraphStore class but have them raise a special\n sentinel exception if the particular implementation doesn't provide\n the algorithm.\n- Add support for transactions and make the code thread-safe.\n- Add support for reading & writing common graph file formats.\n- Add support for transferring from one graph store to another.\n- 100% code coverage for unit testing.\n- Continuous integration for unit testing.\n- Prettify the string representations for Edges and Vertices.\n- Make the DBM graph store more efficient.\n- Support older versions of Python.\n- Consider adding flags to ``GraphStore.iter_edges()`` for independent\n inclusion/exclusion of directed & undirected edges.\n- Add a ``rebuild()`` method to ``DBMGraphStore`` which ensures the\n stored graph is in a consistent state through minimum modifications,\n allowing recovery from disk or power failure.", "description_content_type": null, "docs_url": null, "download_url": null, "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://pypi.python.org/pypi/vert", "keywords": "graph vertex edge node link network semantic database", "license": "MIT", "maintainer": null, "maintainer_email": null, "name": "vert", "package_url": "https://pypi.org/project/vert/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/vert/", "project_urls": { "Homepage": "https://pypi.python.org/pypi/vert" }, "release_url": "https://pypi.org/project/vert/1.0.1/", "requires_dist": null, "requires_python": null, "summary": "Universal Graph Interface for Python", "version": "1.0.1" }, "last_serial": 2695675, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "00e9ba2441e5754ec55764a92d69bc62", "sha256": "d95e1250a1d0c12d0dd43412f025aa58d5f947cd91cfe1474ce2dc79b29608f6" }, "downloads": -1, "filename": "vert-0.0.1-py3-none-any.whl", "has_sig": false, "md5_digest": "00e9ba2441e5754ec55764a92d69bc62", "packagetype": "bdist_wheel", "python_version": "3.5", "requires_python": null, "size": 17659, "upload_time": "2017-02-26T06:00:33", "url": "https://files.pythonhosted.org/packages/37/fe/b532d936172743bc063e9c9f1229bb34848c4ddacfd64f58ed89cd347cd4/vert-0.0.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "36df04a213982ae56ddd83ab2256367b", "sha256": "b01bf053f30fc2d9e440aa50615d6b8dc05589cfe26abf13f55a05cf1771305b" }, "downloads": -1, "filename": "vert-0.0.1.tar.gz", "has_sig": false, "md5_digest": "36df04a213982ae56ddd83ab2256367b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14916, "upload_time": "2017-02-26T06:00:58", "url": "https://files.pythonhosted.org/packages/d6/ca/2df373d1f9ff8bcb512210d7ca72b6725248255862272d489c911052c0c5/vert-0.0.1.tar.gz" } ], "1.0": [ { "comment_text": "", "digests": { "md5": "aa0384e6391849316ac8692b07032edc", "sha256": "bd093260c18237de1043240a91105377016e1809538d3002c62a862f9215e149" }, "downloads": -1, "filename": "vert-1.0-py3.5.egg", "has_sig": false, "md5_digest": "aa0384e6391849316ac8692b07032edc", "packagetype": "bdist_egg", "python_version": "3.5", "requires_python": null, "size": 55722, "upload_time": "2017-03-09T04:40:06", "url": "https://files.pythonhosted.org/packages/1a/83/dc06b992a1ff07334bb948a43ccf5d4d85d4285961e9b189abc76dbaf45c/vert-1.0-py3.5.egg" }, { "comment_text": "", "digests": { "md5": "8d16cf10dc7ab3b772b915578686723b", "sha256": "08fc7395344b30e9ff1977cf19c99a71a31a6935f73dd6cf8033f116487dad84" }, "downloads": -1, "filename": "vert-1.0-py3-none-any.whl", "has_sig": false, "md5_digest": "8d16cf10dc7ab3b772b915578686723b", "packagetype": "bdist_wheel", "python_version": "3.5", "requires_python": null, "size": 25961, "upload_time": "2017-03-09T04:39:47", "url": "https://files.pythonhosted.org/packages/f6/9a/f4777fbdd529e0fa0d0a1099c61910ea11a829202d760a4e6ea1b96b0aea/vert-1.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "673dfc37b731d42421da846a231f84c7", "sha256": "06d52b32aa5713c5ba942e1d15766864ab802c85e7576f8f9375acfdc59e73e3" }, "downloads": -1, "filename": "vert-1.0.tar.gz", "has_sig": false, "md5_digest": "673dfc37b731d42421da846a231f84c7", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21688, "upload_time": "2017-03-09T04:40:22", "url": "https://files.pythonhosted.org/packages/f3/d9/78efea90bc5b83e2f60681437502690b4938723c28194c6f8376b0fa630a/vert-1.0.tar.gz" } ], "1.0.1": [ { "comment_text": "", "digests": { "md5": "2816b2a337b9da6ed1767b52ecf479cc", "sha256": "9d56672830800535204605681320c1c656ce733073d731d8ecbbf7355d0335a9" }, "downloads": -1, "filename": "vert-1.0.1-py3-none-any.whl", "has_sig": false, "md5_digest": "2816b2a337b9da6ed1767b52ecf479cc", "packagetype": "bdist_wheel", "python_version": "3.5", "requires_python": null, "size": 26062, "upload_time": "2017-03-10T00:53:46", "url": "https://files.pythonhosted.org/packages/d5/2c/c1a775b9d53d76f3426c8c860e183f97caa1b105ac2fe69df34585f04e6d/vert-1.0.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "d0539b4e9b902493721233d37bdc1816", "sha256": "d9e7280f19cca372a8e7f36ab2a9508ad7f486f4cbdcbcf3cc242617b6bc41b4" }, "downloads": -1, "filename": "vert-1.0.1.tar.gz", "has_sig": false, "md5_digest": "d0539b4e9b902493721233d37bdc1816", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21751, "upload_time": "2017-03-10T00:53:27", "url": "https://files.pythonhosted.org/packages/66/68/46adaba694eff1b52ffa000b64b045ae58df30c2e96769e7eacbfd5b3b21/vert-1.0.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "2816b2a337b9da6ed1767b52ecf479cc", "sha256": "9d56672830800535204605681320c1c656ce733073d731d8ecbbf7355d0335a9" }, "downloads": -1, "filename": "vert-1.0.1-py3-none-any.whl", "has_sig": false, "md5_digest": "2816b2a337b9da6ed1767b52ecf479cc", "packagetype": "bdist_wheel", "python_version": "3.5", "requires_python": null, "size": 26062, "upload_time": "2017-03-10T00:53:46", "url": "https://files.pythonhosted.org/packages/d5/2c/c1a775b9d53d76f3426c8c860e183f97caa1b105ac2fe69df34585f04e6d/vert-1.0.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "d0539b4e9b902493721233d37bdc1816", "sha256": "d9e7280f19cca372a8e7f36ab2a9508ad7f486f4cbdcbcf3cc242617b6bc41b4" }, "downloads": -1, "filename": "vert-1.0.1.tar.gz", "has_sig": false, "md5_digest": "d0539b4e9b902493721233d37bdc1816", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21751, "upload_time": "2017-03-10T00:53:27", "url": "https://files.pythonhosted.org/packages/66/68/46adaba694eff1b52ffa000b64b045ae58df30c2e96769e7eacbfd5b3b21/vert-1.0.1.tar.gz" } ] }