CLI Reference

The Code-y CLI is your main entry point for all operations. Here is a detailed breakdown of the available commands and options.

Main Commands

CommandDescription
generateThe primary command. Performs a complete analysis, generates documentation data, and starts the web server.
serve-uiStarts the web server using existing documentation data without running a new analysis.
initCreates a `codey.config.js` file in your project to get you started with configuration.
buildCreates a static, production-ready build of your documentation website.
cleanupRemoves temporary files and AI environments created by Code-y.

`generate` Command Options

The `generate` command accepts numerous options to customize its behavior.

OptionDescription
--root <path>Specify the project root directory to analyze.
--port <number>Set the port for the documentation server (default: 3000).
--output <path>Set a custom output directory for documentation files.
--generate-descriptionsEnable AI-powered description generation.
--no-aiDisable all AI features for a basic, non-AI analysis.
--ollama-model <model>Specify the chat model to use with Ollama (e.g., `llama3:8b`).
--ollama-embedding-model <model>Specify the embedding model to use (default: `nomic-embed-text:latest`).