Pyjsgf

Latest version: v1.9.0

Safety actively analyzes 619181 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 3

1.9.0

--------------------

Added
^^^^^
* Add JSGF import resolution.
* Add new Grammar methods for getting Rule objects by name.
* Add 'grammar_name', 'rule_name' and 'wildcard_import' Import class properties.
* Add 'qualified_name' and 'fully_qualified_name' Rule class properties.

Changed
^^^^^^^
* Add missing Grammar 'import_names' property.
* Add missing Grammar 'remove_imports()' method.
* Change Grammar class to silently reject duplicate Import objects.
* Rename HiddenRule rule classes to PrivateRule instead and leave in HiddenRule aliases.

Fixed
^^^^^
* Change Grammar.get_rule_from_name() method to validate the 'name' parameter.
* Change Grammar.remove_import() to only accept Import objects.
* Fix bug in Grammar.add_rule() that could cause RecursionErrors.

1.8.0

--------------------

Added
^^^^^
* Add 'case_sensitive' properties to Literal, Rule & Grammar classes.

Changed
^^^^^^^
* Change ChildList into a list wrapper class instead of a sub-class.

Fixed
^^^^^
* Fix a pyparsing-related bug with the Repeat expansion class.
* Fix issues preventing serialization of expansions, rules and grammars.

1.7.1

--------------------

Added
^^^^^
* Add 'matching benchmark.py' script.

Changed
^^^^^^^
* Add a classifier for Python 3.4 in setup.py as it is a supported version.
* Rewrite Expansion.repetition_ancestor property.
* Use the setuptools.find_packages() function in setup.py instead of defining packages manually.

Fixed
^^^^^
* Fix missing call to reset_for_new_match() in Rule.find_matching_part(). Some tests have also been added.

1.7.0

--------------------

Added
^^^^^
* Add Expansion and Rule `generate()` methods for generating matching strings. Thanks `embie27`_.
* Add unit tests for `generate()` methods into a new *test/test_generators.py* file. Thanks `embie27`_.

Changed
^^^^^^^
* Include the `mock` package in *requirements.txt* (test requirement).

Fixed
^^^^^
* Fix two rule expansion parser bugs related to unary operators (`+` or `*`).
* Keep required groupings during parsing to avoid unexpected consequences. Thanks `synesthesiam`_.

1.6.0

--------------------

Added
^^^^^
* Add support for JSGF alternative weights to the AlternativeSet class and the rule expansion parser.
* Add 'Expansion.matching_slice' property for getting the slice of the last speech string that matched an Expansion.
* Add 'Repeat.get_expansion_slices' method for getting matching slices of repeated rule expansions.

Changed
^^^^^^^
* Change AlternativeSet 'weights' list to use a dictionary instead.
* Change grammar class and parser to allow for optional grammar header values.
* Change input and output of the 'save_current_matches' and 'restore_current_matches' expansion functions.
* Change jsgf.ext.Dictation expansions to compile as "<DICTATION>" instead of "".
* Simplify the parser code and improve its performance.
* Use '<NULL>' instead of '<VOID>' to compile expansions that should have children but don't.

Fixed
^^^^^
* Fix parser bug where sequences can lose tags. Thanks `synesthesiam`_.
* Fix parser bug with sequences and alternative sets.

1.5.1

--------------------

Added
^^^^^
* Add section in parser documentation with EBNF for the grammar parser.

Changed
^^^^^^^
* Change install instructions to use pip instead.

Fixed
^^^^^
* Fix a few problems with the README.
* Fix missing newlines from Grammar.compile_to_file(). Thanks `daanzu`_.

Page 1 of 3

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.