Skip to content

Add docstrings and type hints to symbolic_kernel functions #1

@blackboxprogramming

Description

@blackboxprogramming

Description

The symbolic_kernel.py file in the Remember project contains many mathematical and psychological helper functions (e.g., valence, arousal, dominance, etc.) but most of them lack docstrings and type annotations, making the code hard to understand and maintain. Adding clear documentation and type hints will improve readability and ease of use.

Proposed work

  • For each function in symbolic_kernel.py, write a concise docstring describing its purpose, parameters, and return value. Follow the Google or NumPy docstring format for consistency.
  • Add Python type hints for function arguments and return types to clarify expected inputs and outputs.
  • Run a static type checker (e.g., mypy) to ensure that type annotations are correct and resolve any issues uncovered.
  • Update the README or inline comments to mention the availability of docstrings and how to use the functions.

Acceptance criteria

  • Every function in symbolic_kernel.py includes a docstring and appropriate type hints.
  • Static type checking with mypy (or similar) passes without errors.
  • Developers can read the docstrings via IDE or help() and understand each function's purpose and usage.

Metadata

Metadata

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions