API Reference Nasty v#0.3.0

View Source

Modules

Nasty - Natural Abstract Syntax Treey

Adjectival Phrase: A phrase headed by an adjective.

Adverbial Phrase: A phrase headed by an adverb.

Answer node representing an extracted answer to a question.

Classification result representing the predicted class for a document.

Classification model containing learned parameters for prediction.

Clause node representing a subject-predicate structure.

Dependency arc representing a grammatical relation between tokens.

Document node representing the root of the AST.

Represents an event extracted from text.

Intent node representing the semantic intent extracted from natural language.

Base types and utilities for AST nodes.

Noun Phrase: A phrase headed by a noun.

Paragraph node representing a sequence of related sentences.

Phrase-level AST nodes for syntactic structure.

Base protocol for all phrase types.

Prepositional Phrase: A phrase headed by a preposition.

Represents a semantic relation between two entities.

Represents a relative clause that modifies a noun.

Renders AST nodes back to text.

Coreference chain linking mentions that refer to the same entity.

Entity node representing a named entity (person, organization, location, etc.).

Event node representing actions, states, or processes.

Semantic frame representing a predicate with its arguments and adjuncts.

Mention of an entity in text, used for coreference resolution.

Modality node representing epistemic and deontic modality.

Reference node representing anaphora and coreference.

Relation node representing a semantic relationship between entities.

Semantic role assigned to a phrase in relation to a predicate.

Sentence node representing a complete grammatical unit.

Token node representing a single word or punctuation mark.

Verb Phrase: A phrase headed by a verb.

Parser for CoNLL-U format used by Universal Dependencies.

Corpus loading and management with caching.

Loader for OntoNotes 5.0 coreference data in CoNLL-2012 format.

Generates Elixir code from natural language intents.

Generates natural language explanations from Elixir code AST.

Recognizes intents from natural language sentences using semantic role labeling.

Optional integration with Ragex knowledge graph for context-aware code generation.

Behaviour that all natural language implementations must implement.

Catalan (Català) language implementation for Nasty.

Extracts dependency relations from parsed Catalan syntactic structures.

Recognizes named entities in Catalan text.

Morphological analyzer for Catalan tokens.

Part-of-Speech tagger for Catalan using rule-based pattern matching.

Parser for Catalan sentences and phrases.

Phrase structure parser for Catalan.

Renders Catalan AST nodes back to natural language text.

Sentence and clause parser for Catalan.

Generates extractive summaries of Catalan documents.

Tokenizer for Catalan text using NimbleParsec.

English language implementation.

Template-based abstractive summarization for English.

Adapter that bridges the English.CoreferenceResolver implementation to the generic Semantic.CoreferenceResolution behaviour.

Adapter that bridges the English.EntityRecognizer implementation to the generic Semantic.EntityRecognition behaviour.

Adapter that bridges the English.Summarizer implementation to the generic Operations.Summarization behaviour.

English answer extraction for Question Answering.

English-specific configuration for text classification.

English-specific configuration for coreference resolution.

Coreference Resolution for English.

Extracts dependency relations from parsed syntactic structures.

Named Entity Recognition (NER) for English.

Extracts events from documents using semantic role labeling and temporal expressions.

Extracts classification features from parsed documents.

Morphological analyzer for English tokens.

Part-of-Speech tagger for English using rule-based pattern matching.

Phrase structure parser for English.

English-specific configuration for Question Answering.

English question analysis for Question Answering.

Extracts semantic relations between entities in a document.

English-specific configuration for Semantic Role Labeling.

Semantic Role Labeling (SRL) for English.

Sentence and clause parser for English.

Extractive text summarization for English.

Template-based information extraction with customizable patterns and slot filling.

English text classification using Naive Bayes.

English tokenizer using NimbleParsec.

Transformer-based Named Entity Recognition for English.

Transformer-based Part-of-Speech tagger for English.

English word sense disambiguation using WordNet.

Loads and caches grammar rules from external resource files.

Registry for managing natural language implementations.

Loads and caches lexicon files from the priv/languages directory.

Spanish language implementation.

Adapter that bridges Spanish.CoreferenceResolver to generic Semantic.CoreferenceResolution.

Adapter that bridges Spanish.EntityRecognizer to generic Semantic.EntityRecognition.RuleBased.

Adapter that bridges Spanish.Summarizer to generic Operations.Summarization.Extractive.

Configuration for Spanish coreference resolution.

Resolves coreferences (anaphora) in Spanish documents.

Extracts dependency relations from parsed Spanish syntactic structures.

Recognizes named entities in Spanish text.

Extracts linguistic features from Spanish text for ML applications.

Morphological analyzer for Spanish tokens.

Part-of-Speech tagger for Spanish using rule-based pattern matching.

Phrase structure parser for Spanish.

Configuration for Spanish Question Answering (QA).

Analyzes Spanish questions and finds answers in documents.

Configuration for Spanish Semantic Role Labeling (SRL).

Labels semantic roles (who did what to whom) in Spanish sentences.

Sentence and clause parser for Spanish.

Generates summaries of Spanish documents.

Classifies Spanish text into categories using Naive Bayes.

Spanish tokenizer using NimbleParsec.

Main API for accessing WordNet lexical database.

Represents a WordNet lemma - a word form with a specific sense in a synset.

Loads WordNet data from WN-LMF (Lexical Markup Framework) JSON files.

Represents a semantic relation between two WordNet synsets.

Semantic similarity metrics for WordNet synsets.

ETS-based in-memory storage for WordNet data with fast lookups.

Represents a WordNet synset (synonym set) - a group of words that share the same meaning.

Behaviour for language-agnostic text classification.

Generic Naive Bayes classifier for text classification.

Generic answer candidate extraction for Question Answering.

Generic sentence scoring for Question Answering.

Generic Question Answering engine.

Generic question classification for Question Answering systems.

Behaviour for language-agnostic text summarization.

Template-based abstractive summarization.

Language-agnostic extractive summarization algorithms.

Pretty printing for AST nodes to aid debugging and visualization.

Renders AST nodes back to natural language text.

Generates visual representations of AST structures.

Generic clustering module for coreference resolution.

Coreference resolution evaluation metrics.

Generic mention detection for coreference resolution.

End-to-end coreference resolver using span-based models.

Training pipeline for end-to-end span-based coreference resolution.

Neural mention encoder using BiLSTM with attention.

Neural pairwise coreference scorer.

Neural coreference resolver integrating with existing pipeline.

Span enumeration and pruning for end-to-end coreference resolution.

End-to-end span-based model for coreference resolution.

Training pipeline for neural coreference resolution.

Generic coreference resolution coordinator.

Generic scoring module for coreference resolution.

Behaviour for language-agnostic coreference resolution.

Behaviour for language-agnostic named entity recognition (NER).

Language-agnostic rule-based Named Entity Recognition (NER).

Generic classification of adjunct roles (location, time, manner, instrument, etc.)

Generic mapping from syntactic arguments to semantic roles.

Generic coordinator for Semantic Role Labeling.

Generic predicate (main verb) detection and voice identification for Semantic Role Labeling.

Word Sense Disambiguation (WSD) - determining which meaning of a word is used in a given context.

Model evaluation and performance metrics.

Feature extraction utilities for statistical models.

Behaviour for statistical models in Nasty.

Downloads pre-trained statistical models from GitHub releases.

Loads statistical models from the filesystem and registers them.

A registry for managing and caching statistical models.

Bidirectional LSTM with Conditional Random Field (CRF) layer for sequence tagging.

Data loading utilities for neural models.

Word and character embedding utilities for neural models.

Efficient inference utilities for neural models.

Behaviour for neural network models using Axon.

Preprocessing utilities for neural models.

Integration with pre-trained transformer models via Bumblebee.

INT8 post-training quantization for neural models.

Training utilities for neural models using Axon.Loop.

Manages caching of downloaded transformer models.

Configuration management for transformer models.

Data preprocessing pipeline for fine-tuning transformer models.

Fine-tuning pipeline for pre-trained transformer models.

Optimized inference for transformer models.

Loads pre-trained transformer models from HuggingFace Hub or local paths.

Multilingual support utilities for transformer models.

Token classification layer on top of pre-trained transformers.

Bridges between Nasty's word-level tokens and transformer subword tokenization.

Zero-shot classification using pre-trained models.

Hidden Markov Model (HMM) for Part-of-Speech tagging.

Neural POS tagger using BiLSTM-CRF architecture.

CYK (Cocke-Younger-Kasami) parsing algorithm for PCFGs.

Grammar rule representation and manipulation for PCFGs.

Represents a single grammar rule with probability.

Probabilistic Context-Free Grammar (PCFG) model for parsing.

Conditional Random Field (CRF) for sequence labeling.

Feature extraction for sequence labeling tasks (NER, POS tagging, etc.).

Gradient-based optimization for CRF training.

Viterbi algorithm for sequence labeling with linear-chain CRFs.

Transforms Abstract Syntax Trees between languages.

Enforces grammatical agreement in target language.

Loads and caches bilingual lexicons for translation.

Translates individual tokens using bilingual lexicons.

Cross-lingual translation using AST-based transformation.

Handles word order transformations between languages.

High-level query API for extracting information from AST.

AST transformation utilities for modifying tree structures.

AST traversal utilities using the visitor pattern.

AST validation utilities for ensuring structural consistency.

Mix Tasks

Evaluates trained statistical models on test data.

Evaluate neural coreference resolution models.

Evaluate end-to-end span-based coreference resolution models.

Evaluates a trained POS tagging model on test data.

Fine-tunes a pre-trained transformer model for POS tagging.

Manage statistical models for Nasty.

Clears cached transformer models to free disk space.

Downloads a pre-trained transformer model from HuggingFace.

Lists all cached transformer models and available models.

Quantize neural models for faster inference and smaller file size.

Train neural coreference resolution models.

Trains a CRF (Conditional Random Field) model for sequence labeling tasks.

Train end-to-end span-based coreference resolution models.

Train a neural POS tagger on Universal Dependencies corpus.

Trains a PCFG (Probabilistic Context-Free Grammar) model from treebank data.

Trains a Hidden Markov Model for part-of-speech tagging.

Downloads WordNet data files from official sources.

Lists installed WordNet data files and their status.

Zero-shot text classification using NLI models.