Friday, December 27, 2024

Getting Started with AI: NotebookLM

 If you followed along with a previous post on a holiday challenge for learning AI you may now be wondering where too next? Great question, shows you have learned about prompt engineering and are now thinking there has to be more. There is more, a lot more. A good set of skills and understanding of prompt engineering would serve you very well, and you could stop there for a while. Particularly, if you iterate your prompts and increase your literacy in creating prompts. And remember AI can help you improve your prompting.

For many people, I have found that once the intermediate understanding of prompting is achieved the question doesn't seem to go to how do I prompt better. The question seems to go to, can this be automated or can my LLM be more subject specific or can the LLM be restrained personally to my own knowledge. I want the AI to be more specific or give more weight to a narrower or more personal domain of knowledge.

Retrieval-Augmented Generation (RAG)

Retrieval-Augmented Generation (RAG) is like giving an AI system a personalized library to reference while it's talking to you. Instead of only relying on what it learned during training, RAG lets AI search through specific documents or data to find relevant information before generating a response. Think of it like a student who first checks their textbook and notes before answering a question, rather than just going off memory. This helps the AI give more accurate and up-to-date answers based on reliable sources. 

There are a few online options to provide you a personal RAG platform. Currently, my two favorites are perplexity.ai and NotebookLM. Both these platforms allow you to upload or reference other resources (text, video, and others) to augment (and focus) your use of AI. Really very amazing at supporting you in creating subject specific AI mentors. I strongly suggest you begin to play with NotebookLM.

Consider using NotebookLM

  1. Set up an account (or use it with your existing google account). https://notebooklm.google.com/
  2. Watch a NotebookLM introductory overview video: https://youtu.be/UG0DP6nVnrc?si=2bGoT7ZMI-VKsU6_
  3. Think about business and personal use cases: https://youtu.be/U3SgtCWsjXg?si=eR_ESarUJTHenPki
  4. Consider the history of NotebookLM development at google: https://youtu.be/sOyFpSW1Vls?si=F9gVrxXrc2vihRnf
If you remain curious about where RAG and automated agents fit into all the near future of AI I published a post last week discussing these two innovations with AI. Twenty twenty-five will be an interesting year.

Wednesday, December 18, 2024

RAG and Agents: How AI is Learning to Think and Act

Collaborative RAG and Agents.
In the rapidly evolving landscape of artificial intelligence, two technologies are fundamentally changing how AI systems interact with the world: Retrieval-Augmented Generation (RAG) and AI Agents. While both enhance AI capabilities, they serve distinctly different yet complementary purposes in advancing machine intelligence.

RAG: The Power of Grounded Knowledge

Imagine trying to navigate a foreign city using only your general knowledge of how cities work. You might make educated guesses about where to find the downtown area or how the transit system operates, but you'd likely make many mistakes. This is similar to how traditional Large Language Models (LLMs) operate – they rely on their training data to make informed but potentially inaccurate assumptions.

RAG transforms this paradigm by giving LLMs access to specific, relevant information in real-time. Instead of relying solely on their training data, RAG-enabled systems can pull precise information from your organization's documents, databases, and knowledge bases. This means when you ask a question about your company's Q4 2023 results, the AI isn't generating a plausible-sounding response – it's retrieving and synthesizing actual data from your financial reports.

The impact of RAG on accuracy and reliability cannot be overstated. In healthcare, for instance, RAG-enabled systems can access the latest medical research rather than relying on potentially outdated training data. In legal applications, they can reference specific case law and regulations rather than generating generic legal-sounding language.

Agents: From Knowledge to Action

While RAG revolutionizes how AI systems access information, Agents take things a step further by adding autonomous action to the mix. An AI Agent is more like a capable assistant than a simple question-answering system. It can:

  1. Plan and execute multi-step tasks
  2. Interact with external tools and systems
  3. Maintain context across conversations
  4. Learn from past interactions
  5. Make decisions based on evolving situations

Consider a customer service scenario. A RAG-enabled system might accurately answer questions about your return policy by referencing your documentation. An Agent, however, could actually process the return, check inventory for replacements, schedule a pickup, and update your CRM – all while maintaining a natural conversation with the customer.

The Synergistic Future

The real magic happens when RAG and Agents work together. Imagine an AI system that can not only access your entire corporate knowledge base but also take action based on that information. It could:

  • Monitor market trends and automatically adjust your digital advertising strategy
  • Analyze customer feedback across channels and initiate appropriate response workflows
  • Review legal documents and prepare necessary compliance filings
  • Manage complex project timelines while adapting to real-time changes

Practical Implications for Businesses

The combination of RAG and Agents represents a significant leap forward in business process automation. Organizations can now build systems that don't just provide information but actually complete complex workflows with minimal human intervention.

However, this power comes with responsibility. As these systems become more capable, it's crucial to implement proper governance structures, ensuring that AI actions align with business objectives and ethical considerations.

Looking Ahead

As both RAG and Agent technologies continue to mature, we're likely to see increasingly sophisticated applications that blur the line between knowledge systems and autonomous actors. The key will be finding the right balance between automation and human oversight, ensuring that these powerful tools enhance rather than replace human decision-making.

The future of AI isn't just about smarter systems – it's about systems that can both understand and act upon that understanding in meaningful ways. RAG and Agents are just the beginning of this transformative journey.

Saturday, December 14, 2024

Getting Started with AI: A 15-Hour Learning Journey

Want to become AI-savvy in just two weeks? Here's a focused learning path that requires only about an hour a day. This guide explores four essential themes that will transform how you interact with AI:

  1. Learning from AI Experts: How to leverage AI podcasts to build your knowledge foundation
  2. The Art of Iteration: Mastering the technique of refining your prompts to get better results
  3. Trust but Verify: Developing critical thinking skills to verify AI-generated content
  4. Smart Summarization: Converting lengthy AI conversations into powerful, reusable prompts

Let's dive into these themes through practical exercises and real-world examples that will help you harness AI effectively in your daily life.

Week 1: Building Your Foundation (7.5 hours)

Deep Dive into AI Through Podcasts (2.5 hours)

Start your journey by listening to carefully selected podcasts during your commute or daily routine. I recommend you choose only one or  two for your regular listening pleasure:

Mastering Prompt Iteration (2 hours)

Spend time practicing with AI chatbots, focusing on refining your prompts. Here's a fun example:

Initial Prompt:

"Write about dogs"

Improved Iteration:

"Write a 300-word guide about choosing the right dog breed for apartment living, including considerations for size, energy level, and noise"

Final Iteration:

"Create a comprehensive guide for apartment dwellers considering a dog. Include:

  • Top 5 breeds suited for apartment living
  • Exercise requirements for each breed
  • Noise levels and training tips
  • Space considerations
  • Estimated monthly costs

Format this as a practical guide with clear headings and bullet points"

Summary Iteration:

I often ask the chatbot to provide an improved prompt based upon the contents of the session.

  • "Please rewrite the prompts within this session into a single well-engineered prompt"

Asking the AI chatbot to rewrite your prompt really helps in deepening your understanding of prompt engineering.

And to make things interesting I sometimes ask the chatbot to rewrite the response with different literacy levels.

  • "Please rewrite this response for a grade five literacy level"
  • "Please rewrite this response for a PhD literacy level"
I actually find the response for the grade eight literacy level more interesting than the PhD level.

Using the different AI chatbots (3 hours)

There are many emerging AI chatbots, build some prompts within each. Experiment with different AI chatbots: Play, get curious, ask the AI bot to rewrite your prompt, try the rewrites against all these different chatbots, compare and contrast their responses.

  • ChatGPT: Excellent for creative writing and coding
  • Claude: Strong at analysis and detailed explanations
  • Gemini: Particularly good with multimodal tasks
  • Perplexity: Specialized in real-time information retrieval and citation

Week 2: Advanced Techniques (7.5 hours)

Verification Strategies (4 hours)

Learn to verify AI outputs effectively with these examples:

When you have Historical Facts:

"You mentioned the Wright brothers' first flight was in 1903. Can you:

  1. Provide specific sources for this date
  2. Break down the key events of that day
  3. Highlight any details you're uncertain about"

When you asked for Technical Advice:

"You've suggested this Python code solution. Can you:

  1. Explain why each line is necessary
  2. Identify potential edge cases
  3. Compare it with alternative approaches"
When you wanted Financial Analysis:

"You've provided a financial forecast for my small business. Can you:
  1. Explain the key assumptions behind your projections
  2. Identify potential economic factors that could impact these numbers
  3. Compare this forecast with industry benchmarks
  4. Highlight any areas where you have limited data or uncertainty
  5. Suggest additional data points that could improve the accuracy of this analysis"
These  are three examples of verification for your AI outputs. It is always a good idea to request verification as it reduces the AI hallucinations and increases your knowledge of the topic being discussed.

Work through the sessions from last week and write prompts to verify the information in an AI output. Spend a few hours creating verification prompts, ask the AI to write these for you. Improve upon the verification prompts, iterate.

An AI hallucination occurs when an artificial intelligence generates information that appears plausible but is factually incorrect or nonsensical. 

Session Summarization (3.5 hours)

Master the art of creating comprehensive prompts from AI sessions. Here's an example:

Original Conversation:

  • Human: "How can I improve my public speaking?"
  • AI: [Provides tips about preparation]
  • Human: "What about handling nervousness?"
  • AI: [Shares anxiety management techniques]
  • Human: "How should I structure my speech?"
  • AI: [Explains speech organization]

Summarized into Single New Prompt:

"Create a comprehensive public speaking guide for beginners that covers:

  1. Essential preparation steps
  2. Anxiety management techniques
  3. Speech structure and organization
  4. Delivery tips
  5. Common pitfalls to avoid

Include specific examples for each section and actionable steps for implementation"

Practical Exercise Examples

Try these exercises during your learning journey:

1. Content Creation:

  1.    Ask AI to write a blog post, then iterate three times, each time making it more specific
  2.    Example progression:
    •    "Write about healthy eating"
    •    "Write about healthy eating for busy professionals"
    •    "Create a 7-day meal prep guide for busy professionals who have only 30 minutes for dinner"

2. Problem Solving:

  •    Start with a complex problem like home organization
  •    Break it into smaller tasks
  •    Ask AI to verify the feasibility of each step
  •    Create a final, comprehensive action plan

Reminder: Ask AI to summarize a session and all its progressive steps into a single new prompt. Use this prompt in the different chatbots.

Key Takeaways

After completing this learning path, you'll have:

  • A solid understanding of current AI capabilities and limitations
  • Practical experience in prompt engineering
  • The ability to verify and validate AI outputs
  • Skills to maintain efficient AI conversations

Remember: Success with AI tools comes from systematic practice and refinement. Start with simple queries and gradually increase complexity as you become more comfortable with the interaction patterns.

Pro Tip: Keep a "prompt journal" documenting your most effective prompts and the situations where they worked best. This will help you develop your own library of reliable AI interaction strategies.

Tuesday, December 10, 2024

Finding Growth in the Gaps: How Career Breaks Fuel My Tech Journey

As a technology professional, I've discovered an unexpected rhythm in my career - one that turns the spaces between projects into powerful catalysts for growth. Every successful project completion brings not just a sense of accomplishment, but also a valuable gift: a few months of dedicated learning time. These self-directed sabbaticals, occurring naturally in my three-year career cycles, have become essential periods of exploration and reinvention.

Denis Hassabis and Hannah Fry
My current sabbatical feels particularly significant as I navigate the transformative world of Artificial Intelligence. Building upon my foundation in Machine Learning and data science, I've immersed myself in the AI landscape over the past two months. After exploring numerous AI podcasts, I've found two standout sources that consistently deliver valuable insights: "Google DeepMind: The Podcast" for cutting-edge AI research and developments, and "The Artificial Intelligence Show" by Marketing AI Institute for practical business applications.

This deep dive has also included extensive hands-on experimentation with leading Large Language Models (LLMs). Through countless hours working with ChatGPT, Claude, Gemini, and Perplexity, I've developed a nuanced understanding of each platform's strengths and refined my prompt engineering expertise. This practical experience has been invaluable in understanding the real-world capabilities and limitations of current AI technology.

This intensive learning period has already yielded tangible results. I've developed a comprehensive two-week learning module focused on AI fundamentals and practical applications, designed to help professionals enhance their productivity through AI tools. This resource embodies what I find most rewarding about these career interludes - the ability to synthesize new knowledge and share it with others who are eager to embrace technological advancement.

These deliberate pauses between opportunities aren't just breaks - they're investments in staying ahead of the technology curve. Each sabbatical allows me to emerge stronger, more knowledgeable, and better equipped to tackle the next challenge. In an industry that evolves at lightning speed, these learning periods have proven to be my secret weapon for sustained career growth and innovation.