Metadata-Version: 2.0
Name: bel
Version: 0.5.3.dev0
Summary: BEL related functionality
Home-page: https://github.com/belbio/bel
Author: William Hayes
Author-email: whayes@adsworks.com
License: Apache2
Description-Content-Type: UNKNOWN
Platform: UNKNOWN
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Intended Audience :: Science/Research
Classifier: Development Status :: 2 - Pre-Alpha
Requires-Python: ~=3.6
Requires-Dist: click
Requires-Dist: elasticsearch
Requires-Dist: fastcache
Requires-Dist: jsonschema
Requires-Dist: mmh3
Requires-Dist: python-arango
Requires-Dist: pyyaml
Requires-Dist: requests
Requires-Dist: TatSu
Requires-Dist: ulid-py


BEL package
=================

BEL Language
----------------

Initial Plans
---------------

An approach is to use an EBNF template for BEL and a JSON-based data file to create a fully-specified EBNF input for a parsing generator that will allow us to process a potential full or partial BEL statement, convert it to an AST and be able to convert an AST back to a BEL Statement.

Goals
------------

* Read a standard language descriptor file (e.g. EBNF) for parser generation
* Use configuration files for creating a BEL V.x parser/validator/autocomplete engine
* Allow full or partial BEL Statements
* Identify syntax issues in the statement and provide suggestions on fixing them
* Identify semantic issues in the statement and provide suggestions on fixing them
* Identify unknown Namespaces or Namespace values
* Read a Nanopub and validate the full Nanopub, e.g. the BEL statement, Annotations, Citation, etc
* Provide location-based parser state information (e.g. location 10 is in the required arg part of a protein abundance - e.g. the protein value)
* Provide autocompletion suggestions given a location in the BEL Statement
* Convert BEL statements into an AST and then back into a BEL Statement

Install
---------------

    pip install git+https://github.com/belbio/bel@v<RELEASE>#egg=bel-<RELEASE>

Development Notes
-------------------

We will develop a makefile to handle updating the BEL versions, creating EBNF files,
updating the version, running tests and deploying the package to PyPi.


Setting up bel for local development
-------------------------------------------

1. `git clone git@github.com:belbio/bel.git`
1. `cd bel`
1. Setup Virtual Environment `python3.6 -m venv .venv --prompt bel`
1. Install python packages needed `pip install -r requirements.txt`
1. Install local bel `pip install -e .`

Updating version
------------------

Use one of the following commands depending on what part of the semantic version you
want to increase.

    bumpversion major
    bumpversion minor
    bumpversion patch

These commands use the .bumpversion.cfg file to determine in which files to update the
semantic version.

BEL Nanopub processing library.  The performs the following functions:

* BEL Nanopub validation (in development)

  * Nanopub JSONschema validation
  * BEL statement validation
  * BEL context validation

* BEL Nanopub -> Edge conversion (BEL Pipeline)
* CLI scripts to convert BEL Nanopubs to BEL Edges and perform validation




