{"id":255163,"date":"2026-07-13T04:05:11","date_gmt":"2026-07-13T01:05:11","guid":{"rendered":"https:\/\/1kitap1.com\/en\/build-ai-enhanced-web-apps-theo-despoudis\/"},"modified":"2026-07-13T04:05:11","modified_gmt":"2026-07-13T01:05:11","slug":"build-ai-enhanced-web-apps-theo-despoudis","status":"publish","type":"post","link":"https:\/\/1kitap1.com\/en\/build-ai-enhanced-web-apps-theo-despoudis\/","title":{"rendered":"Build AI &#8211; Enhanced Web Apps &#8211; Theo Despoudis"},"content":{"rendered":"<figure style=\"text-align:center;margin:0 auto 1.5em;\"><img decoding=\"async\" src=\"https:\/\/1kitap1.com\/en\/wp-content\/uploads\/2026\/07\/7f74c626ffcf28a2.jpg\" alt=\" - Unknown book cover\" style=\"max-width:300px;width:100%;height:auto;box-shadow:0 4px 12px rgba(0,0,0,.25);border-radius:4px;\"\/><\/figure>\n<p>Similarity determined by closeness in the embedding space Figure 5.8 The concept of embeddings using a restaurant menu analogy. The \u201cembedding space\u201d represents a multidimensional space where both customer orders (queries) and menu items are mapped as vectors. Each menu item (e.g., spaghetti carbonara) is a precomputed vector, while the customer order is converted to a query vector. Similarity between items is determined by their proximity in this space. Attributes like \u201cpasta\u201d or \u201ccreamy\u201d represent dimensions of the embedding space. A similarity search finds the closest match and items similar to the query, mirroring how embedding-based systems in machine learning find relevant results for given inputs.<\/p>\n<p>Here\u2019s a breakdown of figure 5.8: \u00a1 Customer order as query vector\u2014The \u201ccustomer order\u201d is represented as a query vec- tor in this space. This is analogous to how a user\u2019s input or search query would be converted into a vector in an embedding-based system. \u00a1 Menu items as vectors\u2014Each menu item (spaghetti carbonara, fettuccine alfredo, and penne arrabbiata) is also represented as a vector in the same space.<\/p>\n<p>These would be precomputed embeddings of known items in the system. \u00a1 Similarity search\u2014A similarity search is performed by comparing the customer order vector to the menu item vectors within the embedding space. This rep- resents how embedding-based systems find similar items or relevant responses. \u00a1 Closest match and similar items\u2014The system can rank results based on their similar- ity to the query by comparing their distances.<\/p>\n<p>\u00a1 Attributes\u2014Each menu item is connected to various attributes (\u201cpasta,\u201d \u201ccreamy,\u201d \u201csavory,\u201d \u201cspicy\u201d). These attributes can be thought of as dimensions or features in the embedding space that contribute to the position of each item\u2019s vector.<\/p>\n<blockquote>\n<p>How to get reliable results with React, Next.js, and Vercel Using key technologies to create generative AI web applications User React (UI components) Next.js (frontend and backend) Vercel AI SDK (connects UI to AI providers) LangChain.js (LLM app framework, RAG, agents) LLMs and AI models (e.g., OpenAI, Google Gemini\u2013Default) External AI providers Build AI-Enhanced Web Apps M A N N I N G Shelter Island Theo Despoudis Build AI-Enhanced Web Apps How to get reliable results with React, Next.js, and Vercel For online information and ordering of this and other Manning books, please visit www.manning.com.<\/p>\n<p>The publisher offers discounts on this book when ordered in quantity. For more information, please contact Special Sales Department Manning Publications Co. 20 Baldwin Road PO Box 761 Shelter Island, NY 11964 Email: orders@manning.com \u00a9 2026 Manning Publications Co. All rights reserved. No part of this publication may be reproduced, stored in a retrieval system, or transmitted, in any form or by means electronic, mechanical, photocopying, or otherwise, without prior written permission of the publisher.<\/p>\n<p>Many of the designations used by manufacturers and sellers to distinguish their products are claimed as trademarks. Where those designations appear in the book, and Manning Publications was aware of a trademark claim, the designations have been printed in initial caps or all caps. Recognizing the importance of preserving what has been written, it is Manning\u2019s policy to have the books we publish printed on acid-\u00adfree paper, and we exert our best efforts to that end.<\/p>\n<p>Recognizing also our responsibility to conserve the resources of our planet, Manning books are printed on paper that is at least 15 percent recycled and processed without the use of elemental chlorine. \u221e Manning Publications Co. 20 Baldwin Road PO Box 761 Shelter Island, NY 11964 ISBN 9781633436084 Printed in the United States of America The author and publisher have made every effort to ensure that the information in this book was correct at press time. The author and publisher do not assume and hereby disclaim any liability to any party for any loss, damage, or disruption caused by errors or omissions, whether such errors or omissions result from negligence, accident, or any other cause, or from any usage of the information herein.<\/p>\n<\/blockquote>\n<p><em>This is a short excerpt from the opening of &ldquo;&rdquo; by Unknown, quoted for review and introduction purposes. All rights belong to the copyright holders.<\/em><\/p>\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_85 counter-hierarchy ez-toc-counter ez-toc-grey ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<span class=\"ez-toc-title-toggle\"><a href=\"#\" class=\"ez-toc-pull-right ez-toc-btn ez-toc-btn-xs ez-toc-btn-default ez-toc-toggle\" aria-label=\"Toggle Table of Content\"><span class=\"ez-toc-js-icon-con\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/span><\/a><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/1kitap1.com\/en\/build-ai-enhanced-web-apps-theo-despoudis\/#Book_Information\" >Book Information<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/1kitap1.com\/en\/build-ai-enhanced-web-apps-theo-despoudis\/#Reading_Word_Statistics\" >Reading &amp; Word Statistics<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/1kitap1.com\/en\/build-ai-enhanced-web-apps-theo-despoudis\/#Most_Frequent_Words\" >Most Frequent Words<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/1kitap1.com\/en\/build-ai-enhanced-web-apps-theo-despoudis\/#PDF_Download\" >PDF Download<\/a><\/li><\/ul><\/nav><\/div>\n<h2><span class=\"ez-toc-section\" id=\"Book_Information\"><\/span>Book Information<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<ul>\n<li><strong>Unique ID:<\/strong> 7f74c626ffcf28a2<\/li>\n<li><strong>File Extension:<\/strong> .pdf<\/li>\n<li><strong>File Size:<\/strong> 16,638,584 bytes (15.868 MB)<\/li>\n<li><strong>Title:<\/strong> &#8211;<\/li>\n<li><strong>Author:<\/strong> Unknown<\/li>\n<li><strong>ISBN:<\/strong> 9781633436084<\/li>\n<li><strong>Pages:<\/strong> 395<\/li>\n<li><strong>Language:<\/strong> English (en)<\/li>\n<\/ul>\n<h2><span class=\"ez-toc-section\" id=\"Reading_Word_Statistics\"><\/span>Reading &amp; Word Statistics<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<ul>\n<li><strong>Estimated Reading Time:<\/strong> 602.99 minutes<\/li>\n<li><strong>Total Words:<\/strong> 120,598<\/li>\n<li><strong>Total Characters:<\/strong> 819,268<\/li>\n<li><strong>Average Words per Page:<\/strong> 305.31<\/li>\n<li><strong>Average Characters per Page:<\/strong> 2074.1<\/li>\n<\/ul>\n<h2><span class=\"ez-toc-section\" id=\"Most_Frequent_Words\"><\/span>Most Frequent Words<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>model (622), api (599), user (523), application (497), data (485), use (426), using (425), server (415), web (392), prompt (391), text (388), key (387), const (368), langchain (347), response (341), next (339), vercel (339), example (324), input (323), code (322), function (314), sdk (312), state (284), applications (276), models (271), components (266), new (261), mcp (260), chapter (253), openai (252), tools (252), figure (240), message (239), like (236), responses (234), content (230), project (227), process (227), llm (219), document (215), client (215), chat (214), messages (212), building (205), google (199), context (193), system (191), error (191), need (191), react (190), component (188), create (183), documents (183), generative (181), testing (176), specific (172), listing (170), based (169), tool (167), page (167), information (163), users (161), embeddings (159), prompts (158), allows (156), streaming (155), rag (149), language (147), used (145), provides (145), following (145), gemini (143), provider (143), import (143), also (141), security (139), await (137), provide (136), output (135), chain (133), conversation (132), app (131), examples (131), vector (129), within (129), agent (128), integration (128), management (128), generation (128), generate (127), request (126), access (125), providers (124), different (124), return (124), run (122), summarization (121), structured (121), file (119), approach (118).<\/p>\n<h2><span class=\"ez-toc-section\" id=\"PDF_Download\"><\/span>PDF Download<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p style=\"text-align:center;\"><a href=\"https:\/\/1kitap1.com\/en\/wp-content\/uploads\/2026\/07\/build-ai-enhanced-web-apps-theo-despoudis.pdf\" download rel=\"nofollow\" style=\"display:inline-block;background:#2271b1;color:#ffffff;padding:14px 36px;border-radius:6px;text-decoration:none;font-weight:bold;font-size:1.05em;\">&#11015;&#65039; PDF Download<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Similarity determined by closeness in the embedding space Figure 5.8 The concept of embeddings using a restaurant menu analogy. The \u201cembedding space\u201d represents a multidimensional space where both customer orders (queries) and menu items are mapped as vectors. Each menu item (e.g., spaghetti carbonara) is a precomputed vector, while the customer order is converted to [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":255161,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8],"tags":[],"class_list":["post-255163","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-english"],"blocksy_meta":[],"_links":{"self":[{"href":"https:\/\/1kitap1.com\/en\/wp-json\/wp\/v2\/posts\/255163","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/1kitap1.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/1kitap1.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/1kitap1.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/1kitap1.com\/en\/wp-json\/wp\/v2\/comments?post=255163"}],"version-history":[{"count":0,"href":"https:\/\/1kitap1.com\/en\/wp-json\/wp\/v2\/posts\/255163\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/1kitap1.com\/en\/wp-json\/wp\/v2\/media\/255161"}],"wp:attachment":[{"href":"https:\/\/1kitap1.com\/en\/wp-json\/wp\/v2\/media?parent=255163"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/1kitap1.com\/en\/wp-json\/wp\/v2\/categories?post=255163"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/1kitap1.com\/en\/wp-json\/wp\/v2\/tags?post=255163"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}