Inspiration
"There are only two hard things in Computer Science: cache invalidation and naming things." — Phil Karlton.
We built named to solve the latter. Every developer knows the pain of staring at a blinking cursor, trying to summarize complex logic into a single, concise variable name. Poor naming leads to technical debt and confusing codebases. We wanted to eliminate this cognitive load so developers can focus on architecture and logic.
What it does
named is a contextual semantic naming engine. It acts as an intelligent coding companion that analyzes your Abstract Syntax Tree (AST) and the surrounding code context to suggest highly readable, convention-compliant names for your variables, functions, and classes.
How we built it
We architected the backend using FastAPI (Python) to handle file parsing and logic. The frontend is an intuitive dashboard built with React and TailwindCSS.
Under the hood, we pass code snippets to a Large Language Model. To ensure the suggested names are highly relevant to the actual code functionality, we evaluate the semantic distance between the generated name's embedding and the code's documentation embedding using cosine similarity. The relevance score $S$ is calculated as:
$$ S(A, B) = \frac{A \cdot B}{|A| |B|} = \frac{\sum_{i=1}^{n} A_i B_i}{\sqrt{\sum_{i=1}^{n} A_i^2} \sqrt{\sum_{i=1}^{n} B_i^2}} $$
Names that score below a certain threshold are discarded, ensuring only the highest quality suggestions reach the user.
Challenges we ran into
The biggest hurdle was providing enough context to the AI without exceeding token limits. Sending an entire massive codebase for a single variable name was too slow and expensive. We solved this by writing a custom chunking algorithm that recursively extracts only the immediate parent scope and relevant dependencies.
What we learned
We gained a deep understanding of how Language Server Protocols (LSP) work and how to effectively traverse and manipulate Abstract Syntax Trees in real-time. We also learned how to fine-tune prompts to force LLMs to output strict, IDE-ready naming conventions (like camelCase or snake_case) instead of conversational text.
Log in or sign up for Devpost to join the conversation.