All Projects
cat ~/projects/ask-abe/README.md
archived

>Ask Abe

Archived
Started: September 1, 2023Completed: July 1, 2024Company: Recodify.AI

Ask Abe is an AI-powered legal assistant that democratizes access to law by translating complex legal information into plain language through a conversational interface. What sets it apart is its verifiable citation system, linking every answer to the actual US statutes and regulations, ensuring users can trust and verify the information they receive.

Ask Abe

>Problem & Solution

Problem

Legal information is fundamentally inaccessible to ordinary people, creating a justice gap that affects millions. Complex legal language, scattered sources, and lack of context create significant barriers that prevent people from understanding their rights and obligations. This knowledge asymmetry disadvantages those who can't afford legal representation and undermines the principle that everyone should be able to understand the laws governing their lives.

Solution

I built a conversational legal assistant using RAG (Retrieval-Augmented Generation) technology with access to all US statutes and regulations. Users select their jurisdiction, ask questions in plain language, and receive comprehensive answers with verifiable citations to relevant legislation. The innovative citation system transforms references into interactive UI elements in a sidebar, where users can directly verify legislative content, view metadata, and access official .gov sources—creating transparency and trust in an area where accuracy is paramount.

>Challenges

Learning Everything from Scratch

Starting with no prior experience in web development, databases, or AI, I had to teach myself all the necessary technologies simultaneously while building a complex application.

Making Legal Language Accessible

Translating complex legal terminology and concepts into plain language that average users could understand while maintaining accuracy.

Getting LLMs to Follow Citation Instructions

Working with earlier, less capable LLMs that struggled with instruction following, I had to develop a custom citation system using string markers and regex to properly format and link citations to the original legislation.

>Approach

Self-Directed Learning

I adopted a project-based learning approach, teaching myself web development, database design, and LLM integration simultaneously by building a real application with practical value.

Plain Language Translation

I developed a system that could translate complex legal terminology into accessible language by combining LLM capabilities with carefully engineered prompts that maintained accuracy while simplifying concepts.

Custom Citation System

To overcome the limitations of early LLMs in following formatting instructions, I created a regex-based parsing system that could identify and transform citation markers in the model's output into interactive UI elements linked to the original legislation.

>Technical Insights

Custom React Chatbot Architecture

Designed a flexible, queue-based React component system for the chatbot interface. This modular architecture allowed for pushing different types of chat blocks beyond basic user/assistant messages, including custom welcome blocks and 'user clarification' blocks with generated UI response options. This approach enabled more intuitive guidance for users unfamiliar with legal terminology.

>Technologies

RAG
TypeScript
Next.js
Python
SQL

>Results

  • Created a functional legal AI assistant that could accurately answer questions across multiple jurisdictions
  • Developed a citation system that achieved over 95% accuracy in linking to relevant legislation
  • Built a user-friendly interface that made complex legal information accessible to non-experts
  • Established the foundation for Recodify.AI and future legal tech innovations

>Key Learnings

  • Fundamentals of LLM application development including prompt engineering, context management, and handling model limitations
  • Web development fundamentals with React, Next.js, and Tailwind CSS
  • Database design and SQL implementation for storing and retrieving complex legal information
  • Techniques for making complex legal information accessible to non-experts through AI
  • Creative problem-solving for LLM limitations, such as developing regex-based citation parsing
$cd ~/projects
will@diamond:~