چگونه با استفاده از یک فایل صوتی از Gemini 1.5 Pro درخواست کنیم.
احراز هویت شروع سریع
یک کلید API ایجاد کنید و از آن با Python SDK یا یک ابزار خط فرمان مانند curl استفاده کنید.
شروع سریع OAuth
یک رویکرد ساده برای استفاده از OAuth برای احراز هویت.
شروع سریع توکن ها
مقدمه ای تعاملی برای توکن ها و نحوه استفاده از آنها در Gemini API.
جاسازی ها شروع سریع
نمونههای کد سریع که نشان میدهند چگونه شروع به تولید جاسازی کنید.
File API Quickstart
از File API برای آپلود یک فایل رسانه و گنجاندن آن در تماس GenerateContent استفاده کنید.
فراخوانی تابع
نمونه کدهایی برای کمک به شما برای شروع فراخوانی تابع.
تابع Calling Config
راهنمایی برای کسانی که قبلاً با فراخوانی تابع آشنا هستند.
درخواست شروع سریع
نحوه نوشتن و اجرای اولین دستورات خود با Gemini API.
راه اندازی سریع ایمنی
نحوه استفاده از تنظیمات ایمنی قابل تنظیم Gemini API.
پخش جریانی Quick Start
این نوت بوک جریان را در Python SDK نشان می دهد.
دستورالعمل های سیستم
نحوه ارائه دستورالعمل سیستم هنگام تولید محتوا.
تنظیم Quick Start
چگونه با تیونینگ مدل شروع کنیم.
درخواست با ویدیو
مثالی سریع از نحوه درخواست Gemini 1.5 Pro با استفاده از یک فایل ویدیویی.
شروع سریع در حالت استراحت
جاسازی Quick Start
چگونه با استفاده از کرل شروع به تولید جاسازی کنیم.
فراخوانی تابع
نمونه کدهای سریعی که نشان می دهد چگونه می توان با استفاده از curl فراخوانی تابع را شروع کرد.
شروع سریع حالت JSON
یک مثال کد که به شما نشان می دهد چگونه با استفاده از curl با حالت JSON شروع کنید.
درخواست شروع سریع
Gemini API را با استفاده از دستورات curl برای فراخوانی متدها در REST API امتحان کنید.
راه اندازی سریع ایمنی
نحوه استفاده از تنظیمات ایمنی قابل تنظیم با REST.
پخش جریانی Quick Start
این نوت بوک جریان را در REST نشان می دهد.
دستورالعمل های سیستم
نحوه شروع با دستورالعمل های سیستم با استفاده از curl.
نمونه های کد
تشخیص ناهنجاری
از جاسازیهای Gemini API برای شناسایی نقاط پرت احتمالی در مجموعه داده خود استفاده کنید.
طبقه بندی متن
از جاسازیها برای آموزش مدلی برای طبقهبندی پستها بر اساس موضوع استفاده کنید.
شکل را حدس بزنید
نحوه استفاده از چندین تصویر در یک اعلان با Gemini API.
کمپین بازاریابی
یک طرح محصول را تجزیه و تحلیل کنید و یک کمپین بازاریابی و برچسبها در قالب JSON ایجاد کنید.
با استفاده از ReAct در ویکی پدیا جستجو کنید
اجرای حداقلی ReAct: هم افزایی استدلال و عمل در مدل های زبانی
با استفاده از جاسازیهای Gemini، رتبهبندی مجدد را جستجو کنید
از جاسازیها برای رتبهبندی مجدد نتایج جستجو استفاده کنید.
نسلی برای داستان نویسی
چگونه با استفاده از زنجیره سریع و نسل تکراری داستان بنویسیم.
جستجوی سند با جاسازیها
از Gemini API برای ایجاد جاسازی استفاده کنید تا بتوانید جستجوی اسناد را انجام دهید.
[[["درک آسان","easyToUnderstand","thumb-up"],["مشکلم را برطرف کرد","solvedMyProblem","thumb-up"],["غیره","otherUp","thumb-up"]],[["اطلاعاتی که نیاز دارم وجود ندارد","missingTheInformationINeed","thumb-down"],["بیشازحد پیچیده/ مراحل بسیار زیاد","tooComplicatedTooManySteps","thumb-down"],["قدیمی","outOfDate","thumb-down"],["مشکل ترجمه","translationIssue","thumb-down"],["مشکل کد / نمونهها","samplesCodeIssue","thumb-down"],["غیره","otherDown","thumb-down"]],[],[],[],null,["# Gemini API Cookbook\n\nGemini API cookbook\n===================\n\nA collection of guides and examples for the Gemini API. Explore more in the\n[Gemini API Cookbook on GitHub.](https://github.com/google-gemini/cookbook) \n\n### Quickstart in Python\n\n[### Audio Quickstart\nHow to prompt Gemini 1.5 Pro using an audio file.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/Audio.ipynb) \n[### Authentication Quickstart\nCreate an API key and use it with the Python SDK or a command line tool like curl.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/Authentication.ipynb) \n[### OAuth Quickstart\nA simplified approach to using OAuth for authentication.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/Authentication_with_OAuth.ipynb) \n[### Tokens Quickstart\nAn interactive introduction to tokens and how they are used in the Gemini API.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/Counting_Tokens.ipynb) \n[### Embeddings Quickstart\nQuick code examples that show how to get started generating embeddings.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/Embeddings.ipynb) \n[### File API Quickstart\nUse the File API to upload a media file and include it in a GenerateContent call.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/File_API.ipynb) \n[### Function Calling\nCode examples to help you get started with function calling.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/Function_calling.ipynb) \n[### Function Calling Config\nA guide for those already familiar with function calling.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/Function_calling_config.ipynb) \n[### Prompting Quickstart\nHow to write and run your first prompts with the Gemini API.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/Prompting.ipynb) \n[### Safety Quickstart\nHow to use them the Gemini API adjustable safety settings.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/Safety.ipynb) \n[### Streaming Quickstart\nThis notebook demonstrates streaming in the Python SDK.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/Streaming.ipynb) \n[### System instructions\nHow to provide a system instruction when generating content.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/System_instructions.ipynb) \n[### Tuning Quickstart\nHow to get started with model tuning.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/Tuning.ipynb) \n[### Prompting with Video\nQuick example of how to prompt Gemini 1.5 Pro using a video file.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/Video.ipynb) \n\n### Quickstart in Rest\n\n[### Embedding Quickstart\nHow to get started generating embeddings using curl.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/rest/Embeddings_REST.ipynb) \n[### Function calling\nQuick code examples that show how to get started with function calling using curl.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/rest/Function_calling_REST.ipynb) \n[### JSON Mode Quickstart\nA code example that shows you how to get started with JSON mode using curl.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/rest/JSON_mode_REST.ipynb) \n[### Prompting Quickstart\nTry out the Gemini API using curl commands to call the methods in the REST API.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/rest/Prompting_REST.ipynb) \n[### Safety Quickstart\nHow to use adjustable safety settings with REST.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/rest/Safety_REST.ipynb) \n[### Streaming Quickstart\nThis notebook demonstrates streaming in REST.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/rest/Streaming_REST.ipynb) \n[### System instructions\nHow to get started with system instructions using curl.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/quickstarts/rest/System_instructions_REST.ipynb) \n\n### Code examples\n\n[### Anomaly detection\nUse the embeddings from the Gemini API to detect potential outliers in your dataset.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/examples/Anomaly_detection_with_embeddings.ipynb) \n[### Classify text\nUse embeddings to train a model to classify posts based on the topic.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/examples/Classify_text_with_embeddings.ipynb) \n[### Guess the shape\nHow to use multiple images in the same prompt with the Gemini API.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/examples/Guess_the_shape.ipynb) \n[### Marketing campaign\nAnalyze a product sketch and create a marketing campaign \\& taglines in JSON format.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/examples/Market_a_Jet_Backpack.ipynb) \n[### Search Wikipedia using ReAct\nMinimal implementation of ReAct: Synergizing Reasoning and Acting in Language Models](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/examples/Search_Wikipedia_using_ReAct.ipynb) \n[### Search re-ranking using Gemini embeddings\nUse embeddings to re-rank search results.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/examples/Search_reranking_using_embeddings.ipynb) \n[### Generation for Story Writing\nHow to write a story using prompt chaining and iterative generation.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/examples/Story_Writing_with_Prompt_Chaining.ipynb) \n[### Document search with embeddings\nUse the Gemini API to create embeddings so that you can perform document search.](https://colab.research.google.com/github/google-gemini/cookbook/blob/main/examples/Talk_to_documents_with_embeddings.ipynb)"]]