You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
-118Lines changed: 0 additions & 118 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,124 +16,6 @@ As a default it relies on the JSON schema proposed by an expert panel (Haddaway
16
16
The package can be used programmatically or through the command line, has zero dependencies, and can therefore be integrated in a variety of environments.
17
17
The heuristics, parsers, and linters are battle-tested on over 500 peer-reviewed queries registered at [searchRxiv](https://www.cabidigitallibrary.org/journal/searchrxiv).
Copy file name to clipboardExpand all lines: docs/source/dev_docs/parser.rst
+96-1Lines changed: 96 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,29 @@
1
1
Developing a parser
2
2
===================
3
3
4
-
A code skeleton is available for the `parser <parser_skeleton.py>`_ and `tests <parser_skeleton_tests.py>`_.
4
+
.. image:: documentation.png
5
+
:width:800px
6
+
7
+
Development setup
8
+
-------------------
9
+
10
+
.. code-block::
11
+
:caption: Installation in editable mode with `dev` extras
12
+
13
+
pip install -e ".[dev]"
14
+
15
+
Skeleton
16
+
--------------------
17
+
18
+
A code skeleton is available for the parser and tests:
19
+
20
+
.. literalinclude:: parser_skeleton.py
21
+
:language: python
22
+
23
+
24
+
.. literalinclude:: parser_skeleton_tests.py
25
+
:language: python
26
+
5
27
6
28
To parse a list format, the numbered sub-queries should be replaced to create a search string, which can be parsed with the standard string-parser. This helps to avoid redundant implementation.
7
29
@@ -30,3 +52,76 @@ When parsing combined DB-Fields, the standard syntax should consist of n nodes,
30
52
**n:1 matches**
31
53
32
54
If multiple Database-Fields correspond to the same Standard-Field, a combination of the default Database-Field and Standard-Field are added to the ``constants.SYNTAX_FIELD_MAP``. Non-default Database-Fields are replaced by the parser. For example, the default for MeSH terms at Pubmed is ``[mh]``, but the parser also supports ``[mesh]``.
55
+
56
+
Search Field Validation in Strict vs. Non-Strict Modes
0 commit comments