What Cody Freeman Actually Is and How to Get It Working
Cody Freeman is a lightweight code search and navigation tool built on top of LLMs. It was created by Sourcegraph as a local-first coding assistant that indexes your codebase and answers questions about it using semantic search rather than just grep. The idea is simple — you point it at your repo, it builds an index, and then you can ask natural language questions about functions, classes, or architecture without leaving your editor. It integrates with VS Code, JetBrains IDEs, and the web interface. You run it either through Sourcegraph's cloud instance or self-host it behind your own Sourcegraph deployment. The free tier gives you access to public repositories and limited indexing. Paid tiers add private repo support and higher rate limits. Most teams I've seen end up self-hosting because the cloud quota burns through fast when you're working with large codebases. Getting set up on VS Code takes about ten minutes if you already have a Sourcegraph account. Install the Cody extension from the marketplace, sign in, and run cody auth login from the command palette. It will prompt you for your Sourcegraph endpoint URL. If you're using sourcegraph.com, that's just https://sourcegraph.com. After that, click the Cody icon in the sidebar and it starts scanning whatever workspace folder is open. The initial index on a medium-sized TypeScript project took roughly 20 minutes on my machine with 16GB RAM. Subsequent reindexes run in under two minutes.
The chat interface works differently than ChatGPT-style assistants. It grounds every response in your actual code. When you ask something like "where is the payment validation logic," it pulls actual file paths and line numbers, not generic advice. That's the whole value proposition. The downside is that if your codebase lacks descriptive naming or has sparse comments, the results get vaguer. I ran into this with a legacy Java monolith where half the methods were named thing1, thing2, and processData. Cody would still return results, but they required manual scanning to be useful. The workaround was running a quick find-and-replace pass to rename the worst offenders before asking Cody anything substantive about those areas.
Common Pitfalls and Where It Breaks
The indexing engine struggles with dynamically generated code — things created at runtime through reflection, metaprogramming, or build scripts. If your project uses heavy code generation, Cody will miss those files entirely unless you explicitly add them to the index configuration. I spent a solid afternoon chasing a missing reference in a Go project where the structs were generated by a protobuf tool. The fix was adding the generated directory to the cody.ignore list in reverse — actually including it via the includePatterns config in .sourcegraph/configuration.json. Without that, the tool simply doesn't see those files. Another issue is context window limits. The free tier caps your conversation history, and even self-hosted instances throttle aggressively if you paste large file contents into the chat. My practical rule is to keep each query under 50 lines of pasted context. If you need more, reference the file path and let Cody pull it itself. That usually keeps responses accurate and fast. If you're working in a language or framework I haven't mentioned here, the tool's knowledge cuts off at its training data. It knows common patterns for React, Django, Spring Boot, and .NET, but niche frameworks will get generic answers. In those cases, pairing Cody with standard documentation search tends to work better than relying on it alone.
Get the Full Details
