{"id":28739,"date":"2026-09-03T13:19:50","date_gmt":"2026-09-03T13:19:50","guid":{"rendered":"https:\/\/umang.pk\/2026\/09\/03\/%d8%a7%d8%b2%da%af%d8%b1-%d9%85%db%8c%da%ba-ai-%d9%81%d8%a7%d8%a6%d9%84-%d8%aa%d8%ac%d8%b2%db%8c%db%81-%d8%a7%db%8c%d8%ac%d9%86%d9%b9-%da%a9%db%8c%d8%b3%db%92-%d8%a8%d9%86%d8%a7%db%8c%d8%a7-%d8%ac\/"},"modified":"2026-09-03T13:19:50","modified_gmt":"2026-09-03T13:19:50","slug":"%d8%a7%d8%b2%da%af%d8%b1-%d9%85%db%8c%da%ba-ai-%d9%81%d8%a7%d8%a6%d9%84-%d8%aa%d8%ac%d8%b2%db%8c%db%81-%d8%a7%db%8c%d8%ac%d9%86%d9%b9-%da%a9%db%8c%d8%b3%db%92-%d8%a8%d9%86%d8%a7%db%8c%d8%a7-%d8%ac","status":"publish","type":"post","link":"https:\/\/umang.pk\/ur\/2026\/09\/03\/%d8%a7%d8%b2%da%af%d8%b1-%d9%85%db%8c%da%ba-ai-%d9%81%d8%a7%d8%a6%d9%84-%d8%aa%d8%ac%d8%b2%db%8c%db%81-%d8%a7%db%8c%d8%ac%d9%86%d9%b9-%da%a9%db%8c%d8%b3%db%92-%d8%a8%d9%86%d8%a7%db%8c%d8%a7-%d8%ac\/","title":{"rendered":"\u0627\u0632\u06af\u0631 \u0645\u06cc\u06ba AI \u0641\u0627\u0626\u0644 \u062a\u062c\u0632\u06cc\u06c1 \u0627\u06cc\u062c\u0646\u0679 \u06a9\u06cc\u0633\u06d2 \u0628\u0646\u0627\u06cc\u0627 \u062c\u0627\u0626\u06d2\u06d4"},"content":{"rendered":"\n<div id=\"\">\n<p>\u0627\u06af\u0631 \u0622\u067e \u0646\u06d2 \u06a9\u0628\u06be\u06cc 30 \u0635\u0641\u062d\u0627\u062a \u067e\u0631 \u0645\u0634\u062a\u0645\u0644 \u067e\u06cc \u0688\u06cc \u0627\u06cc\u0641 \u06a9\u06be\u0648\u0644\u06cc \u06c1\u06d2 \u0627\u0648\u0631 \u0633\u0648\u0686\u0627 \u06c1\u06d2\u060c &quot;\u0645\u06cc\u06ba \u06cc\u06c1 \u0633\u0628 \u067e\u0691\u06be\u0646\u06d2 \u06a9\u0627 \u06a9\u0648\u0626\u06cc \u0637\u0631\u06cc\u0642\u06c1 \u0646\u06c1\u06cc\u06ba \u06c1\u06d2\u060c&#8221; \u062a\u0648 \u0622\u067e \u0634\u0627\u06cc\u062f \u067e\u06c1\u0644\u06d2 \u06c1\u06cc \u0633\u0645\u062c\u06be \u06af\u0626\u06d2 \u06c1\u0648\u06ba \u06af\u06d2 \u06a9\u06c1 \u0641\u0627\u0626\u0644 \u0627\u06cc\u0646\u0627\u0644\u06cc\u0633\u0633 AI \u0627\u06cc\u062c\u0646\u0679\u0633 \u06a9\u06cc\u0648\u06ba \u06a9\u0627\u0631\u0622\u0645\u062f \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0627\u06cc\u06a9 \u062a\u062d\u0642\u06cc\u0642\u06cc \u0645\u0642\u0627\u0644\u06c1\u060c \u062f\u0648\u0628\u0627\u0631\u06c1 \u0634\u0631\u0648\u0639\u060c CSV \u0641\u0627\u0626\u0644\u060c \u06a9\u0627\u0631\u0648\u0628\u0627\u0631\u06cc \u0631\u067e\u0648\u0631\u0679 \u06cc\u0627 \u067e\u06cc \u0688\u06cc \u0627\u06cc\u0641 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u0646\u06d2 \u06a9\u0627 \u062a\u0635\u0648\u0631 \u06a9\u0631\u06cc\u06ba \u0627\u0648\u0631 \u0635\u0631\u0641 \u06cc\u06c1 \u067e\u0648\u0686\u06be\u06cc\u06ba:<\/p>\n<blockquote>\n<p>&quot;\u0622\u067e \u06a9\u06cc \u0633\u0628 \u0633\u06d2 \u0627\u06c1\u0645 \u062f\u0631\u06cc\u0627\u0641\u062a \u06a9\u06cc\u0627 \u06c1\u06d2\u061f&#8221;<\/p>\n<\/blockquote>\n<p>\u062f\u0633\u062a\u0627\u0648\u06cc\u0632\u0627\u062a \u06a9\u0648 \u062f\u0633\u062a\u06cc \u0637\u0648\u0631 \u067e\u0631 \u062a\u0644\u0627\u0634 \u06a9\u0631\u0646\u06d2 \u06a9\u06d2 \u0628\u062c\u0627\u0626\u06d2\u060c AI \u0627\u06cc\u062c\u0646\u0679 \u0641\u0627\u0626\u0644\u0648\u06ba \u06a9\u06cc \u062c\u0627\u0646\u0686 \u06a9\u0631 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u060c \u0627\u0646 \u06a9\u06d2 \u0645\u0648\u0627\u062f \u06a9\u0648 \u0633\u0645\u062c\u06be \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba \u0627\u0648\u0631 \u0627\u0646 \u06a9\u06d2 \u0628\u0627\u0631\u06d2 \u0645\u06cc\u06ba \u0633\u0648\u0627\u0644\u0627\u062a \u06a9\u06d2 \u062c\u0648\u0627\u0628\u0627\u062a \u062f\u06d2 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0627\u0633 \u0679\u06cc\u0648\u0679\u0648\u0631\u06cc\u0644 \u0645\u06cc\u06ba \u06c1\u0645 \u0635\u0631\u0641 \u0627\u0633\u06d2 \u0628\u0646\u0627\u0626\u06cc\u06ba \u06af\u06d2\u06d4 \u06c1\u0645 \u0627\u06cc\u06a9 \u0627\u0628\u062a\u062f\u0627\u0626\u06cc \u062f\u0648\u0633\u062a\u0627\u0646\u06c1 \u0645\u0627\u062d\u0648\u0644 \u0628\u0646\u0627\u0626\u06cc\u06ba \u06af\u06d2\u06d4 <strong>Python \u0645\u06cc\u06ba AI \u0641\u0627\u0626\u0644 \u062a\u062c\u0632\u06cc\u06c1 \u0627\u06cc\u062c\u0646\u0679<\/strong> \u06cc\u06c1 \u06a9\u0631 \u0633\u06a9\u062a\u0627 \u06c1\u06d2:<\/p>\n<ul>\n<li>\n<p>\u0627\u067e\u0646\u06d2 \u06a9\u0645\u067e\u06cc\u0648\u0679\u0631 \u0633\u06d2 \u0641\u0627\u0626\u0644\u06cc\u06ba \u0642\u0628\u0648\u0644 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<li>\n<p>AI \u0645\u0627\u0688\u0644 \u067e\u0631 \u0641\u0627\u0626\u0644\u06cc\u06ba \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<li>\n<p>\u0641\u0627\u0626\u0644 \u06a9\u0627 \u0645\u0648\u0627\u062f \u067e\u0691\u06be\u06cc\u06ba<\/p>\n<\/li>\n<li>\n<p>\u0641\u0637\u0631\u06cc \u0632\u0628\u0627\u0646 \u06a9\u06d2 \u0633\u0648\u0627\u0644\u0627\u062a \u06a9\u0648 \u0633\u0645\u062c\u06be\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<li>\n<p>\u0641\u0627\u0626\u0644 \u06a9\u0627 \u062a\u062c\u0632\u06cc\u06c1<\/p>\n<\/li>\n<li>\n<p>\u0645\u0641\u06cc\u062f \u062c\u0648\u0627\u0628\u0627\u062a \u0648\u0627\u067e\u0633 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<li>\n<p>\u0622\u067e \u06c1\u0631 \u0645\u0645\u06a9\u0646\u06c1 \u0633\u0648\u0627\u0644 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0627\u0644\u06af \u0641\u0646\u06a9\u0634\u0646 \u0644\u06a9\u06be\u06d2 \u0628\u063a\u06cc\u0631 \u0628\u06c1\u062a \u0633\u06d2 \u0645\u062e\u062a\u0644\u0641 \u0642\u0633\u0645 \u06a9\u06d2 \u0633\u0648\u0627\u0644\u0627\u062a \u06a9\u0648 \u06c1\u06cc\u0646\u0688\u0644 \u06a9\u0631 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<\/ul>\n<p>\u06c1\u0645 Python \u0627\u0648\u0631 OpenAI API \u06a9\u0627 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631\u062a\u06d2 \u06c1\u0648\u0626\u06d2 \u067e\u0631\u0648\u062c\u06cc\u06a9\u0679 \u0628\u0646\u0627\u0626\u06cc\u06ba \u06af\u06d2\u06d4<\/p>\n<p>\u0627\u06c1\u0645 \u062d\u0635\u06c1 \u06cc\u06c1 \u06c1\u06d2 \u06a9\u06c1 \u0622\u067e \u06a9\u0648\u0688 \u06a9\u0648 \u0635\u0631\u0641 \u06a9\u0627\u067e\u06cc \u0627\u0648\u0631 \u067e\u06cc\u0633\u0679 \u0646\u06c1\u06cc\u06ba \u06a9\u0631\u062a\u06d2 \u0627\u0648\u0631 \u0627\u0645\u06cc\u062f \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba \u06a9\u06c1 \u06cc\u06c1 \u06a9\u0627\u0645 \u06a9\u0631\u06d2 \u06af\u0627\u06d4 \u06c1\u0645 \u06a9\u0648\u0688 \u0644\u0627\u0626\u0646 \u067e\u0631 \u0644\u0627\u0626\u0646 \u06a9\u06d2 \u0630\u0631\u06cc\u0639\u06d2 \u0686\u0644\u062a\u06d2 \u06c1\u06cc\u06ba \u062a\u0627\u06a9\u06c1 \u0622\u067e \u0633\u0645\u062c\u06be \u0633\u06a9\u06cc\u06ba \u06a9\u06c1 \u06c1\u0631 \u0627\u06c1\u0645 \u062d\u0635\u06c1 \u06a9\u06cc\u0627 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0622\u062e\u0631 \u0645\u06cc\u06ba\u060c \u0622\u067e \u06a9\u0648 \u0646\u06c1 \u0635\u0631\u0641 \u06cc\u06c1 \u0633\u0645\u062c\u06be\u0646\u06d2 \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u06c1\u0648\u06af\u06cc \u06a9\u06c1 \u0627\u0633 \u067e\u0631\u0648\u062c\u06cc\u06a9\u0679 \u06a9\u0648 \u06a9\u06cc\u0633\u06d2 \u0628\u0646\u0627\u06cc\u0627 \u062c\u0627\u0626\u06d2\u060c \u0628\u0644\u06a9\u06c1 \u0628\u06c1\u062a \u0633\u06d2 \u062d\u0642\u06cc\u0642\u06cc \u062f\u0646\u06cc\u0627 \u06a9\u06d2 AI \u0627\u06cc\u062c\u0646\u0679\u0648\u06ba \u06a9\u06d2 \u0628\u0646\u06cc\u0627\u062f\u06cc \u0641\u0646 \u062a\u0639\u0645\u06cc\u0631 \u06a9\u0648 \u0628\u06be\u06cc \u0633\u0645\u062c\u06be\u0646\u0627 \u06c1\u0648\u06af\u0627\u06d4<\/p>\n<h2 id=\"heading-what-well-cover\">\u06c1\u0645 \u06a9\u06cc\u0627 \u0627\u062d\u0627\u0637\u06c1 \u06a9\u0631\u06cc\u06ba \u06af\u06d2:<\/h2>\n<h2 id=\"heading-what-are-we-actually-building\">\u06c1\u0645 \u0627\u0635\u0644 \u0645\u06cc\u06ba \u06a9\u06cc\u0627 \u0628\u0646\u0627 \u0631\u06c1\u06d2 \u06c1\u06cc\u06ba\u061f<\/h2>\n<p>\u0627\u0633 \u0633\u06d2 \u067e\u06c1\u0644\u06d2 \u06a9\u06c1 \u06c1\u0645 \u06a9\u0648\u0626\u06cc \u06a9\u0648\u0688 \u0644\u06a9\u06be\u06cc\u06ba\u060c \u0622\u0626\u06cc\u06d2 \u0627\u0633 \u06a9\u06cc \u0648\u0636\u0627\u062d\u062a \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba \u06a9\u06c1 AI \u0627\u06cc\u062c\u0646\u0679 \u06a9\u0627 \u0627\u0635\u0644 \u0645\u0637\u0644\u0628 \u06a9\u06cc\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0627\u06cc\u06a9 \u0639\u0627\u0645 AI \u0686\u06cc\u0679 \u0628\u0648\u0679 \u0627\u0633 \u0637\u0631\u062d \u06a9\u0627\u0645 \u06a9\u0631 \u0633\u06a9\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">User \u2192 Question \u2192 AI \u2192 Answer\n<\/code><\/pre>\n<p>AI \u0627\u06cc\u062c\u0646\u0679 \u0632\u06cc\u0627\u062f\u06c1 \u0644\u0686\u06a9\u062f\u0627\u0631 \u06c1\u0648 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<pre><code class=\"language-text\">User \u2192 Goal \u2192 Agent \u2192 Decide what it needs \u2192 Use tools\/data \u2192 Analyze \u2192 Answer\n<\/code><\/pre>\n<p>\u06c1\u0645\u0627\u0631\u06d2 \u067e\u0631\u0648\u062c\u06cc\u06a9\u0679 \u06a9\u06d2 \u0644\u06cc\u06d2\u060c &quot;\u0688\u06cc\u0679\u0627&#8221; \u0627\u06cc\u06a9 \u0641\u0627\u0626\u0644 \u06c1\u06d2\u06d4<\/p>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631\u060c \u06c1\u0645 \u06a9\u06c1\u062a\u06d2 \u06c1\u06cc\u06ba \u06a9\u06c1 \u0622\u067e \u0627\u067e\u0646\u06d2 \u0627\u06cc\u062c\u0646\u0679 \u06a9\u0648 \u062f\u0631\u062c \u0630\u06cc\u0644 \u062a\u062d\u0642\u06cc\u0642\u06cc \u0631\u067e\u0648\u0631\u0679 \u062f\u06cc\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">ai-research.pdf\n<\/code><\/pre>\n<p>\u067e\u06be\u0631 \u06c1\u0645 \u067e\u0648\u0686\u06be\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">What is the main argument of this paper?\n<\/code><\/pre>\n<p>\u0627\u06cc\u062c\u0646\u0679\u0648\u06ba \u06a9\u0648 \u0686\u0627\u06c1\u06cc\u06d2:<\/p>\n<ol>\n<li>\n<p>\u0645\u06cc\u06ba \u0633\u0648\u0627\u0644\u0627\u062a \u0644\u06cc\u062a\u0627 \u06c1\u0648\u06ba\u06d4<\/p>\n<\/li>\n<li>\n<p>\u0627\u067e\u0646\u06cc \u0641\u0627\u0626\u0644\u0648\u06ba \u062a\u06a9 \u0631\u0633\u0627\u0626\u06cc \u062d\u0627\u0635\u0644 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<li>\n<p>\u0627\u0633 \u06a9\u06d2 \u0628\u0627\u0631\u06d2 \u0645\u06cc\u06ba \u067e\u0691\u06be\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<li>\n<p>\u0645\u0648\u0627\u062f \u06a9\u0648 \u0633\u0645\u062c\u06be\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<li>\n<p>\u0627\u0633 \u06a9\u0627 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<li>\n<p>\u0627\u06cc\u06a9 \u062c\u0648\u0627\u0628 \u06a9\u06d2 \u0633\u0627\u062a\u06be \u0622\u0626\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<\/ol>\n<p>AI \u0645\u0627\u0688\u0644\u0632 \u0632\u0628\u0627\u0646 \u06a9\u06cc \u062a\u0641\u06c1\u06cc\u0645 \u0627\u0648\u0631 \u0627\u0633\u062a\u062f\u0644\u0627\u0644 \u06a9\u0648 \u0633\u0646\u0628\u06be\u0627\u0644\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4 \u06c1\u0645\u0627\u0631\u0627 Python \u067e\u0631\u0648\u06af\u0631\u0627\u0645 \u0627\u0633 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0648\u0631\u06a9 \u0641\u0644\u0648 \u06a9\u0648 \u06c1\u06cc\u0646\u0688\u0644 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u06cc\u06c1 \u0641\u0631\u0642 \u0627\u06c1\u0645 \u06c1\u06d2\u06d4<\/p>\n<p>\u0645\u0627\u0688\u0644 \u062c\u0627\u062f\u0648\u0626\u06cc \u0637\u0648\u0631 \u067e\u0631 \u0622\u067e \u06a9\u06d2 \u0644\u06cc\u067e \u0679\u0627\u067e \u067e\u0631 \u0641\u0627\u0626\u0644 \u0646\u06c1\u06cc\u06ba \u067e\u0691\u06be\u062a\u0627 \u06c1\u06d2\u06d4 <strong>\u06c1\u0645\u0627\u0631\u06cc \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u06a9\u0648 \u06c1\u0645\u0627\u0631\u06d2 \u0645\u0627\u0688\u0644 \u06a9\u0648 \u0641\u0627\u0626\u0644 \u062a\u06a9 \u0631\u0633\u0627\u0626\u06cc \u062f\u06cc\u0646\u06d2 \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u06c1\u06d2\u06d4<\/strong><\/p>\n<p>OpenAI \u06a9\u0627 \u0645\u0648\u062c\u0648\u062f\u06c1 API \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u062f\u06c1 \u0641\u0627\u0626\u0644\u0648\u06ba \u06a9\u0648 \u062c\u0648\u0627\u0628\u0627\u062a API \u0645\u06cc\u06ba \u0627\u0646 \u067e\u0679 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631 \u0628\u06be\u06cc\u062c\u0646\u06d2 \u06a9\u06cc \u062d\u0645\u0627\u06cc\u062a \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u060c \u062c\u0633 \u0633\u06d2 \u0645\u0627\u0688\u0644 \u06a9\u0648 \u0641\u0627\u0626\u0644\u0648\u06ba \u06a9\u0627 \u0628\u0631\u0627\u06c1 \u0631\u0627\u0633\u062a \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u0631\u0646\u06d2 \u06a9\u06cc \u0627\u062c\u0627\u0632\u062a \u0645\u0644\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-what-we-are-going-to-use\">\u06c1\u0645 \u06a9\u06cc\u0627 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631\u06cc\u06ba \u06af\u06d2<\/h2>\n<p>\u06c1\u0645\u0627\u0631\u06d2 \u067e\u0631\u0648\u062c\u06cc\u06a9\u0679 \u0645\u06cc\u06ba \u06c1\u0645 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<ul>\n<li>\n<p><strong>\u0627\u0632\u06af\u0631<\/strong>: \u06c1\u0645\u0627\u0631\u06cc \u067e\u0631\u0648\u06af\u0631\u0627\u0645\u0646\u06af \u0632\u0628\u0627\u0646<\/p>\n<\/li>\n<li>\n<p><strong>OpenAI Python SDK<\/strong>: \u0627\u0632\u06af\u0631 \u06a9\u0648 OpenAI API \u06a9\u06d2 \u0633\u0627\u062a\u06be \u0628\u0627\u062a \u0686\u06cc\u062a \u06a9\u0631\u0646\u06d2 \u06a9\u06cc \u0627\u062c\u0627\u0632\u062a \u062f\u06cc\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<\/li>\n<li>\n<p><strong>\u0631\u0633\u067e\u0627\u0646\u0633 API<\/strong>: \u0645\u0627\u0688\u0644 \u06a9\u06d2 \u0633\u0627\u062a\u06be \u062a\u0639\u0627\u0645\u0644 \u06a9\u0631\u0646\u06d2 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631\u0646\u06d2 \u06a9\u06d2 \u0644\u06cc\u06d2 API \u0627\u06cc\u0646\u0688 \u067e\u0648\u0627\u0626\u0646\u0679<\/p>\n<\/li>\n<li>\n<p><strong>\u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u062f\u06c1 \u0641\u0627\u0626\u0644<\/strong>: \u06c1\u0645\u0627\u0631\u06d2 \u0627\u06cc\u062c\u0646\u0679\u0648\u06ba \u06a9\u06cc \u0637\u0631\u0641 \u0633\u06d2 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u0631\u0646\u06d2 \u0648\u0627\u0644\u06cc \u0645\u0639\u0644\u0648\u0645\u0627\u062a<\/p>\n<\/li>\n<li>\n<p><strong>\u0641\u0648\u0631\u06cc<\/strong>: \u06c1\u062f\u0627\u06cc\u0627\u062a \u062c\u0648 \u0627\u06cc\u062c\u0646\u0679 \u06a9\u0648 \u0628\u062a\u0627\u062a\u06cc \u06c1\u06cc\u06ba \u06a9\u06c1 \u06a9\u06cc\u0627 \u06a9\u0631\u0646\u0627 \u06c1\u06d2\u06d4<\/p>\n<\/li>\n<\/ul>\n<p>\u06c1\u0645 \u062c\u0627\u0646 \u0628\u0648\u062c\u06be \u06a9\u0631 \u067e\u06c1\u0644\u06d2 \u0648\u0631\u0698\u0646 \u06a9\u0648 \u0633\u0627\u062f\u06c1 \u0631\u06a9\u06be\u06cc\u06ba \u06af\u06d2\u06d4<\/p>\n<p>LangChain\u060c \u0648\u06cc\u06a9\u0679\u0631 \u0688\u06cc\u0679\u0627 \u0628\u06cc\u0633\u060c React \u06cc\u0627 \u06a9\u0633\u06cc \u067e\u06cc\u0686\u06cc\u062f\u06c1 \u067e\u0633\u062f\u06cc\u062f \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u0646\u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0627\u06cc\u06a9 \u0628\u0627\u0631 \u062c\u0628 \u0622\u067e \u0627\u0633 \u0648\u0631\u0698\u0646 \u06a9\u0648 \u0633\u0645\u062c\u06be \u0644\u06cc\u06ba\u060c \u062a\u0648 \u0622\u067e \u0628\u0639\u062f \u0645\u06cc\u06ba \u0627\u0646 \u0645\u06c1\u0627\u0631\u062a\u0648\u06ba \u06a9\u0648 \u0634\u0627\u0645\u0644 \u06a9\u0631 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<h2 id=\"heading-what-you-should-know-before-starting\">\u0634\u0631\u0648\u0639 \u06a9\u0631\u0646\u06d2 \u0633\u06d2 \u067e\u06c1\u0644\u06d2 \u0622\u067e \u06a9\u0648 \u06a9\u06cc\u0627 \u062c\u0627\u0646\u0646\u06d2 \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u06c1\u06d2\u06d4<\/h2>\n<p>\u06cc\u06c1 \u0679\u06cc\u0648\u0679\u0648\u0631\u06cc\u0644 \u0627\u0628\u062a\u062f\u0627\u0626\u06cc \u0627\u0648\u0631 \u0627\u0646\u0679\u0631\u0645\u06cc\u0688\u06cc\u0679 \u0688\u0648\u06cc\u0644\u067e\u0631\u0632 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0688\u06cc\u0632\u0627\u0626\u0646 \u06a9\u06cc\u0627 \u06af\u06cc\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0622\u067e \u06a9\u0648 \u0645\u0646\u062f\u0631\u062c\u06c1 \u0630\u06cc\u0644 \u0628\u0646\u06cc\u0627\u062f\u06cc Python \u062a\u0635\u0648\u0631\u0627\u062a \u0633\u06d2 \u0648\u0627\u0642\u0641 \u06c1\u0648\u0646\u0627 \u0686\u0627\u06c1\u06cc\u06d2:<\/p>\n<p>\u062a\u0645 \u06c1\u0648 <strong>~ \u0646\u06c1\u06cc\u06ba<\/strong> \u0622\u067e \u06a9\u0648 \u0645\u0634\u06cc\u0646 \u0644\u0631\u0646\u0646\u06af\u060c \u0679\u0631\u0627\u0646\u0633\u0641\u0627\u0631\u0645\u0631\u0632 \u0627\u0646\u062f\u0631\u0648\u0646\u06cc \u0637\u0648\u0631 \u067e\u0631 \u06a9\u06cc\u0633\u06d2 \u06a9\u0627\u0645 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u060c \u06cc\u0627 \u0628\u0691\u06d2 \u0644\u06cc\u0646\u06af\u0648\u06cc\u062c \u0645\u0627\u0688\u0644\u0632 \u06a9\u06d2 \u067e\u06cc\u0686\u06be\u06d2 \u0631\u06cc\u0627\u0636\u06cc \u062c\u0627\u0646\u0646\u06d2 \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u06c1\u06d2\u06d4<\/p>\n<p>\u06cc\u06c1\u0627\u06ba \u062a\u0648\u062c\u06c1 \u0627\u0633 \u0628\u0627\u062a \u067e\u0631 \u06c1\u06d2 \u06a9\u06c1 \u0627\u06cc\u06a9 \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u06a9\u06cc\u0633\u06d2 \u0628\u0646\u0627\u0626\u06cc \u062c\u0627\u0626\u06d2\u06d4<\/p>\n<h2 id=\"heading-step-1-create-the-project\">\u0645\u0631\u062d\u0644\u06c1 1: \u0627\u06cc\u06a9 \u067e\u0631\u0648\u062c\u06cc\u06a9\u0679 \u0628\u0646\u0627\u0626\u06cc\u06ba<\/h2>\n<p>\u0633\u0628 \u0633\u06d2 \u067e\u06c1\u0644\u06d2\u060c \u0627\u06cc\u06a9 \u067e\u0631\u0648\u062c\u06cc\u06a9\u0679 \u0641\u0648\u0644\u0688\u0631 \u0628\u0646\u0627\u0626\u06cc\u06ba.<\/p>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631:<\/p>\n<pre><code class=\"language-text\">file-analysis-agent\/\n<\/code><\/pre>\n<p>\u0627\u0633 \u0645\u06cc\u06ba \u0628\u0627\u0644\u0622\u062e\u0631 \u0634\u0627\u0645\u0644 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">file-analysis-agent\/\n\u2502\n\u251c\u2500\u2500 agent.py\n\u251c\u2500\u2500 requirements.txt\n\u2514\u2500\u2500 .env\n<\/code><\/pre>\n<p>\u06c1\u0631 \u0641\u0627\u0626\u0644 \u06a9\u0627 \u0627\u06cc\u06a9 \u0645\u0642\u0635\u062f \u06c1\u0648\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<ol>\n<li>\n<p><code>agent.py<\/code>: \u06cc\u06c1 \u0648\u06c1 \u062c\u06af\u06c1 \u06c1\u06d2 \u062c\u06c1\u0627\u06ba Python \u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646 \u0631\u06c1\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<\/li>\n<li>\n<p><code>requirements.txt<\/code>: \u06cc\u06c1 Python \u06a9\u0648 \u0628\u062a\u0627\u062a\u0627 \u06c1\u06d2 \u06a9\u06c1 \u0622\u067e \u06a9\u06d2 \u067e\u0631\u0648\u062c\u06cc\u06a9\u0679 \u06a9\u0648 \u06a9\u0646 \u0628\u06cc\u0631\u0648\u0646\u06cc \u067e\u06cc\u06a9\u06cc\u062c\u0632 \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u06c1\u06d2\u06d4<\/p>\n<\/li>\n<li>\n<p><code>.env<\/code>: \u06cc\u06c1 \u0648\u06c1 \u062c\u06af\u06c1 \u06c1\u06d2 \u062c\u06c1\u0627\u06ba \u0622\u067e \u0627\u067e\u0646\u06cc API \u06a9\u0644\u06cc\u062f \u06a9\u0648 \u0628\u0631\u0627\u06c1 \u0631\u0627\u0633\u062a \u0627\u067e\u0646\u06d2 Python \u06a9\u0648\u0688 \u0645\u06cc\u06ba \u062f\u0627\u062e\u0644 \u06a9\u0631\u0646\u06d2 \u06a9\u06d2 \u0628\u062c\u0627\u0626\u06d2 \u0645\u0642\u0627\u0645\u06cc \u0637\u0648\u0631 \u067e\u0631 \u0627\u0633\u0679\u0648\u0631 \u06a9\u0631\u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<\/ol>\n<p>\u0645\u0627\u062e\u0630 \u06a9\u0648\u0688 \u0645\u06cc\u06ba \u0631\u0627\u0632\u062f\u0627\u0631\u06cc \u06a9\u0648 \u0628\u0631\u0642\u0631\u0627\u0631 \u0631\u06a9\u06be\u0646\u0627 \u0627\u0628\u062a\u062f\u0627\u0626\u06cc \u062a\u0631\u0642\u06cc \u0645\u06cc\u06ba \u0627\u06cc\u06a9 \u0627\u06c1\u0645 \u0639\u0627\u062f\u062a \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-step-2-create-a-virtual-environment\">\u0645\u0631\u062d\u0644\u06c1 2: \u0627\u06cc\u06a9 \u0648\u0631\u0686\u0648\u0626\u0644 \u0645\u0627\u062d\u0648\u0644 \u0628\u0646\u0627\u0626\u06cc\u06ba<\/h2>\n<p>\u0627\u067e\u0646\u06d2 \u067e\u0631\u0648\u062c\u06cc\u06a9\u0679 \u0641\u0648\u0644\u0688\u0631 \u0645\u06cc\u06ba \u0679\u0631\u0645\u06cc\u0646\u0644 \u06a9\u06be\u0648\u0644\u06cc\u06ba\u06d4<\/p>\n<p>\u0686\u0644\u0627\u0626\u06cc\u06ba:<\/p>\n<pre><code class=\"language-bash\">python -m venv venv\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0627\u0632\u06af\u0631 \u06a9\u0627 \u0648\u0631\u0686\u0648\u0626\u0644 \u0645\u0627\u062d\u0648\u0644 \u0628\u0646\u0627\u0626\u06d2 \u06af\u0627\u06d4<\/p>\n<p>\u0627\u06cc\u06a9 \u0648\u0631\u0686\u0648\u0626\u0644 \u0645\u0627\u062d\u0648\u0644 \u0622\u067e \u06a9\u06d2 \u067e\u0631\u0648\u062c\u06cc\u06a9\u0679 \u06a9\u0648 \u0627\u0632\u06af\u0631 \u067e\u06cc\u06a9\u062c\u0648\u06ba \u06a9\u0627 \u0627\u067e\u0646\u0627 \u0627\u0644\u06af \u062a\u06be\u0644\u06af \u0645\u062c\u0645\u0648\u0639\u06c1 \u0641\u0631\u0627\u06c1\u0645 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4 \u0627\u0633 \u06a9\u06d2 \u0628\u0627\u0631\u06d2 \u0645\u06cc\u06ba \u0633\u0648\u0686\u06cc\u06ba \u062c\u06cc\u0633\u06d2 \u0627\u0633 \u067e\u0631\u0648\u062c\u06cc\u06a9\u0679 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0627\u06cc\u06a9 \u0686\u06be\u0648\u0679\u0627 Python \u0648\u0631\u06a9 \u0627\u0633\u067e\u06cc\u0633 \u0641\u0631\u0627\u06c1\u0645 \u06a9\u0631\u0646\u0627\u06d4<\/p>\n<p>\u0622\u067e \u0627\u0633\u06d2 \u0648\u0646\u0688\u0648\u0632 \u067e\u0631 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631 \u06a9\u06d2 \u0686\u0627\u0644\u0648 \u06a9\u0631 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-bash\">venv\\Scripts\\activate\n<\/code><\/pre>\n<p>macOS \u06cc\u0627 Linux \u06a9\u06d2 \u0644\u06cc\u06d2:<\/p>\n<pre><code class=\"language-bash\">source venv\/bin\/activate\n<\/code><\/pre>\n<p>\u0627\u06cc\u06a9 \u0628\u0627\u0631 \u0686\u0627\u0644\u0648 \u06c1\u0648\u0646\u06d2 \u06a9\u06d2 \u0628\u0639\u062f\u060c \u0622\u067e \u06a9\u0648 \u0645\u0646\u062f\u0631\u062c\u06c1 \u0630\u06cc\u0644 \u06a9\u06cc \u0637\u0631\u062d \u06a9\u0686\u06be \u0646\u0638\u0631 \u0622\u0626\u06d2 \u06af\u0627:<\/p>\n<pre><code class=\"language-text\">(venv)\n<\/code><\/pre>\n<p>\u0679\u0631\u0645\u06cc\u0646\u0644 \u067e\u0631\u0627\u0645\u067e\u0679 \u06a9\u06d2 \u0634\u0631\u0648\u0639 \u0645\u06cc\u06ba\u06d4<\/p>\n<h2 id=\"heading-step-3-install-the-openai-sdk\">\u0645\u0631\u062d\u0644\u06c1 3: OpenAI SDK \u0627\u0646\u0633\u0679\u0627\u0644 \u06a9\u0631\u06cc\u06ba\u06d4<\/h2>\n<p>\u0627\u0628 \u0622\u0641\u06cc\u0634\u0644 OpenAI Python \u067e\u06cc\u06a9\u06cc\u062c \u0627\u0646\u0633\u0679\u0627\u0644 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<pre><code class=\"language-bash\">pip install openai\n<\/code><\/pre>\n<p>SDK Python \u06a9\u06cc \u06a9\u0644\u0627\u0633\u06cc\u06ba \u0627\u0648\u0631 \u0637\u0631\u06cc\u0642\u06d2 \u0645\u06c1\u06cc\u0627 \u06a9\u0631\u062a\u0627 \u06c1\u06d2 \u062c\u0648 API \u06a9\u0627\u0644\u0632 \u06a9\u0648 \u0628\u06c1\u062a \u0622\u0633\u0627\u0646 \u0628\u0646\u0627 \u062f\u06cc\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>SDK \u06a9\u06d2 \u0628\u063a\u06cc\u0631\u060c \u0622\u067e \u06a9\u0648 HTTP \u062f\u0631\u062e\u0648\u0627\u0633\u062a\u0648\u06ba \u06a9\u0648 \u062f\u0633\u062a\u06cc \u0637\u0648\u0631 \u067e\u0631 \u06a9\u0646\u0641\u06cc\u06af\u0631 \u06a9\u0631\u0646\u0627 \u06c1\u0648\u06af\u0627\u06d4<\/p>\n<p>SDK \u0622\u067e \u06a9\u0648 \u0627\u0632\u06af\u0631 \u06a9\u0648 \u0627\u0633 \u0637\u0631\u062d \u0644\u06a9\u06be\u0646\u06d2 \u06a9\u06cc \u0627\u062c\u0627\u0632\u062a \u062f\u06cc\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-python\">client.responses.create(...)\n<\/code><\/pre>\n<p>\u067e\u0648\u0631\u06cc HTTP \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u06a9\u0648 \u062f\u0633\u062a\u06cc \u0637\u0648\u0631 \u067e\u0631 \u0628\u0646\u0627\u0646\u06d2 \u06a9\u06d2 \u0628\u062c\u0627\u0626\u06d2\u06d4<\/p>\n<p>\u0627\u0648\u067e\u0646 \u0627\u06d2 \u0622\u0626\u06cc \u06a9\u0648\u0626\u06cc\u06a9 \u0633\u0679\u0627\u0631\u0679 \u0641\u06cc \u0627\u0644\u062d\u0627\u0644 \u0631\u06cc\u0633\u067e\u0627\u0646\u0633 API \u06a9\u0648 API \u062f\u0631\u062e\u0648\u0627\u0633\u062a\u0648\u06ba \u06a9\u06d2 \u0646\u0642\u0637\u06c1 \u0622\u063a\u0627\u0632 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-step-4-create-your-api-key\">\u0645\u0631\u062d\u0644\u06c1 4: \u0627\u06cc\u06a9 API \u06a9\u0644\u06cc\u062f \u0628\u0646\u0627\u0626\u06cc\u06ba<\/h2>\n<p>API \u06a9\u06d2 \u0633\u0627\u062a\u06be \u0628\u0627\u062a \u0686\u06cc\u062a \u06a9\u0631\u0646\u06d2 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0622\u067e \u06a9\u0648 \u0627\u06cc\u06a9 OpenAI API \u06a9\u0644\u06cc\u062f \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u06c1\u06d2\u06d4 \u0627\u067e\u0646\u06d2 OpenAI \u0688\u0648\u06cc\u0644\u067e\u0631 \u0627\u06a9\u0627\u0624\u0646\u0679 \u06a9\u06d2 \u0630\u0631\u06cc\u0639\u06d2 \u0627\u06cc\u06a9 API \u06a9\u0644\u06cc\u062f \u0628\u0646\u0627\u0626\u06cc\u06ba\u06d4<\/p>\n<p>\u06a9\u0631\u0648 <strong>~ \u0646\u06c1\u06cc\u06ba<\/strong> \u0627\u067e\u0646\u06cc \u0627\u0635\u0644 API \u06a9\u0644\u06cc\u062f \u0628\u0631\u0627\u06c1 \u0631\u0627\u0633\u062a \u0627\u067e\u0646\u06d2 \u0633\u0648\u0631\u0633 \u06a9\u0648\u0688 \u0645\u06cc\u06ba \u062f\u0631\u062c \u06a9\u0631\u06cc\u06ba\u060c \u0627\u0633 \u0637\u0631\u062d:<\/p>\n<pre><code class=\"language-python\">api_key = \"sk-your-real-key\"\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0627\u06cc\u06a9 \u0628\u0631\u06cc \u0639\u0627\u062f\u062a \u06c1\u06d2\u06d4<\/p>\n<p>\u062c\u0628 \u0622\u067e \u0627\u067e\u0646\u0627 \u067e\u0631\u0648\u062c\u06cc\u06a9\u0679 GitHub \u067e\u0631 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u060c \u062a\u0648 \u0622\u067e \u06a9\u06cc \u0686\u0627\u0628\u06cc\u0627\u06ba \u062d\u0627\u062f\u062b\u0627\u062a\u06cc \u0637\u0648\u0631 \u067e\u0631 \u0633\u0627\u0645\u0646\u06d2 \u0622 \u0633\u06a9\u062a\u06cc \u06c1\u06cc\u06ba\u06d4 \u0627\u0633 \u06a9\u06d2 \u0628\u062c\u0627\u0626\u06d2\u060c \u0627\u0633\u06d2 \u0645\u0627\u062d\u0648\u0644\u06cc\u0627\u062a\u06cc \u0645\u062a\u063a\u06cc\u0631 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631 \u0645\u062d\u0641\u0648\u0638 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631\u060c Windows PowerShell \u0645\u06cc\u06ba:<\/p>\n<pre><code class=\"language-powershell\">$env:OPENAI_API_KEY=\"your_api_key_here\"\n<\/code><\/pre>\n<p>macOS\/Linux \u06a9\u06d2 \u0644\u06cc\u06d2:<\/p>\n<pre><code class=\"language-bash\">export OPENAI_API_KEY=\"your_api_key_here\"\n<\/code><\/pre>\n<p>OpenAI SDK \u062e\u0648\u062f \u0628\u062e\u0648\u062f <code>OPENAI_API_KEY<\/code> \u0645\u0627\u062d\u0648\u0644\u06cc\u0627\u062a\u06cc \u0645\u062a\u063a\u06cc\u0631\u0627\u062a\u06d4<\/p>\n<h2 id=\"heading-step-5-create-requirementstxt\">\u0645\u0631\u062d\u0644\u06c1 5: \u0628\u0646\u0627\u0626\u06cc\u06ba <code>requirements.txt<\/code><\/h2>\n<p>\u0646\u0627\u0645 \u06a9\u06cc \u0627\u06cc\u06a9 \u0641\u0627\u0626\u0644 \u0628\u0646\u0627\u0626\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">requirements.txt\n<\/code><\/pre>\n<p>\u0627\u0633\u06d2 \u0627\u0646\u062f\u0631 \u0631\u06a9\u06be\u0648:<\/p>\n<pre><code class=\"language-text\">openai\n<\/code><\/pre>\n<p>\u0627\u0628 \u062f\u0648\u0633\u0631\u06d2 \u0688\u0648\u06cc\u0644\u067e\u0631 \u0622\u067e \u06a9\u06d2 \u067e\u0631\u0648\u062c\u06cc\u06a9\u0679 \u06a9\u06cc \u0627\u0646\u062d\u0635\u0627\u0631 \u06a9\u0648 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631\u06a9\u06d2 \u0627\u0646\u0633\u0679\u0627\u0644 \u06a9\u0631\u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-bash\">pip install -r requirements.txt\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0627\u06cc\u06a9 \u0686\u06be\u0648\u0679\u06cc \u0633\u06cc \u0628\u0627\u062a \u06c1\u06d2\u060c \u0644\u06cc\u06a9\u0646 \u0627\u06cc\u06a9 \u0628\u06c1\u062a \u0645\u0641\u06cc\u062f \u067e\u06cc\u0634\u06c1 \u0648\u0631\u0627\u0646\u06c1 \u0639\u0627\u062f\u062a \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-step-6-create-the-python-file\">\u0645\u0631\u062d\u0644\u06c1 6: \u0627\u0632\u06af\u0631 \u0641\u0627\u0626\u0644 \u0628\u0646\u0627\u0626\u06cc\u06ba<\/h2>\n<p>\u0628\u0646\u0627\u0646\u0627:<\/p>\n<pre><code class=\"language-text\">agent.py\n<\/code><\/pre>\n<p>\u06a9\u06d2 \u0633\u0627\u062a\u06be \u0634\u0631\u0648\u0639 \u06a9\u0631\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">from openai import OpenAI\n<\/code><\/pre>\n<p>\u0622\u0626\u06cc\u06d2 \u0627\u0633 \u06a9\u0627 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<ul>\n<li>\n<p><code>from<\/code>: \u0627\u0632\u06af\u0631 \u0645\u06cc\u06ba <code>from<\/code> \u0645\u0637\u0644\u0648\u0628\u06c1 \u0627\u0644\u0641\u0627\u0638 \u0622\u067e \u06a9\u0648 \u06a9\u0633\u06cc \u062f\u0648\u0633\u0631\u06d2 \u0645\u0627\u0688\u06cc\u0648\u0644 \u0633\u06d2 \u06a9\u0686\u06be \u062f\u0631\u0622\u0645\u062f \u06a9\u0631\u0646\u06d2 \u06a9\u06cc \u0627\u062c\u0627\u0632\u062a \u062f\u06cc\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<li>\n<p><code>openai<\/code>: \u06cc\u06c1 Python \u067e\u06cc\u06a9\u06cc\u062c \u06c1\u06d2 \u062c\u0648 \u06c1\u0645 \u0646\u06d2 \u0627\u0646\u0633\u0679\u0627\u0644 \u06a9\u06cc\u0627 \u06c1\u06d2\u06d4<\/p>\n<\/li>\n<li>\n<p><code>import OpenAI<\/code>: \u06c1\u0645 \u06c1\u06cc\u06ba\u06d4 <code>OpenAI<\/code> \u06cc\u06c1 \u0627\u0633 \u067e\u06cc\u06a9\u06cc\u062c \u06a9\u06cc \u06a9\u0644\u0627\u0633 \u06c1\u06d2\u06d4<\/p>\n<\/li>\n<\/ul>\n<p>\u0627\u0628 \u0622\u067e OpenAI \u06a9\u0644\u0627\u0626\u0646\u0679 \u0628\u0646\u0627 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0634\u0627\u0645\u0644 \u06a9\u0631\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">client = OpenAI()\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0627\u06cc\u06a9 API \u06a9\u0644\u0627\u0626\u0646\u0679 \u0628\u0646\u0627\u0626\u06d2 \u06af\u0627\u06d4<\/p>\n<p>\u0622\u067e \u0633\u0648\u0686 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba <code>client<\/code> \u06cc\u06c1 OpenAI API \u0633\u06d2 \u0622\u067e \u06a9\u06cc \u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646 \u06a9\u06d2 \u06a9\u0646\u06a9\u0634\u0646 \u067e\u0648\u0627\u0626\u0646\u0679 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631 \u06a9\u0627\u0645 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4 \u062c\u0628 \u0628\u06be\u06cc \u0622\u067e API \u06a9\u06d2 \u0633\u0627\u062a\u06be \u0628\u0627\u062a \u0686\u06cc\u062a \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba \u062a\u0648 \u0622\u067e \u0627\u0633 \u06a9\u0644\u0627\u0626\u0646\u0679 \u06a9\u0648 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631:<\/p>\n<pre><code class=\"language-python\">response = client.responses.create(...)\n<\/code><\/pre>\n<p>\u06a9\u0644\u0627\u0626\u0646\u0679 \u06c1\u0645\u0627\u0631\u06d2 \u0644\u06cc\u06d2 \u0628\u0646\u06cc\u0627\u062f\u06cc HTTP \u0645\u0648\u0627\u0635\u0644\u062a \u06a9\u0648 \u06c1\u06cc\u0646\u0688\u0644 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-step-7-ask-the-user-for-a-file\">\u0645\u0631\u062d\u0644\u06c1 7: \u0635\u0627\u0631\u0641 \u0633\u06d2 \u0641\u0627\u0626\u0644 \u06a9\u06cc \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u06a9\u0631\u06cc\u06ba\u06d4<\/h2>\n<p>\u06c1\u0645 \u0635\u0627\u0631\u0641 \u06a9\u0648 \u0627\u067e\u0646\u06cc \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u0645\u06cc\u06ba \u0627\u06cc\u06a9 \u0641\u0627\u0626\u0644 \u06a9\u06cc \u0648\u0636\u0627\u062d\u062a \u06a9\u0631\u0646\u06d2 \u06a9\u06cc \u0627\u062c\u0627\u0632\u062a \u062f\u06cc\u0646\u0627 \u0686\u0627\u06c1\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0634\u0627\u0645\u0644 \u06a9\u0631\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">file_path = input(\"Enter the path to your file: \")\n<\/code><\/pre>\n<p>\u0622\u0626\u06cc\u06d2 \u0627\u0628 \u0627\u0633 \u0644\u0627\u0626\u0646 \u06a9\u0648 \u0633\u0645\u062c\u06be\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u06a9\u06c1 <code>input()<\/code> \u0641\u0646\u06a9\u0634\u0646 \u0635\u0627\u0631\u0641 \u06a9\u06d2 \u06a9\u0686\u06be \u062f\u0627\u062e\u0644 \u06a9\u0631\u0646\u06d2 \u06a9\u0627 \u0627\u0646\u062a\u0638\u0627\u0631 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631\u060c \u0622\u067e \u06a9\u0627 \u0679\u0631\u0645\u06cc\u0646\u0644 \u0638\u0627\u06c1\u0631 \u06a9\u0631 \u0633\u06a9\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">Enter the path to your file:\n<\/code><\/pre>\n<p>\u0635\u0627\u0631\u0641\u06cc\u0646 \u062f\u0631\u062c \u06a9\u0631 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">research.pdf\n<\/code><\/pre>\n<p>\u0627\u0632\u06af\u0631 \u0627\u0633 \u0645\u062a\u0646 \u06a9\u0648 \u0627\u0646\u062f\u0631 \u0627\u0633\u0679\u0648\u0631 \u06a9\u0631\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-python\">file_path\n<\/code><\/pre>\n<p>\u0644\u06c1\u0630\u0627 \u0635\u0627\u0631\u0641 \u06a9\u06d2 \u062f\u0627\u062e\u0644 \u06c1\u0648\u0646\u06d2 \u06a9\u06d2 \u0628\u0639\u062f:<\/p>\n<pre><code class=\"language-text\">research.pdf\n<\/code><\/pre>\n<p>\u06c1\u0645 \u0645\u0624\u062b\u0631 \u0637\u0631\u06cc\u0642\u06d2 \u0633\u06d2:<\/p>\n<pre><code class=\"language-python\">file_path = \"research.pdf\"\n<\/code><\/pre>\n<p>\u0627\u0628 \u06c1\u0645\u0627\u0631\u0627 \u067e\u0631\u0648\u06af\u0631\u0627\u0645 \u062c\u0627\u0646\u062a\u0627 \u06c1\u06d2 \u06a9\u06c1 \u0622\u067e \u06a9\u0633 \u0641\u0627\u0626\u0644 \u06a9\u0627 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u0631\u0646\u0627 \u0686\u0627\u06c1\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<h2 id=\"heading-step-8-check-whether-the-file-exists\">\u0645\u0631\u062d\u0644\u06c1 8: \u0686\u06cc\u06a9 \u06a9\u0631\u06cc\u06ba \u06a9\u06c1 \u0622\u06cc\u0627 \u0641\u0627\u0626\u0644 \u0645\u0648\u062c\u0648\u062f \u06c1\u06d2\u06d4<\/h2>\n<p>\u06cc\u06c1 \u062a\u0635\u062f\u06cc\u0642 \u06a9\u0631\u0646\u0627 \u0627\u0686\u06be\u0627 \u062e\u06cc\u0627\u0644 \u06c1\u06d2 \u06a9\u06c1 \u0641\u0627\u0626\u0644 \u06a9\u0648 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u0646\u06d2 \u0633\u06d2 \u067e\u06c1\u0644\u06d2 \u0627\u0635\u0644 \u0645\u06cc\u06ba \u0645\u0648\u062c\u0648\u062f \u06c1\u06d2\u06d4<\/p>\n<p>\u0622\u067e Python \u06a9\u06d2 \u0628\u0644\u0679 \u0627\u0646 \u0641\u0646\u06a9\u0634\u0646\u0632 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba: <code>os<\/code> \u0627\u0633 \u06a9\u06d2 \u0644\u06cc\u06d2 \u06cc\u06c1 \u0645\u0627\u0688\u06cc\u0648\u0644 \u06c1\u06d2\u06d4<\/p>\n<p>\u0634\u0627\u0645\u0644 \u06a9\u0631\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">import os\n<\/code><\/pre>\n<p>\u067e\u06be\u0631:<\/p>\n<pre><code class=\"language-python\">if not os.path.exists(file_path):\n    print(\"File not found.\")\n    exit()\n<\/code><\/pre>\n<p>\u0622\u0626\u06cc\u06d2 \u0627\u0633 \u06a9\u0627 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u06a9\u06c1 <code>os<\/code> \u0645\u0627\u0688\u06cc\u0648\u0644 \u0622\u067e\u0631\u06cc\u0679\u0646\u06af \u0633\u0633\u0679\u0645 \u06a9\u06d2 \u0633\u0627\u062a\u06be \u062a\u0639\u0627\u0645\u0644 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0627\u0632\u06af\u0631 \u06a9\u06d2 \u0627\u0648\u0632\u0627\u0631 \u0641\u0631\u0627\u06c1\u0645 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0627\u0646 \u0679\u0648\u0644\u0632 \u0645\u06cc\u06ba \u0633\u06d2 \u0627\u06cc\u06a9 \u06cc\u06c1 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-python\">os.path.exists()\n<\/code><\/pre>\n<p>\u0686\u06cc\u06a9 \u06a9\u0631\u06cc\u06ba \u06a9\u06c1 \u0622\u06cc\u0627 \u06a9\u0648\u0626\u06cc \u0641\u0627\u0626\u0644 \u06cc\u0627 \u0641\u0648\u0644\u0688\u0631 \u06a9\u0633\u06cc \u0645\u062e\u0635\u0648\u0635 \u0631\u0627\u0633\u062a\u06d2 \u0645\u06cc\u06ba \u0645\u0648\u062c\u0648\u062f \u06c1\u06d2\u06d4<\/p>\n<p><code>if<\/code>: \u062d\u0627\u0644\u0627\u062a \u06a9\u06cc \u062c\u0627\u0646\u0686 \u06a9\u0631\u0646\u0627\u06d4<\/p>\n<pre><code class=\"language-python\">if not os.path.exists(file_path):\n<\/code><\/pre>\n<p>\u0627\u0633 \u06a9\u0627 \u0645\u0637\u0644\u0628 \u06c1\u06d2:<\/p>\n<blockquote>\n<p>\u0627\u06af\u0631 \u0641\u0627\u0626\u0644 \u0645\u0648\u062c\u0648\u062f \u0646\u06c1\u06cc\u06ba \u06c1\u06d2&#8230;<\/p>\n<\/blockquote>\n<p>\u06a9\u06c1 <code>not<\/code> \u0645\u0637\u0644\u0648\u0628\u06c1 \u0627\u0644\u0641\u0627\u0638 \u0646\u062a\u0627\u0626\u062c \u06a9\u0648 \u0627\u0644\u0679 \u062f\u06cc\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0627\u06af\u0631:<\/p>\n<pre><code class=\"language-python\">os.path.exists(file_path)\n<\/code><\/pre>\n<p>\u0631\u067e\u0648\u0631\u0679 <code>True<\/code> \u067e\u06be\u0631 <code>not True<\/code> \u0628\u0646 \u062c\u0627\u062a\u0627 \u06c1\u06d2\u06d4 <code>False<\/code>. \u0644\u06cc\u06a9\u0646 \u0627\u06af\u0631 \u0641\u0627\u0626\u0644 \u0645\u0648\u062c\u0648\u062f \u0646\u06c1\u06cc\u06ba \u06c1\u06d2 &#8230;<code>False<\/code> \u0628\u0646 \u062c\u0627\u062a\u0627 \u06c1\u06d2\u06d4 <code>True<\/code>.<\/p>\n<p>\u062a\u0648 \u0627\u0646\u062f\u0631 \u06a9\u0627 \u06a9\u0648\u0688 \u06c1\u06d2\u06d4 <code>if<\/code> \u0628\u06cc\u0627\u0646 \u0635\u0631\u0641 \u0627\u0633 \u0635\u0648\u0631\u062a \u0645\u06cc\u06ba \u0639\u0645\u0644 \u0645\u06cc\u06ba \u0644\u0627\u06cc\u0627 \u062c\u0627\u062a\u0627 \u06c1\u06d2 \u062c\u0628 \u0641\u0627\u0626\u0644 \u0646\u06c1 \u0645\u0644\u06d2\u06d4<\/p>\n<p>\u0627\u06af\u0644\u0627\u060c <code>print()<\/code> \u0688\u0633\u067e\u0644\u06d2:<\/p>\n<pre><code class=\"language-text\">File not found.\n<\/code><\/pre>\n<p><code>exit()<\/code>    \u067e\u0631\u0648\u06af\u0631\u0627\u0645 \u0628\u0646\u062f \u06a9\u0631\u0648\u06d4<\/p>\n<p>\u06cc\u06c1 \u06c1\u0645\u0627\u0631\u06cc \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u06a9\u0648 \u0627\u06cc\u0633\u06cc \u0641\u0627\u0626\u0644 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u0646\u06d2 \u06a9\u06cc \u06a9\u0648\u0634\u0634 \u06a9\u0631\u0646\u06d2 \u0633\u06d2 \u0631\u0648\u06a9\u062a\u0627 \u06c1\u06d2 \u062c\u0648 \u0645\u0648\u062c\u0648\u062f \u0646\u06c1\u06cc\u06ba \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-step-9-upload-the-file\">\u0645\u0631\u062d\u0644\u06c1 9: \u0641\u0627\u0626\u0644\u06cc\u06ba \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u06cc\u06ba\u06d4<\/h2>\n<p>\u0627\u0628 \u0622\u062a\u0627 \u06c1\u06d2 \u062f\u0644\u0686\u0633\u067e \u062d\u0635\u06c1\u06d4 \u0622\u067e \u06a9\u0648 \u0641\u0627\u0626\u0644 API \u06a9\u0648 \u0628\u06be\u06cc\u062c\u0646\u06d2 \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u06c1\u06d2\u06d4<\/p>\n<p>\u0634\u0627\u0645\u0644 \u06a9\u0631\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">with open(file_path, \"rb\") as file:\n    uploaded_file = client.files.create(\n        file=file,\n        purpose=\"user_data\"\n    )\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0627\u0633 \u0633\u06d2 \u06a9\u06c1\u06cc\u06ba \u0632\u06cc\u0627\u062f\u06c1 \u067e\u06cc\u0686\u06cc\u062f\u06c1 \u0644\u06af\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0622\u0626\u06cc\u06d2 \u0627\u06cc\u06a9 \u0627\u06cc\u06a9 \u06a9\u0631\u06a9\u06d2 \u0627\u0646 \u06a9\u0648 \u062f\u06cc\u06a9\u06be\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<h3 id=\"heading-understanding-open\">\u0633\u0645\u062c\u06be <code>open()<\/code><\/h3>\n<p>\u067e\u06c1\u0644\u06cc \u0633\u0637\u0631 \u06cc\u06c1 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-python\">with open(file_path, \"rb\") as file:\n<\/code><\/pre>\n<p>\u06a9\u06c1 <code>open()<\/code> \u0641\u0646\u06a9\u0634\u0646 \u0627\u06cc\u06a9 \u0641\u0627\u0626\u0644 \u06a9\u06be\u0648\u0644\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u067e\u06c1\u0644\u06cc \u062f\u0644\u06cc\u0644 \u06cc\u06c1 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-python\">file_path\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0635\u0627\u0631\u0641 \u06a9\u0627 \u062f\u0627\u062e\u0644 \u06a9\u0631\u062f\u06c1 \u0631\u0627\u0633\u062a\u06c1 \u06c1\u06d2\u06d4<\/p>\n<p>\u062f\u0648\u0633\u0631\u06cc \u062f\u0644\u06cc\u0644 \u06cc\u06c1 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-python\">\"rb\"\n<\/code><\/pre>\n<p>\u0627\u0633 \u06a9\u0627 \u0645\u0637\u0644\u0628 \u06c1\u06d2:<\/p>\n<p>\u06c1\u0645 \u0628\u0627\u0626\u0646\u0631\u06cc \u0645\u0648\u0688 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba \u06a9\u06cc\u0648\u0646\u06a9\u06c1 \u06c1\u0645 \u0633\u0627\u062f\u06c1 \u0645\u062a\u0646 \u067e\u0691\u06be\u0646\u06d2 \u06a9\u06d2 \u0628\u062c\u0627\u0626\u06d2 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u062f\u06c1 \u0641\u0627\u0626\u0644\u0648\u06ba \u067e\u0631 \u06a9\u0627\u0631\u0631\u0648\u0627\u0626\u06cc \u06a9\u0631 \u0631\u06c1\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u06a9\u06c1 <code>with<\/code> \u0628\u06cc\u0627\u0646 \u0627\u06c1\u0645 \u06c1\u06d2 \u06a9\u06cc\u0648\u0646\u06a9\u06c1 \u062c\u0628 \u0622\u067e \u0627\u0633 \u06a9\u06d2 \u0633\u0627\u062a\u06be \u06a9\u0627\u0645 \u062e\u062a\u0645 \u06a9\u0631 \u0644\u06cc\u062a\u06d2 \u06c1\u06cc\u06ba \u062a\u0648 \u0627\u0632\u06af\u0631 \u0641\u0627\u0626\u0644 \u06a9\u0648 \u0628\u0646\u062f \u06a9\u0631\u0646\u06d2 \u06a9\u0648 \u062e\u0648\u062f \u0628\u062e\u0648\u062f \u06c1\u06cc\u0646\u0688\u0644 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0645\u062a\u063a\u06cc\u0631:<\/p>\n<pre><code class=\"language-python\">file\n<\/code><\/pre>\n<p>\u0627\u06cc\u06a9 \u06a9\u06be\u0644\u06cc \u0641\u0627\u0626\u0644 \u06a9\u06cc \u0646\u0634\u0627\u0646\u062f\u06c1\u06cc \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<h3 id=\"heading-uploading-the-file\">\u0641\u0627\u0626\u0644 \u0627\u067e \u0644\u0648\u0688<\/h3>\n<p>\u0627\u0646\u062f\u0631\u0648\u0646\u06cc <code>with<\/code> \u06c1\u0645\u0627\u0631\u06d2 \u067e\u0627\u0633 \u062c\u0648 \u0628\u0644\u0627\u06a9\u0633 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">uploaded_file = client.files.create(\n<\/code><\/pre>\n<p>\u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u062f\u06c1 \u0641\u0627\u0626\u0644 \u0628\u0646\u0627\u0646\u06d2 \u06a9\u06d2 \u0644\u06cc\u06d2 OpenAI API \u0633\u06d2 \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u06a9\u06c1 <code>file<\/code> \u062a\u0646\u0627\u0632\u0639\u06c1:<\/p>\n<pre><code class=\"language-python\">file=file\n<\/code><\/pre>\n<p>\u06c1\u0645 \u0646\u06d2 \u062c\u0648 \u0641\u0627\u0626\u0644 \u06a9\u06be\u0648\u0644\u06cc \u0627\u0633\u06d2 \u067e\u0627\u0633 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u067e\u06be\u0631:<\/p>\n<pre><code class=\"language-python\">purpose=\"user_data\"\n<\/code><\/pre>\n<p>API \u06a9\u0648 \u0645\u0637\u0644\u0639 \u06a9\u0631\u062a\u0627 \u06c1\u06d2 \u06a9\u06c1 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u062f\u06c1 \u0641\u0627\u0626\u0644 \u06a9\u0648 \u0635\u0627\u0631\u0641 \u06a9\u06d2 \u0688\u06cc\u0679\u0627 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u06cc\u0627 \u062c\u0627\u0626\u06d2 \u06af\u0627\u06d4<\/p>\n<p>\u0641\u0627\u0626\u0644 API \u0633\u067e\u0648\u0631\u0679 \u06a9\u0631\u062a\u0627 \u06c1\u06d2: <code>user_data<\/code> \u0644\u0686\u06a9\u062f\u0627\u0631 \u0641\u0627\u0626\u0644 \u06a9\u06d2 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0627 \u0645\u0642\u0635\u062f\u06d4<\/p>\n<p>\u0627\u06cc\u06a9 \u0628\u0627\u0631 \u06cc\u06c1 \u06c1\u0648 \u062c\u0627\u0646\u06d2 \u06a9\u06d2 \u0628\u0639\u062f\u060c OpenAI \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u062f\u06c1 \u0641\u0627\u0626\u0644 \u06a9\u06d2 \u0628\u0627\u0631\u06d2 \u0645\u06cc\u06ba \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u0648\u0627\u067e\u0633 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4 \u06c1\u0645 \u0627\u0633 \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u06a9\u0648 \u062f\u0631\u062c \u0630\u06cc\u0644 \u0645\u0642\u0627\u0645\u0627\u062a \u067e\u0631 \u0645\u062d\u0641\u0648\u0638 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">uploaded_file\n<\/code><\/pre>\n<p>\u0627\u0633 \u06a9\u06cc \u0645\u0641\u06cc\u062f \u062e\u0635\u0648\u0635\u06cc\u0627\u062a \u0645\u06cc\u06ba \u0633\u06d2 \u0627\u06cc\u06a9 \u06cc\u06c1 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-python\">uploaded_file.id\n<\/code><\/pre>\n<p>\u0648\u06c1 ID \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u062f\u06c1 \u0641\u0627\u0626\u0644 \u06a9\u06cc \u0634\u0646\u0627\u062e\u062a \u06a9\u0631\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-step-10-look-at-the-uploaded-file-id\">\u0645\u0631\u062d\u0644\u06c1 10: \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u062f\u06c1 \u0641\u0627\u0626\u0644 \u06a9\u06cc \u0634\u0646\u0627\u062e\u062a \u0686\u06cc\u06a9 \u06a9\u0631\u06cc\u06ba\u06d4<\/h2>\n<p>\u0634\u0627\u0645\u0644 \u06a9\u0631\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">print(\"Uploaded file:\", uploaded_file.id)\n<\/code><\/pre>\n<p>\u0627\u0628 \u0622\u067e \u06a9\u0648 \u06a9\u0686\u06be \u0627\u0633 \u0637\u0631\u062d \u062f\u06cc\u06a9\u06be\u0646\u0627 \u0686\u0627\u06c1\u0626\u06d2:<\/p>\n<pre><code class=\"language-text\">Uploaded file: file-abc123\n<\/code><\/pre>\n<p>\u0648\u06c1 ID \u0627\u06c1\u0645 \u06c1\u06d2\u06d4<\/p>\n<p>\u0645\u0642\u0627\u0645\u06cc \u06a9\u0645\u067e\u06cc\u0648\u0679\u0631 \u0641\u0627\u0626\u0644 \u06a9\u0648 \u0627\u0633 \u0637\u0631\u062d \u062c\u0627\u0646\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">research.pdf\n<\/code><\/pre>\n<p>API \u0627\u0633\u06d2 \u062f\u0631\u062c \u0630\u06cc\u0644 \u0637\u0631\u06cc\u0642\u0648\u06ba \u0633\u06d2 \u062c\u0627\u0646\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">file-abc123\n<\/code><\/pre>\n<p>\u0622\u067e \u0627\u067e\u0646\u06d2 \u0645\u0627\u0688\u0644 \u067e\u0631 \u0641\u0627\u0626\u0644\u06cc\u06ba \u0628\u06be\u06cc\u062c\u062a\u06d2 \u0648\u0642\u062a \u0627\u0633 ID \u06a9\u0627 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<h2 id=\"heading-step-11-create-the-agents-instructions\">\u0645\u0631\u062d\u0644\u06c1 11: \u0627\u06cc\u062c\u0646\u0679 \u06a9\u06cc \u06c1\u062f\u0627\u06cc\u0627\u062a \u0628\u0646\u0627\u0626\u06cc\u06ba<\/h2>\n<p>\u0627\u0628 \u06c1\u0645\u06cc\u06ba AI \u06a9\u0648 \u0628\u062a\u0627\u0646\u06d2 \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u06c1\u06d2 \u06a9\u06c1 \u0627\u0633 \u06a9\u0627 \u06a9\u0631\u062f\u0627\u0631 \u06a9\u06cc\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0628\u0646\u0627\u0646\u0627:<\/p>\n<pre><code class=\"language-python\">instructions = \"\"\"\nYou are a file analysis assistant.\n\nYour job is to carefully analyze the file provided by the user.\n\nAnswer questions using information from the file.\n\nIf the answer can't be found in the file, clearly say that the information is not available in the file.\n\nDo not invent facts.\n\nWhen useful, organize your answer with headings and bullet points.\n\"\"\"\n<\/code><\/pre>\n<p>\u0627\u0646 \u06a9\u0648 \u06c1\u062f\u0627\u06cc\u0627\u062a \u06cc\u0627 \u0627\u0634\u0627\u0631\u06d2 \u06a9\u06c1\u0627 \u062c\u0627\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0679\u0631\u067e\u0644 \u0627\u0642\u062a\u0628\u0627\u0633:<\/p>\n<pre><code class=\"language-python\">\"\"\"\n...\n\"\"\"\n<\/code><\/pre>\n<p>\u0622\u067e \u0645\u062a\u0639\u062f\u062f \u0644\u0627\u0626\u0646\u0648\u06ba \u06a9\u06d2 \u0633\u0627\u062a\u06be \u062a\u0627\u0631 \u0628\u0646\u0627 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0627\u0628 \u06c1\u0645\u0627\u0631\u06d2 \u0627\u06cc\u062c\u0646\u0679\u0648\u06ba \u0646\u06d2 \u06a9\u0631\u062f\u0627\u0631 \u0627\u062f\u0627 \u06a9\u06cc\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u06cc\u06c1 \u062c\u0627\u0646\u062a\u0627 \u06c1\u06d2:<\/p>\n<ul>\n<li>\n<p>\u06a9\u06cc\u0627 \u06a9\u0631\u0646\u0627 \u06c1\u06d2\u061f<\/p>\n<\/li>\n<li>\n<p>\u0645\u062c\u06be\u06d2 \u06a9\u0648\u0646 \u0633\u06cc \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631\u0646\u06cc \u0686\u0627\u06c1\u06cc\u06d2\u061f<\/p>\n<\/li>\n<li>\n<p>\u0627\u06af\u0631 \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u063a\u0627\u0626\u0628 \u06c1\u0648 \u062a\u0648 \u06a9\u06cc\u0627 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<li>\n<p>\u0627\u067e\u0646\u06d2 \u062c\u0648\u0627\u0628 \u06a9\u0648 \u0641\u0627\u0631\u0645\u06cc\u0679 \u06a9\u0631\u0646\u06d2 \u06a9\u0627 \u0637\u0631\u06cc\u0642\u06c1<\/p>\n<\/li>\n<\/ul>\n<p>\u06c1\u062f\u0627\u06cc\u0627\u062a:<\/p>\n<pre><code class=\"language-text\">Do not invent facts.\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0641\u0627\u0626\u0644 \u062a\u062c\u0632\u06cc\u06c1 \u0627\u06cc\u067e\u0644\u06cc \u06a9\u06cc\u0634\u0646\u0632 \u06a9\u06d2 \u0644\u06cc\u06d2 \u062e\u0627\u0635 \u0637\u0648\u0631 \u067e\u0631 \u0627\u06c1\u0645 \u06c1\u06d2\u06d4<\/p>\n<p>\u06c1\u0645 \u0686\u0627\u06c1\u062a\u06d2 \u06c1\u06cc\u06ba \u06a9\u06c1 \u06c1\u0645\u0627\u0631\u0627 \u0645\u0627\u0688\u0644 \u0627\u0646 \u0645\u06cc\u06ba \u0641\u0631\u0642 \u06a9\u0631\u06d2:<\/p>\n<blockquote>\n<p>&quot;\u06cc\u06c1 \u0641\u0627\u0626\u0644 \u0645\u06cc\u06ba \u06cc\u06c1 \u06a9\u06c1\u062a\u0627 \u06c1\u06d2\u06d4&#8221;<\/p>\n<\/blockquote>\n<p>\u0627\u0648\u0631:<\/p>\n<blockquote>\n<p>&quot;\u0645\u06cc\u0631\u06d2 \u062e\u06cc\u0627\u0644 \u0645\u06cc\u06ba \u06cc\u06c1 \u0633\u0686 \u06c1\u0648 \u0633\u06a9\u062a\u0627 \u06c1\u06d2\u06d4&#8221;<\/p>\n<\/blockquote>\n<p>\u0648\u06c1 \u0627\u06cc\u06a9 \u06c1\u06cc \u0686\u06cc\u0632 \u0646\u06c1\u06cc\u06ba \u06c1\u06cc\u06ba\u06d4<\/p>\n<h2 id=\"heading-step-12-ask-the-user-what-they-want-to-know\">\u0645\u0631\u062d\u0644\u06c1 12: \u0627\u067e\u0646\u06d2 \u0635\u0627\u0631\u0641\u06cc\u0646 \u0633\u06d2 \u067e\u0648\u0686\u06be\u06cc\u06ba \u06a9\u06c1 \u0648\u06c1 \u06a9\u06cc\u0627 \u062c\u0627\u0646\u0646\u0627 \u0686\u0627\u06c1\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/h2>\n<p>\u0627\u0628 \u06c1\u0645\u06cc\u06ba \u0627\u0635\u0644 \u0633\u0648\u0627\u0644 \u067e\u0648\u0686\u06be\u0646\u06d2 \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u06c1\u06d2\u06d4<\/p>\n<p>\u0634\u0627\u0645\u0644 \u06a9\u0631\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">question = input(\"What would you like me to analyze? \")\n<\/code><\/pre>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631\u060c \u0635\u0627\u0631\u0641 \u0679\u0627\u0626\u067e \u06a9\u0631 \u0633\u06a9\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">What are the three most important findings in this paper?\n<\/code><\/pre>\n<p>\u06cc\u0627:<\/p>\n<pre><code class=\"language-text\">Summarize this document in five bullet points.\n<\/code><\/pre>\n<p>\u06cc\u0627:<\/p>\n<pre><code class=\"language-text\">What methodology did the researchers use?\n<\/code><\/pre>\n<p>\u06cc\u06c1\u06cc\u06ba \u0633\u06d2 \u06c1\u0645\u0627\u0631\u06cc \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u0644\u0686\u06a9\u062f\u0627\u0631 \u06c1\u0648 \u062c\u0627\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<p>\u06c1\u0631 \u0645\u0645\u06a9\u0646\u06c1 \u0633\u0648\u0627\u0644 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0639\u0644\u06cc\u062d\u062f\u06c1 \u0627\u0632\u06af\u0631 \u0641\u0646\u06a9\u0634\u0646 \u0628\u0646\u0627\u0646\u06d2 \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u0646\u06c1\u06cc\u06ba \u06c1\u06d2\u06d4 \u0635\u0627\u0631\u0641\u06cc\u0646 \u0642\u062f\u0631\u062a\u06cc \u0637\u0648\u0631 \u067e\u0631 \u0633\u0648\u0627\u0644\u0627\u062a \u067e\u0648\u0686\u06be \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<h2 id=\"heading-step-13-send-the-file-and-question-to-the-model\">\u0645\u0631\u062d\u0644\u06c1 13: \u0627\u067e\u0646\u06d2 \u0645\u0627\u0688\u0644 \u06a9\u0648 \u0641\u0627\u0626\u0644\u06cc\u06ba \u0627\u0648\u0631 \u0633\u0648\u0627\u0644\u0627\u062a \u0628\u06be\u06cc\u062c\u06cc\u06ba\u06d4<\/h2>\n<p>\u0627\u0628 \u0622\u067e \u0622\u062e\u0631 \u06a9\u0627\u0631 \u062c\u0648\u0627\u0628 \u0628\u0646\u0627 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0634\u0627\u0645\u0644 \u06a9\u0631\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">response = client.responses.create(\n    model=\"gpt-5\",\n    instructions=instructions,\n    input=[\n        {\n            \"role\": \"user\",\n            \"content\": [\n                {\n                    \"type\": \"input_text\",\n                    \"text\": question\n                },\n                {\n                    \"type\": \"input_file\",\n                    \"file_id\": uploaded_file.id\n                }\n            ]\n        }\n    ]\n)\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u067e\u0648\u0631\u06d2 \u0645\u0646\u0635\u0648\u0628\u06d2 \u06a9\u0627 \u0633\u0628 \u0633\u06d2 \u0627\u06c1\u0645 \u062d\u0635\u06c1 \u06c1\u06d2\u06d4<\/p>\n<p>\u0622\u0626\u06cc\u06d2 \u0627\u0633\u06d2 \u0622\u06c1\u0633\u062a\u06c1 \u0622\u06c1\u0633\u062a\u06c1 \u0633\u0645\u062c\u06be\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<h3 id=\"heading-understanding-clientresponsescreate\">\u0633\u0645\u062c\u06be <code>client.responses.create()<\/code><\/h3>\n<p>\u06c1\u0645 \u0627\u0633 \u0637\u0631\u062d \u0634\u0631\u0648\u0639 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">client.responses.create(\n<\/code><\/pre>\n<p>\u06c1\u0645 Responses API \u0633\u06d2 \u062c\u0648\u0627\u0628 \u067e\u06cc\u062f\u0627 \u06a9\u0631\u0646\u06d2 \u06a9\u06d2 \u0644\u06cc\u06d2 \u06a9\u06c1\u06c1 \u0631\u06c1\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>OpenAI API Responses API \u0645\u06cc\u06ba \u0641\u0627\u0626\u0644 \u0627\u0646 \u067e\u0679 \u06a9\u0648 \u0633\u067e\u0648\u0631\u0679 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u060c \u0628\u0634\u0645\u0648\u0644 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u062f\u06c1 \u0641\u0627\u0626\u0644 \u06a9\u06cc ID \u06a9\u0648 \u0628\u0637\u0648\u0631 \u0641\u0627\u0626\u0644 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631\u0646\u0627\u06d4 <code>input_file<\/code>.<\/p>\n<h3 id=\"heading-understanding-the-model\">\u0645\u0627\u0688\u0644 \u06a9\u0648 \u0633\u0645\u062c\u06be\u0646\u0627<\/h3>\n<p>\u06c1\u0645 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">model=\"gpt-5\"\n<\/code><\/pre>\n<p>\u06cc\u06c1 API \u06a9\u0648 \u0628\u062a\u0627\u062a\u0627 \u06c1\u06d2 \u06a9\u06c1 \u06a9\u0648\u0646 \u0633\u0627 \u0645\u0627\u0688\u0644 \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u06a9\u0648 \u06c1\u06cc\u0646\u0688\u0644 \u06a9\u0631\u06d2\u06d4<\/p>\n<p>\u0645\u0627\u0688\u0644 \u0633\u0648\u0627\u0644 \u06a9\u0648 \u0633\u0645\u062c\u06be\u0646\u06d2 \u0627\u0648\u0631 \u0641\u0631\u0627\u06c1\u0645 \u06a9\u0631\u062f\u06c1 \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u06a9\u0627 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u0631\u0646\u06d2 \u06a9\u0627 \u0630\u0645\u06c1 \u062f\u0627\u0631 \u062d\u0635\u06c1 \u06c1\u06d2\u06d4<\/p>\n<p>\u0622\u067e \u0646\u06d2 \u062c\u0648 \u0639\u06cc\u0646 \u0645\u0627\u0688\u0644 \u0645\u0646\u062a\u062e\u0628 \u06a9\u06cc\u0627 \u06c1\u06d2 \u0648\u06c1 \u0648\u0642\u062a \u06a9\u06d2 \u0633\u0627\u062a\u06be \u0628\u062f\u0644 \u0633\u06a9\u062a\u0627 \u06c1\u06d2\u060c \u0627\u0633 \u0644\u06cc\u06d2 \u0645\u0627\u0688\u0644 \u06a9\u06d2 \u0646\u0627\u0645\u0648\u06ba \u06a9\u0648 \u0641\u0646 \u062a\u0639\u0645\u06cc\u0631 \u0645\u06cc\u06ba \u0645\u0633\u062a\u0642\u0644 \u0637\u0648\u0631 \u067e\u0631 \u0633\u062e\u062a \u06a9\u0648\u0688 \u06a9\u06cc\u06d2 \u06af\u0626\u06d2 \u0646\u0627\u0645\u0648\u06ba \u06a9\u06d2 \u0628\u062c\u0627\u0626\u06d2 \u0627\u067e\u0646\u06cc \u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646 \u06a9\u0627 \u0627\u06cc\u06a9 \u0642\u0627\u0628\u0644 \u062a\u0631\u062a\u06cc\u0628 \u062d\u0635\u06c1 \u0633\u0645\u062c\u06be\u06cc\u06ba\u06d4<\/p>\n<h3 id=\"heading-understanding-instructions\">\u0633\u0645\u062c\u06be <code>instructions<\/code><\/h3>\n<p>\u0627\u06af\u0644\u0627:<\/p>\n<pre><code class=\"language-python\">instructions=instructions\n<\/code><\/pre>\n<p>\u06a9\u06cc\u0627 \u0622\u067e \u06a9\u0648 \u0648\u06c1 \u0645\u062a\u063a\u06cc\u0631 \u06cc\u0627\u062f \u06c1\u06cc\u06ba \u062c\u0648 \u06c1\u0645 \u0646\u06d2 \u067e\u06c1\u0644\u06d2 \u0628\u0646\u0627\u0626\u06d2 \u062a\u06be\u06d2\u061f<\/p>\n<pre><code class=\"language-python\">instructions = \"\"\"\nYou are a file analysis assistant.\n...\n\"\"\"\n<\/code><\/pre>\n<p>\u0622\u067e \u0627\u0646 \u06c1\u062f\u0627\u06cc\u0627\u062a \u06a9\u0648 \u0627\u067e\u0646\u06cc API \u06a9\u06cc \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u067e\u0631 \u0645\u0646\u062a\u0642\u0644 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba \u062a\u0627\u06a9\u06c1 \u0645\u0627\u0688\u0644 \u06a9\u0648 \u0645\u0639\u0644\u0648\u0645 \u06c1\u0648 \u06a9\u06c1 \u0627\u0633\u06d2 \u06a9\u06cc\u0627 \u06a9\u0631\u062f\u0627\u0631 \u0627\u062f\u0627 \u06a9\u0631\u0646\u0627 \u0686\u0627\u06c1\u06cc\u06d2\u06d4<\/p>\n<h3 id=\"heading-understanding-input\">\u0633\u0645\u062c\u06be <code>input<\/code><\/h3>\n<p>\u06cc\u06c1\u0627\u06ba \u0645\u0646\u062f\u0631\u062c\u06c1 \u0630\u06cc\u0644 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-python\">input=[\n<\/code><\/pre>\n<p>The <code>input<\/code> contains the information we give the model.<\/p>\n<p>In our case, we&#8217;re giving it:<\/p>\n<ol>\n<li>\n<p>The user&#8217;s question<\/p>\n<\/li>\n<li>\n<p>The file<\/p>\n<\/li>\n<\/ol>\n<p>This is important because an AI model can&#8217;t answer a file-specific question if we never give it the file.<\/p>\n<h3 id=\"heading-understanding-the-user-message\">Understanding the User Message<\/h3>\n<p>Inside the input we have:<\/p>\n<pre><code class=\"language-python\">{\n    \"role\": \"user\",\n<\/code><\/pre>\n<p>This tells the API that this input represents the user&#8217;s message.<\/p>\n<p>Then:<\/p>\n<pre><code class=\"language-python\">\"content\": [\n<\/code><\/pre>\n<p>contains the actual content of that message.<\/p>\n<h3 id=\"heading-sending-the-question\">Sending the Question<\/h3>\n<p>The first content item is:<\/p>\n<pre><code class=\"language-python\">{\n    \"type\": \"input_text\",\n    \"text\": question\n}\n<\/code><\/pre>\n<p>This tells the model:<\/p>\n<blockquote>\n<p>Here is some text input.<\/p>\n<\/blockquote>\n<p>The actual text comes from:<\/p>\n<pre><code class=\"language-python\">question\n<\/code><\/pre>\n<p>which was entered by the user.<\/p>\n<p>If the user entered:<\/p>\n<pre><code class=\"language-text\">What is the main conclusion?\n<\/code><\/pre>\n<p>then the model receives that question.<\/p>\n<h3 id=\"heading-sending-the-file\">Sending the File<\/h3>\n<p>The next content item is:<\/p>\n<pre><code class=\"language-python\">{\n    \"type\": \"input_file\",\n    \"file_id\": uploaded_file.id\n}\n<\/code><\/pre>\n<p>This tells the API:<\/p>\n<blockquote>\n<p>Here is a file input.<\/p>\n<\/blockquote>\n<p>And:<\/p>\n<pre><code class=\"language-python\">uploaded_file.id\n<\/code><\/pre>\n<p>tells the API exactly which uploaded file we&#8217;re referring to.<\/p>\n<p>So our request effectively contains:<\/p>\n<pre><code class=\"language-text\">Question:\n\"What is the main conclusion?\"\n\nFile:\nresearch.pdf\n<\/code><\/pre>\n<p>The model can then analyze the provided file in the context of the user&#8217;s question.<\/p>\n<h2 id=\"heading-step-14-print-the-answer\">Step 14: Print the Answer<\/h2>\n<p>We have the response stored in:<\/p>\n<pre><code class=\"language-python\">response\n<\/code><\/pre>\n<p>But we don&#8217;t want to print the entire response object.<\/p>\n<p>We want the generated text.<\/p>\n<p>The SDK provides:<\/p>\n<pre><code class=\"language-python\">response.output_text\n<\/code><\/pre>\n<p>So add:<\/p>\n<pre><code class=\"language-python\">print(\"\\nAgent:\\n\")\nprint(response.output_text)\n<\/code><\/pre>\n<p>The first <code>print()<\/code> creates a little spacing and prints:<\/p>\n<pre><code class=\"language-text\">Agent:\n<\/code><\/pre>\n<p>The second prints the actual answer.<\/p>\n<h2 id=\"heading-our-first-complete-version\">Our First Complete Version<\/h2>\n<p>At this point, our entire <code>agent.py<\/code> looks like this:<\/p>\n<pre><code class=\"language-python\">import os\nfrom openai import OpenAI\n\n\nclient = OpenAI()\n\n\nfile_path = input(\"Enter the path to your file: \")\n\n\nif not os.path.exists(file_path):\n    print(\"File not found.\")\n    exit()\n\n\nwith open(file_path, \"rb\") as file:\n    uploaded_file = client.files.create(\n        file=file,\n        purpose=\"user_data\"\n    )\n\n\nprint(\"Uploaded file:\", uploaded_file.id)\n\n\ninstructions = \"\"\"\nYou are a file analysis assistant.\n\nYour job is to carefully analyze the file provided by the user.\n\nAnswer questions using information from the file.\n\nIf the answer cannot be found in the file, clearly say that the information is not available in the file.\n\nDo not invent facts.\n\nWhen useful, organize your answer with headings and bullet points.\n\"\"\"\n\n\nquestion = input(\"What would you like me to analyze? \")\n\n\nresponse = client.responses.create(\n    model=\"gpt-5\",\n    instructions=instructions,\n    input=[\n        {\n            \"role\": \"user\",\n            \"content\": [\n                {\n                    \"type\": \"input_text\",\n                    \"text\": question\n                },\n                {\n                    \"type\": \"input_file\",\n                    \"file_id\": uploaded_file.id\n                }\n            ]\n        } ]) \u067e\u0631\u0646\u0679 (\"\\n\u0627\u06cc\u062c\u0646\u0679:\\n\") \u067e\u0631\u0646\u0679 (response.output_text)\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u067e\u06c1\u0644\u06d2 \u0633\u06d2 \u06c1\u06cc \u0627\u06cc\u06a9 \u0641\u0639\u0627\u0644 \u0641\u0627\u0626\u0644 \u062a\u062c\u0632\u06cc\u06c1 AI \u0627\u06cc\u067e\u0644\u06cc \u06a9\u06cc\u0634\u0646 \u06c1\u06d2\u06d4<\/p>\n<p>\u0644\u06cc\u06a9\u0646 \u06c1\u0645 \u0627\u0633\u06d2 \u0628\u06c1\u062a \u0628\u06c1\u062a\u0631 \u0628\u0646\u0627 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<h2 id=\"heading-step-15-run-the-application\">\u0645\u0631\u062d\u0644\u06c1 15: \u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646 \u0686\u0644\u0627\u0626\u06cc\u06ba\u06d4<\/h2>\n<p>\u062f\u0631\u062c \u0630\u06cc\u0644 \u0641\u0627\u0626\u0644\u06cc\u06ba \u0631\u06a9\u06be\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">research.pdf\n<\/code><\/pre>\n<p>\u067e\u0631\u0648\u062c\u06cc\u06a9\u0679 \u0641\u0648\u0644\u0688\u0631 \u06a9\u06d2 \u0627\u0646\u062f\u0631\u06d4<\/p>\n<p>\u067e\u06be\u0631 \u0686\u0644\u0627\u0626\u06cc\u06ba:<\/p>\n<pre><code class=\"language-bash\">python agent.py\n<\/code><\/pre>\n<p>\u0622\u067e \u06a9\u0648 \u062f\u0631\u062c \u0630\u06cc\u0644 \u06a9\u0648 \u0686\u06cc\u06a9 \u06a9\u0631\u0646\u0627 \u0686\u0627\u06c1\u0626\u06d2:<\/p>\n<pre><code class=\"language-text\">Enter the path to your file:\n<\/code><\/pre>\n<p>\u062f\u0631\u062c \u06a9\u0631\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">research.pdf\n<\/code><\/pre>\n<p>\u067e\u06be\u0631 \u0622\u067e \u062f\u06cc\u06a9\u06be\u06cc\u06ba \u06af\u06d2:<\/p>\n<pre><code class=\"language-text\">Uploaded file: file-abc123\n<\/code><\/pre>\n<p>\u0627\u06af\u0644\u0627:<\/p>\n<pre><code class=\"language-text\">What would you like me to analyze?\n<\/code><\/pre>\n<p>\u0622\u067e \u067e\u0648\u0686\u06be \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">Summarize the main findings in five bullet points.\n<\/code><\/pre>\n<p>\u0627\u06cc\u062c\u0646\u0679 \u0641\u0627\u0626\u0644 \u06a9\u0627 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u0631\u062a\u0627 \u06c1\u06d2 \u0627\u0648\u0631 \u062c\u0648\u0627\u0628 \u062f\u06cc\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<h3 id=\"heading-why-is-this-an-agent\">\u06cc\u06c1 \u0627\u06cc\u062c\u0646\u0679 \u06a9\u06cc\u0648\u06ba \u06c1\u06d2\u061f<\/h3>\n<p>\u067e\u06c1\u0644\u06cc \u0646\u0638\u0631 \u0645\u06cc\u06ba\u060c \u06cc\u06c1 \u0627\u06cc\u06a9 \u0639\u0627\u0645 API \u06a9\u0627\u0644 \u06a9\u06cc \u0637\u0631\u062d \u0644\u06af \u0633\u06a9\u062a\u0627 \u06c1\u06d2\u06d4 \u0627\u0648\u0631 \u062a\u06a9\u0646\u06cc\u06a9\u06cc \u0637\u0648\u0631 \u067e\u0631\u060c \u06c1\u0627\u06ba\u06d4 \u067e\u06c1\u0644\u0627 \u0648\u0631\u0698\u0646 \u0627\u06cc\u06a9 \u0628\u06c1\u062a \u06c1\u06cc \u0622\u0633\u0627\u0646 \u0627\u06cc\u062c\u0646\u0679 \u0648\u0631\u06a9 \u0641\u0644\u0648 \u06c1\u06d2\u06d4<\/p>\n<p>\u0627\u06c1\u0645 \u062a\u0635\u0648\u0631 \u06c1\u06d2\u06d4 <strong>\u0627\u06cc\u062c\u0646\u0679 \u0644\u0648\u067e<\/strong>.<\/p>\n<p>\u0627\u06cc\u062c\u0646\u0679\u0648\u06ba \u06a9\u06d2 \u067e\u0627\u0633 \u0639\u0627\u0645 \u0637\u0648\u0631 \u067e\u0631:<\/p>\n<ol>\n<li>\n<p>\u06c1\u062f\u0641<\/p>\n<\/li>\n<li>\n<p>\u0631\u06c1\u0646\u0645\u0627 \u062e\u0637\u0648\u0637<\/p>\n<\/li>\n<li>\n<p>\u0645\u0639\u0644\u0648\u0645\u0627\u062a \u062a\u06a9 \u0631\u0633\u0627\u0626\u06cc<\/p>\n<\/li>\n<li>\n<p>\u0645\u0645\u06a9\u0646\u06c1 \u0622\u0644\u06c1<\/p>\n<\/li>\n<li>\n<p>\u0627\u0633\u062a\u062f\u0644\u0627\u0644 \u06a9\u0627 \u0639\u0645\u0644<\/p>\n<\/li>\n<li>\n<p>\u06a9\u0627\u0631\u0631\u0648\u0627\u0626\u06cc<\/p>\n<\/li>\n<li>\n<p>\u0637\u0627\u0642\u062a \u06a9\u06cc \u067e\u06cc\u062f\u0627\u0648\u0627\u0631<\/p>\n<\/li>\n<\/ol>\n<p>\u06c1\u0645\u0627\u0631\u06cc \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u0645\u06cc\u06ba \u0627\u0646 \u0645\u06cc\u06ba \u0633\u06d2 \u06a9\u0626\u06cc \u0679\u06a9\u0691\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0635\u0627\u0631\u0641 \u0627\u06c1\u062f\u0627\u0641 \u0641\u0631\u0627\u06c1\u0645 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<pre><code class=\"language-text\">Analyze this research paper.\n<\/code><\/pre>\n<p>\u06c1\u062f\u0627\u06cc\u0627\u062a \u0627\u06cc\u062c\u0646\u0679 \u06a9\u06d2 \u0631\u0648\u06cc\u06d2 \u06a9\u06cc \u0648\u0636\u0627\u062d\u062a \u06a9\u0631\u062a\u06cc \u06c1\u06cc\u06ba\u06d4<\/p>\n<pre><code class=\"language-text\">You are a file analysis assistant.\n<\/code><\/pre>\n<p>\u0641\u0627\u0626\u0644 \u062f\u0631\u062c \u0630\u06cc\u0644 \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u0641\u0631\u0627\u06c1\u0645 \u06a9\u0631\u062a\u06cc \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">research.pdf\n<\/code><\/pre>\n<p>\u0645\u0627\u0688\u0644 \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u067e\u0631 \u06a9\u0627\u0631\u0631\u0648\u0627\u0626\u06cc \u06a9\u0631\u062a\u0627 \u06c1\u06d2 \u0627\u0648\u0631 \u067e\u06be\u0631 \u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646 \u0646\u062a\u0627\u0626\u062c \u06a9\u0648 \u0644\u0648\u0679\u0627\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u062c\u06cc\u0633\u06d2 \u062c\u06cc\u0633\u06d2 \u0627\u06cc\u067e\u0644\u06cc \u06a9\u06cc\u0634\u0646\u0632 \u0632\u06cc\u0627\u062f\u06c1 \u062a\u0631\u0642\u06cc \u06cc\u0627\u0641\u062a\u06c1 \u06c1\u0648\u062a\u06cc \u062c\u0627\u062a\u06cc \u06c1\u06cc\u06ba\u060c \u0627\u06cc\u062c\u0646\u0679\u0633 \u0641\u0627\u0626\u0644 \u06a9\u06cc \u062a\u0644\u0627\u0634\u060c \u0648\u06cc\u0628 \u062a\u0644\u0627\u0634\u060c \u0641\u0646\u06a9\u0634\u0646 \u06a9\u0627\u0644\u0632\u060c \u0627\u0648\u0631 \u062f\u06cc\u06af\u0631 \u0628\u06cc\u0631\u0648\u0646\u06cc \u0646\u0638\u0627\u0645 \u062c\u06cc\u0633\u06d2 \u0679\u0648\u0644\u0632 \u0628\u06be\u06cc \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4 OpenAI \u067e\u0644\u06cc\u0679 \u0641\u0627\u0631\u0645 \u0641\u06cc \u0627\u0644\u062d\u0627\u0644 \u0627\u06cc\u062c\u0646\u0679 \u06a9\u06cc \u062a\u0648\u0633\u06cc\u0639 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0628\u0644\u0679 \u0627\u0646 \u0679\u0648\u0644\u0632 \u0627\u0648\u0631 \u06a9\u0633\u0679\u0645 \u0641\u0646\u06a9\u0634\u0646 \u0679\u0648\u0644\u0632 \u06a9\u0648 \u0633\u067e\u0648\u0631\u0679 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-step-16-turn-it-into-a-real-conversation\">\u0645\u0631\u062d\u0644\u06c1 16: \u0627\u0633\u06d2 \u062d\u0642\u06cc\u0642\u06cc \u06af\u0641\u062a\u06af\u0648 \u0645\u06cc\u06ba \u062a\u0628\u062f\u06cc\u0644 \u06a9\u0631\u06cc\u06ba\u06d4<\/h2>\n<p>\u0641\u06cc \u0627\u0644\u062d\u0627\u0644\u060c \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u0635\u0631\u0641 \u0627\u06cc\u06a9 \u0633\u0648\u0627\u0644 \u067e\u0648\u0686\u06be\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<p>\u0645\u0641\u06cc\u062f\u060c \u0644\u06cc\u06a9\u0646 \u0645\u062b\u0627\u0644\u06cc \u0646\u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0627\u06cc\u06a9 \u062a\u062d\u0642\u06cc\u0642\u06cc \u0645\u0642\u0627\u0644\u06c1 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u0646\u06d2 \u06a9\u0627 \u062a\u0635\u0648\u0631 \u06a9\u0631\u06cc\u06ba \u0627\u0648\u0631 \u067e\u06be\u0631 \u062c\u0628 \u0628\u06be\u06cc \u0622\u067e \u06a9\u0648\u0626\u06cc \u0627\u0648\u0631 \u0633\u0648\u0627\u0644 \u067e\u0648\u0686\u06be\u0646\u0627 \u0686\u0627\u06c1\u06cc\u06ba \u067e\u0631\u0648\u06af\u0631\u0627\u0645 \u06a9\u0648 \u062f\u0648\u0628\u0627\u0631\u06c1 \u0634\u0631\u0648\u0639 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<p>\u0622\u067e \u0633\u0648\u0627\u0644 \u06a9\u0648 \u0627\u06cc\u06a9 \u0644\u0648\u067e \u06a9\u06d2 \u0627\u0646\u062f\u0631 \u0631\u06a9\u06be \u06a9\u0631 \u0627\u0633\u06d2 \u0628\u06c1\u062a\u0631 \u0628\u0646\u0627 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0628\u062c\u0627\u0626\u06d2:<\/p>\n<pre><code class=\"language-python\">question = input(\"What would you like me to analyze? \")\n<\/code><\/pre>\n<p>\u06c1\u0645 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">while True:\n    question = input(\"\\nAsk a question (or type 'exit'): \")\n\n    if question.lower() == \"exit\":\n        break\n<\/code><\/pre>\n<p>\u0627\u0628 \u0622\u0626\u06cc\u06d2 \u0633\u0645\u062c\u06be\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<ul>\n<li>\n<p><code>while True<\/code>: \u0627\u06cc\u06a9 \u0644\u0648\u067e \u0628\u0646\u0627\u062a\u0627 \u06c1\u06d2 \u062c\u0648 \u063a\u06cc\u0631 \u0645\u0639\u06cc\u0646\u06c1 \u0645\u062f\u062a \u062a\u06a9 \u062c\u0627\u0631\u06cc \u0631\u06c1\u062a\u0627 \u06c1\u06d2\u06d4 \u0648\u06c1 \u0627\u0633 \u0648\u0642\u062a \u062a\u06a9 \u0633\u0648\u0627\u0644\u0627\u062a \u067e\u0648\u0686\u06be\u062a\u06d2 \u0631\u06c1\u06cc\u06ba \u06af\u06d2 \u062c\u0628 \u062a\u06a9 \u06c1\u0645 \u0627\u0646\u06c1\u06cc\u06ba \u0631\u06a9\u0646\u06d2 \u06a9\u0648 \u0646\u06c1\u06cc\u06ba \u06a9\u06c1\u06cc\u06ba \u06af\u06d2\u06d4<\/p>\n<\/li>\n<li>\n<p><code>question = input(...)<\/code>: \u0635\u0627\u0631\u0641 \u0646\u06d2 \u062f\u0648\u0633\u0631\u0627 \u0633\u0648\u0627\u0644 \u062f\u0631\u062c \u06a9\u06cc\u0627 \u06c1\u06d2\u06d4<\/p>\n<\/li>\n<li>\n<p><code>question.lower()<\/code>: <code>.lower()<\/code> \u0637\u0631\u06cc\u0642\u06c1 \u0633\u0648\u0627\u0644 \u06a9\u0648 \u0686\u06be\u0648\u0679\u06d2 \u062d\u0631\u0648\u0641 \u0645\u06cc\u06ba \u062a\u0628\u062f\u06cc\u0644 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<\/li>\n<\/ul>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631:<\/p>\n<pre><code class=\"language-text\">EXIT\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0627\u0633 \u0637\u0631\u062d \u062c\u0627\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">exit\n<\/code><\/pre>\n<p>\u0627\u0648\u0631:<\/p>\n<pre><code class=\"language-text\">Exit\n<\/code><\/pre>\n<p>\u0627\u0633 \u06a9\u06d2 \u0639\u0644\u0627\u0648\u06c1:<\/p>\n<pre><code class=\"language-text\">exit\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0679\u0631\u0645\u06cc\u0646\u06cc\u0634\u0646 \u0686\u06cc\u06a9\u0646\u06af \u06a9\u0648 \u0632\u06cc\u0627\u062f\u06c1 \u0642\u0627\u0628\u0644 \u0627\u0639\u062a\u0645\u0627\u062f \u0628\u0646\u0627\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0622\u062e\u0631 \u06a9\u0627\u0631 <code>break<\/code> \u06a9\u0644\u06cc\u062f\u06cc \u0644\u0641\u0638 \u0644\u0648\u067e \u06a9\u0648 \u0631\u0648\u06a9\u062a\u0627 \u06c1\u06d2\u06d4 \u062a\u0648:<\/p>\n<pre><code class=\"language-python\">if question.lower() == \"exit\":\n    break\n<\/code><\/pre>\n<p>\u0637\u0631\u06cc\u0642\u06c1:<\/p>\n<blockquote>\n<p>\u0635\u0627\u0631\u0641 \u06a9\u06cc \u0642\u0633\u0645\u06cc\u06ba \u062e\u062a\u0645 \u06c1\u0648\u0646\u06d2 \u067e\u0631 \u0633\u0648\u0627\u0644\u0627\u062a \u067e\u0648\u0686\u06be\u0646\u0627 \u0628\u0646\u062f \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<\/blockquote>\n<h2 id=\"heading-step-17-move-the-ai-request-into-the-loop\">\u0645\u0631\u062d\u0644\u06c1 17: AI \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u06a9\u0648 \u0644\u0648\u067e \u0645\u06cc\u06ba \u0645\u0646\u062a\u0642\u0644 \u06a9\u0631\u06cc\u06ba\u06d4<\/h2>\n<p>API \u06a9\u06cc \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u0627\u0628 \u0627\u06cc\u06a9 \u0644\u0648\u067e \u06a9\u06d2 \u0627\u0646\u062f\u0631 \u06c1\u0648\u0646\u06cc \u0686\u0627\u06c1\u0626\u06d2\u06d4<\/p>\n<p>\u06c1\u0645\u0627\u0631\u06cc \u0633\u0627\u062e\u062a \u0627\u0633 \u0637\u0631\u062d \u06c1\u06d2:<\/p>\n<pre><code class=\"language-python\">while True:\n    question = input(\"\\nAsk a question (or type 'exit'): \")\n\n    if question.lower() == \"exit\":\n        break\n\n    response = client.responses.create(\n        model=\"gpt-5\",\n        instructions=instructions,\n        input=[\n            {\n                \"role\": \"user\",\n                \"content\": [\n                    {\n                        \"type\": \"input_text\",\n                        \"text\": question\n                    },\n                    {\n                        \"type\": \"input_file\",\n                        \"file_id\": uploaded_file.id\n                    }\n                ]\n            }\n        ]\n    )\n\n    print(\"\\nAgent:\\n\")\n    print(response.output_text)\n<\/code><\/pre>\n<p>\u0635\u0627\u0631\u0641\u06cc\u0646 \u0627\u0628 \u0627\u06cc\u06a9 \u06c1\u06cc \u0641\u0627\u0626\u0644 \u06a9\u06d2 \u0628\u0627\u0631\u06d2 \u0645\u06cc\u06ba \u0645\u062a\u0639\u062f\u062f \u0633\u0648\u0627\u0644\u0627\u062a \u067e\u0648\u0686\u06be \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631:<\/p>\n<pre><code class=\"language-text\">Ask a question:\nWhat is this paper about?\n<\/code><\/pre>\n<p>\u067e\u06be\u0631:<\/p>\n<pre><code class=\"language-text\">Ask a question:\nWhat methodology did the researchers use?\n<\/code><\/pre>\n<p>\u067e\u06be\u0631:<\/p>\n<pre><code class=\"language-text\">Ask a question:\nWhat were the biggest limitations?\n<\/code><\/pre>\n<p>\u0627\u0648\u0631 \u0622\u062e\u0631 \u0645\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">Ask a question:\nexit\n<\/code><\/pre>\n<p>\u0627\u0633 \u0633\u06d2 \u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646 \u0627\u06cc\u06a9 \u062d\u0642\u06cc\u0642\u06cc \u0627\u0633\u0633\u0679\u0646\u0679 \u06a9\u06cc \u0637\u0631\u062d \u0645\u062d\u0633\u0648\u0633 \u06c1\u0648\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-step-18-improve-the-agents-instructions\">\u0645\u0631\u062d\u0644\u06c1 18: \u0627\u06cc\u062c\u0646\u0679 \u06a9\u06cc \u06c1\u062f\u0627\u06cc\u0627\u062a \u06a9\u0648 \u0628\u06c1\u062a\u0631 \u0628\u0646\u0627\u0626\u06cc\u06ba<\/h2>\n<p>\u0627\u0686\u06be\u06cc AI \u0627\u06cc\u067e\u0644\u06cc \u06a9\u06cc\u0634\u0646\u0632 \u0635\u0631\u0641 APIs \u06a9\u0648 \u06a9\u0627\u0644 \u0646\u06c1\u06cc\u06ba \u06a9\u0631\u062a\u06cc \u06c1\u06cc\u06ba\u06d4 \u06c1\u062f\u0627\u06cc\u0627\u062a \u0628\u06c1\u062a \u0627\u06c1\u0645 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u06c1\u0645 \u06c1\u062f\u0627\u06cc\u0627\u062a \u06a9\u0648 \u0645\u0632\u06cc\u062f \u0645\u062e\u0635\u0648\u0635 \u0628\u0646\u0627 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631:<\/p>\n<pre><code class=\"language-python\">instructions = \"\"\"\nYou are an AI file analysis assistant.\n\nYour job is to analyze the file provided by the user.\n\nFollow these rules:\n\n1. Use the provided file as your primary source.\n2. Answer the user's question directly.\n3. Do not invent information that is not supported by the file.\n4. If the file does not contain enough information to answer a question, say so.\n5. When summarizing, focus on the most important information.\n6. When comparing ideas, clearly explain the similarities and differences.\n7. When analyzing research, distinguish between results, methods, and conclusions.\n8. Use simple language unless the user asks for technical language.\n9. Use bullet points when they make the answer easier to understand.\n10. If you make an inference, clearly label it as an inference.\n\"\"\"\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0628\u06c1\u062a \u0632\u06cc\u0627\u062f\u06c1 \u0645\u0636\u0628\u0648\u0637 \u06c1\u06d2\u06d4<\/p>\n<p>\u06c1\u0645 \u0628\u0646\u06cc\u0627\u062f\u06cc \u0637\u0648\u0631 \u067e\u0631 AI \u06a9\u0648 \u0642\u0648\u0627\u0639\u062f \u06a9\u0627 \u0627\u06cc\u06a9 \u0633\u06cc\u0679 \u062f\u06d2 \u0631\u06c1\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<h3 id=\"heading-why-good-instructions-matter\">\u0627\u0686\u06be\u06cc \u0631\u06c1\u0646\u0645\u0627\u0626\u06cc \u06a9\u06cc\u0648\u06ba \u0636\u0631\u0648\u0631\u06cc \u06c1\u06d2\u06d4<\/h3>\n<p>\u06a9\u0633\u06cc \u0633\u06d2 \u06cc\u06c1 \u06a9\u06c1\u0646\u06d2 \u06a9\u0627 \u062a\u0635\u0648\u0631 \u06a9\u0631\u06cc\u06ba:<\/p>\n<blockquote>\n<p>&quot;\u0628\u0631\u0627\u06c1 \u06a9\u0631\u0645 \u0627\u0633 \u062f\u0633\u062a\u0627\u0648\u06cc\u0632 \u06a9\u0648 \u067e\u0691\u06be\u06cc\u06ba\u06d4&#8221;<\/p>\n<\/blockquote>\n<p>\u0648\u06c1 \u0627\u0633\u06d2 \u067e\u0691\u06be\u06cc\u06ba \u06af\u06d2 \u0627\u0648\u0631 \u0622\u067e \u06a9\u0648 \u062a\u0642\u0631\u06cc\u0628\u0627\u064b \u06a9\u0686\u06be \u0628\u06be\u06cc \u062f\u06cc\u06ba \u06af\u06d2\u06d4<\/p>\n<p>\u0627\u0628 \u0645\u0646\u062f\u0631\u062c\u06c1 \u0630\u06cc\u0644 \u06a9\u06c1\u0646\u06d2 \u06a9\u0627 \u062a\u0635\u0648\u0631 \u06a9\u0631\u06cc\u06ba:<\/p>\n<blockquote>\n<p>&quot;\u0627\u0633 \u062f\u0633\u062a\u0627\u0648\u06cc\u0632 \u06a9\u0648 \u067e\u0691\u06be\u06cc\u06ba\u060c \u062a\u062d\u0642\u06cc\u0642\u06cc \u0633\u0648\u0627\u0644 \u06a9\u06cc \u0634\u0646\u0627\u062e\u062a \u06a9\u0631\u06cc\u06ba\u060c \u0637\u0631\u06cc\u0642\u06c1 \u06a9\u0627\u0631 \u06a9\u0627 \u062e\u0644\u0627\u0635\u06c1 \u06a9\u0631\u06cc\u06ba\u060c \u06a9\u0644\u06cc\u062f\u06cc \u0646\u062a\u0627\u0626\u062c \u06a9\u06cc \u0646\u0634\u0627\u0646\u062f\u06c1\u06cc \u06a9\u0631\u06cc\u06ba\u060c \u0627\u0648\u0631 \u0622\u0633\u0627\u0646 \u0632\u0628\u0627\u0646 \u06a9\u0627 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631\u062a\u06d2 \u06c1\u0648\u0626\u06d2 \u062d\u062f\u0648\u062f \u06a9\u06cc \u0648\u0636\u0627\u062d\u062a \u06a9\u0631\u06cc\u06ba\u06d4&#8221;<\/p>\n<\/blockquote>\n<p>\u062f\u0648\u0633\u0631\u06cc \u06c1\u062f\u0627\u06cc\u062a \u0628\u06c1\u062a \u0632\u06cc\u0627\u062f\u06c1 \u0645\u0641\u06cc\u062f \u06c1\u06d2\u06d4<\/p>\n<p>AI \u0627\u06cc\u062c\u0646\u0679 \u0627\u0633\u06cc \u0637\u0631\u062d \u06a9\u0627\u0645 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4 \u062c\u062a\u0646\u06cc \u0632\u06cc\u0627\u062f\u06c1 \u0648\u0627\u0636\u062d \u0637\u0648\u0631 \u067e\u0631 \u0622\u067e \u06a9\u0627\u0645 \u06a9\u06cc \u0648\u0636\u0627\u062d\u062a \u06a9\u0631\u06cc\u06ba \u06af\u06d2\u060c \u0622\u067e \u06a9\u06d2 \u0645\u0627\u0688\u0644 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0645\u0633\u062a\u0642\u0644 \u0646\u062a\u0627\u0626\u062c \u067e\u06cc\u062f\u0627 \u06a9\u0631\u0646\u0627 \u0627\u062a\u0646\u0627 \u06c1\u06cc \u0622\u0633\u0627\u0646 \u06c1\u0648\u06af\u0627\u06d4<\/p>\n<h2 id=\"heading-step-19-add-error-handling\">\u0645\u0631\u062d\u0644\u06c1 19: \u0627\u06cc\u0631\u0631 \u06c1\u06cc\u0646\u0688\u0644\u0646\u06af \u0634\u0627\u0645\u0644 \u06a9\u0631\u06cc\u06ba\u06d4<\/h2>\n<p>\u0641\u06cc \u0627\u0644\u062d\u0627\u0644 \u06c1\u0645\u0627\u0631\u0627 \u067e\u0631\u0648\u06af\u0631\u0627\u0645 \u0641\u0631\u0636 \u06a9\u0631\u062a\u0627 \u06c1\u06d2 \u06a9\u06c1 \u0633\u0628 \u06a9\u0686\u06be \u06a9\u0627\u0645 \u06a9\u0631\u06d2 \u06af\u0627\u06d4<\/p>\n<p>\u062d\u0642\u06cc\u0642\u06cc \u0627\u06cc\u067e\u0644\u06cc \u06a9\u06cc\u0634\u0646\u0632 \u0645\u06cc\u06ba \u0622\u067e \u06a9\u0648 \u0627\u06cc\u0633\u0627 \u0646\u06c1\u06cc\u06ba \u06a9\u0631\u0646\u0627 \u0686\u0627\u06c1\u06cc\u06d2\u06d4 \u0641\u0627\u0626\u0644 \u0627\u067e \u0644\u0648\u0688 \u0646\u0627\u06a9\u0627\u0645 \u06c1\u0648 \u0633\u06a9\u062a\u0627 \u06c1\u06d2\u060c API \u0627\u06cc\u06a9 \u063a\u0644\u0637\u06cc \u0648\u0627\u067e\u0633 \u06a9\u0631 \u0633\u06a9\u062a\u0627 \u06c1\u06d2\u060c \u0635\u0627\u0631\u0641 \u063a\u0644\u0637 \u0631\u0627\u0633\u062a\u06c1 \u062f\u0627\u062e\u0644 \u06a9\u0631 \u0633\u06a9\u062a\u0627 \u06c1\u06d2\u060c \u06cc\u0627 \u0646\u06cc\u0679 \u0648\u0631\u06a9 \u0639\u0627\u0631\u0636\u06cc \u0637\u0648\u0631 \u067e\u0631 \u0646\u0627\u06a9\u0627\u0645 \u06c1\u0648 \u0633\u06a9\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u06c1\u0645 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba <code>try<\/code> \u0627\u0648\u0631 <code>except<\/code> \u0627\u0646 \u062d\u0627\u0644\u0627\u062a \u0633\u06d2 \u0646\u0645\u0679\u0646\u06d2 \u06a9\u06d2 \u0644\u06cc\u06d2\u06d4<\/p>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631:<\/p>\n<pre><code class=\"language-python\">try:\n    response = client.responses.create(\n        model=\"gpt-5\",\n        instructions=instructions,\n        input=[\n            {\n                \"role\": \"user\",\n                \"content\": [\n                    {\n                        \"type\": \"input_text\",\n                        \"text\": question\n                    },\n                    {\n                        \"type\": \"input_file\",\n                        \"file_id\": uploaded_file.id\n                    }\n                ]\n            }\n        ]\n    )\n\n    print(response.output_text)\n\nexcept Exception as error:\n    print(\"Something went wrong:\")\n    print(error)\n<\/code><\/pre>\n<ul>\n<li>\n<p><code>try<\/code>: \u0627\u0646\u062f\u0631 \u06a9\u0648\u0688 <code>try<\/code> \u0628\u0644\u0627\u06a9 \u0627\u06cc\u06a9 \u06a9\u0648\u0688 \u06c1\u06d2 \u062c\u0648 \u0646\u0627\u06a9\u0627\u0645 \u06c1\u0648 \u0633\u06a9\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<\/li>\n<li>\n<p><code>except<\/code>: \u062c\u0628 \u06a9\u0648\u0626\u06cc \u062e\u0631\u0627\u0628\u06cc \u06c1\u0648\u062a\u06cc \u06c1\u06d2\u060c Python <code>except<\/code> \u0628\u0644\u0627\u06a9<\/p>\n<\/li>\n<li>\n<p><code>Exception as error<\/code>: \u063a\u0644\u0637\u06cc\u0648\u06ba \u06a9\u0648 \u067e\u06a9\u0691\u0627 \u0627\u0648\u0631 \u062f\u06a9\u06be\u0627\u06cc\u0627 \u062c\u0627 \u0633\u06a9\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<\/li>\n<\/ul>\n<p>\u0645\u0628\u06c1\u0645 \u0628\u06cc\u06a9 \u0679\u0631\u06cc\u06a9\u0646\u06af \u06a9\u06cc \u0648\u062c\u06c1 \u0633\u06d2 \u067e\u0648\u0631\u06cc \u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646 \u06a9\u0631\u06cc\u0634 \u06c1\u0648\u0646\u06d2 \u06a9\u06d2 \u0628\u062c\u0627\u0626\u06d2\u060c \u0635\u0627\u0631\u0641 \u062f\u06cc\u06a9\u06be\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">Something went wrong:\n...\n<\/code><\/pre>\n<p>\u067e\u0631\u0648\u0688\u06a9\u0634\u0646 \u0627\u06cc\u067e\u0644\u06cc \u06a9\u06cc\u0634\u0646\u0632 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0622\u067e \u0639\u0627\u0645 \u0637\u0648\u0631 \u067e\u0631 \u0632\u06cc\u0627\u062f\u06c1 \u0646\u0641\u06cc\u0633 \u0644\u0627\u06af\u0646\u06af \u0627\u0648\u0631 \u0627\u06cc\u0631\u0631 \u06c1\u06cc\u0646\u0688\u0644\u0646\u06af \u0686\u0627\u06c1\u062a\u06d2 \u06c1\u06cc\u06ba\u060c \u0644\u06cc\u06a9\u0646 \u06cc\u06c1 \u0627\u06cc\u06a9 \u0627\u0686\u06be\u0627 \u0646\u0642\u0637\u06c1 \u0622\u063a\u0627\u0632 \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-step-20-validate-the-file-extension\">\u0645\u0631\u062d\u0644\u06c1 20: \u0641\u0627\u0626\u0644 \u06a9\u06cc \u062a\u0648\u0633\u06cc\u0639 \u06a9\u0648 \u0686\u06cc\u06a9 \u06a9\u0631\u06cc\u06ba\u06d4<\/h2>\n<p>\u0622\u067e \u0627\u067e\u0646\u06cc \u0645\u0646\u062a\u062e\u0628 \u06a9\u0631\u062f\u06c1 \u0641\u0627\u0626\u0644 \u06a9\u06cc \u0642\u0633\u0645 \u06a9\u0648 \u0628\u06be\u06cc \u0686\u06cc\u06a9 \u06a9\u0631 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0634\u0627\u0645\u0644 \u06a9\u0631\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">allowed_extensions = {\n    \".pdf\",\n    \".txt\",\n    \".docx\",\n    \".csv\"\n}\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0641\u0627\u0626\u0644 \u0627\u06cc\u06a9\u0633\u0679\u06cc\u0646\u0634\u0646\u0632 \u06a9\u0627 \u0627\u06cc\u06a9 \u0633\u06cc\u0679 \u0628\u0646\u0627\u062a\u0627 \u06c1\u06d2 \u062c\u0633 \u06a9\u06cc \u0622\u067e \u06a9\u06cc \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u06a9\u06cc \u062d\u0645\u0627\u06cc\u062a \u06a9\u06cc \u062a\u0648\u0642\u0639 \u06a9\u06cc \u062c\u0627\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<p>\u067e\u06be\u0631:<\/p>\n<pre><code class=\"language-python\">extension = os.path.splitext(file_path)[1].lower()\n<\/code><\/pre>\n<p>\u0622\u0626\u06cc\u06d2 \u0627\u0633 \u06a9\u0627 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<h3 id=\"heading-ospathsplitext\"><code>os.path.splitext()<\/code><\/h3>\n<p>\u06cc\u06c1 \u0641\u0627\u0626\u0644 \u06a9\u0627 \u0646\u0627\u0645 \u0627\u06cc\u06a9\u0633\u0679\u06cc\u0646\u0634\u0646 \u0633\u06d2 \u0627\u0644\u06af \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u06a9\u06d2 \u0644\u06cc\u06d2:<\/p>\n<pre><code class=\"language-text\">research.pdf\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u06c1\u0645\u06cc\u06ba \u062a\u0642\u0631\u06cc\u0628\u0627\u064b \u062f\u06cc\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">research\n<\/code><\/pre>\n<p>\u0627\u0648\u0631:<\/p>\n<pre><code class=\"language-text\">.pdf\n<\/code><\/pre>\n<p>\u06a9\u06c1 <code>[1]<\/code> \u0627\u06cc\u06a9 \u062a\u0648\u0633\u06cc\u0639 \u0645\u0646\u062a\u062e\u0628 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<p>\u067e\u06be\u0631:<\/p>\n<pre><code class=\"language-python\">.lower()\n<\/code><\/pre>\n<p>\u0686\u06be\u0648\u0679\u06d2 \u062d\u0631\u0648\u0641 \u0645\u06cc\u06ba \u062a\u0628\u062f\u06cc\u0644 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<p>\u062a\u0648:<\/p>\n<pre><code class=\"language-text\">RESEARCH.PDF\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0627\u0633 \u0637\u0631\u062d \u062c\u0627\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">.pdf\n<\/code><\/pre>\n<p>\u0627\u0628 \u0622\u067e \u0686\u06cc\u06a9 \u06a9\u0631 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">if extension not in allowed_extensions:\n    print(\"Unsupported file type.\")\n    exit()\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0635\u0627\u0631\u0641\u06cc\u0646 \u06a9\u0648 \u0627\u0646 \u0641\u0627\u0626\u0644\u0648\u06ba \u06a9\u06cc \u0627\u0642\u0633\u0627\u0645 \u06a9\u0648 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u0646\u06d2 \u0633\u06d2 \u0631\u0648\u06a9\u062a\u0627 \u06c1\u06d2 \u062c\u0646 \u06a9\u0648 \u0633\u0646\u0628\u06be\u0627\u0644\u0646\u06d2 \u06a9\u06d2 \u0644\u06cc\u06d2 \u06c1\u0645\u0627\u0631\u06cc \u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646 \u0688\u06cc\u0632\u0627\u0626\u0646 \u0646\u06c1\u06cc\u06ba \u06a9\u06cc \u06af\u0626\u06cc \u06c1\u06d2\u06d4<\/p>\n<p>\u0627\u067e\u0646\u06cc \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u06a9\u0648 \u0628\u0691\u06be\u0627\u0646\u06d2 \u0633\u06d2 \u067e\u06c1\u0644\u06d2 \u06c1\u0645\u06cc\u0634\u06c1 \u0627\u067e\u0646\u06d2 \u0645\u0646\u062a\u062e\u0628 \u06a9\u0631\u062f\u06c1 API \u0627\u0648\u0631 \u0645\u0627\u0688\u0644 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0641\u06cc \u0627\u0644\u062d\u0627\u0644 \u062a\u0639\u0627\u0648\u0646 \u06cc\u0627\u0641\u062a\u06c1 \u0641\u0627\u0626\u0644 \u0641\u0627\u0631\u0645\u06cc\u0679\u0633 \u06a9\u0648 \u0686\u06cc\u06a9 \u06a9\u0631\u06cc\u06ba\u06d4 OpenAI \u06a9\u06cc \u0641\u0627\u0626\u0644 \u0627\u0648\u0631 \u0627\u0646 \u067e\u0679 API \u062f\u0633\u062a\u0627\u0648\u06cc\u0632\u0627\u062a \u0641\u0627\u0626\u0644 \u067e\u0631\u0648\u0633\u06cc\u0633\u0646\u06af \u0627\u0648\u0631 \u0645\u0639\u0627\u0648\u0646 \u0627\u0646 \u067e\u0679 \u0627\u0642\u0633\u0627\u0645\u06d4<\/p>\n<h2 id=\"heading-step-21-add-a-file-name-to-the-interface\">\u0645\u0631\u062d\u0644\u06c1 21: \u0627\u0646\u0679\u0631\u0641\u06cc\u0633 \u0645\u06cc\u06ba \u0641\u0627\u0626\u0644 \u06a9\u0627 \u0646\u0627\u0645 \u0634\u0627\u0645\u0644 \u06a9\u0631\u06cc\u06ba\u06d4<\/h2>\n<p>\u06cc\u06c1 \u0622\u067e \u06a9\u06d2 \u0679\u0631\u0645\u06cc\u0646\u0644 \u06a9\u06d2 \u062a\u062c\u0631\u0628\u06d2 \u06a9\u0648 \u062a\u06be\u0648\u0691\u0627 \u0628\u06c1\u062a\u0631 \u0628\u0646\u0627 \u0633\u06a9\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0628\u062c\u0627\u0626\u06d2:<\/p>\n<pre><code class=\"language-python\">print(\"Uploaded file:\", uploaded_file.id)\n<\/code><\/pre>\n<p>\u06c1\u0645 \u0644\u06a9\u06be \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">print(f\"\\nSuccessfully uploaded: {os.path.basename(file_path)}\")\n<\/code><\/pre>\n<p>\u06a9\u06c1 <code>f<\/code> \u0627\u0633 \u0633\u06d2 \u067e\u06c1\u0644\u06d2 \u06a9\u06c1 \u0633\u0679\u0631\u0646\u06af \u0627\u06cc\u0641 \u0633\u0679\u0631\u0646\u06af \u067e\u06cc\u062f\u0627 \u06a9\u0631\u06d2\u06d4<\/p>\n<p>\u06cc\u06c1 \u0622\u067e \u06a9\u0648 Python \u0645\u062a\u063a\u06cc\u0631\u0627\u062a \u06a9\u06d2 \u0627\u0646\u062f\u0631 \u062f\u0627\u062e\u0644 \u06a9\u0631\u0646\u06d2 \u06a9\u06cc \u0627\u062c\u0627\u0632\u062a \u062f\u06cc\u062a\u0627 \u06c1\u06d2\u06d4 <code>{}<\/code>.<\/p>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631:<\/p>\n<pre><code class=\"language-python\">f\"Successfully uploaded: {os.path.basename(file_path)}\"\n<\/code><\/pre>\n<p>\u0622\u067e \u062a\u0634\u06a9\u06cc\u0644 \u062f\u06d2 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">Successfully uploaded: research.pdf\n<\/code><\/pre>\n<h3 id=\"heading-ospathbasename\"><code>os.path.basename()<\/code><\/h3>\n<p>\u06cc\u06c1 \u0631\u0627\u0633\u062a\u06d2 \u0633\u06d2 \u0635\u0631\u0641 \u0641\u0627\u0626\u0644 \u06a9\u0627 \u0646\u0627\u0645 \u0646\u06a9\u0627\u0644\u06d2 \u06af\u0627\u06d4<\/p>\n<p>\u0627\u06af\u0631 \u0635\u0627\u0631\u0641 \u0679\u0627\u0626\u067e \u06a9\u0631\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">documents\/research.pdf\n<\/code><\/pre>\n<p>\u067e\u06be\u0631:<\/p>\n<pre><code class=\"language-python\">os.path.basename(file_path)\n<\/code><\/pre>\n<p>\u0631\u067e\u0648\u0631\u0679:<\/p>\n<pre><code class=\"language-text\">research.pdf\n<\/code><\/pre>\n<h2 id=\"heading-step-22-build-the-clean-final-version\">\u0645\u0631\u062d\u0644\u06c1 22: \u0627\u06cc\u06a9 \u06a9\u0644\u06cc\u0646 \u0641\u0627\u0626\u0646\u0644 \u0648\u0631\u0698\u0646 \u0628\u0646\u0627\u0626\u06cc\u06ba<\/h2>\n<p>\u0627\u0628 \u06c1\u0645 \u0633\u0628 \u06a9\u0686\u06be \u0627\u06cc\u06a9 \u0633\u0627\u062a\u06be \u0688\u0627\u0644\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u06cc\u06c1\u0627\u06ba \u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646 \u06a9\u0627 \u0635\u0627\u0641 \u0648\u0631\u0698\u0646 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-python\">import os\n\nfrom openai import OpenAI\n\n\n# Create the OpenAI client.\nclient = OpenAI()\n\n\n# Ask the user for a file.\nfile_path = input(\"Enter the path to your file: \").strip()\n\n\n# Make sure the file exists.\nif not os.path.exists(file_path):\n    print(\"File not found.\")\n    exit()\n\n\n# Allowed file types.\nallowed_extensions = {\n    \".pdf\",\n    \".txt\",\n    \".docx\",\n    \".csv\"\n}\n\n\n# Get the file extension.\nextension = os.path.splitext(file_path)[1].lower()\n\n\n# Make sure the file type is supported by our application.\nif extension not in allowed_extensions:\n    print(f\"Unsupported file type: {extension}\")\n    print(\"Supported types:\", \", \".join(allowed_extensions))\n    exit()\n\n\n# Upload the file.\ntry:\n    with open(file_path, \"rb\") as file:\n        uploaded_file = client.files.create(\n            file=file,\n            purpose=\"user_data\"\n        )\n\nexcept Exception as error:\n    print(\"The file could not be uploaded.\")\n    print(error)\n    exit()\n\n\nprint(f\"\\nSuccessfully uploaded: {os.path.basename(file_path)}\")\n\n\n# Define the agent's behavior.\ninstructions = \"\"\"\nYou are an AI file analysis assistant.\n\nYour job is to analyze the file provided by the user.\n\nFollow these rules:\n\n1. Use the provided file as your primary source.\n2. Answer the user's question directly.\n3. Do not invent information that is not supported by the file.\n4. If the file does not contain enough information to answer a question, say so.\n5. When summarizing, focus on the most important information.\n6. When comparing ideas, clearly explain similarities and differences.\n7. When analyzing research, distinguish between methods, results, and conclusions.\n8. Use simple language unless the user asks for technical language.\n9. Use bullet points when they make the answer easier to understand.\n10. If you make an inference, clearly label it as an inference.\n\"\"\"\n\n\n# Start the conversation.\nprint(\"\\nYour file is ready to analyze.\")\nprint(\"Ask questions about the file.\")\nprint(\"Type 'exit' when you are finished.\")\n\n\nwhile True:\n\n    # Get a question from the user.\n    question = input(\"\\nYou: \").strip()\n\n\n    # Stop the program if the user wants to exit.\n    if question.lower() == \"exit\":\n        print(\"Goodbye!\")\n        break\n\n\n    # Ignore empty questions.\n    if not question:\n        print(\"Please enter a question.\")\n        continue\n\n\n    # Send the question and file to the model.\n    try:\n        response = client.responses.create(\n            model=\"gpt-5\",\n            instructions=instructions,\n            input=[\n                {\n                    \"role\": \"user\",\n                    \"content\": [\n                        {\n                            \"type\": \"input_text\",\n                            \"text\": question\n                        },\n                        {\n                            \"type\": \"input_file\",\n                            \"file_id\": uploaded_file.id\n                        }\n                    ]\n                }\n            ]\n        )\n\n\n        # Display the AI's response.\n        print(\"\\nAgent:\")\n        print(response.output_text)\n\n\n    except Exception as error:\n        print(\"\\nThe agent encountered an error.\")\n        print(error)\n<\/code><\/pre>\n<h3 id=\"heading-lets-understand-the-architecture\">\u0622\u0626\u06cc\u06d2 \u0641\u0646 \u062a\u0639\u0645\u06cc\u0631 \u06a9\u0648 \u0633\u0645\u062c\u06be\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/h3>\n<p>\u0627\u0633 \u0648\u0642\u062a \u06a9\u0648\u0688 \u0633\u06d2 \u0627\u0644\u06af \u06c1\u0648\u0646\u0627 \u0645\u0641\u06cc\u062f \u06c1\u06d2\u06d4 \u06c1\u0645\u0627\u0631\u06cc \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u0645\u06cc\u06ba \u06a9\u0626\u06cc \u067e\u0631\u062a\u06cc\u06ba \u06c1\u06cc\u06ba\u06d4<\/p>\n<h4 id=\"heading-layer-1-user-interface\">\u067e\u0631\u062a 1: \u06cc\u0648\u0632\u0631 \u0627\u0646\u0679\u0631\u0641\u06cc\u0633<\/h4>\n<p>\u0679\u0631\u0645\u06cc\u0646\u0644 \u067e\u0648\u0686\u06be\u06d2 \u06af\u0627:<\/p>\n<pre><code class=\"language-text\">Enter the path to your file:\n<\/code><\/pre>\n<p>\u0627\u0648\u0631:<\/p>\n<pre><code class=\"language-text\">You:\n<\/code><\/pre>\n<p>\u0627\u0633 \u0637\u0631\u062d \u0635\u0627\u0631\u0641 \u0627\u06cc\u067e\u0644\u06cc \u06a9\u06cc\u0634\u0646 \u06a9\u06d2 \u0633\u0627\u062a\u06be \u062a\u0639\u0627\u0645\u0644 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<h4 id=\"heading-layer-2-file-handling\">\u0679\u0627\u0626\u0631 2: \u0641\u0627\u0626\u0644 \u067e\u0631\u0648\u0633\u06cc\u0633\u0646\u06af<\/h4>\n<p>\u0627\u0632\u06af\u0631 \u06a9\u0627 \u0645\u0639\u0627\u0626\u0646\u06c1:<\/p>\n<pre><code class=\"language-python\">os.path.exists(file_path)\n<\/code><\/pre>\n<p>\u0627\u0648\u0631 \u06cc\u06c1 \u06a9\u06be\u0644\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-python\">open(file_path, \"rb\")\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u067e\u0631\u062a \u0645\u0642\u0627\u0645\u06cc \u0641\u0627\u0626\u0644\u0648\u06ba \u06a9\u0648 \u06c1\u06cc\u0646\u0688\u0644 \u06a9\u0631\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<h4 id=\"heading-layer-3-file-upload\">\u067e\u0631\u062a 3: \u0641\u0627\u0626\u0644 \u0627\u067e \u0644\u0648\u0688<\/h4>\n<p>\u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646 \u0641\u0627\u0626\u0644 \u06a9\u0648 API \u06a9\u0648 \u0628\u06be\u06cc\u062c\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<pre><code class=\"language-python\">client.files.create(...)\n<\/code><\/pre>\n<p>API \u0627\u06cc\u06a9 \u0641\u0627\u0626\u0644 ID \u0641\u0631\u0627\u06c1\u0645 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<h4 id=\"heading-layer-4-agent-instructions\">\u0679\u0627\u0626\u0631 4: \u0627\u06cc\u062c\u0646\u0679 \u06a9\u06d2 \u0631\u06c1\u0646\u0645\u0627 \u062e\u0637\u0648\u0637<\/h4>\n<p>\u06c1\u0645 \u062a\u0639\u0631\u06cc\u0641 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">instructions\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0645\u0627\u0688\u0644 \u06a9\u0648 \u0628\u062a\u0627\u062a\u0627 \u06c1\u06d2 \u06a9\u06c1 \u06a9\u0633 \u0637\u0631\u062d \u0628\u0631\u062a\u0627\u0624 \u06a9\u0631\u0646\u0627 \u06c1\u06d2\u06d4<\/p>\n<h4 id=\"heading-layer-5-user-request\">\u067e\u0631\u062a 5: \u0635\u0627\u0631\u0641 \u06a9\u06cc \u062f\u0631\u062e\u0648\u0627\u0633\u062a<\/h4>\n<p>\u0627\u06cc\u06a9 \u0635\u0627\u0631\u0641 \u067e\u0648\u0686\u06be\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">What are the main findings?\n<\/code><\/pre>\n<h4 id=\"heading-layer-6-model\">\u067e\u0631\u062a 6: \u0645\u0627\u0688\u0644<\/h4>\n<p>\u0645\u0627\u0688\u0644 \u062d\u0627\u0635\u0644 \u06a9\u0631\u062a\u0627 \u06c1\u06d2:<\/p>\n<ul>\n<li>\n<p>\u0631\u06c1\u0646\u0645\u0627 \u062e\u0637\u0648\u0637<\/p>\n<\/li>\n<li>\n<p>\u0633\u0648\u0627\u0644<\/p>\n<\/li>\n<li>\n<p>\u0641\u0627\u0626\u0644<\/p>\n<\/li>\n<\/ul>\n<p>\u0627\u0648\u0631 \u06cc\u06c1 \u0627\u06cc\u06a9 \u062c\u0648\u0627\u0628 \u067e\u06cc\u062f\u0627 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<h4 id=\"heading-layer-7-output\">\u067e\u0631\u062a 7: \u0622\u0624\u0679 \u067e\u0679<\/h4>\n<p>\u06c1\u0645 \u062f\u06a9\u06be\u0627\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">response.output_text\n<\/code><\/pre>\n<p>\u0635\u0627\u0631\u0641\u06cc\u0646 \u06a9\u0648\u06d4<\/p>\n<p>\u06cc\u06c1 \u0639\u0644\u06cc\u062d\u062f\u06af\u06cc \u0645\u0641\u06cc\u062f \u06c1\u06d2 \u06a9\u06cc\u0648\u0646\u06a9\u06c1 \u0627\u0633 \u0633\u06d2 \u0628\u0639\u062f \u0645\u06cc\u06ba \u067e\u0631\u0627\u062c\u06cc\u06a9\u0679 \u06a9\u0648 \u0628\u0691\u06be\u0627\u0646\u0627 \u0622\u0633\u0627\u0646 \u06c1\u0648 \u062c\u0627\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0627\u0628\u062a\u062f\u0627\u0626\u06cc \u0633\u0648\u0627\u0644\u0627\u062a \u067e\u0648\u0686\u06be \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba \u062c\u06cc\u0633\u06d2:<\/p>\n<blockquote>\n<p>&quot;\u067e\u06c1\u0644\u06d2 \u062a\u0645\u0627\u0645 \u0645\u062a\u0646 \u06a9\u0648 \u0646\u06a9\u0627\u0644\u0646\u06d2 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0627\u0632\u06af\u0631 \u06a9\u0627 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u06cc\u0648\u06ba \u0646\u06c1\u06cc\u06ba \u06a9\u0631\u062a\u06d2\u061f&#8221;<\/p>\n<\/blockquote>\n<p>\u06cc\u06c1 \u0628\u0627\u0644\u06a9\u0644 \u0645\u0645\u06a9\u0646 \u06c1\u06d2\u06d4 \u0622\u067e \u062f\u0631\u062c \u0630\u06cc\u0644 \u0644\u0627\u0626\u0628\u0631\u06cc\u0631\u06cc\u0648\u06ba \u06a9\u0648 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">PyPDF\npython-docx\npandas\n<\/code><\/pre>\n<p>\u0641\u0627\u0626\u0644 \u0641\u0627\u0631\u0645\u06cc\u0679\u0633 \u06a9\u06cc \u0627\u06cc\u06a9 \u0642\u0633\u0645 \u0628\u0631\u0627\u06c1 \u0631\u0627\u0633\u062a \u067e\u0691\u06be\u06cc \u062c\u0627 \u0633\u06a9\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<p>\u0646\u06a9\u0627\u0644\u0627 \u06c1\u0648\u0627 \u0645\u062a\u0646 \u067e\u06be\u0631 AI \u0645\u0627\u0688\u0644 \u06a9\u0648 \u0628\u06be\u06cc\u062c\u0627 \u062c\u0627 \u0633\u06a9\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u06cc\u06c1 \u0646\u0642\u0637\u06c1 \u0646\u0638\u0631 \u062e\u0627\u0635 \u0637\u0648\u0631 \u067e\u0631 \u0645\u0641\u06cc\u062f \u06c1\u0648 \u0633\u06a9\u062a\u0627 \u06c1\u06d2 \u062c\u0628 \u062d\u0633\u0628 \u0636\u0631\u0648\u0631\u062a \u067e\u0631\u06cc \u067e\u0631\u0648\u0633\u06cc\u0633\u0646\u06af \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u06c1\u0648\u06d4 \u0644\u06cc\u06a9\u0646 \u06cc\u06c1 \u0645\u0632\u06cc\u062f \u06a9\u0627\u0645 \u0628\u06be\u06cc \u067e\u06cc\u062f\u0627 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0622\u067e \u06a9\u0648 \u0627\u0644\u06af \u0627\u0644\u06af \u0645\u0646\u0637\u0642 \u0644\u06a9\u06be\u0646\u06d2 \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u06c1\u0648\u06af\u06cc:<\/p>\n<pre><code class=\"language-text\">PDF \u2192 extract text\nDOCX \u2192 extract text\nCSV \u2192 read rows\nTXT \u2192 read text\n<\/code><\/pre>\n<p>\u067e\u06be\u0631 \u06c1\u0645\u06cc\u06ba \u06cc\u06c1 \u0645\u0639\u0644\u0648\u0645 \u06a9\u0631\u0646\u06d2 \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u06c1\u06d2 \u06a9\u06c1 \u0648\u06c1 \u062a\u0645\u0627\u0645 \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u0645\u0627\u0688\u0644 \u06a9\u0648 \u06a9\u06cc\u0633\u06d2 \u0628\u06be\u06cc\u062c\u06cc\u06ba\u06d4<\/p>\n<p>\u0641\u0627\u0626\u0644 \u0627\u0646 \u067e\u0679 API \u06a9\u0648 \u0628\u0631\u0627\u06c1 \u0631\u0627\u0633\u062a \u0641\u0627\u0626\u0644\u0648\u06ba \u06a9\u0648 \u0642\u0628\u0648\u0644 \u06a9\u0631\u0646\u06d2 \u06a9\u06cc \u0627\u062c\u0627\u0632\u062a \u062f\u06cc\u062a\u0627 \u06c1\u06d2\u060c \u0645\u0639\u0627\u0648\u0646 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u06d2 \u0645\u0639\u0627\u0645\u0644\u0627\u062a \u06a9\u06d2 \u0644\u06cc\u06d2 \u0641\u0646 \u062a\u0639\u0645\u06cc\u0631 \u06a9\u0648 \u0622\u0633\u0627\u0646 \u0628\u0646\u0627\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<h3 id=\"heading-but-what-about-very-large-files\">\u0644\u06cc\u06a9\u0646 \u0628\u06c1\u062a \u0628\u0691\u06cc \u0641\u0627\u0626\u0644\u0648\u06ba \u06a9\u0627 \u06a9\u06cc\u0627 \u06c1\u0648\u06af\u0627\u061f<\/h3>\n<p>\u06cc\u06c1 \u0648\u06c1 \u062c\u06af\u06c1 \u06c1\u06d2 \u062c\u06c1\u0627\u06ba \u0686\u06cc\u0632\u06cc\u06ba \u0632\u06cc\u0627\u062f\u06c1 \u062f\u0644\u0686\u0633\u067e \u06c1\u0648\u062a\u06cc \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u062a\u0635\u0648\u0631 \u06a9\u0631\u06cc\u06ba \u06a9\u06c1 \u06a9\u0648\u0626\u06cc \u0635\u0627\u0631\u0641 2,000 \u0635\u0641\u062d\u0627\u062a \u067e\u0631 \u0645\u062d\u06cc\u0637 \u062f\u0633\u062a\u0627\u0648\u06cc\u0632\u0627\u062a \u06a9\u0627 \u0645\u062c\u0645\u0648\u0639\u06c1 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4 \u0622\u067e \u0634\u0627\u06cc\u062f \u06c1\u0631 \u0627\u06cc\u06a9 \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u0645\u06cc\u06ba \u0633\u0628 \u06a9\u0686\u06be \u0646\u06c1\u06cc\u06ba \u0628\u06be\u06cc\u062c\u0646\u0627 \u0686\u0627\u06c1\u062a\u06d2\u06d4<\/p>\n<p>\u0627\u0633 \u06a9\u06d2 \u0628\u062c\u0627\u0626\u06d2\u060c \u0622\u067e \u06a9\u0648 \u0627\u06cc\u06a9 \u0627\u06cc\u0633\u06d2 \u0646\u0638\u0627\u0645 \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u06c1\u0648 \u0633\u06a9\u062a\u06cc \u06c1\u06d2 \u062c\u0648 \u0633\u0628 \u0633\u06d2 \u0632\u06cc\u0627\u062f\u06c1 \u0645\u062a\u0639\u0644\u0642\u06c1 \u062d\u0635\u0648\u06ba \u06a9\u0648 \u062a\u0644\u0627\u0634 \u06a9\u0631 \u0633\u06a9\u06d2\u06d4 \u06cc\u06c1 \u062c\u06af\u06c1 <strong>\u062a\u0644\u0627\u0634 \u06a9\u0631\u06cc\u06ba<\/strong> \u06cc\u06c1 \u0627\u06c1\u0645 \u06c1\u0648 \u062c\u0627\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0627\u06cc\u06a9 \u0639\u0627\u0645 \u0641\u0646 \u062a\u0639\u0645\u06cc\u0631 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">Documents\n    \u2193\nSplit into chunks\n    \u2193\nCreate embeddings\n    \u2193\nStore searchable representations\n    \u2193\nUser asks question\n    \u2193\nFind relevant chunks\n    \u2193\nSend relevant information to model\n    \u2193\nGenerate answer\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0646\u0642\u0637\u06c1 \u0646\u0638\u0631 \u0639\u0627\u0645 \u0637\u0648\u0631 \u067e\u0631 \u0627\u0633 \u0633\u06d2 \u0648\u0627\u0628\u0633\u062a\u06c1 \u06c1\u06d2: <strong>\u062a\u0644\u0627\u0634 \u0645\u06cc\u06ba \u0627\u0636\u0627\u0641\u06c1 \u0628\u0646\u0627\u0626\u06cc\u06ba<\/strong>\u06cc\u0627 RAG\u06d4<\/p>\n<p>OpenAI \u0627\u06cc\u06a9 \u0641\u0627\u0626\u0644 \u0633\u0631\u0686 \u0679\u0648\u0644 \u0628\u06be\u06cc \u0641\u0631\u0627\u06c1\u0645 \u06a9\u0631\u062a\u0627 \u06c1\u06d2 \u062c\u0648 \u0622\u067e \u06a9\u0648 \u0648\u06cc\u06a9\u0679\u0631 \u0627\u0633\u0679\u0648\u0631 \u06a9\u0627 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631\u062a\u06d2 \u06c1\u0648\u0626\u06d2 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u062f\u06c1 \u0641\u0627\u0626\u0644\u0648\u06ba \u06a9\u0648 \u062a\u0644\u0627\u0634 \u06a9\u0631\u0646\u06d2 \u06a9\u06cc \u0627\u062c\u0627\u0632\u062a \u062f\u06cc\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0627\u067e\u0646\u06d2 \u067e\u06c1\u0644\u06d2 \u067e\u0631\u0648\u062c\u06cc\u06a9\u0679 \u0645\u06cc\u06ba\u060c \u06c1\u0645 \u0646\u06d2 \u062c\u0627\u0646 \u0628\u0648\u062c\u06be \u06a9\u0631 RAG \u0645\u062a\u0639\u0627\u0631\u0641 \u0646\u06c1\u06cc\u06ba \u06a9\u0631\u0627\u06cc\u0627 \u06a9\u06cc\u0648\u0646\u06a9\u06c1 \u06c1\u0645 \u0627\u06cc\u06a9 \u0633\u0627\u062a\u06be \u0628\u06c1\u062a \u0633\u0627\u0631\u06d2 \u062a\u0635\u0648\u0631\u0627\u062a \u0634\u0627\u0645\u0644 \u06a9\u0631 \u0631\u06c1\u06d2 \u062a\u06be\u06d2\u06d4<\/p>\n<p>\u067e\u06c1\u0644\u06d2 \u0628\u0631\u0627\u06c1 \u0631\u0627\u0633\u062a \u0641\u0627\u0626\u0644 \u06a9\u06d2 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u0648 \u0633\u0645\u062c\u06be\u06cc\u06ba\u06d4 \u067e\u06be\u0631 \u062a\u0644\u0627\u0634 \u06a9\u0631\u0646\u0627 \u0633\u06cc\u06a9\u06be\u06cc\u06ba\u06d4 \u067e\u06be\u0631 \u062f\u0648\u0646\u0648\u06ba \u06a9\u0648 \u0645\u0644\u0627 \u062f\u06cc\u06ba\u06d4<\/p>\n<h3 id=\"heading-direct-file-input-vs-rag\">\u0628\u0631\u0627\u06c1 \u0631\u0627\u0633\u062a \u0641\u0627\u0626\u0644 \u0627\u0646 \u067e\u0679 \u0627\u0648\u0631 RAG<\/h3>\n<p>\u0627\u062e\u062a\u0644\u0627\u0641\u0627\u062a \u06a9\u0648 \u0633\u0645\u062c\u06be\u0646\u0627 \u0645\u0641\u06cc\u062f \u06c1\u06d2\u06d4<\/p>\n<h4 id=\"heading-direct-file-input\">\u0628\u0631\u0627\u06c1 \u0631\u0627\u0633\u062a \u0641\u0627\u0626\u0644 \u0627\u0646 \u067e\u0679<\/h4>\n<p>\u0645\u0627\u0688\u0644 \u06a9\u0648 \u0645\u062e\u0635\u0648\u0635 \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u06a9\u06d2 \u0644\u06cc\u06d2 \u0641\u0627\u0626\u0644\u0648\u06ba \u06a9\u06d2 \u0633\u0627\u062a\u06be \u0641\u0631\u0627\u06c1\u0645 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631:<\/p>\n<pre><code class=\"language-text\">Upload:\nresearch-paper.pdf\n\nQuestion:\nWhat was the main conclusion?\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0628\u06c1\u062a \u0633\u06cc \u0686\u06be\u0648\u0679\u06cc \u0627\u06cc\u067e\u0644\u06cc \u06a9\u06cc\u0634\u0646\u0632 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0622\u0633\u0627\u0646 \u0627\u0648\u0631 \u0645\u0648\u0632\u0648\u06ba \u06c1\u06d2\u06d4<\/p>\n<h4 id=\"heading-rag\">\u0679\u06a9\u0691\u0627<\/h4>\n<p>\u062f\u0633\u062a\u0627\u0648\u06cc\u0632\u0627\u062a \u06a9\u06d2 \u0627\u0648\u0631 \u0628\u06be\u06cc \u0628\u06c1\u062a \u0633\u0627\u0631\u06d2 \u0645\u062c\u0645\u0648\u0639\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631:<\/p>\n<pre><code class=\"language-text\">100 research papers\n50 reports\n20 manuals\n<\/code><\/pre>\n<p>\u06c1\u0631 \u0633\u0648\u0627\u0644 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0645\u0627\u0688\u0644 \u06a9\u0648 \u062a\u0645\u0627\u0645 \u062f\u0633\u062a\u0627\u0648\u06cc\u0632\u0627\u062a \u0641\u0631\u0627\u06c1\u0645 \u06a9\u0631\u0646\u06d2 \u06a9\u06d2 \u0628\u062c\u0627\u0626\u06d2\u060c \u06c1\u0645 \u067e\u06c1\u0644\u06d2 \u0645\u062a\u0639\u0644\u0642\u06c1 \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u06a9\u0627 \u0645\u062c\u0645\u0648\u0639\u06c1 \u0628\u0627\u0632\u06cc\u0627\u0641\u062a \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4 \u067e\u06be\u0631 \u06c1\u0645 \u0645\u062a\u0639\u0644\u0642\u06c1 \u062d\u0635\u0648\u06ba \u06a9\u0648 \u0645\u0627\u0688\u0644 \u0645\u06cc\u06ba \u06a9\u06be\u0644\u0627\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u06cc\u06c1 \u0628\u0691\u06d2 \u0639\u0644\u0645\u06cc \u0627\u0688\u0648\u06ba \u06a9\u06d2 \u0644\u06cc\u06d2 \u0632\u06cc\u0627\u062f\u06c1 \u062a\u0648\u0633\u06cc\u0639 \u067e\u0630\u06cc\u0631 \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-step-23-make-the-agent-better-at-different-types-of-files\">\u0645\u0631\u062d\u0644\u06c1 23: \u0645\u062e\u062a\u0644\u0641 \u0641\u0627\u0626\u0644 \u06a9\u06cc \u0627\u0642\u0633\u0627\u0645 \u067e\u0631 \u0627\u06cc\u062c\u0646\u0679 \u06a9\u06cc \u06a9\u0627\u0631\u06a9\u0631\u062f\u06af\u06cc \u06a9\u0648 \u0628\u06c1\u062a\u0631 \u0628\u0646\u0627\u0626\u06cc\u06ba<\/h2>\n<p>\u0645\u062e\u062a\u0644\u0641 \u0641\u0627\u0626\u0644\u0648\u06ba \u0645\u06cc\u06ba \u0645\u062e\u062a\u0644\u0641 \u0642\u0633\u0645 \u06a9\u06cc \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u06c1\u0648\u062a\u06cc \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>PDF \u0645\u06cc\u06ba \u0634\u0627\u0645\u0644 \u06c1\u0648 \u0633\u06a9\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">Research paper\n<\/code><\/pre>\n<p>CSV \u067e\u0631 \u0645\u0634\u062a\u0645\u0644 \u06c1\u0648 \u0633\u06a9\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">Name,Age,Score\nAlex,17,91\nSam,18,87\n<\/code><\/pre>\n<p>DOCX \u0645\u06cc\u06ba \u0634\u0627\u0645\u0644 \u06c1\u0648\u0633\u06a9\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">A long essay\n<\/code><\/pre>\n<p>\u0627\u06cc\u06a9 \u0627\u0686\u06be\u06d2 \u0627\u06cc\u062c\u0646\u0679 \u06a9\u0648 \u06cc\u06c1 \u0633\u0645\u062c\u06be\u0646\u0627 \u0686\u0627\u06c1\u06cc\u06d2 \u06a9\u06c1 \u0648\u06c1 \u06a9\u0633 \u0642\u0633\u0645 \u06a9\u06cc \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u06a9\u06d2 \u0633\u0627\u062a\u06be \u06a9\u0627\u0645 \u06a9\u0631 \u0631\u06c1\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u06c1\u0645 \u0627\u0633 \u0628\u0627\u062a \u06a9\u0648 \u06cc\u0642\u06cc\u0646\u06cc \u0628\u0646\u0627 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba \u06a9\u06c1 \u06c1\u0645\u0627\u0631\u06cc \u0631\u06c1\u0646\u0645\u0627\u0626\u06cc \u0627\u0633 \u06a9\u06cc \u0639\u06a9\u0627\u0633\u06cc \u06a9\u0631\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631:<\/p>\n<pre><code class=\"language-python\">instructions = \"\"\"\nYou are an AI file analysis assistant.\n\nFirst understand what type of information the uploaded file contains.\n\nIf the file is a research paper:\n- Identify the research question.\n- Explain the methodology.\n- Summarize the results.\n- Explain the conclusion.\n- Identify limitations.\n\nIf the file contains tabular data:\n- Identify the columns.\n- Describe important patterns.\n- Identify unusual values when possible.\n- Explain trends clearly.\n- Do not invent numerical results.\n\nIf the file is a general document:\n- Identify its main purpose.\n- Summarize the important sections.\n- Answer questions using information from the document.\n\nAlways:\n- Use the file as your primary source.\n- Do not invent facts.\n- Clearly distinguish facts from inferences.\n- Say when the file does not contain enough information.\n- Use simple language.\n\"\"\"\n<\/code><\/pre>\n<p>\u0627\u0628 \u0622\u067e \u06a9\u06d2 \u067e\u0627\u0633 \u0627\u0646 \u06a9\u0627\u0645\u0648\u06ba \u06a9\u06d2 \u0628\u0627\u0631\u06d2 \u0645\u06cc\u06ba \u0645\u0632\u06cc\u062f \u0633\u06cc\u0627\u0642 \u0648 \u0633\u0628\u0627\u0642 \u06c1\u06d2 \u062c\u0648 \u0622\u067e \u06a9\u0627 \u0627\u06cc\u062c\u0646\u0679 \u0627\u0646\u062c\u0627\u0645 \u062f\u06d2 \u0633\u06a9\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-step-24-give-the-agent-a-specific-role\">\u0645\u0631\u062d\u0644\u06c1 24: \u0627\u06cc\u062c\u0646\u0679\u0648\u06ba \u06a9\u0648 \u0645\u062e\u0635\u0648\u0635 \u06a9\u0631\u062f\u0627\u0631 \u062a\u0641\u0648\u06cc\u0636 \u06a9\u0631\u06cc\u06ba\u06d4<\/h2>\n<p>\u0622\u067e \u0631\u06c1\u0646\u0645\u0627 \u062e\u0637\u0648\u0637 \u06a9\u0648 \u0627\u06cc\u062c\u0646\u0679 \u06a9\u06cc \u0645\u0644\u0627\u0632\u0645\u062a \u06a9\u06cc \u062a\u0641\u0635\u06cc\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631 \u0633\u0648\u0686 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631:<\/p>\n<pre><code class=\"language-text\">You are an AI research assistant.\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u06a9\u0627\u0641\u06cc \u06a9\u0634\u0627\u062f\u06c1 \u06c1\u06d2\u06d4<\/p>\n<p>\u0644\u06cc\u06a9\u0646:<\/p>\n<pre><code class=\"language-text\">You are an AI research assistant who analyzes academic papers.\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0632\u06cc\u0627\u062f\u06c1 \u0645\u062e\u0635\u0648\u0635 \u06c1\u06d2\u06d4<\/p>\n<p>\u06c1\u0645 \u0622\u06af\u06d2 \u062c\u0627 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">You are an AI research assistant specializing in helping students understand academic papers.\n<\/code><\/pre>\n<p>\u0627\u0628 \u06c1\u0645\u0627\u0631\u06d2 \u067e\u0627\u0633 \u0627\u06cc\u06a9 \u06c1\u062f\u0641 \u0648\u0627\u0644\u06d2 \u0633\u0627\u0645\u0639\u06cc\u0646 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0645\u0627\u0688\u0644 \u0627\u0633 \u06a9\u06d2 \u0645\u0637\u0627\u0628\u0642 \u0627\u067e\u0646\u06cc \u0648\u0636\u0627\u062d\u062a \u06a9\u0648 \u0627\u06cc\u0688\u062c\u0633\u0679 \u06a9\u0631\u0633\u06a9\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u06cc\u06c1 \u0622\u067e \u06a9\u06d2 AI \u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646\u0632 \u06a9\u0648 \u0628\u06c1\u062a \u0632\u06cc\u0627\u062f\u06c1 \u06a9\u0648\u0688 \u0644\u06a9\u06be\u06d2 \u0628\u063a\u06cc\u0631 \u0632\u06cc\u0627\u062f\u06c1 \u06a9\u0627\u0631\u0622\u0645\u062f \u0628\u0646\u0627\u0646\u06d2 \u06a9\u0627 \u0627\u06cc\u06a9 \u0622\u0633\u0627\u0646 \u062a\u0631\u06cc\u0646 \u0637\u0631\u06cc\u0642\u06c1 \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-step-25-add-an-analysis-mode\">\u0645\u0631\u062d\u0644\u06c1 25: \u062a\u062c\u0632\u06cc\u06c1 \u0645\u0648\u0688 \u0634\u0627\u0645\u0644 \u06a9\u0631\u06cc\u06ba\u06d4<\/h2>\n<p>\u0622\u067e \u0635\u0627\u0631\u0641\u06cc\u0646 \u06a9\u0648 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u06d2 \u0637\u0631\u06cc\u0642\u0648\u06ba \u06a9\u0627 \u0627\u0646\u062a\u062e\u0627\u0628 \u06a9\u0631\u0646\u06d2 \u06a9\u06cc \u0627\u062c\u0627\u0632\u062a \u062f\u06d2 \u06a9\u0631 \u0627\u067e\u0646\u06cc \u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646 \u06a9\u0648 \u0645\u0632\u06cc\u062f \u06a9\u0627\u0631\u0622\u0645\u062f \u0628\u0646\u0627 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631:<\/p>\n<pre><code class=\"language-text\">1. Summarize\n2. Explain\n3. Find key points\n4. Analyze\n5. Ask a question\n<\/code><\/pre>\n<p>\u06c1\u0645 \u067e\u0648\u0686\u06be \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">mode = input(\n    \"\\nChoose a mode: \"\n    \"summarize, explain, analyze, or question: \"\n)\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u067e\u06be\u0631 \u0635\u0627\u0631\u0641 \u06a9\u06d2 \u0627\u0646\u062a\u062e\u0627\u0628 \u06a9\u06cc \u0628\u0646\u06cc\u0627\u062f \u067e\u0631 \u067e\u0631\u0627\u0645\u067e\u0679 \u0645\u06cc\u06ba \u062a\u0631\u0645\u06cc\u0645 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0645\u062b\u0627\u0644 \u06a9\u06d2 \u0637\u0648\u0631 \u067e\u0631:<\/p>\n<pre><code class=\"language-python\">if mode.lower() == \"summarize\":\n    task = \"Summarize the most important information from the file.\"\n\nelif mode.lower() == \"explain\":\n    task = \"Explain the file in beginner-friendly language.\"\n\nelif mode.lower() == \"analyze\":\n    task = \"Perform a detailed analysis of the file.\"\n\nelse:\n    task = question\n<\/code><\/pre>\n<p>\u06cc\u06c1 \u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646 \u0645\u0646\u0637\u0642 \u06a9\u06cc \u0627\u06cc\u06a9 \u0633\u0627\u062f\u06c1 \u0633\u06cc \u0645\u062b\u0627\u0644 \u06c1\u06d2 \u062c\u0648 AI \u0645\u0627\u0688\u0644 \u06a9\u0648 \u06a9\u0646\u0679\u0631\u0648\u0644 \u06a9\u0631\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<p>AI \u0627\u0628 \u0628\u06be\u06cc \u0632\u0628\u0627\u0646 \u062a\u06cc\u0627\u0631 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u060c \u0644\u06cc\u06a9\u0646 Python \u0627\u06cc\u067e\u0644\u06cc \u06a9\u06cc\u0634\u0646\u0632 \u0627\u0633 \u0628\u0627\u062a \u06a9\u0627 \u062a\u0639\u06cc\u0646 \u06a9\u0631\u062a\u06cc \u06c1\u06cc\u06ba \u06a9\u06c1 \u06a9\u0633 \u0642\u0633\u0645 \u06a9\u06d2 \u06a9\u0627\u0645 \u0627\u0646\u062c\u0627\u0645 \u062f\u06cc\u0646\u06d2 \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-step-26-why-this-is-different-from-hard-coding-every-answer\">\u0645\u0631\u062d\u0644\u06c1 26: \u06cc\u06c1 \u062a\u0645\u0627\u0645 \u062c\u0648\u0627\u0628\u0627\u062a \u06a9\u0648 \u06c1\u0627\u0631\u0688 \u06a9\u0648\u0688\u0646\u06af \u0633\u06d2 \u0645\u062e\u062a\u0644\u0641 \u06a9\u06cc\u0648\u06ba \u06c1\u06d2\u06d4<\/h2>\n<p>\u062a\u0635\u0648\u0631 \u06a9\u0631\u06cc\u06ba \u06a9\u06c1 \u0622\u067e \u062f\u0631\u062c \u0630\u06cc\u0644 \u0633\u0648\u0627\u0644 \u06a9\u06cc \u062d\u0645\u0627\u06cc\u062a \u06a9\u0631\u0646\u0627 \u0686\u0627\u06c1\u062a\u06d2 \u06c1\u06cc\u06ba:<\/p>\n<ol>\n<li>\n<p>\u0641\u0627\u0626\u0644 \u06a9\u0627 \u062e\u0644\u0627\u0635\u06c1 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<li>\n<p>\u0645\u0631\u06a9\u0632\u06cc \u062e\u06cc\u0627\u0644 \u06a9\u06cc\u0627 \u06c1\u06d2\u061f<\/p>\n<\/li>\n<li>\n<p>\u062d\u062f\u0648\u062f \u06a9\u06cc\u0627 \u06c1\u06cc\u06ba\u061f<\/p>\n<\/li>\n<li>\n<p>\u0622\u067e \u06a9\u0627 \u06c1\u062f\u0641 \u0633\u0627\u0645\u0639\u06cc\u0646 \u06a9\u0648\u0646 \u06c1\u06d2\u061f<\/p>\n<\/li>\n<li>\n<p>\u06a9\u06cc\u0627 \u062b\u0628\u0648\u062a \u0622\u067e \u06a9\u06d2 \u0646\u062a\u06cc\u062c\u06d2 \u06a9\u06cc \u062d\u0645\u0627\u06cc\u062a \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u061f<\/p>\n<\/li>\n<\/ol>\n<p>\u062a\u06a9\u0646\u06cc\u06a9\u06cc \u0637\u0648\u0631 \u067e\u0631\u060c \u0622\u067e \u06c1\u0631 \u0627\u06cc\u06a9 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0639\u0644\u06cc\u062d\u062f\u06c1 \u0627\u0632\u06af\u0631 \u06a9\u06d2 \u0641\u0646\u06a9\u0634\u0646 \u0628\u0646\u0627 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4 \u0644\u06cc\u06a9\u0646 \u06cc\u06c1 \u062c\u0644\u062f \u06c1\u06cc \u0645\u0636\u062d\u06a9\u06c1 \u062e\u06cc\u0632 \u0628\u0646 \u062c\u0627\u0626\u06d2 \u06af\u0627\u06d4<\/p>\n<p>\u0627\u0633 \u06a9\u06d2 \u0628\u062c\u0627\u0626\u06d2\u060c \u0622\u067e \u0635\u0627\u0631\u0641\u06cc\u0646 \u06a9\u0648 \u0642\u062f\u0631\u062a\u06cc \u0637\u0648\u0631 \u067e\u0631 \u0633\u0648\u0627\u0644\u0627\u062a \u06a9\u0631\u0646\u06d2 \u062f\u06d2 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<pre><code class=\"language-python\">question = input(\"What would you like to know? \")\n<\/code><\/pre>\n<p>AI \u0632\u0628\u0627\u0646 \u067e\u0631 \u06a9\u0627\u0631\u0631\u0648\u0627\u0626\u06cc \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4 \u06c1\u0645\u0627\u0631\u06cc \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u0627\u06cc\u06a9 \u0641\u0627\u0626\u0644 \u0627\u0648\u0631 \u0633\u06cc\u0627\u0642 \u0648 \u0633\u0628\u0627\u0642 \u0641\u0631\u0627\u06c1\u0645 \u06a9\u0631\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<p>\u06cc\u06c1 \u0622\u067e \u06a9\u06cc \u0627\u06cc\u067e\u0644\u06cc \u06a9\u06cc\u0634\u0646\u0632 \u0645\u06cc\u06ba \u0644\u06cc\u0646\u06af\u0648\u06cc\u062c \u0645\u0627\u0688\u0644 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631\u0646\u06d2 \u06a9\u06d2 \u0627\u06c1\u0645 \u0641\u0648\u0627\u0626\u062f \u0645\u06cc\u06ba \u0633\u06d2 \u0627\u06cc\u06a9 \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-step-27-security-matters\">\u0645\u0631\u062d\u0644\u06c1 27: \u0633\u06cc\u06a9\u06cc\u0648\u0631\u0679\u06cc \u06a9\u06d2 \u0645\u0633\u0627\u0626\u0644<\/h2>\n<p>\u0627\u0628 \u0628\u0627\u062a \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba \u0627\u06cc\u06a9 \u0627\u06cc\u0633\u06cc \u0686\u06cc\u0632 \u06a9\u06d2 \u0628\u0627\u0631\u06d2 \u0645\u06cc\u06ba \u062c\u0648 \u06a9\u06c1 AI \u062d\u0635\u06d2 \u06a9\u06cc \u0637\u0631\u062d \u067e\u0631\u062c\u0648\u0634 \u062a\u0648 \u0646\u06c1\u06cc\u06ba \u0644\u06cc\u06a9\u0646 \u0628\u06c1\u062a \u0627\u06c1\u0645 \u06c1\u06d2\u06d4<\/p>\n<p><strong>\u0627\u067e\u0646\u06cc API \u06a9\u0644\u06cc\u062f \u06a9\u0648 \u0628\u06d2 \u0646\u0642\u0627\u0628 \u0646\u06c1 \u06a9\u0631\u06cc\u06ba\u06d4<\/strong><\/p>\n<p>\u0628\u0631\u0627:<\/p>\n<pre><code class=\"language-python\">client = OpenAI(\n    api_key=\"sk-real-secret-key\"\n)\n<\/code><\/pre>\n<p>\u0628\u06c1\u062a\u0631:<\/p>\n<pre><code class=\"language-python\">client = OpenAI()\n<\/code><\/pre>\n<p>\u0645\u0627\u062d\u0648\u0644\u06cc\u0627\u062a\u06cc \u0645\u062a\u063a\u06cc\u0631 \u0645\u06cc\u06ba \u0630\u062e\u06cc\u0631\u06c1 \u0634\u062f\u06c1 \u06a9\u0644\u06cc\u062f \u06a9\u0627 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<p>\u0627\u0633 \u06a9\u06d2 \u0639\u0644\u0627\u0648\u06c1\u060c GitHub \u06a9\u06d2 \u0631\u0627\u0632\u0648\u06ba \u06a9\u0627 \u0627\u0631\u062a\u06a9\u0627\u0628 \u0646\u06c1 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<p>\u0622\u067e \u06a9\u0627 <code>.gitignore<\/code> \u0641\u0627\u0626\u0644 \u0645\u06cc\u06ba \u062f\u0631\u062c \u0630\u06cc\u0644 \u067e\u0631 \u0645\u0634\u062a\u0645\u0644 \u06c1\u0648\u0646\u0627 \u0686\u0627\u06c1\u0626\u06d2:<\/p>\n<pre><code class=\"language-text\">.env\nvenv\/\n__pycache__\/\n<\/code><\/pre>\n<p>\u0627\u06af\u0631 \u0622\u067e \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631\u0646\u06d2 \u06a9\u0627 \u0641\u06cc\u0635\u0644\u06c1 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4 <code>.env<\/code> \u0627\u06af\u0631 \u0622\u067e \u0641\u0627\u0626\u0644 \u06a9\u0648 \u0645\u0642\u0627\u0645\u06cc \u0637\u0648\u0631 \u067e\u0631 \u0645\u062d\u0641\u0648\u0638 \u06a9\u0631\u0646\u0627 \u0686\u0627\u06c1\u062a\u06d2 \u06c1\u06cc\u06ba \u062a\u0648 \u06cc\u0642\u06cc\u0646\u06cc \u0628\u0646\u0627\u0626\u06cc\u06ba \u06a9\u06c1 \u0627\u0633\u06d2 Git \u0646\u06d2 \u0646\u0638\u0631 \u0627\u0646\u062f\u0627\u0632 \u06a9\u0631 \u062f\u06cc\u0627 \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-step-28-be-careful-with-sensitive-files\">\u0645\u0631\u062d\u0644\u06c1 28: \u062d\u0633\u0627\u0633 \u0641\u0627\u0626\u0644\u0648\u06ba \u0633\u06d2 \u0645\u062d\u062a\u0627\u0637 \u0631\u06c1\u06cc\u06ba<\/h2>\n<p>\u0641\u0627\u0626\u0644 \u06a9\u06d2 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u06d2 \u0627\u06cc\u062c\u0646\u0679 \u0645\u0645\u06a9\u0646\u06c1 \u0637\u0648\u0631 \u067e\u0631 \u062d\u0633\u0627\u0633 \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u067e\u0631 \u06a9\u0627\u0631\u0631\u0648\u0627\u0626\u06cc \u06a9\u0631 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0627\u0633 \u06a9\u0627 \u0645\u0637\u0644\u0628 \u06c1\u06d2 \u06a9\u06c1 \u0622\u067e \u06a9\u0648 \u06a9\u0648\u0626\u06cc \u0628\u06be\u06cc \u0686\u06cc\u0632 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u0646\u06d2 \u0633\u06d2 \u067e\u06c1\u0644\u06d2 \u0627\u062d\u062a\u06cc\u0627\u0637 \u0633\u06d2 \u0633\u0648\u0686\u0646\u0627 \u0686\u0627\u06c1\u06cc\u06d2 \u06a9\u06c1:<\/p>\n<ul>\n<li>\n<p>\u0637\u0628\u06cc \u0631\u06cc\u06a9\u0627\u0631\u0688<\/p>\n<\/li>\n<li>\n<p>\u0645\u0627\u0644\u06cc \u0645\u0639\u0644\u0648\u0645\u0627\u062a<\/p>\n<\/li>\n<li>\n<p>\u067e\u0627\u0633 \u0648\u0631\u0688<\/p>\n<\/li>\n<li>\n<p>\u0646\u062c\u06cc \u06a9\u0645\u067e\u0646\u06cc \u06a9\u06d2 \u062f\u0633\u062a\u0627\u0648\u06cc\u0632\u0627\u062a<\/p>\n<\/li>\n<li>\n<p>\u0630\u0627\u062a\u06cc \u0634\u0646\u0627\u062e\u062a\u06cc \u062f\u0633\u062a\u0627\u0648\u06cc\u0632\u0627\u062a<\/p>\n<\/li>\n<li>\n<p>\u062e\u0641\u06cc\u06c1 \u0627\u0633\u06a9\u0648\u0644 \u06a9\u06d2 \u0631\u06cc\u06a9\u0627\u0631\u0688\u0632<\/p>\n<\/li>\n<\/ul>\n<p>\u0622\u067e \u06a9\u06cc \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u06a9\u06cc \u0631\u0627\u0632\u062f\u0627\u0631\u06cc \u06a9\u06d2 \u062a\u0642\u0627\u0636\u0648\u06ba \u06a9\u0627 \u0627\u0646\u062d\u0635\u0627\u0631 \u0627\u0633 \u0688\u06cc\u0679\u0627 \u06a9\u06cc \u0642\u0633\u0645 \u067e\u0631 \u06c1\u0648\u062a\u0627 \u06c1\u06d2 \u062c\u0633 \u067e\u0631 \u06cc\u06c1 \u06a9\u0627\u0631\u0631\u0648\u0627\u0626\u06cc \u06a9\u0631\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<p>AI API \u06a9\u0648 \u0627\u067e\u0646\u06d2 \u06a9\u0645\u067e\u06cc\u0648\u0679\u0631 \u067e\u0631 \u06c1\u0631 \u062f\u0633\u062a\u0627\u0648\u06cc\u0632 \u06a9\u0648 \u0628\u06d2 \u062a\u0631\u062a\u06cc\u0628\u06cc \u0633\u06d2 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u0646\u06d2 \u06a9\u06cc \u062c\u06af\u06c1 \u0646\u06c1 \u0633\u0645\u062c\u06be\u06cc\u06ba\u06d4<\/p>\n<p>\u062d\u0633\u0627\u0633 \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u067e\u0631 \u0645\u0634\u062a\u0645\u0644 \u0641\u0627\u0626\u0644 \u067e\u0631\u0648\u0633\u06cc\u0633\u0646\u06af \u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646 \u06a9\u0648 \u062a\u0639\u06cc\u0646\u0627\u062a \u06a9\u0631\u0646\u06d2 \u0633\u06d2 \u067e\u06c1\u0644\u06d2\u060c \u0627\u067e\u0646\u06d2 \u0641\u0631\u0627\u06c1\u0645 \u06a9\u0646\u0646\u062f\u06c1 \u06a9\u06d2 \u0645\u0648\u062c\u0648\u062f\u06c1 \u0688\u06cc\u0679\u0627 \u06a9\u0646\u0679\u0631\u0648\u0644\u0632\u060c \u0628\u0631\u0642\u0631\u0627\u0631 \u0631\u06a9\u06be\u0646\u06d2 \u06a9\u06d2 \u0631\u0648\u06cc\u06d2\u060c \u0627\u0648\u0631 \u067e\u0627\u0644\u06cc\u0633\u06cc\u0648\u06ba \u06a9\u0648 \u0633\u0645\u062c\u06be\u06cc\u06ba\u06d4 \u0627\u0648\u067e\u0646 \u0627\u06d2 \u0622\u0626\u06cc \u062f\u0633\u062a\u0627\u0648\u06cc\u0632\u0627\u062a \u0627\u0633 \u06a9\u06d2 \u067e\u0644\u06cc\u0679 \u0641\u0627\u0631\u0645 \u062f\u0633\u062a\u0627\u0648\u06cc\u0632\u0627\u062a \u0645\u06cc\u06ba \u0641\u0627\u0626\u0644 \u06a9\u06cc \u0628\u0631\u0642\u0631\u0627\u0631\u06cc \u0627\u0648\u0631 \u0688\u06cc\u0679\u0627 \u06a9\u0646\u0679\u0631\u0648\u0644\u0632\u06d4<\/p>\n<h2 id=\"heading-common-mistakes-that-developers-make\">\u0639\u0627\u0645 \u063a\u0644\u0637\u06cc\u0627\u06ba \u062c\u0648 \u0688\u0648\u06cc\u0644\u067e\u0631\u0632 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/h2>\n<h3 id=\"heading-common-mistake-1-putting-the-api-key-in-github\">\u0639\u0627\u0645 \u063a\u0644\u0637\u06cc #1: \u0627\u067e\u0646\u06cc API \u06a9\u0644\u06cc\u062f \u06a9\u0648 GitHub \u067e\u0631 \u0688\u0627\u0644\u0646\u0627<\/h3>\n<p>\u0627\u06cc\u0633\u0627 \u06a9\u0628\u06be\u06cc \u0646\u06c1 \u06a9\u0631\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">api_key = \"your-secret-key\"\n<\/code><\/pre>\n<p>\u0627\u0648\u0631 \u0627\u0633 \u06a9\u0627 \u0627\u0631\u062a\u06a9\u0627\u0628 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<p>\u0627\u0633 \u06a9\u06d2 \u0628\u062c\u0627\u0626\u06d2 \u0645\u0627\u062d\u0648\u0644\u06cc\u0627\u062a\u06cc \u0645\u062a\u063a\u06cc\u0631\u0627\u062a \u06a9\u0627 \u0627\u0633\u062a\u0639\u0645\u0627\u0644 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<h3 id=\"heading-common-mistake-2-assuming-the-ai-knows-everything-in-the-file\">\u0639\u0627\u0645 \u063a\u0644\u0637\u06cc #2: \u06cc\u06c1 \u0641\u0631\u0636 \u06a9\u0631\u0646\u0627 \u06a9\u06c1 AI \u0622\u067e \u06a9\u06cc \u0641\u0627\u0626\u0644 \u0645\u06cc\u06ba \u0633\u0628 \u06a9\u0686\u06be \u062c\u0627\u0646\u062a\u0627 \u06c1\u06d2\u06d4<\/h3>\n<p>\u0641\u0627\u0626\u0644 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u0646\u06d2 \u06a9\u0627 \u0645\u0637\u0644\u0628 \u06cc\u06c1 \u0646\u06c1\u06cc\u06ba \u06c1\u06d2 \u06a9\u06c1 \u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646 \u06c1\u0631 \u0645\u0645\u06a9\u0646\u06c1 \u0633\u0648\u0627\u0644 \u06a9\u0648 \u062c\u0627\u062f\u0648\u0626\u06cc \u0637\u0631\u06cc\u0642\u06d2 \u0633\u06d2 \u062d\u0644 \u06a9\u0631 \u062f\u06d2 \u06af\u06cc\u06d4<\/p>\n<p>\u0641\u0627\u0626\u0644\u0648\u06ba \u06a9\u0627 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u0631\u0646\u06d2 \u06a9\u06cc \u0645\u0627\u0688\u0644 \u06a9\u06cc \u0635\u0644\u0627\u062d\u06cc\u062a \u067e\u0631 \u0645\u0646\u062d\u0635\u0631 \u06c1\u06d2:<\/p>\n<p>\u0627\u067e\u0646\u06cc \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u06a9\u0648 \u0627\u0646 \u062d\u062f\u0648\u062f \u06a9\u06d2 \u06af\u0631\u062f \u0688\u06cc\u0632\u0627\u0626\u0646 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<h3 id=\"heading-common-mistake-3-telling-the-model-to-just-analyze-it\">\u0639\u0627\u0645 \u063a\u0644\u0637\u06cc #3: \u0645\u0627\u0688\u0644 \u06a9\u0648 \u0628\u062a\u0627\u0646\u0627 \u06a9\u06c1 &quot;\u0635\u0631\u0641 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u0631\u06cc\u06ba&#8221;<\/h3>\n<p>\u06cc\u06c1:<\/p>\n<pre><code class=\"language-text\">Analyze the file.\n<\/code><\/pre>\n<p>\u0628\u06c1\u062a \u0645\u0628\u06c1\u0645\u06d4<\/p>\n<p>\u06cc\u06c1 \u0628\u06c1\u062a\u0631 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">Identify the main argument, summarize the evidence,\nexplain the methodology, and identify the limitations.\n<\/code><\/pre>\n<p>\u0648\u0627\u0636\u062d \u06c1\u062f\u0627\u06cc\u0627\u062a \u0648\u0627\u0636\u062d \u06a9\u0627\u0645 \u062a\u062e\u0644\u06cc\u0642 \u06a9\u0631\u062a\u06cc \u06c1\u06cc\u06ba\u06d4<\/p>\n<h3 id=\"heading-common-mistake-4-ignoring-hallucinations\">\u0639\u0627\u0645 \u063a\u0644\u0637\u06cc #4: \u06c1\u06cc\u0644\u0648\u0633\u06cc\u0646\u06cc\u0634\u0646 \u06a9\u0648 \u0646\u0638\u0631 \u0627\u0646\u062f\u0627\u0632 \u06a9\u0631\u0646\u0627<\/h3>\n<p>AI \u0645\u0627\u0688\u0644 \u063a\u0644\u0637 \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u067e\u06cc\u062f\u0627 \u06a9\u0631 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0627\u0633\u06cc \u0644\u06cc\u06d2 \u06c1\u0645\u0627\u0631\u06cc \u0631\u06c1\u0646\u0645\u0627\u0626\u06cc \u0645\u06cc\u06ba \u0634\u0627\u0645\u0644 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">Do not invent information.\n<\/code><\/pre>\n<p>\u0627\u0648\u0631:<\/p>\n<pre><code class=\"language-text\">If the file does not contain enough information, say so.\n<\/code><\/pre>\n<p>\u0622\u067e \u06a9\u0648 \u0630\u0627\u062a\u06cc \u0637\u0648\u0631 \u067e\u0631 \u06a9\u0633\u06cc \u0628\u06be\u06cc \u062d\u0633\u0627\u0633 \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u06a9\u06cc \u062a\u0635\u062f\u06cc\u0642 \u06a9\u0631\u0646\u06cc \u06c1\u0648\u06af\u06cc\u06d4<\/p>\n<p>\u06c1\u0627\u0626\u06cc \u0631\u0633\u06a9 \u0627\u06cc\u067e\u0644\u06cc \u06a9\u06cc\u0634\u0646\u0632 \u06a9\u0648 \u0632\u06cc\u0627\u062f\u06c1 \u0645\u0636\u0628\u0648\u0637 \u062a\u0634\u062e\u06cc\u0635 \u0627\u0648\u0631 \u062a\u0635\u062f\u06cc\u0642\u06cc \u0646\u0638\u0627\u0645 \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u06c1\u0648\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<h3 id=\"heading-common-mistake-5-sending-huge-amounts-of-data-everywhere\">\u0639\u0627\u0645 \u063a\u0644\u0637\u06cc #5: \u06c1\u0631 \u062c\u06af\u06c1 \u0628\u06c1\u062a \u0632\u06cc\u0627\u062f\u06c1 \u0688\u06cc\u0679\u0627 \u0628\u06be\u06cc\u062c\u0646\u0627<\/h3>\n<p>\u0627\u06af\u0631 \u0622\u067e \u06a9\u06d2 \u067e\u0627\u0633 \u06c1\u0632\u0627\u0631\u0648\u06ba \u062f\u0633\u062a\u0627\u0648\u06cc\u0632\u0627\u062a \u06c1\u06cc\u06ba \u062a\u0648 \u0627\u0646 \u0633\u0628 \u06a9\u0648 \u06c1\u0631 \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u0645\u06cc\u06ba \u0634\u0627\u0645\u0644 \u0646\u06c1 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<p>\u06cc\u06c1 \u0648\u06c1 \u062c\u06af\u06c1 \u06c1\u06d2 \u062c\u06c1\u0627\u06ba \u062a\u0644\u0627\u0634 \u06a9\u0627 \u0646\u0638\u0627\u0645 \u06a9\u0627\u0631\u0622\u0645\u062f \u06c1\u0648 \u062c\u0627\u062a\u0627 \u06c1\u06d2\u06d4 \u067e\u06c1\u0644\u06d2 \u062a\u0644\u0627\u0634 \u06a9\u0631\u06cc\u06ba\u06d4 \u0627\u0633 \u06a9\u06d2 \u0628\u0639\u062f \u06c1\u0645 \u0645\u0627\u0688\u0644 \u06a9\u0648 \u0627\u0646\u062a\u06c1\u0627\u0626\u06cc \u0645\u062a\u0639\u0644\u0642\u06c1 \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u0641\u0631\u0627\u06c1\u0645 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<h3 id=\"heading-common-mistake-6-building-everything-at-once\">\u0639\u0627\u0645 \u063a\u0644\u0637\u06cc #6: \u0633\u0628 \u06a9\u0686\u06be \u0627\u06cc\u06a9 \u0633\u0627\u062a\u06be \u0628\u0646\u0627\u0646\u0627<\/h3>\n<p>\u0639\u0627\u0645 \u0627\u0628\u062a\u062f\u0627\u0626\u06cc \u063a\u0644\u0637\u06cc\u0627\u06ba \u0627\u0633 \u0637\u0631\u062d \u0634\u0631\u0648\u0639 \u06c1\u0648\u062a\u06cc \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">React\nFastAPI\nLangChain\nPostgreSQL\nPinecone\nDocker\nKubernetes\nOpenAI\nAuthentication\nRAG\nAgents\n<\/code><\/pre>\n<p>\u0633\u0628 \u0627\u06cc\u06a9 \u06c1\u06cc \u0648\u0642\u062a \u0645\u06cc\u06ba\u06d4<\/p>\n<p>\u0627\u06cc\u0633\u0627 \u0645\u062a \u06a9\u0631\u0648\u06d4<\/p>\n<p>\u0622\u067e AI \u0633\u06cc\u06a9\u06be\u0646\u06d2 \u06a9\u06d2 \u0628\u062c\u0627\u0626\u06d2 \u0627\u067e\u0646\u06d2 \u0627\u0646\u0641\u0631\u0627\u0633\u0679\u0631\u06a9\u0686\u0631 \u06a9\u0648 \u0688\u06cc\u0628\u06af \u06a9\u0631\u0646\u06d2 \u0645\u06cc\u06ba \u0632\u06cc\u0627\u062f\u06c1 \u0648\u0642\u062a \u06af\u0632\u0627\u0631\u06cc\u06ba \u06af\u06d2\u06d4<\/p>\n<p>\u06a9\u06d2 \u0633\u0627\u062a\u06be \u0634\u0631\u0648\u0639 \u06a9\u0631\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">Python\n+\nOpenAI API\n+\nFile\n<\/code><\/pre>\n<p>\u0627\u0633\u06d2 \u06a9\u0627\u0645 \u06a9\u0631\u0648\u06d4<\/p>\n<p>\u067e\u06be\u0631 \u0627\u06cc\u06a9 \u0648\u0642\u062a \u0645\u06cc\u06ba \u0627\u06cc\u06a9 \u062e\u0635\u0648\u0635\u06cc\u0627\u062a \u0634\u0627\u0645\u0644 \u06a9\u0631\u06cc\u06ba\u06d4<\/p>\n<h2 id=\"heading-how-the-final-program-works\">\u062d\u062a\u0645\u06cc \u067e\u0631\u0648\u06af\u0631\u0627\u0645 \u06a9\u06cc\u0633\u06d2 \u06a9\u0627\u0645 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/h2>\n<p>\u0622\u0626\u06cc\u06d2 \u0634\u0631\u0648\u0639 \u0633\u06d2 \u0622\u062e\u0631 \u062a\u06a9 \u0627\u067e\u0646\u06d2 \u067e\u0631\u0648\u06af\u0631\u0627\u0645 \u06a9\u0627 \u062e\u0644\u0627\u0635\u06c1 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0635\u0627\u0631\u0641 \u0686\u0644\u0627\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-bash\">python agent.py\n<\/code><\/pre>\n<p>\u067e\u0631\u0648\u06af\u0631\u0627\u0645 \u067e\u0648\u0686\u06be\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">Enter the path to your file:\n<\/code><\/pre>\n<p>\u0635\u0627\u0631\u0641 \u06a9\u06cc \u0627\u0642\u0633\u0627\u0645:<\/p>\n<pre><code class=\"language-text\">research.pdf\n<\/code><\/pre>\n<p>\u067e\u0627\u0626\u062a\u06be\u0648\u0646 \u0686\u06cc\u06a9 \u06a9\u0631\u062a\u0627 \u06c1\u06d2 \u06a9\u06c1 \u0622\u06cc\u0627 \u0641\u0627\u0626\u0644 \u0645\u0648\u062c\u0648\u062f \u06c1\u06d2\u06d4<\/p>\n<p>\u062f\u0631\u062e\u0648\u0627\u0633\u062a \u067e\u06be\u0631 \u0627\u0633\u06d2 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<pre><code class=\"language-python\">client.files.create(...)\n<\/code><\/pre>\n<p>API \u0641\u0627\u0626\u0644 ID \u0648\u0627\u067e\u0633 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4 \u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646 \u0627\u0633 ID \u06a9\u0648 \u0627\u0633\u0679\u0648\u0631 \u06a9\u0631\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<p>\u0635\u0627\u0631\u0641 \u067e\u06be\u0631 \u067e\u0648\u0686\u06be\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">What is the main argument?\n<\/code><\/pre>\n<p>\u06c1\u0645\u0627\u0631\u06cc \u062f\u0631\u062e\u0648\u0627\u0633\u062a \u0628\u06be\u06cc\u062c\u062a\u06cc \u06c1\u06d2:<\/p>\n<pre><code class=\"language-text\">Instructions\n+\nQuestion\n+\nFile\n<\/code><\/pre>\n<p>\u0645\u0627\u0688\u0644 \u06a9\u0648\u06d4<\/p>\n<p>\u0645\u0627\u0688\u0644 \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u06a9\u0627 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u067e\u06be\u0631 \u06c1\u0645\u0627\u0631\u0627 \u067e\u0631\u0648\u06af\u0631\u0627\u0645 \u067e\u0631\u0646\u0679 \u06a9\u0631\u062a\u0627 \u06c1\u06d2:<\/p>\n<pre><code class=\"language-python\">response.output_text\n<\/code><\/pre>\n<p>\u0635\u0627\u0631\u0641 \u06a9\u0648 \u062c\u0648\u0627\u0628 \u0645\u0644\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u06cc\u06c1 \u0641\u0627\u0626\u0644 \u062a\u062c\u0632\u06cc\u06c1 AI \u0627\u06cc\u062c\u0646\u0679 \u06a9\u0627 \u0628\u0646\u06cc\u0627\u062f\u06cc \u062d\u0635\u06c1 \u06c1\u06d2\u06d4<\/p>\n<h2 id=\"heading-the-most-important-code-to-remember\">\u06cc\u0627\u062f \u0631\u06a9\u06be\u0646\u06d2 \u06a9\u06d2 \u0644\u06cc\u06d2 \u0633\u0628 \u0633\u06d2 \u0627\u06c1\u0645 \u06a9\u0648\u0688\u0632<\/h2>\n<p>\u0627\u06af\u0631 \u0622\u067e \u0628\u0627\u0642\u06cc \u0633\u0628 \u06a9\u0686\u06be \u0628\u06be\u0648\u0644 \u062c\u0627\u0626\u06cc\u06ba \u062a\u0648 \u0627\u0633 \u0633\u0627\u062e\u062a \u06a9\u0648 \u06cc\u0627\u062f \u0631\u06a9\u06be\u06cc\u06ba:<\/p>\n<pre><code class=\"language-python\">from openai import OpenAI\n\n\nclient = OpenAI()\n\n\nwith open(\"research.pdf\", \"rb\") as file:\n    uploaded_file = client.files.create(\n        file=file,\n        purpose=\"user_data\"\n    )\n\n\nresponse = client.responses.create(\n    model=\"gpt-5\",\n    instructions=\"Analyze the uploaded file carefully.\",\n    input=[\n        {\n            \"role\": \"user\",\n            \"content\": [\n                {\n                    \"type\": \"input_text\",\n                    \"text\": \"What is the main argument?\"\n                },\n                {\n                    \"type\": \"input_file\",\n                    \"file_id\": uploaded_file.id\n                }\n            ]\n        }\n    ]\n)\n\n\nprint(response.output_text)\n<\/code><\/pre>\n<p>\u0627\u06c1\u0645 \u0630\u06c1\u0646\u06cc \u0645\u0627\u0688\u0644\u0632 \u0645\u06cc\u06ba \u0634\u0627\u0645\u0644 \u06c1\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">Open file\n    \u2193\nUpload file\n    \u2193\nGet file ID\n    \u2193\nSend question + file ID\n    \u2193\nModel analyzes file\n    \u2193\nPrint answer\n<\/code><\/pre>\n<p>\u0627\u0633 \u0628\u06c1\u0627\u0624 \u06a9\u0648 \u0633\u0645\u062c\u06be\u0646\u06d2 \u06a9\u06d2 \u0628\u0639\u062f\u060c \u0622\u067e \u0627\u0633 \u06a9\u06d2 \u0627\u0648\u067e\u0631 \u0628\u06c1\u062a \u0632\u06cc\u0627\u062f\u06c1 \u067e\u06cc\u0686\u06cc\u062f\u06c1 \u0627\u06cc\u067e\u0644\u06cc \u06a9\u06cc\u0634\u0646\u0632 \u0628\u0646\u0627 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<h2 id=\"heading-what-you-can-build-with-this\">\u0622\u067e \u0627\u0633 \u0633\u06d2 \u06a9\u06cc\u0627 \u0628\u0646\u0627 \u0633\u06a9\u062a\u06d2 \u06c1\u06cc\u06ba\u061f<\/h2>\n<p>\u06cc\u06c1 \u0633\u0627\u062f\u06c1 \u067e\u0631\u0648\u062c\u06cc\u06a9\u0679 \u0628\u06c1\u062a \u0633\u06d2 \u062d\u0642\u06cc\u0642\u06cc \u062f\u0646\u06cc\u0627 \u06a9\u06d2 \u0627\u06cc\u067e\u0644\u06cc \u06a9\u06cc\u0634\u0646\u0632 \u06a9\u06cc \u0628\u0646\u06cc\u0627\u062f \u0628\u0646 \u0633\u06a9\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<h3 id=\"heading-ai-research-assistant\">\u0627\u06d2 \u0622\u0626\u06cc \u0631\u06cc\u0633\u0631\u0686 \u0627\u0633\u0633\u0679\u0646\u0679<\/h3>\n<p>\u0627\u067e\u0646\u0627 \u062a\u0639\u0644\u06cc\u0645\u06cc \u06a9\u0627\u063a\u0630 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u06cc\u06ba \u0627\u0648\u0631 \u0633\u0648\u0627\u0644\u0627\u062a \u067e\u0648\u0686\u06be\u06cc\u06ba \u062c\u06cc\u0633\u06d2:<\/p>\n<pre><code class=\"language-text\">What is the research question?\n<\/code><\/pre>\n<pre><code class=\"language-text\">What methodology was used?\n<\/code><\/pre>\n<pre><code class=\"language-text\">What were the main findings?\n<\/code><\/pre>\n<h3 id=\"heading-resume-analyzer\">\u062e\u0644\u0627\u0635\u06c1 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u0627\u0631<\/h3>\n<p>\u0627\u067e\u0646\u0627 \u0631\u06cc\u0632\u06cc\u0648\u0645\u06d2 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u06cc\u06ba \u0627\u0648\u0631 \u062f\u0631\u062c \u0630\u06cc\u0644 \u0633\u0648\u0627\u0644\u0627\u062a \u067e\u0648\u0686\u06be\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">What skills are missing for this job?\n<\/code><\/pre>\n<h3 id=\"heading-study-assistant\">\u0633\u06cc\u06a9\u06be\u0646\u06d2 \u06a9\u06d2 \u0627\u0633\u0633\u0679\u0646\u0679<\/h3>\n<p>\u0646\u0635\u0627\u0628\u06cc \u06a9\u062a\u0627\u0628 \u06a9\u0627 \u0627\u06cc\u06a9 \u0628\u0627\u0628 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u06cc\u06ba \u0627\u0648\u0631 \u0627\u0633 \u0637\u0631\u062d \u06a9\u0627 \u0633\u0648\u0627\u0644 \u067e\u0648\u0686\u06be\u06cc\u06ba:<\/p>\n<pre><code class=\"language-text\">Explain this chapter in beginner-friendly language.\n<\/code><\/pre>\n<h3 id=\"heading-legal-document-assistant\">\u0642\u0627\u0646\u0648\u0646\u06cc \u062f\u0633\u062a\u0627\u0648\u06cc\u0632 \u0627\u0633\u0633\u0679\u0646\u0679<\/h3>\n<p>\u062f\u0633\u062a\u0627\u0648\u06cc\u0632\u0627\u062a \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u06cc\u06ba \u0627\u0648\u0631 \u0631\u0627\u0632\u062f\u0627\u0631\u06cc\u060c \u062f\u0631\u0633\u062a\u06af\u06cc \u0627\u0648\u0631 \u0645\u0646\u0627\u0633\u0628 \u0642\u0627\u0646\u0648\u0646\u06cc \u062a\u062d\u0641\u0638\u0627\u062a \u067e\u0631 \u063a\u0648\u0631 \u06a9\u0631\u062a\u06d2 \u06c1\u0648\u0626\u06d2 \u0627\u0646 \u06a9\u06d2 \u0645\u0648\u0627\u062f \u06a9\u06d2 \u0628\u0627\u0631\u06d2 \u0645\u06cc\u06ba \u0633\u0648\u0627\u0644\u0627\u062a \u067e\u0648\u0686\u06be\u06cc\u06ba\u06d4<\/p>\n<h3 id=\"heading-business-report-analyzer\">\u06a9\u0627\u0631\u0648\u0628\u0627\u0631\u06cc \u0631\u067e\u0648\u0631\u0679 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u0627\u0631<\/h3>\n<p>\u0627\u067e\u0646\u06cc \u0631\u067e\u0648\u0631\u0679 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u06cc\u06ba \u0627\u0648\u0631 \u0633\u0648\u0627\u0644\u0627\u062a \u067e\u0648\u0686\u06be\u06cc\u06ba \u062c\u06cc\u0633\u06d2:<\/p>\n<pre><code class=\"language-text\">What are the most important trends?\n<\/code><\/pre>\n<h3 id=\"heading-data-analysis-assistant\">\u0688\u06cc\u0679\u0627 \u062a\u062c\u0632\u06cc\u06c1 \u0627\u0633\u0633\u0679\u0646\u0679<\/h3>\n<p>\u0627\u067e\u0646\u0627 \u0688\u06cc\u0679\u0627\u0633\u06cc\u0679 \u0627\u067e \u0644\u0648\u0688 \u06a9\u0631\u06cc\u06ba \u0627\u0648\u0631 \u0622\u062e\u0631 \u0645\u06cc\u06ba \u0627\u067e\u0646\u06d2 \u0627\u06cc\u062c\u0646\u0679 \u06a9\u0648 \u0627\u0632\u06af\u0631 \u067e\u0631 \u0645\u0628\u0646\u06cc \u062a\u062c\u0632\u06cc\u06c1 \u0679\u0648\u0644\u0632 \u062a\u06a9 \u0631\u0633\u0627\u0626\u06cc \u062f\u06cc\u06ba\u06d4<\/p>\n<p>\u0627\u0645\u06a9\u0627\u0646\u0627\u062a \u0628\u06c1\u062a \u0632\u06cc\u0627\u062f\u06c1 \u06c1\u06cc\u06ba\u06d4<\/p>\n<h2 id=\"heading-final-thoughts\">\u062d\u062a\u0645\u06cc \u062e\u06cc\u0627\u0644\u0627\u062a<\/h2>\n<p>\u0627\u06cc\u06a9 AI \u0627\u06cc\u062c\u0646\u0679 \u0628\u0646\u0627\u0646\u0627 \u062c\u0648 \u0641\u0627\u0626\u0644\u0648\u06ba \u06a9\u0648 \u067e\u0691\u06be \u0633\u06a9\u062a\u0627 \u06c1\u06d2 \u067e\u06c1\u0644\u06d2 \u062a\u0648 \u067e\u06cc\u0686\u06cc\u062f\u06c1 \u0644\u06af \u0633\u06a9\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0644\u06cc\u06a9\u0646 \u062c\u0628 \u0622\u067e \u0627\u0633\u06d2 \u062a\u0648\u0691 \u062f\u06cc\u062a\u06d2 \u06c1\u06cc\u06ba\u060c \u062a\u0648 \u0628\u0646\u06cc\u0627\u062f\u06cc \u062e\u06cc\u0627\u0644 \u062d\u06cc\u0631\u062a \u0627\u0646\u06af\u06cc\u0632 \u0637\u0648\u0631 \u067e\u0631 \u0622\u0633\u0627\u0646 \u06c1\u0648\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<ol>\n<li>\n<p>Python \u0627\u06cc\u067e\u0644\u06cc\u06a9\u06cc\u0634\u0646 \u0633\u06cc\u0679 \u0627\u067e \u06a9\u0631\u062a\u06cc \u06c1\u06d2\u06d4<\/p>\n<\/li>\n<li>\n<p>APIs AI \u0645\u0627\u0688\u0644\u0632 \u062a\u06a9 \u0631\u0633\u0627\u0626\u06cc \u0641\u0631\u0627\u06c1\u0645 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<li>\n<p>\u0641\u0627\u0626\u0644\u06cc\u06ba \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u0641\u0631\u0627\u06c1\u0645 \u06a9\u0631\u062a\u06cc \u06c1\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<li>\n<p>\u0631\u06c1\u0646\u0645\u0627 \u062e\u0637\u0648\u0637 \u0627\u06cc\u062c\u0646\u0679 \u06a9\u06d2 \u06a9\u0627\u0645\u0648\u06ba \u06a9\u06cc \u0648\u0636\u0627\u062d\u062a \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<li>\n<p>\u0635\u0627\u0631\u0641\u06cc\u0646 \u0633\u0648\u0627\u0644\u0627\u062a \u0641\u0631\u0627\u06c1\u0645 \u06a9\u0631\u062a\u06d2 \u06c1\u06cc\u06ba\u06d4<\/p>\n<\/li>\n<li>\n<p>\u0645\u0627\u0688\u0644 \u0645\u0639\u0644\u0648\u0645\u0627\u062a \u06a9\u0627 \u062a\u062c\u0632\u06cc\u06c1 \u06a9\u0631\u062a\u0627 \u06c1\u06d2 \u0627\u0648\u0631 \u062c\u0648\u0627\u0628 \u067e\u06cc\u062f\u0627 \u06a9\u0631\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<\/li>\n<\/ol>\n<p>\u0648\u0627\u0642\u0639\u06cc \u062f\u0644\u0686\u0633\u067e \u062d\u0635\u06c1 \u06cc\u06c1 \u06c1\u06d2 \u06a9\u06c1 \u0622\u06af\u06d2 \u06a9\u06cc\u0627 \u06c1\u0648\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u0627\u067e\u0646\u06d2 AI \u0645\u0627\u0688\u0644 \u06a9\u0648 \u0641\u0627\u0626\u0644 \u062a\u06a9 \u0631\u0633\u0627\u0626\u06cc \u062f\u06cc\u0646\u06d2 \u06a9\u06d2 \u0637\u0631\u06cc\u0642\u06c1 \u06a9\u0648 \u0633\u0645\u062c\u06be\u0646\u0627 \u0622\u067e \u06a9\u0648 \u062a\u0644\u0627\u0634\u060c \u0679\u0648\u0644\u0632\u060c \u0688\u06cc\u0679\u0627 \u0628\u06cc\u0633\u060c \u0648\u06cc\u0628 \u0633\u0631\u0686\u060c \u0645\u06cc\u0645\u0648\u0631\u06cc\u060c \u06cc\u0648\u0632\u0631 \u0627\u0646\u0679\u0631\u0641\u06cc\u0633\u060c \u0627\u0648\u0631 \u0645\u0644\u0679\u06cc \u0633\u0679\u06cc\u067e \u0648\u0631\u06a9 \u0641\u0644\u0648\u0632 \u0634\u0627\u0645\u0644 \u06a9\u0631\u0646\u06d2 \u06a9\u06cc \u0627\u062c\u0627\u0632\u062a \u062f\u06cc\u062a\u0627 \u06c1\u06d2\u06d4<\/p>\n<p>\u06cc\u06c1\u06cc\u06ba \u0633\u06d2 \u0633\u0627\u062f\u06c1 AI \u0627\u0633\u06a9\u0631\u067e\u0679\u0633 \u062d\u0642\u06cc\u0642\u06cc AI \u0627\u06cc\u067e\u0644\u06cc \u06a9\u06cc\u0634\u0646\u0632 \u0645\u06cc\u06ba \u062a\u0628\u062f\u06cc\u0644 \u06c1\u0648\u0646\u0627 \u0634\u0631\u0648\u0639 \u06c1\u0648 \u062c\u0627\u062a\u06cc \u06c1\u06cc\u06ba\u06d4<\/p>\n<p>\u0627\u0648\u0631 \u0628\u06c1\u062a\u0631\u06cc\u0646 \u062d\u0635\u06c1\u061f \u0622\u067e \u06a9\u0648 \u0627\u0633 \u06a9\u06cc \u062a\u0639\u0645\u06cc\u0631 \u0634\u0631\u0648\u0639 \u06a9\u0631\u0646\u06d2 \u0633\u06d2 \u067e\u06c1\u0644\u06d2 AI \u06a9\u06d2 \u06c1\u0631 \u062d\u0635\u06d2 \u06a9\u0648 \u0633\u0645\u062c\u06be\u0646\u06d2 \u06a9\u06cc \u0636\u0631\u0648\u0631\u062a \u0646\u06c1\u06cc\u06ba \u06c1\u06d2\u06d4<\/p>\n<p>\u0686\u06be\u0648\u0679\u0627 \u0634\u0631\u0648\u0639 \u06a9\u0631\u06cc\u06ba \u0627\u0648\u0631 \u06a9\u0627\u0645 \u06a9\u0631\u0646\u06d2 \u06a9\u06d2 \u0644\u0626\u06d2 \u0627\u06cc\u06a9 \u0641\u0627\u0626\u0644 \u062d\u0627\u0635\u0644 \u06a9\u0631\u06cc\u06ba\u06d4 \u0628\u0631\u0627\u06c1 \u06a9\u0631\u0645 \u0627\u06cc\u06a9 \u0633\u0648\u0627\u0644 \u067e\u0648\u0686\u06be\u06cc\u06ba\u06d4 \u0633\u0645\u062c\u06be\u06cc\u06ba \u06a9\u06c1 \u06a9\u0648\u0688 \u06a9\u06cc \u06c1\u0631 \u0644\u0627\u0626\u0646 \u06a9\u06cc\u0627 \u06a9\u0631\u062a\u06cc \u06c1\u06d2\u06d4 \u067e\u06be\u0631 \u0645\u0646\u062f\u0631\u062c\u06c1 \u0630\u06cc\u0644 \u0641\u0646\u06a9\u0634\u0646 \u0634\u0627\u0645\u0644 \u06a9\u0631\u06cc\u06ba:<\/p>\n<p>\u0627\u0633 \u0637\u0631\u062d \u0622\u067e &quot;\u0645\u06cc\u06ba \u0627\u06cc\u06a9 AI \u0627\u06cc\u062c\u0646\u0679 \u0628\u0646\u0627\u0646\u0627 \u0686\u0627\u06c1\u062a\u0627 \u06c1\u0648\u06ba&#8221; \u0633\u06d2 &quot;\u0645\u06cc\u06ba \u0646\u06d2 \u0627\u0635\u0644 \u0645\u06cc\u06ba \u0627\u06cc\u06a9 AI \u0627\u06cc\u062c\u0646\u0679 \u0628\u0646\u0627\u06cc\u0627 \u06c1\u06d2\u06d4&#8221;<\/p>\n<p>\u0645\u0628\u0627\u0631\u06a9 \u06a9\u0648\u0688\u0646\u06af!<\/p>\n<\/p><\/div>\n","protected":false},"excerpt":{"rendered":"<p>\u0627\u06af\u0631 \u0622\u067e \u0646\u06d2 \u06a9\u0628\u06be\u06cc 30 \u0635\u0641\u062d\u0627\u062a \u067e\u0631 \u0645\u0634\u062a\u0645\u0644 \u067e\u06cc \u0688\u06cc \u0627\u06cc\u0641 \u06a9\u06be\u0648\u0644\u06cc \u06c1\u06d2 \u0627\u0648\u0631 \u0633\u0648\u0686\u0627 \u06c1\u06d2\u060c &quot;\u0645\u06cc\u06ba \u06cc\u06c1 \u0633\u0628 \u067e\u0691\u06be\u0646\u06d2 \u06a9\u0627 \u06a9\u0648\u0626\u06cc \u0637\u0631\u06cc\u0642\u06c1 \u0646\u06c1\u06cc\u06ba \u06c1\u06d2\u060c&#8221; \u062a\u0648 \u0622\u067e \u0634\u0627\u06cc\u062f \u067e\u06c1\u0644\u06d2 \u06c1\u06cc \u0633\u0645\u062c\u06be \u06af\u0626\u06d2 \u06c1\u0648\u06ba \u06af\u06d2 \u06a9\u06c1 \u0641\u0627\u0626\u0644 \u0627\u06cc\u0646\u0627\u0644\u06cc\u0633\u0633 AI \u0627\u06cc\u062c\u0646\u0679\u0633 \u06a9\u06cc\u0648\u06ba \u06a9\u0627\u0631\u0622\u0645\u062f \u06c1\u06cc\u06ba\u06d4 \u0627\u06cc\u06a9 \u062a\u062d\u0642\u06cc\u0642\u06cc \u0645\u0642\u0627\u0644\u06c1\u060c \u062f\u0648\u0628\u0627\u0631\u06c1 \u0634\u0631\u0648\u0639\u060c CSV \u0641\u0627\u0626\u0644\u060c \u06a9\u0627\u0631\u0648\u0628\u0627\u0631\u06cc \u0631\u067e\u0648\u0631\u0679 \u06cc\u0627 \u067e\u06cc \u0688\u06cc \u0627\u06cc\u0641 [&hellip;]<\/p>\n","protected":false},"author":7,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[1],"tags":[],"class_list":["post-28739","post","type-post","status-publish","format-standard","hentry","category-blog"],"_links":{"self":[{"href":"https:\/\/umang.pk\/ur\/wp-json\/wp\/v2\/posts\/28739","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/umang.pk\/ur\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/umang.pk\/ur\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/umang.pk\/ur\/wp-json\/wp\/v2\/users\/7"}],"replies":[{"embeddable":true,"href":"https:\/\/umang.pk\/ur\/wp-json\/wp\/v2\/comments?post=28739"}],"version-history":[{"count":0,"href":"https:\/\/umang.pk\/ur\/wp-json\/wp\/v2\/posts\/28739\/revisions"}],"wp:attachment":[{"href":"https:\/\/umang.pk\/ur\/wp-json\/wp\/v2\/media?parent=28739"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/umang.pk\/ur\/wp-json\/wp\/v2\/categories?post=28739"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/umang.pk\/ur\/wp-json\/wp\/v2\/tags?post=28739"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}