재무 설계사에게 투자 추천을 제공하는 Node 기반 RAG 앱을 빌드하는 방법을 알아봅니다. 이 샘플은 Vertex AI, Cloud Run, AlloyDB, Cloud Run Functions와 통합됩니다. Angular, TypeScript, Express.js, LangChain으로 빌드되었습니다.
자동차 소유자가 제조사 설명서를 펼치지 않고도 차량 문제를 해결하는 데 도움을 주는 RAG 앱을 빌드하는 방법을 알아보세요. 변형에는 pgvector를 사용하는 Cloud SQL 및 AI Applications가 포함됩니다. Java(Spring) 및 Python(Streamlit)으로 빌드되었습니다.
중급자바
SDK 및 프레임워크
SDK 코드 스니펫을 사용하여 Google Cloud의 생성형 AI API를 사용하는 방법을 알아봅니다.
채팅 모델(Vertex AI), 벡터 데이터베이스(AlloyDB, Cloud SQL, Firestore, AI Applications, BigQuery 등), 기타 제품(Google Drive, Google 지도, YouTube 등)을 포함한 Google Cloud 제품과 함께 LangChain을 사용하기 위한 코드 스니펫을 살펴봅니다.
[[["이해하기 쉬움","easyToUnderstand","thumb-up"],["문제가 해결됨","solvedMyProblem","thumb-up"],["기타","otherUp","thumb-up"]],[["이해하기 어려움","hardToUnderstand","thumb-down"],["잘못된 정보 또는 샘플 코드","incorrectInformationOrSampleCode","thumb-down"],["필요한 정보/샘플이 없음","missingTheInformationSamplesINeed","thumb-down"],["번역 문제","translationIssue","thumb-down"],["기타","otherDown","thumb-down"]],["최종 업데이트: 2025-05-29(UTC)"],[[["\u003cp\u003eExplore pre-built generative AI sample applications that you can deploy and customize for your specific needs, including document summarization, RAG-based chat applications, and knowledge base creation.\u003c/p\u003e\n"],["\u003cp\u003eDiscover a range of sample applications demonstrating Retrieval-Augmented Generation (RAG) with various database integrations, such as Cloud SQL and AlloyDB for PostgreSQL, tailored for different use cases like an airport assistant and car troubleshooting.\u003c/p\u003e\n"],["\u003cp\u003eUtilize SDKs and frameworks like Vertex AI Gemini SDKs, Vertex AI Agent Builder SDKs, LangChain, and Genkit, in languages like Python, Node, Java, Go, and C#, to integrate generative AI capabilities into your applications.\u003c/p\u003e\n"],["\u003cp\u003eAccess numerous hands-on notebook tutorials for various generative AI tasks, including working with Gemini 1.5 Flash, analyzing sheet music and videos, and understanding text and multimodal embeddings.\u003c/p\u003e\n"],["\u003cp\u003eLearn how to implement function-calling with Gemini, and also migrate from PaLM to Gemini, along with information on supervised tuning with Gemini for specialized question-answering scenarios.\u003c/p\u003e\n"]]],[],null,["# Generative AI code samples and sample applications\n==================================================\n\nSample applications\n-------------------\n\nDeploy a prebuilt generative AI sample application, then fork the code to modify it for your own use-case.\n\n\n### [Jump Start Solution: Document Summarization](/architecture/ai-ml/generative-ai-document-summarization)\n\nDeploy a one-click sample application to summarize long documents with Vertex AI. \n\n\nBeginner\n\nPython\n\n### [Jump Start Solution: Generative AI RAG with Cloud SQL](/architecture/ai-ml/generative-ai-rag)\n\nDeploy a one-click sample application that uses vector embeddings stored in Cloud SQL to improve the accuracy of responses from a chat application. \n\n\nBeginner\n\nPython\n\n### [Jump Start Solution: Generative AI Knowledge Base](/architecture/ai-ml/generative-ai-knowledge-base)\n\nDeploy a one-click sample application that extracts question-and-answer pairs from a set of documents, along with a pipeline that triggers the application when a document is uploaded. \n\n\nBeginner\n\nPython\n\n### [Generate a marketing campaign with Gemini](https://github.com/GoogleCloudPlatform/generative-ai/tree/main/gemini/sample-apps/gemini-streamlit-cloudrun)\n\nBuild a web app to generate marketing campaign ideas, using Gemini on Vertex AI, Cloud Run, and [Streamlit](https://streamlit.io/). \n\n\nBeginner\n\nPython\n\n### [Airport Assistant: RAG App](https://github.com/GoogleCloudPlatform/genai-databases-retrieval-app)\n\nSample app for retrieval-augmented generation with AlloyDB for PostgreSQL and Vertex AI. ([blog post](https://cloud.google.com/blog/products/databases/introducing-sample-genai-databases-retrieval-app), [codelab](https://codelabs.developers.google.com/codelabs/genai-db-retrieval-app)). \n\n\nIntermediate\n\nPython\n\n### [GenWealth: RAG app](https://github.com/GoogleCloudPlatform/generative-ai/tree/main/gemini/sample-apps/genwealth)\n\nLearn to build a Node-based RAG app that provides investment recommendations for financial advisors. This sample integrates with Vertex AI, Cloud Run, AlloyDB, and Cloud Run functions. Built with Angular, TypeScript, Express.js, and LangChain. \n\n\nIntermediate\n\nNode\n\n### [Fix My Car: RAG app](https://github.com/GoogleCloudPlatform/generative-ai/tree/main/gemini/sample-apps/fixmycar)\n\nLearn to build a RAG app that helps car owners troubleshoot their vehicle, without having to flip through their owner's manual. Variants include Cloud SQL with pgvector, and AI Applications. Built with Java (Spring) and Python (Streamlit). \n\n\nIntermediate\n\nJava\n\nSDKs and Frameworks\n-------------------\n\nLearn how to work with Google Cloud's generative AI APIs using SDK code snippets.\n\n\n### [Vertex AI - Gemini SDKs](https://github.com/GoogleCloudPlatform/generative-ai/tree/main/gemini/sample-apps/genwealth)\n\nLearn how to apply the Vertex AI Gemini SDKs to tasks like chat, multimodal prompts, and document processing. [Browse additional code samples here.](/vertex-ai/docs/samples?text=gemini) \n\n\nBeginner\n\nPython\n\nNode\n\nJava\n\nGo\n\nC#\n\n### [AI Applications SDKs](https://github.com/GoogleCloudPlatform/generative-ai/tree/main/gemini/sample-apps/genwealth)\n\nLearn how to store and retrieve RAG documents using AI Applications (formerly Vertex AI Search). \n\n\nBeginner\n\nPython\n\nNode\n\nJava\n\nGo\n\nC#\n\nPHP\n\nRuby\n\n### [Browse all Google Cloud client libraries](https://github.com/GoogleCloudPlatform/generative-ai/tree/main/gemini/sample-apps/genwealth)\n\nIntegrating other products, like Cloud Storage or Firestore, into your generative AI app? Browse all Google Cloudclient libraries in your programming language of choice. \n\n\nBeginner\n\nPython\n\nNode\n\nJava\n\nGo\n\nC#\n\nPHP\n\nRuby\n\n### [LangChain (Python)](https://github.com/GoogleCloudPlatform/generative-ai/tree/main/gemini/sample-apps/genwealth)\n\nExplore code snippets for using LangChain alongside Google Cloud products, including chat models (Vertex AI), vector databases (AlloyDB, Cloud SQL, Firestore, AI Applications, BigQuery, and others), and others (Google Drive, Google Maps, YouTube, and others). \n\n\nBeginner\n\nPython\n\n### [LangChain.js (Node)](https://github.com/GoogleCloudPlatform/generative-ai/tree/main/gemini/sample-apps/genwealth)\n\nExplore code snippets for using LangChain alongside Google Cloud products, including chat models (Vertex AI), vector databases (Vertex AI Vector Search), and others (Google Search). \n\n\nBeginner\n\nNode\n\n### [Genkit (Node)](https://firebase.google.com/docs/genkit)\n\nGenkit is an open-source framework that helps you build, deploy, and monitor production-ready AI-powered web applications. Genkit comes with plugins for [Vertex AI](https://firebase.google.com/docs/genkit/plugins/vertex-ai), [Cloud Operations](https://firebase.google.com/docs/genkit/plugins/google-cloud), and [Firestore](https://firebase.google.com/docs/genkit/plugins/firebase). \n\n\nBeginner\n\nNode\n\n### [LangChain4j (Java)](https://docs.langchain4j.dev/integrations/language-models/google-gemini)\n\nExplore code snippets for using LangChain alongside Google Cloud products, including chat models (Vertex AI). \n\n\nBeginner\n\nJava\n\nNotebooks\n---------\n\nExplore hands-on walkthroughs of generative AI use cases.\n\n\n### [Getting started with Vertex AI Gemini 1.5 Flash](https://github.com/GoogleCloudPlatform/generative-ai/blob/main/gemini/getting-started/intro_gemini_1_5_flash.ipynb)\n\nLearn how to call Gemini 1.5 Flash, and leverage its long context window, using the Vertex AI SDK. This notebook includes text, video, and audio modalities. \n\n\nBeginner\n\nPython\n\n### [Sheet Music Analysis with Gemini](https://github.com/GoogleCloudPlatform/generative-ai/blob/main/gemini/use-cases/document-processing/sheet_music.ipynb)\n\nLearn how to extract sheet music metadata, such as composer and tempo, from PDFs using the Vertex AI SDK. \n\n\nBeginner\n\nPython\n\n### [Video Analysis with Gemini](https://github.com/GoogleCloudPlatform/generative-ai/blob/main/gemini/use-cases/video-analysis/video_analysis.ipynb)\n\nLearn how to analyze video sentiment, including facial expressions, using the Vertex AI SDK. \n\n\nBeginner\n\nPython\n\n### [Analyzing movie posters in BigQuery with Gemini](https://github.com/GoogleCloudPlatform/generative-ai/blob/main/gemini/use-cases/applying-llms-to-data/analyze-poster-images-in-bigquery/poster_image_analysis.ipynb)\n\nLearn how to extract information from movie posters by calling Gemini directly from BigQuery. \n\n\nIntermediate\n\nPython\n\n### [Introduction to Vertex AI Embeddings - Text \\& Multimodal](https://github.com/GoogleCloudPlatform/generative-ai/blob/main/gemini/qa-ops/intro_Vertex_AI_embeddings.ipynb)\n\nLearn how to convert text and images to vector embeddings using the Vertex AI SDK, for use in a retrieval-augmented generation (RAG) application. \n\n\nIntermediate\n\nPython\n\n### [Function-calling with Gemini](https://github.com/GoogleCloudPlatform/generative-ai/blob/main/gemini/function-calling/use_case_company_news_and_insights.ipynb)\n\nLearn how to augment Gemini's response with real-time data, such as a company's stock price and latest news. \n\n\nIntermediate\n\nPython\n\n### [Code migration from PaLM to Gemini](https://github.com/GoogleCloudPlatform/generative-ai/blob/main/language/migration/PaLM_to_gemini_codemigration.ipynb)\n\nLearn how to migrate your existing Vertex AI SDK code to call Gemini instead of PaLM. \n\n\nIntermediate\n\nPython\n\n### [Supervised Tuning with Gemini for Question-answering](https://github.com/GoogleCloudPlatform/generative-ai/blob/main/language/migration/PaLM_to_gemini_codemigration.ipynb)\n\nLearn how to tune Gemini using Vertex AI, to train the model to respond well to questions about Python coding. \n\n\nAdvanced\n\nPython\n\n### [Browse all notebooks](https://cloud.google.com/vertex-ai/generative-ai/docs/samples?doctype=notebook)\n\nExplore dozens of other Vertex AI notebooks in the Google Cloud Sample Browser. \n\n\nIntermediate\n\nPython\n\nLearn more\n----------\n\n- [All Vertex AI code samples](/vertex-ai/generative-ai/docs/samples)\n- [Google Cloud sample browser](/docs/samples)"]]