Explore the Future with Gen AI: Your Weekly Passport to Innovation!

Explore the Future with Gen AI: Your Weekly Passport to Innovation!

We are back with another exciting edition, ready to dive into the fascinating world of GenAI, and the future-shaping tech trends.

Understanding RAG: A Comparative Analysis with Fine-Tuning in AI-Language Models

In the realm of AI, Large Language Models (LLMs) have immense potential, but they come with certain limitations, such as:

  • Static Nature: LLMs lack real-time information and are impractical to update.
  • Domain Expertise: They lack domain-specific knowledge, especially regarding proprietary information.
  • Enigmatic Decisions: It's challenging to understand the factors influencing their decisions.
  • Resource-Intensive: Creating LLMs requires substantial resources only available to a few organisations.

So, How do we build such a trustworthy, data-driven and continuously updated framework?

In order to suffice these limitations the following two approaches can be used:

RAG: Retrieval Augmented Generation, leverages external data sources to give LLMs contextual reference for improved reliability and context of the AI generated responses.?

RAG consists of two key phases:

  1. Retrieval of Comparable Documents: Fetch relevant information from external databases.
  2. Prompt augmentation for Generation: Use augmented (Document enriched) prompts to ensure accurate responses reducing the likelihood of hallucinations.

Why RAG Excels:

  • Improving AI Reliability: RAG boosts AI reliability by incorporating real-time data, reducing inaccuracies.
  • Adding Context : It adds context, enriching AI responses with diverse but limited to data, relevant information.
  • Effective Approach: Compared to alternatives like model-building from scratch, fine-tuning, or prompt engineering, RAG is a practical and effective solution to boost AI reliability

Limitations of RAG:

  • Retrieval Quality: RAG's responses depend on retrieval accuracy, which can lead to incorrect or incomplete information.
  • Scalability Challenges: Handling extensive knowledge bases can be resource-intensive.
  • Complexity and Maintenance: Implementing and maintaining RAG is complex and requires continuous knowledge base upkeep.

Fine-tuning: Fine-tuning is a machine learning technique that adjusts the parameters of a pre-trained model to adapt it to a specific task. It helps the model specialise in the target task by updating its weights, enabling it to make more accurate predictions or generate better outputs for that particular task.

Some common use cases where fine-tuning can improve results:

  • Setting the style, tone, format, or other qualitative aspects
  • Improving reliability at producing a desired output
  • Correcting failures to follow complex prompts
  • Handling many edge cases in specific ways
  • Performing a new skill or task that’s hard to articulate in a prompt

When it comes to text summarization, the decision between RAG and Fine-Tuning is crucial to ensure that your AI model aligns with your project's specific needs and resources, optimising performance and control.

Here's a concise breakdown of their differences:

In conclusion,?finding the right tool for each AI job involves asking yourself a few questions like -?

  • Does your app need to query live data? -> RAG
  • How critical is matching your brand voice and style? -> Fine-tuning
  • Do you have extensive labelled training data? -> Fine-tuning
  • Will your data change frequently after deployment? -> RAG

Frequently, using both RAG and fine-tuning together can be a good idea because they each have their own strengths that work well together. The important thing is not to assume that one approach works for everything, but to carefully think about your specific needs and choose the best way to improve your model.

Sources:


Optimizing Language Models: Exploring Diverse Prompt Engineering Strategies

The LLMs are becoming increasingly capable and sophisticated, the technique of prompt engineering has emerged as a powerful tool to optimise and fine-tune these models for specific tasks.

Prompt engineering, also called prompt design, is a method in AI that involves crafting specialised inputs or prompts to enhance language models' performance on specific tasks by guiding their behaviour and improving response accuracy.

But why do we need different Prompt engineering techniques?

Different prompt engineering techniques are primarily needed to improve the performance and usability of language models by:

  • Customising models for specific tasks.
  • Controlling output quality, style, and biases.
  • Addressing limitations and improving user experience.

Different prompting strategies:

Chain of Thought(CoT):

Definition: This is a linear way of progressing through a topic or problem. One idea leads directly to the next, forming a chain.

Example: Asking about the history of computers could progress like:

  1. What is a computer?
  2. When was the first computer invented?
  3. Who invented the first programmable computer?
  4. How have computers evolved over time?

In this way it delves deeper into a subject by asking follow-up questions that build upon the previous responses, much like links in a chain.?

Tree of Thought(ToT):

Tree-of-thoughts prompting is similar to CoT prompting, but it allows for more complex and branching decision-making

Definition: This strategy branches out from a main idea, leading to sub-ideas or related topics, forming a hierarchical structure like a tree.

Example: Using the topic "Solar System":

  1. What is the Solar System?
  2. What is the Sun?
  3. What are planets?
  4. Tell me about Earth.
  5. How is Mars different from Earth?
  6. What are asteroids and comets?

Here, you can see each subsequent query is contingent upon the previous answer, guiding the exploration systematically.?

Graph of Thought(GoT):

Chain of Thought Prompting is rigid, hindering error correction, while Tree of Thoughts (ToT) Prompting offers more flexibility with backtracking but still retains some rigidity and linearity

To overcome this, the GOTR(Graph of Thoughts Reasoning)? technique aids large models in complex reasoning, especially for deep context understanding.

Definition: This method views topics as interconnected nodes. Unlike a tree, which is hierarchical, a graph can have nodes that connect to multiple other nodes, showing complex relationships.

Example: Discussing "Music"

What is music?

  1. How is music composed? (Links to "Composition")
  2. What are different music genres? (Links to "Genres")
  3. How has music influenced culture? (Links to "Cultural Influence")

From "Genres", you might branch to:

  1. How did jazz evolve?
  2. Which instruments are prominent in rock music?

"Cultural Influence" might connect back to:

  1. How did jazz influence the 1920s culture?

Chain of Verification Prompting

Definition: ?A key assumption behind this method is that language models, when suitably prompted, can both generate and execute a plan of how to verify itself in order to check it's own work, and finally incorporate this analysis into an improved response.

It involves a four-step process where the model drafts an initial response, plans verification questions to fact-check its draft, answers those questions independently, and generates its final verified response.

Example:

Chain of Density Prompting

Definition:

Chain of Density (CoD) is a method for generating summaries that are increasingly entity-dense. It involves generating an initial entity-sparse summary before iteratively incorporating missing salient entities without increasing the length.

CoD is an effective approach for generating summaries that are preferred by human annotators and can be used for a variety of applications, including news articles and scientific papers.

Example:

In Summary,

  • CoT is a straightforward, step-by-step progression.
  • ToT begins centrally and branches out hierarchically.
  • Graph of Thought offers a network of interconnected ideas, allowing for a more intricate exploration of relationships.
  • COVE improves precision in list-based answers, and fixing incorrect responses by verifying its own answers.
  • CoD works by enriching the answer by more entities at each subsequent step It is useful for tasks like question answering and information retrieval.

Sources:


Unlocking the Potential of Large Language Models in Legal Summarization: The PRODIGIT Project

Italian tax law adjudication is a multi-tiered system with a significant caseload stemming from a large taxpayer base and complex tax laws. In 2022 the number of complaints received by tax courts of the first instance was about 145,972, while appeals brought to courts of the second instance were 41,051. The Court of Cassation received about 10,531 appeals against second-instance decisions.

The PRODIGIT project, led by the Presidential Council of Tax Justice and the Ministry of the Economy and Finance, aims to leverage AI in tax adjudication by harnessing the power of LLMs to provide judges and professionals with the tools needed to navigate the intricacies of tax law in two crucial areas:?

  1. Generating summaries and headnotes of judicial decisions.
  2. Providing semantic tools for searching and analyzing case law.?

Dataset: The PRODIGIT dataset includes approximately 1,500 decisions including scanned images of past decisions.?

Summarization of Tax Law Decisions: PRODIGIT experimented with various NLP tools and generative models depending on the document's structure and content.

  • PRODIGIT initially experimented with extractive summarization which selects meaningful sentences from the input text. However, the results were unsatisfactory, as the generated summaries lacked completeness and coherence.

  • This led to the exploration of Abstractive summarization which generates new content that captures the essence of the original text using LLMs like GPT-4 which yielded superior results in terms of readability and completeness. This approach also introduced "issue-based summarization," outlining legal issues and principles examined in decisions.?

Evaluation: PRODIGIT employed questionnaires, reviewed by an ethical committee, to assess criteria such as satisfaction, correctness, form, and completeness. Expert evaluations favoured the outcomes produced by generative tools, underscoring their potential in the legal domain.?

The use of LLMs in the legal domain has shown promise, with various models like BERT and GPT being explored for tasks like judgment prediction and statutory reasoning. The ethical implications of LLMs in law are subject to debate, but their potential impact on legal tasks is undeniable

Sources:


Google's Multimodal Bio LLM : Med-PaLM 2

Med-PaLM (Medical Pre-trained Language Model) is an advanced AI language model made specifically for the complex challenges in medicine that can work with various types of biomedical data, like medical records, images, and genetic information.

Google introduced this latest model, which is able to score 85% on medical exam questions, which is comparable to the level of an “expert” doctor. This score is an 18% improvement from the original Med-PaLM’s performance.

It was built by fine-tuning and aligning PaLM-E, a language model from Google AI, to the medical field using a specially curated open-source benchmark called MultiMedBench.

Key Features of Med-PaLM:

  1. Understanding Technical Language: Med-PaLM is highly skilled in understanding complex medical language, including abbreviations and acronyms. This skill is crucial for tasks like translating medical texts, creating accurate reports, and extracting important information from large medical datasets.
  2. Grasping Context: Med-PaLM is excellent at understanding the context in which medical terms are used. This ability allows it to make sense of unclear references and provide more precise responses, making it very useful in medical settings.
  3. Multilingual Capability: Med-PaLM is built to work with medical texts in multiple languages, making it a valuable tool for healthcare worldwide and promoting international research collaborations.

Applications of Med-PaLM:?

  1. Clinical Decision Support: Med-PaLM can be integrated into clinical decision support systems, aiding healthcare professionals in diagnosing rare diseases, suggesting treatment plans, and predicting patient outcomes based on similar cases.?
  2. Drug Discovery: Med-PaLM can analyse vast amounts of research papers and clinical trial data to expedite drug discovery processes by identifying potential drug targets, understanding drug interactions, and predicting adverse effects.?
  3. Medical Research: Researchers can leverage Med-PaLM to extract valuable insights from medical literature, accelerate data analysis, and discover patterns in patient populations, thereby advancing medical knowledge.?

To evaluate possible harm in medical question answering, Google researchers conducted a pairwise ranking analysis. Raters were presented with pairs of answers from different sources, such as physician-generated responses versus those from Med-PaLM-2, for a given question.

The rates were then asked to assess the potential harm associated with each answer along two axes:

  1. The extent of possible harm.
  2. The likelihood of causing harm.

Med-PaLM's Limitations and Considerations:

  1. Benchmark Challenges: While MultiMedBench is a positive step towards unified benchmarks, it has limitations like small dataset sizes and limited diversity in modalities and tasks, excluding essential life sciences data.
  2. Language and Multimodal Limitations: Med-PaLM's language and multimodal capabilities, while strong, face challenges in aligning with human responses, capturing empathy, and generalising to specific clinical scenarios.
  3. Fairness and Equity: Current evaluations for fairness and equity are limited in scope and must expand to cover a broader range of health equity topics. Careful consideration is necessary to avoid perpetuating biases against certain demographics.
  4. Ethical Concerns: Ethical considerations encompass patient privacy, fairness, safety, interpretability, clinical validation, informed consent, and accountability.?

Sources:?


Recent Business News

Accenture announced on September 19, 2023 that it will invest in Writer, a full stack generative AI platform for content creation, incorporating it into the “Project Spotlight” program which will enable Writer to tap into Accenture’s expertise and extend its influence across industries.

Oracle's Clinical Digital Assistant, powered by generative AI, streamlines healthcare tasks with voice commands, automating notes and tasks during appointments to reduce physician burnout and simplify patient record access, with availability expected within a year.

Morgan Stanley pioneers generative AI on Wall Street with its AI Morgan Stanley Assistant, powered by OpenAI GPT-4, enhancing client interactions and efficiency for financial advisors by providing quick access to the bank’s extensive database of research reports while setting a precedent for AI adoption in the industry with plans for additional AI-driven tools in the pipeline.


If you are looking for Generative AI Solutions, check out our offerings at www.perpetualblock.io


Saurav Drolia

Senior Business Development Manager | XLRI | Artificial Intelligence

1 年
回复

要查看或添加评论,请登录

Perpetual Block - a Partex Company的更多文章

社区洞察

其他会员也浏览了