Is this related to a problem?
TypeScript tools in apps/web/src/lib/tools/ lack JSDoc comments. This makes it harder for contributors and API consumers to understand what each function does, what parameters it expects, and what it returns.
Describe the feature
Add comprehensive JSDoc comments to all exported functions in the TypeScript tools directory. Each function should document:
- Purpose and behavior
- Parameter types and descriptions
- Return value structure
- Brief usage example
Which module does this relate to?
Example usage
Before:
export async function generateStylusCode(prompt: string, env: Env) {
After:
/**
* Generates a Stylus smart contract from a natural language prompt.
* Uses RAG retrieval + LLM generation with compile verification.
*
* @param prompt - Natural language description of the contract to generate
* @param env - Cloudflare Worker environment bindings
* @returns Generated contract code with Cargo.toml, lib.rs, main.rs, and metadata
*/
export async function generateStylusCode(prompt: string, env: Env) {
Additional context
- Files:
apps/web/src/lib/tools/*.ts (all tool files)
- Reference
apps/web/src/lib/openrouter.ts for documentation style
Is this related to a problem?
TypeScript tools in
apps/web/src/lib/tools/lack JSDoc comments. This makes it harder for contributors and API consumers to understand what each function does, what parameters it expects, and what it returns.Describe the feature
Add comprehensive JSDoc comments to all exported functions in the TypeScript tools directory. Each function should document:
Which module does this relate to?
Example usage
Before:
After:
Additional context
apps/web/src/lib/tools/*.ts(all tool files)apps/web/src/lib/openrouter.tsfor documentation style