Read the original at linear.app ↗linear.app
By Linear · linear.app
Linear built a Similar Issues detection feature using vector embeddings and LLMs to help teams identify duplicate or related issues during creation, triage, and support intake. Rather than pursuing flashy AI, the team focused on reducing repetitive work by surfacing semantic matches across the product. They chose PostgreSQL with pgvector for storage after evaluating specialized vector databases, and backfilled embeddings across tens of millions of existing issues using parallel processing.
01Key takeaways
- Use LLM-generated embeddings to capture semantic similarity beyond keyword matching, reducing duplicate issues and wasted engineering effort.
- Start with simple storage (blobs in primary DB) during proof-of-concept, then migrate to specialized infrastructure only when justified by scale and performance needs.
- Partition large embedding tables by logical boundaries (workspace ID) and index partitions separately to achieve sub-second query latency at scale.
- Integrate AI detection early in workflows (creation, triage, support intake) rather than as a post-hoc analysis tool to maximize impact.
- Focus AI features on reducing repetitive work and organizing data rather than pursuing flashy capabilities that don't solve real problems.
- Backfill embeddings efficiently using existing parallel processing infrastructure (task runners, Kubernetes) to avoid building new systems.
02Key sections
- The Problem: Duplicate Issues and Backlog Chaos
- Large teams struggle with duplicate issues scattered across backlogs, leading to wasted engineering effort and poor visibility. Linear saw an opportunity to intervene early in the issue creation workflow by suggesting related or duplicate issues using LLM-powered semantic matching.
- Vector Embeddings as the Core Technology
- The team used vector embeddings to encode semantic meaning of issue text as floating-point matrices, enabling cosine similarity searches. This approach captures conceptual relationships (e.g., 'bug' and 'broken' are similar) that keyword-based matching would miss.
- Storage and Infrastructure Decisions
- After evaluating specialized vector databases, Linear chose PostgreSQL with pgvector on Google Cloud for its operational simplicity and reasonable query performance. They initially stored vectors as blobs for rapid iteration, then migrated to a dedicated extension.
- Scaling to Tens of Millions of Issues
- Backfilling embeddings across existing workspaces required partitioning the embeddings table by workspace ID and creating separate indexes on each partition to achieve acceptable query latency at scale.
- Practical Impact and Future Roadmap
- The feature has already reduced manual work for support teams consolidating issues. Linear plans to expand integrations, refine embeddings to consider labels and templates, and integrate similarity signals into their main search functionality.
“Instead of flashy AI features, we focused on areas where automation can reduce repetitive work and organize your data.”Linear · linear.app
“Embeddings encode the semantic meaning or concept of a piece of data as a matrix of floating point numbers.”Linear · linear.app
03Frameworks mentioned
Summary and takeaways written by PM Atlas; quotes are short excerpts. © the original author.