codergpt.documenter package

Submodules

codergpt.documenter.documenter module

Documenter module for codergpt.

class codergpt.documenter.documenter.CodeDocumenter(chain)

Bases: object

Code Explainer class that extracts and explains code from a given file.

document(filename, code, language=None, outfile=None)

Document the contents of the code file by invoking the runnable chain.

Parameters:
  • filename (str) – filename of the code file.

  • code (str) – The string containing the code to be documented.

  • language (Optional[str]) – Coding language of the file, defaults to None

  • outfile (Optional[str]) – Destination filepath, defaults to None

Module contents

Documenter module for codergpt.

class codergpt.documenter.CodeDocumenter(chain)

Bases: object

Code Explainer class that extracts and explains code from a given file.

document(filename, code, language=None, outfile=None)

Document the contents of the code file by invoking the runnable chain.

Parameters:
  • filename (str) – filename of the code file.

  • code (str) – The string containing the code to be documented.

  • language (Optional[str]) – Coding language of the file, defaults to None

  • outfile (Optional[str]) – Destination filepath, defaults to None