<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Zeeshan Hamid on Medium]]></title>
        <description><![CDATA[Stories by Zeeshan Hamid on Medium]]></description>
        <link>https://medium.com/@zeeshanhamid17?source=rss-241f81d4cab4------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*dHurQR9ACaD8-_QW</url>
            <title>Stories by Zeeshan Hamid on Medium</title>
            <link>https://medium.com/@zeeshanhamid17?source=rss-241f81d4cab4------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 04 Dec 2026 13:47:26 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@zeeshanhamid17/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Beyond the Prompt: The Three Engineering Layers Powering Production AI Agents]]></title>
            <link>https://medium.com/@zeeshanhamid17/beyond-the-prompt-the-three-engineering-layers-powering-production-ai-agents-b27841044c3c?source=rss-241f81d4cab4------2</link>
            <guid isPermaLink="false">https://medium.com/p/b27841044c3c</guid>
            <category><![CDATA[ai-engineering]]></category>
            <category><![CDATA[context-engineering]]></category>
            <category><![CDATA[agentic-ai]]></category>
            <category><![CDATA[prompt-engineering]]></category>
            <category><![CDATA[harness-engineering]]></category>
            <dc:creator><![CDATA[Zeeshan Hamid]]></dc:creator>
            <pubDate>Thu, 28 May 2026 15:48:54 GMT</pubDate>
            <atom:updated>2026-05-28T15:48:54.604Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*oc-E4M3mf0nFVJUSZp3WJg.png" /></figure><p>In 2023, prompt engineering felt like the whole job. Agent misbehaving? Tweak the system message, add a few examples, ship it.</p><p>That was fine when the stakes were low. Now that teams are pushing autonomous agents into production, with real tools, real memory, and real blast radiuses, the same uncomfortable lesson keeps coming up: writing better instructions doesn’t fix broken architecture.</p><p>When an operational agent hallucinates, it’s usually not because an adjective was off. It’s because the service catalog was missing. When it burns through thousands of dollars in an hour, it’s because it’s resending megabytes of instructions on every turn. When it takes a destructive action, nothing in the runtime was built to say no.</p><p>Getting this right means treating your system as three distinct layers.</p><p><strong>The Three Layers</strong></p><p>Think of a single agent interaction flowing from the outside in. The Harness governs the loop. Context builds the sandbox of facts. The Prompt tells the model how to think within those boundaries.</p><pre>┌─────────────────────────────────────────────────────────┐<br>│  HARNESS ENGINEERING (The Loop, Policy, RBAC, Audits)   │<br>│  ┌───────────────────────────────────────────────────┐  │<br>│  │  CONTEXT ENGINEERING (RAG, Token Economy, Facts)  │  │<br>│  │  ┌─────────────────────────────────────────────┐  │  │<br>│  │  │  PROMPT ENGINEERING (Format, Instructions)  │  │  │<br>│  │  └─────────────────────────────────────────────┘  │  │<br>│  └───────────────────────────────────────────────────┘  │<br>└─────────────────────────────────────────────────────────┘</pre><p><strong>1. Prompt Engineering: The Ask</strong></p><p>Closest to the model. You’re shaping behavior through instructions, role-setting, output formats, constraints. If you need strict JSON schemas or behavioral guardrails (“never delete data”), this is where that lives.</p><p>The ceiling is real though: prompts can’t invent facts. They can’t fix a broken tool or stand in for an approval workflow. You’re tuning how the model interprets what it receives, not whether what it receives is accurate or safe.</p><p><strong>2. Context Engineering: The Window</strong></p><p>The context window is finite and expensive, and most teams treat it like a junk drawer. Context engineering means assembling exactly what the model needs for this specific turn, not a static blob of everything.</p><p>That means graph-aware data fetches, compressed conversation histories, truncated tool logs, stripped secrets, and progressive disclosure that only surfaces detailed instructions when a specific skill is actually being used.</p><p>Two clear signals you have a context problem: the agent gives generic answers when it should know better, or your API costs creep up every time a conversation gets long.</p><p>Even perfect context won’t save you from double-committed transactions. That’s not a data problem.</p><p><strong>3. Harness Engineering: The Loop</strong></p><p>The harness is the real software engineering, the infrastructure wrapped around a probabilistic engine. It manages execution: planning, tool calls, timeouts, retries, and policy enforcement.</p><p>It’s also what stands between your agent and a 2am production incident. Sandboxing, circuit breakers, RBAC, human approval gates. None of that lives in a prompt.</p><p>Without solid context and clean prompts, the harness just becomes expensive automation with a chatbot facade. But without the harness, the other two layers are building on sand.</p><p><strong>Matching the Symptom to the Layer</strong></p><p>The most expensive debugging habit is rewriting the system prompt when the problem is somewhere else.</p><p>Failure SymptomRoot CauseFixAmbiguous output / bad formattingPoor instructions or missing examplesPrompt EngineeringHallucinations / token wasteStale data or dumping entire runbooks into contextContext EngineeringDouble-commits / budget overrunsNo policy loops, missing authHarness Engineering</p><p><strong>How Teams Actually Evolve</strong></p><p><strong>Copilot stage.</strong> Mostly prompt engineering and basic vector search. The “harness” is a rate limiter and some logs.</p><p><strong>Tool-using assistant.</strong> Context engineering becomes unavoidable. Tool outputs have to be curated per turn. The harness needs to handle execution errors without crashing.</p><p><strong>Operational agent.</strong> The harness runs the show. The agent operates under human policies, requests approvals for risky actions, and leaves an audit trail. Prompts still matter, they’re just not the bottleneck anymore.</p><p><strong>Three questions that actually divide the work:</strong></p><p>Prompt: how do I frame this request?</p><p>Context: what does the model need to know right now?</p><p>Harness: what happens when the model is wrong, and who owns that?</p><p>All three need real attention. The answer to a hard architecture problem is rarely buried in the system prompt.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b27841044c3c" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Simplifying Database Interaction with Sequelize ORM]]></title>
            <link>https://medium.com/@zeeshanhamid17/simplifying-database-interaction-with-sequelize-orm-0a07a6c5159a?source=rss-241f81d4cab4------2</link>
            <guid isPermaLink="false">https://medium.com/p/0a07a6c5159a</guid>
            <category><![CDATA[sequelize]]></category>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[mysql]]></category>
            <category><![CDATA[object-relational-mapping]]></category>
            <dc:creator><![CDATA[Zeeshan Hamid]]></dc:creator>
            <pubDate>Fri, 05 Jul 2024 08:12:59 GMT</pubDate>
            <atom:updated>2024-07-05T08:12:59.267Z</atom:updated>
            <content:encoded><![CDATA[<p>Working with databases is a fundamental part of developing web applications, but writing complex SQL queries can be a headache. That’s where Object-Relational Mapping (ORM) comes in. In this post, we’ll dive into what ORM is, how it makes our lives easier, and specifically how to use Sequelize with MySQL in a Node.js application.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*F4ObamkUd8x6ABL_sDULBg.png" /></figure><h4>What is ORM?</h4><p>ORM stands for Object-Relational Mapping. It’s a technique that allows you to interact with your database using the programming language you’re already comfortable with, instead of writing raw SQL queries. Think of it as a translator that converts the code you write in your app into the SQL that your database understands.</p><h4>Why Use ORM?</h4><ol><li><strong>Simplicity</strong>: ORM makes database operations straightforward. Instead of writing complex SQL queries, you can use familiar programming constructs.</li><li><strong>Speed</strong>: ORM reduces the amount of code you need to write, which means you can develop features faster.</li><li><strong>Flexibility</strong>: ORM tools work with different databases, making your application more adaptable.</li><li><strong>Maintainability</strong>: ORM leads to more structured and maintainable code.</li></ol><h3>Meet Sequelize</h3><p>Sequelize is a popular ORM for Node.js that supports various SQL-based databases, including MySQL. It allows you to define models (representations of your database tables) and interact with them using a clean, consistent API. You can access Sequelize official documentation here: <a href="https://sequelize.org/">https://sequelize.org/</a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/811/0*AEr6Jy9pRVTj3fPO.png" /></figure><h4>Setting Up Sequelize with MySQL</h4><p>Here’s how you can set up a Node.js project with Sequelize and MySQL:</p><blockquote>1- Install the necessary packages<br>2- Configure the database<br>3- Define Models</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/986/1*M6ik3Ct95wh5bPGsa78yxg.png" /></figure><h4>How Sequelize Simplifies Complex Queries</h4><p>Writing complex SQL queries is no fun, especially when you need to join multiple tables. Sequelize makes this process a lot more enjoyable with its powerful querying capabilities.</p><h4>Example: Fetching Data from Multiple Tables</h4><p>Let’s say we want to fetch user information along with their orders and the products in each order. Without Sequelize, you’d write a complex SQL query like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pIGr87ahNq836CgJB7dwPA.png" /></figure><p>With Sequelize, you can achieve the same result with a much simpler and more readable syntax:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*oj1QBuCZhCSd9Fs0jBMwhA.png" /></figure><h4>Why Use Sequelize for Complex Queries?</h4><ol><li><strong>Readability</strong>: The code is more readable and closer to how we think about data relationships in our application.</li><li><strong>Maintainability</strong>: Changes in the database schema are easier to handle. You only need to update the models and associations.</li><li><strong>Error Reduction</strong>: ORM handles the creation of proper joins and ensures that queries are constructed correctly, reducing the risk of SQL injection and other errors.</li></ol><h4>Conclusion</h4><p>Using Sequelize with MySQL in a Node.js application simplifies database interactions, making your code more readable, maintainable, and less prone to errors. By abstracting away the complexities of SQL queries, Sequelize allows you to focus on building features and functionality.</p><p>If you haven’t already, give Sequelize a try in your next Node.js project. You’ll appreciate how it can transform the way you interact with your database.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=0a07a6c5159a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[SQL vs. NoSQL: Choosing the Best Database for Your Next Project]]></title>
            <link>https://medium.com/@zeeshanhamid17/sql-vs-nosql-choosing-the-best-database-for-your-next-project-a2be54d64aed?source=rss-241f81d4cab4------2</link>
            <guid isPermaLink="false">https://medium.com/p/a2be54d64aed</guid>
            <category><![CDATA[database]]></category>
            <category><![CDATA[nosql]]></category>
            <category><![CDATA[data-analysis]]></category>
            <category><![CDATA[sql]]></category>
            <dc:creator><![CDATA[Zeeshan Hamid]]></dc:creator>
            <pubDate>Wed, 03 Jul 2024 06:30:03 GMT</pubDate>
            <atom:updated>2024-07-03T06:30:03.080Z</atom:updated>
            <content:encoded><![CDATA[<p>When it comes to designing systems, selecting the appropriate database is crucial. Your choice between SQL (Structured Query Language) and NoSQL (Not only SQL) databases can significantly impact the performance, scalability, and flexibility of your application. Here’s a concise guide to help you decide which database is best for your next project.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4lq9Mm3GChZbL6CN9geFkQ.png" /></figure><h3><strong>Understanding SQL Databases:</strong></h3><p>SQL (Structured Query Language) databases, also known as relational databases, are built on a structured model where data is stored in tables with predefined schemas. Each table consists of rows (entries) and columns (attributes), which define the relationships between different data points. Following are some key points regarding SQL databases</p><p><strong>Structure and Consistency:<br></strong>SQL databases enforce a structured schema, ensuring data is organized and consistent. This is ideal for applications where data integrity and relationships (like in banking or e-commerce systems) are critical.</p><p>Popular SQL databases include MySQL, PostgreSQL, Microsoft SQL Server.</p><p>Use Case: <em>E-commerce platforms rely on SQL databases to manage orders, products, and customer data due to their reliable structure and transactional support.</em></p><p><strong>Querying Power:</strong></p><p>SQL offers powerful query capabilities (SELECT, INSERT, UPDATE, DELETE), making it easy to perform complex operations like filtering, sorting, and joining data across multiple tables.</p><p><em>Use Case: Financial systems use SQL to handle complex queries and ensure accurate transaction processing.</em></p><p><strong>ACID Compliance:<br></strong>SQL databases adhere to ACID (Atomicity, Consistency, Isolation, Durability) properties, guaranteeing transactional reliability and data consistency even in high-demand environments.</p><p><strong>Scalability Challenges:</strong></p><p>While SQL databases can scale vertically (by adding more resources to a single server), horizontal scaling (across multiple servers) can be challenging due to relational constraints and ACID compliance requirements.</p><h3><strong>Understanding NoSQL Databases</strong></h3><p>NoSQL (Not only SQL) databases are designed to be more flexible and scalable than SQL databases, accommodating diverse data models and handling large volumes of unstructured or semi-structured data. Following are some key-points related to NoSQL databases</p><p><strong>Flexibility and Scalability:<br></strong>NoSQL databases are schema-less or schema-flexible, allowing them to easily adapt to changing data structures and scale horizontally by distributing data across multiple servers.</p><p>Examples: MongoDB, Redis, Apache Cassandra.</p><p><em>Use Case: Social media platforms use NoSQL (graph databases) to manage complex relationships and scale efficiently with growing user bases.</em></p><p><strong>Types of NoSQL Databases:<br></strong>Document databases (e.g., MongoDB) store data in flexible JSON-like documents, ideal for content management systems and applications with variable data structures.</p><p>Key-value stores, such as Redis, are highly effective in scenarios where quick access to data and caching are essential. For example, they excel in applications that need to manage user sessions efficiently or perform real-time analytics, where fast retrieval of data is critical for maintaining responsiveness and performance.</p><p><strong>Performance and Consistency:<br></strong>NoSQL databases prioritize performance under specific workloads but may sacrifice immediate consistency (eventual consistency model) to achieve scalability and high availability.</p><p><strong>Use Case Flexibility:<br></strong><em>NoSQL databases are well-suited for applications with dynamic data needs, such as IoT systems or real-time analytics (processing large volumes of data quickly).</em></p><h3><strong>Choosing the Right Database for Your Project</strong></h3><p>When deciding between SQL and NoSQL databases, consider these factors:<br><strong>Data Structure:</strong> If your data is structured and relational, SQL might be the better choice. For unstructured or rapidly changing data, NoSQL offers more flexibility.</p><p><strong>Scalability Needs:</strong> NoSQL databases scale horizontally more easily, making them suitable for applications expecting rapid growth or handling large data volumes.</p><p><strong>Query Complexity:</strong> SQL databases are optimal for complex queries and transactional consistency. NoSQL databases excel in simple data operations and high-performance scenarios.</p><p><strong>Operational Considerations:</strong> Evaluate deployment complexity, maintenance requirements, and your team’s expertise when choosing a database solution.</p><p><strong>Conclusion</strong></p><p>Both SQL and NoSQL databases offer unique strengths tailored to different application needs. By understanding these differences, you can make an informed decision that aligns with your project’s requirements and sets you up for success in building scalable, efficient applications.</p><p><strong>Examples of Popular Web Applications Using SQL:</strong></p><p><strong>LinkedIn:</strong> Manages user profiles, connections, job postings, and messaging.<br><strong>Amazon:</strong> Handles transactions, inventory, orders, and customer data.<br><strong>Airbnb:</strong> Manages property listings, bookings, payments, and user accounts.</p><p><strong>Examples of Popular Web Applications Using NoSQL:</strong></p><p><strong>Twitter:</strong> Stores tweets, user timelines, and follower relationships using Apache Cassandra.<br><strong>Netflix:</strong> Stores user preferences, viewing history, and content metadata using Apache Cassandra and Amazon DynamoDB.<br><strong>Instagram:</strong> Manages user profiles, photos, comments, and likes using MongoDB.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a2be54d64aed" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>