Releases: onsen-ai/node-doc-llm
Releases · onsen-ai/node-doc-llm
Release list
v1.1.1
v1.1.0
v1.0.0
Release Notes
v1.0.0 - Initial Release
Overview
We are excited to announce the initial release of our automated documentation generation script! This tool is designed to help developers quickly generate detailed and structured documentation for their JavaScript/TypeScript codebases using OpenAI's powerful language models.
Features
-
Dependency Parsing:
- Parses JavaScript and TypeScript files to extract dependencies.
- Supports various file extensions including
.js,.jsx,.ts,.tsx,.mjs, and.cjs.
-
Dependency Graph:
- Recursively builds a comprehensive dependency graph from the root file.
- Skips files in
node_modulesand handles directories withindex.jsfiles.
-
AI-Powered Descriptions:
- Utilizes OpenAI's
gpt-4omodel by default to generate detailed summaries. - Dynamically adjusts word count based on the complexity and level of the dependencies.
- Utilizes OpenAI's
-
Markdown Documentation:
- Generates a markdown document with a table of contents and detailed descriptions for each file.
- Organized by sections based on the directory structure.
Customization
- Model Selection:
- The script uses
gpt-4oby default but can be configured to use other models such asgpt-3.5-turboby modifying thegetAiDescriptionfunction.
- The script uses
Usage
-
Installation:
- Clone the repository and install dependencies using
npm install. - Create a
.envfile with your OpenAI API key.
- Clone the repository and install dependencies using
-
Execution:
- Run the script with the root JavaScript file of your project:
node index.js <rootFilePath> [outFile]
- Example:
node index.js src/index.js DOCUMENTATION.md
- Run the script with the root JavaScript file of your project:
Improvements and Enhancements
- Detailed logging of progress, including API usage and costs.
- Handles edge cases for file resolution and extension handling.
- Ensures generated descriptions are relevant and concise, suitable for README inclusion.
Notes
- This is the initial release and we welcome feedback and contributions.
- Future updates will focus on performance improvements, additional features, and enhanced customization options.
Thank you for using our automated documentation generation tool! We look forward to your feedback and contributions.
For more details, please refer to the ./README.md file in the repository.
Happy coding!