<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Devpratap Tomar</title>
    <description>The latest articles on DEV Community by Devpratap Tomar (@devpratap_tomar2005).</description>
    <link>https://dev.to/devpratap_tomar2005</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3719848%2Fcb80cd0a-d1db-4d76-bc89-1a6ee813da84.png</url>
      <title>DEV Community: Devpratap Tomar</title>
      <link>https://dev.to/devpratap_tomar2005</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/devpratap_tomar2005"/>
    <language>en</language>
    <item>
      <title>Introduction to RAG (Retrieval-Augmented Generation)</title>
      <dc:creator>Devpratap Tomar</dc:creator>
      <pubDate>Mon, 30 Mar 2026 09:56:05 +0000</pubDate>
      <link>https://dev.to/devpratap_tomar2005/introduction-to-rag-retrieval-augmented-generation-mk8</link>
      <guid>https://dev.to/devpratap_tomar2005/introduction-to-rag-retrieval-augmented-generation-mk8</guid>
      <description>&lt;p&gt;I’ve been diving into &lt;strong&gt;Generative AI&lt;/strong&gt; lately, and one thing is clear: if you’ve spent any time with LLMs, you’ve probably run into their limitations. You ask an LLM a highly specific question about a new software library, your company's internal documents, or breaking news, and it either politely declines to answer or confidently makes up a complete lie.&lt;/p&gt;

&lt;p&gt;The LLMs don't know about the recent information because they are limited to knowledge available till the time they were trained. And they don’t know about your company's internal info or documents because they were never trained on them and it is not safe because anyone with access to that model can get your internal information.&lt;/p&gt;

&lt;p&gt;So, if you want the LLM to answer the questions based on information or data you provide to it without making it available publicly, how will you do it? Well there are plenty of ways by which you can make this possible. The ways are:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Fine-tuning:&lt;/strong&gt; With the fine-tuning you can train the existing AI model on your private data and users can then ask questions based on that data. It is a high computation task, time consuming and is very costly.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Large Context Window Prompting:&lt;/strong&gt; You provide all the information in your prompt and tell the LLM to answer based on your provided data only.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Although these methods can work they have their own limitations. Fine-tuning the LLM on your data is very &lt;strong&gt;costly&lt;/strong&gt; and it requires high &lt;strong&gt;resources&lt;/strong&gt; for &lt;strong&gt;computation&lt;/strong&gt; and if your information is updated you have to fine-tune again which makes it an even more expensive approach. The LLMs have limited context window and when you query  a LLM, you are not only sending a query to the user, you also send other stuff like system prompt and chat history along with your query. So, if you give large no. of information or data in prompt, you might hit the &lt;strong&gt;context window&lt;/strong&gt; limit&lt;/p&gt;

&lt;p&gt;Now, we need a solution which is cost and computation efficient and you can easily update your information without hitting the context window limit. This is where &lt;strong&gt;RAG&lt;/strong&gt; comes into the picture.&lt;/p&gt;

&lt;h2&gt;
  
  
  What is RAG?
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Retrieval-Augmented Generation (RAG)&lt;/strong&gt; is an AI framework that improves LLM &lt;strong&gt;accuracy&lt;/strong&gt; by fetching relevant, up-to-date information from external, trusted sources (like databases or company documents) before generating a response. It prevents misinformation ("hallucinations") by grounding the answer in verified data rather than relying solely on training data.&lt;/p&gt;

&lt;p&gt;The RAG is implemented in two phases:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Indexing Phase:&lt;/strong&gt; Indexing phase involves gathering the information or documents, generating embeddings and storing it in vector stores or vector DB.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Retrieval Phase:&lt;/strong&gt; This phase involves retrieving the relevant information from vector store or DB and providing it to LLM for generating response based on the user's query.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Imagine you are hosting a major award show and you have a massive script that contains every single detail. This script includes the names of all the winners, the order of every performance, and every word you need to say. The problem is that the script is far too long for you to memorize entirely, and carrying the whole book on stage is too clumsy when you need to find a specific name quickly.&lt;/p&gt;

&lt;p&gt;To solve this, you go through the script and pick out the most important facts to write on small &lt;strong&gt;cue cards&lt;/strong&gt;. Each card contains just one specific piece of information, like the winner of a single category. You keep these cards organized in a small box so you can grab the right one at the right moment. When it is time to announce the Best Actor award, you don't flip through the whole script. You simply pull out the specific cue card for that award, read the name, and announce it to the crowd.&lt;/p&gt;

&lt;p&gt;This process is exactly how RAG works. The long script represents your massive collection of data or documents. The difficulty of memorizing that script is the same as the limit on how much information an AI can "remember" or process at once. Breaking the script down into small cue cards is the same as turning your documents into small chunks. Storing those cards in a box is like putting those chunks into a vector store. Finally, finding the right card and reading the winner's name is the same as the AI finding the most relevant piece of information and using it to give you a perfect answer.&lt;/p&gt;

&lt;h2&gt;
  
  
  Components of RAG
&lt;/h2&gt;

&lt;p&gt;A RAG pipeline consists of various components which makes the implementation of indexing phase and retrieval phase possible.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Document Ingestion &amp;amp; Indexing:&lt;/strong&gt; This is responsible for gathering the information or documents from various sources and loading them.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Text Splitters:&lt;/strong&gt; This is a crucial part of a RAG pipeline because this is responsible for dividing your large documents into smaller and manageable chunks. If we don’t convert large documents into small chunks it will not give us good results at the time of retrieval.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Vector Embeddings:&lt;/strong&gt; This phase involves converting these small chunks into vector embeddings with the help of embedding models. This will help us to capture the semantic meaning of our texts.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Vector Stores &amp;amp; VectorDB:&lt;/strong&gt; Stores embeddings and enables similarity search for fast information retrieval.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Retriever:&lt;/strong&gt; Finds and returns the most relevant chunks from the database based on query similarity.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Prompt Augmentation Layer:&lt;/strong&gt; Combines retrieved chunks with the user’s query to provide context to the LLM.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The Output:&lt;/strong&gt; The LLM reads the context and provides highly accurate, hallucination-free answers.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzk3ytt8rjpkgu308ahl5.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzk3ytt8rjpkgu308ahl5.png" alt=" " width="800" height="436"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Disadvantages of RAG
&lt;/h2&gt;

&lt;p&gt;From the above discussions the advantages of RAG is clear but everything has its own limitations and disadvantages, and so does RAG. Here are some key disadvantages of RAG:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Retrieval Dependency and Quality:&lt;/strong&gt; RAG depends entirely on the retriever component. If the retriever fetches irrelevant, outdated, or incomplete data, the LLM will generate poor-quality, inaccurate, or "hallucinated" answers.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Performance and Latency Bottlenecks&lt;/strong&gt;: The extra step of searching a database (vector retrieval + generation) increases latency, making it unsuitable for some real-time applications.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;System Complexity and Maintenance:&lt;/strong&gt; Implementing and maintaining a RAG system involves managing databases, embedding models, and retrieval techniques. Updating knowledge bases requires complex re-indexing and re-embedding.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Data Security and Privacy Risks:&lt;/strong&gt; RAG systems may expose sensitive or proprietary internal data to unauthorized users if access controls are not robustly implemented.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Contextual Understanding Failures:&lt;/strong&gt; RAG systems can struggle with complex, interdisciplinary queries or connecting disparate pieces of retrieved information, leading to incoherent outputs.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Cost:&lt;/strong&gt; Running RAG systems can be expensive, requiring both vector storage infrastructure and increased compute for the retrieval and generation processes&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Chunking Errors:&lt;/strong&gt; Improperly splitting documents can cause vital information to be missing or disjointed.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Debugging Difficulties: Due to the multiple moving parts (retriever + LLM), identifying the root cause of a poor answer is complex.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;In short, RAG is a practical way to make AI smarter and more useful for your specific needs. Instead of spending a lot of time and money trying to "teach" an AI everything from scratch, RAG simply gives the AI the ability to look up facts from your own private documents before it answers a question, much like taking an open-book test.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>rag</category>
      <category>genreativeai</category>
      <category>programming</category>
    </item>
    <item>
      <title>The Evolution of Humanoid Robots: From Ancient Mythology to Futuristic Companions</title>
      <dc:creator>Devpratap Tomar</dc:creator>
      <pubDate>Tue, 20 Jan 2026 19:10:57 +0000</pubDate>
      <link>https://dev.to/devpratap_tomar2005/the-evolution-of-humanoid-robots-from-ancient-mythology-to-futuristic-companions-n14</link>
      <guid>https://dev.to/devpratap_tomar2005/the-evolution-of-humanoid-robots-from-ancient-mythology-to-futuristic-companions-n14</guid>
      <description>&lt;p&gt;&lt;strong&gt;Ancient History and Mythical Origins:&lt;/strong&gt;&lt;br&gt;
The story of humanoid robots starts not in labs or factories, but in the distant corners of human imagination. Around the 4th century BCE, Greek mythology introduced the idea of mechanical beings designed in human shape. **Hephaestus **had golden handmaidens that helped him in his forge, and Talos was a bronze automaton that protected Crete by throwing boulders at invaders. These stories showed humanity’s early interest in making life-like machines to serve and protect.&lt;/p&gt;

&lt;p&gt;Meanwhile, in the 3rd century BCE in China, a Taoist text talked about an inventive engineer named &lt;strong&gt;Yan Shi&lt;/strong&gt;. He presented a realistic mechanical figure to &lt;strong&gt;King Mu of Zhou&lt;/strong&gt;. This automaton could walk, sing, and even flirt but was taken apart when it became too convincing. These mythological stories sparked the belief that humans could someday create companions that resemble us in form and function.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;"Automaton: A self-operating machine or mechanism, often resembling a human or animal, that performs tasks automatically"&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;The Renaissance era bridged the gap, turning distant fantasies into tangible designs. In 1495, the visionary &lt;strong&gt;Leonardo da Vinci&lt;/strong&gt; sketched what is considered one of the first verifiable blueprints for a humanoid automaton: a mechanical knight wearing armor, operated by a complex system of pulleys, cables, and gears.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fra7jl7lwa1iey2125w9o.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fra7jl7lwa1iey2125w9o.webp" alt=" " width="414" height="273"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This device was designed to sit up, move its arms, and turn its head, showing da Vinci’s mix of anatomy and engineering. Although it was never built during his lifetime, it marked an important shift from myth to mechanics. It inspired future inventors to create automated, human-like figures.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The Birth of the Modern Concept (Early 20th Century):&lt;/strong&gt;&lt;br&gt;
The beginning of the 20th century turned these ideas into cultural and scientific discussions. In 1921, Czech writer &lt;strong&gt;Karel Čapek&lt;/strong&gt; introduced the term “robot” in his play &lt;em&gt;R.U.R. (Rossum’s Universal Robots)&lt;/em&gt;. The term comes from the Czech word “robota,” which means forced labor.&lt;/p&gt;

&lt;p&gt;The play showed artificial workers rising against their creators. It sparked global conversations about the ethics and risks of synthetic beings. Building on this, in 1942, science fiction author &lt;strong&gt;Isaac Asimov&lt;/strong&gt; came up with the “Three Laws of Robotics” in his short story &lt;em&gt;“Runaround.”&lt;/em&gt; These laws stated that robots must protect humans, obey orders, and keep themselves safe. These principles would shape robotics ethics in the real world for many years.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Post-War Foundations and Early Autonomy (1940s–1960s):&lt;/strong&gt;&lt;br&gt;
After World War II, advancements moved the field from fiction to prototypes. In 1949, British scientist &lt;strong&gt;William Grey Walter&lt;/strong&gt; created simple, tortoise-shaped robots. They had sensors that allowed them to navigate their environments on their own and avoid obstacles with basic feedback loops. This showed that self-directed machines were possible.&lt;/p&gt;

&lt;p&gt;Then, in the 1960s, practical industrial automation began to develop. &lt;strong&gt;George Devol&lt;/strong&gt; patented the first programmable robotic arm in 1954. &lt;strong&gt;Joseph Engelberger&lt;/strong&gt; commercialized it as &lt;strong&gt;Unimate&lt;/strong&gt;, which was installed in a **General Motors **factory in 1961 to handle hot die-cast metal parts. Although not humanoid, Unimate laid the foundation for robotic manipulation, proving that machines could perform repetitive and dangerous tasks reliably.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0ad7h9vebnx7dphjmxkx.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0ad7h9vebnx7dphjmxkx.webp" alt=" " width="607" height="332"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The Dawn of True Humanoid Robots (1970s–1980s):&lt;/strong&gt;&lt;br&gt;
The 1970s marked the emergence of real humanoid robots. In 1972, researchers at &lt;strong&gt;Waseda University&lt;/strong&gt; in Japan introduced &lt;strong&gt;WABOT-1&lt;/strong&gt;, the world’s first full-scale anthropomorphic robot. It had limbs and a head, enabling it to walk on two legs, grasp objects, and hold simple conversations using voice recognition and synthesis. This breakthrough demonstrated that it was possible to combine movement, handling objects, and interaction. Building on this success, Waseda launched &lt;strong&gt;WABOT-2&lt;/strong&gt; in 1984. This enhanced version could read sheet music and play a keyboard organ, blending robotics with art and showcasing improvements in vision and dexterity.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fjim71nydhmf8iadhwii5.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fjim71nydhmf8iadhwii5.webp" alt=" " width="447" height="366"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Mobility and Human-Like Movement (1990s–2000s):&lt;/strong&gt;&lt;br&gt;
The 1990s and early 2000s experienced fast growth in mobility and human interaction. In 2000, Honda launched &lt;strong&gt;ASIMO&lt;/strong&gt;, a compact humanoid robot that could walk, climb stairs, recognize faces and gestures, and even run at speeds of up to 3.7 miles per hour. ASIMO became a global symbol by appearing in everyday situations, like serving drinks or conducting orchestras. Soon after, in 2003, Sony introduced &lt;strong&gt;QRIO&lt;/strong&gt;, a smaller and more agile humanoid. QRIO could dance, run, and recover from falls, demonstrating its balance and flexibility.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fuy5fdfzgqdcp3tm0yyg9.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fuy5fdfzgqdcp3tm0yyg9.webp" alt=" " width="618" height="388"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Improvements And Real-World Applications:&lt;/strong&gt;&lt;br&gt;
As the decade went on, companies like Boston Dynamics made significant improvements in their physical capabilities. Their &lt;strong&gt;Atlas **robot, which developed throughout the 2010s, could perform acrobatic moves like backflips and parkour, thanks to better hydraulics and AI. In 2021, Tesla joined the effort by announcing **Optimus&lt;/strong&gt;, a general-purpose humanoid designed for household tasks. This indicated a shift toward consumer applications.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Commercialization and Mass Deployment:&lt;/strong&gt;&lt;br&gt;
This progress, from basic autonomy in the mid-20th century to more complex AI integration, has been fueled by lower hardware costs, increased computing power, and improvements in machine learning. By the 2020s, humanoid robots moved from prototypes to commercial tools, helping to fill labor shortages in aging populations and dangerous industries.&lt;/p&gt;

&lt;p&gt;Today, in early 2026, humanoid robots are being used in real-world settings. At CES 2026, more than 35 models were displayed, indicating a quick move to commercialization. For instance, UBTECH delivered over 1,000 Walker S2 units to Chinese factories in 2025 for tasks like object manipulation and navigation.&lt;/p&gt;

&lt;p&gt;Looking forward, humanoid robots are expected to play a significant role in society. By the late 2020s and into the 2030s, experts predict that 10–20 million units will be in use worldwide. This number could increase to 1–3 billion by 2050 as prices drop to $10,000-$25,000 per unit. Markets are expected to reach $38 billion by 2035 and possibly $5 trillion by 2050, with applications in manufacturing (30% share), logistics (25%), healthcare (20%), and households (15%).&lt;/p&gt;

&lt;p&gt;Advancements in AI are bringing us closer to artificial general intelligence. This will enable adaptive learning. Lighter materials and biomechanics will offer near-human dexterity for tasks like eldercare, precise surgery, and disaster response. By 2030, these technologies could automate 30% of work hours in the U.S., impacting economies and city layouts. However, we need to tackle regulatory, ethical, and social challenges, such as job loss and safety standards. China is poised to lead in scale due to government support. Still, global collaboration could lead to a time when humanoids transition from being assistants to vital partners, fulfilling the age-old visions that started it all.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>machinelearning</category>
      <category>automation</category>
      <category>programming</category>
    </item>
  </channel>
</rss>
