Explore Prompt Architecting as a First Approach Instead of Fine-Tuning an LLM

Navigating the Generative AI Landscape: Tailoring Chatbots and LLMs

As generative AI continues to flourish, innovation directors are increasingly fortifying their IT departments to develop customized chatbots and large language models (LLMs). Their aim? To harness the capabilities of ChatGPT while incorporating domain-specific data, ensuring data security and compliance, and enhancing accuracy and relevance.

This leads to a common query: Should organizations create an LLM from scratch, or should they enhance an existing model with their own data? For most companies, neither option is realistic. Here’s why.

TL;DR: With the right sequence of prompts, LLMs can effectively cater to your specific needs without the necessity of altering the model or its training data. Investing time and effort into a robust “prompt architecture” is recommended before exploring costlier alternatives. This strategy aims to maximize the value derived from various prompts, significantly enhancing API-driven tools.

If prompt architecture proves insufficient, which is rare, consider fine-tuning the model; however, this option often incurs higher costs due to data preparation requirements. The prospect of building an LLM from scratch is almost universally unfeasible. The ultimate goal is to utilize existing documents to create customized solutions that automate frequent tasks or answer common inquiries with precision, speed, and security. Prompt architecture stands as the most effective and economical route to this end.

Understanding the Distinction: Prompt Architecting vs. Fine-Tuning

If you're delving into prompt architecture, chances are you’re already familiar with fine-tuning. Here’s the principal difference:

Fine-tuning adjusts the foundational LLM, while prompt architecting refrains from altering the model itself or its training data.

Fine-tuning is a significant undertaking, involving the retraining of a portion of an LLM with a large, new dataset—ideally one tailored to your specific needs. This process infuses domain-specific knowledge into the LLM, aligning it with your industry and business context.

Conversely, prompt architecting utilizes existing LLMs without modifications, relying instead on a sophisticated array of prompts to yield consistent outputs.

Fine-tuning is better suited for organizations with strict data privacy constraints, such as banks. While it may appear straightforward—retraining an existing model with personal data—fine-tuning carries hidden costs associated with dataset acquisition and compatibility. Once the dataset is prepared, the fine-tuning process itself—uploading the data and covering API and computing costs—is relatively simple.

Given the potential expenses, fine-tuning should be considered only when prompt architecture-based solutions have proven inadequate. Moreover, a solid prompt architecture is often necessary to optimize the outputs from fine-tuning efforts.

When engaging with tech partners for fine-tuning, ensure they provide comprehensive insights on dataset preparation and a detailed cost breakdown. A lack of transparency may indicate unreliable services or insufficient experience in this field.

Ideally, valuable fine-tune scenarios should pass through a prompt architecture-based proof of concept before significant investments are made.

Building Secure, Tailored Solutions for Your Organization

Consider a practical example: a research tool that delivers swift answers related to numerous documents. This solution, accessible to employees via a secure web interface, is developed using an API and personalized through prompt architecting.

Employees can ask questions, such as, “Display all conversations between Jane Doe and John Smith referencing ‘transaction,’” and the tool efficiently searches through documents to offer clear, concise results. It employs sophisticated retrieval mechanisms and intelligent prompts to sift through extensive text and deliver coherent answers.

For instance, Dentons, a client of Springbok AI, recently launched FleetAI—their proprietary version of ChatGPT tailored for analyzing and querying legal documents, marking a first in the legal industry.

The Challenge of Building an LLM from Scratch

Attempting to create a proprietary LLM from ground up poses significant challenges. This ambitious goal often proves misguided, requiring an investment of at least $150 million with uncertain results. Competing against established entities such as Meta, OpenAI, and Google, as well as leading university research teams, is a daunting endeavor.

Only a handful of companies worldwide possess the resources to undertake this task. What executives typically envision as their “own LLM” often translates to a secure, LLM-powered solution adapted to their data. Thus, the most practical path for most executives involves pursuing either fine-tuning or prompt architecting strategies tailored to their data.

Best Practices for Crafting Prompt Architectures

To begin, develop data flow and software architecture diagrams that illustrate the overall solution design, including analytics feedback mechanisms.

Establish guidelines for context-based text enhancement with prompt templates outlining tone and length requirements.

Adapt the architecture to the preferred output format, whether a dashboard, conversational interface, or standard document template.

Ensure compatibility with additional data sources, such as databases for efficient information retrieval, Salesforce for CRM engagement, and optical character recognition (OCR) capabilities to process text from images or scanned documents.

Lastly, implement measures to ensure output quality. If output fails quality checks, revise the text through a feedback loop. This mechanism screens for inappropriate content, tone, length, and misinformation. Once the content has passed all checks, it can be delivered to the user.

While it’s crucial to note that LLMs may still produce errors or "hallucinate," these quality checks help minimize inaccuracies.

Key Takeaways

Innovation directors are on the lookout for tailored chatbots and LLMs but face the complex dilemma of either building from scratch or fine-tuning. For most organizations, both avenues are impractical.

LLMs exhibit remarkable flexibility through well-structured prompts. Thorough exploration of prompt architecture is advised before delving into more expensive options. Importantly, a strong prompt architecture will be necessary, regardless of whether you fine-tune or attempt to build a model.

Most people like

Find AI tools in YBX