<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Furkan İlbay</title>
    <description>The latest articles on DEV Community by Furkan İlbay (@furkanilbay).</description>
    <link>https://dev.to/furkanilbay</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4159607%2Fae8fbb42-95ff-471d-9543-1410d6901b9c.jpg</url>
      <title>DEV Community: Furkan İlbay</title>
      <link>https://dev.to/furkanilbay</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/furkanilbay"/>
    <language>en</language>
    <item>
      <title>React Native ve FastAPI ile Yapay Zeka Destekli Mobil Uygulama Mimarisi: SafeBite AI</title>
      <dc:creator>Furkan İlbay</dc:creator>
      <pubDate>Sat, 03 Oct 2026 11:58:05 +0000</pubDate>
      <link>https://dev.to/furkanilbay/react-native-ve-fastapi-ile-yapay-zeka-destekli-mobil-uygulama-mimarisi-safebite-ai-1e2o</link>
      <guid>https://dev.to/furkanilbay/react-native-ve-fastapi-ile-yapay-zeka-destekli-mobil-uygulama-mimarisi-safebite-ai-1e2o</guid>
      <description>&lt;p&gt;Yapay zeka modellerini mobil bir uygulamaya entegre etmek ilk bakışta basit bir API çağrısı gibi görünse de; ağ gecikmesi, görsel boyutu optimizasyonu ve deterministik veri çıkışı alma gibi konular işin içine girdiğinde ciddi bir mühendislik mimarisi gerektiriyor.&lt;/p&gt;

&lt;p&gt;Bu yazıda, yakın zamanda iOS App Store'da yayına aldığım &lt;strong&gt;SafeBite AI&lt;/strong&gt; uygulamasının teknik mimarisini, mobil kamera akışından API'ye kadar uzanan hattı ve karşılaştığım optimizasyon problemlerini nasıl çözdüğümü paylaşıyorum.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;📲 &lt;strong&gt;Uygulama Linki:&lt;/strong&gt; &lt;a href="https://apps.apple.com/tr/app/safebite-ai/id6809148412" rel="noopener noreferrer"&gt;SafeBite AI - iOS App Store&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  🛠 Sistem Mimarisi
&lt;/h2&gt;

&lt;p&gt;Uygulamanın uçtan uca akışı temel olarak üç katmandan oluşuyor:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;İstemci (Mobile Client - React Native):&lt;/strong&gt; Kullanıcının kamera ile etiket fotoğrafı çekmesini, görselin istemci tarafında sıkıştırılmasını ve sonuçların anlık kullanıcıya sunulmasını yönetir.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Backend Gateway (FastAPI - Python):&lt;/strong&gt; Mobil istemciden gelen istekleri karşılayan, gelen görselleri ön işlemeden geçiren ve model orkestrasyonunu sağlayan yüksek performanslı asenkron API katmanı.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Yapay Zeka &amp;amp; Çok Modlu (Multimodal) Çıkarım:&lt;/strong&gt; Etiket üzerindeki içerik metinlerini ayrıştıran, kullanıcının alerjen profiliyle eşleştiren ve yapılandırılmış JSON çıktısı üreten model hattı.
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[React Native Mobil Uygulama]
           │  (Sıkıştırılmış Görsel + Kullanıcı Profili)
           ▼
[FastAPI Backend Gateway]
           │  (Pydantic Doğrulama &amp;amp; Prompt Orkestrasyonu)
           ▼
[Çok Modlu Yapay Zeka Hattı]
           │  (Yapılandırılmış JSON Yanıtı)
           ▼
[Mobil Arayüz (Anlık Alerjen &amp;amp; Güvenilirlik Raporu)]
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ⚡ Karşılaşılan Teknik Zorluklar ve Çözümler
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. Ağ Bant Genişliği ve Gecikme (Latency) Optimizasyonu
&lt;/h3&gt;

&lt;p&gt;Kullanıcının kameradan çektiği 4K çözünürlüğündeki ham görselleri doğrudan backend API'ye yüklemek hem mobil ağlarda ciddi bir gecikmeye yol açıyor hem de sunucu tarafında gereksiz kaynak tüketiyor.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Çözüm:&lt;/strong&gt; İstemci tarafında görsel ön işleme pipeline'ı kurarak resim çözünürlüğünü ve kalitesini optimize ettim. OCR ve çok modlu modellerin metin okuma başarımını düşürmeyecek bir eşik belirleyerek görsel boyutunu ~800 KB seviyesine çektim. Bu optimizasyon, mobil taraftaki istek süresini (roundtrip latency) yaklaşık &lt;strong&gt;%60 oranında azalttı&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  2. Yapay Zekadan Deterministik JSON Çıktısı Alma
&lt;/h3&gt;

&lt;p&gt;Büyük dil modelleri (LLM) serbest metin üretmeye meyillidir. Mobil istemcinin arayüzü hatasız çizebilmesi için her zaman aynı veri şemasının dönmesi gerekir.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Çözüm:&lt;/strong&gt; FastAPI tarafında &lt;strong&gt;Pydantic&lt;/strong&gt; kütüphanesini kullanarak kesin veri modelleri tanımladım. Model sistem prompt'larına JSON şema kısıtları ve few-shot örnekleri ekleyerek çıktıyı tip güvenli (type-safe) hale getirdim:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;pydantic&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;BaseModel&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;typing&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;List&lt;/span&gt;

&lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;AllergenResult&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;BaseModel&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
    &lt;span class="n"&gt;is_safe&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;bool&lt;/span&gt;
    &lt;span class="n"&gt;detected_allergens&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;List&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
    &lt;span class="n"&gt;confidence_score&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;float&lt;/span&gt;
    &lt;span class="n"&gt;summary&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  3. App Store Onay Süreçleri ve Güvenlik
&lt;/h3&gt;

&lt;p&gt;Sağlık ve gıda hassasiyeti içeren yapay zeka projelerinde Apple'ın inceleme kuralları oldukça katıdır. Uygulamanın tıbbi tavsiye vermediğini belirten sorumluluk reddi metinleri ve model güven skorunun düşük olduğu durumlarda devreye giren fallback mekanizmaları tasarlayarak onay sürecini başarıyla tamamladım.&lt;/p&gt;




&lt;h2&gt;
  
  
  🎯 Çıkarımlar
&lt;/h2&gt;

&lt;p&gt;Bu projeyi sıfırdan hayata geçirip App Store'a taşımak; yapay zeka mühendisliğinin asıl zorluğunun model çağırmak değil, &lt;strong&gt;uçtan uca veri hattı performansı&lt;/strong&gt;, &lt;strong&gt;hata toleransı&lt;/strong&gt; ve &lt;strong&gt;kullanıcı deneyimi&lt;/strong&gt; inşa etmek olduğunu bir kez daha gösterdi.&lt;/p&gt;

&lt;p&gt;Siz mobil uygulamalarınızda yapay zeka modellerini entegre ederken gecikme ve veri doğrulama sorunlarını nasıl çözüyorsunuz? Yorumlarda tartışalım!&lt;/p&gt;

</description>
      <category>turkish</category>
      <category>reactnative</category>
      <category>python</category>
      <category>ai</category>
    </item>
    <item>
      <title>How I Built and Shipped an AI Food Label Scanner to the App Store Using React Native &amp; FastAPI</title>
      <dc:creator>Furkan İlbay</dc:creator>
      <pubDate>Sat, 03 Oct 2026 11:21:33 +0000</pubDate>
      <link>https://dev.to/furkanilbay/how-i-built-and-shipped-an-ai-food-label-scanner-to-the-app-store-using-react-native-fastapi-1ag1</link>
      <guid>https://dev.to/furkanilbay/how-i-built-and-shipped-an-ai-food-label-scanner-to-the-app-store-using-react-native-fastapi-1ag1</guid>
      <description>&lt;p&gt;Building a mobile app powered by multimodal AI sounds straightforward on paper—until you have to deal with noisy camera inputs, low-latency API responses, and strict App Store review guidelines.&lt;/p&gt;

&lt;p&gt;Recently, I built and published &lt;strong&gt;SafeBite AI&lt;/strong&gt; to the iOS App Store. The goal of the app is simple yet critical: allow users with dietary restrictions or allergies to scan food ingredient labels and instantly know if it's safe for them to consume.&lt;/p&gt;

&lt;p&gt;In this article, I want to walk through the system architecture, the technical bottlenecks I faced, and how I optimized the mobile-to-cloud AI pipeline.&lt;/p&gt;




&lt;h2&gt;
  
  
  🛠 System Architecture
&lt;/h2&gt;

&lt;p&gt;The pipeline consists of three core components:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Client (Mobile):&lt;/strong&gt; Built with &lt;strong&gt;React Native / Expo&lt;/strong&gt;. Handles real-time camera capture, image compression, offline cache, and state management.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Backend API:&lt;/strong&gt; Built with &lt;strong&gt;FastAPI (Python)&lt;/strong&gt;. Serves as a high-performance orchestration layer between mobile requests and AI models.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;AI Vision &amp;amp; Inference:&lt;/strong&gt; Processes cropped label images, extracts raw ingredient lists, and analyzes them against user allergen profiles using structured prompt schemas.
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[Mobile App (React Native)]
           │  (Compressed Image + User Profile)
           ▼
[FastAPI Gateway]
           │  (Sanitization &amp;amp; Validation)
           ▼
[Multimodal LLM / OCR Engine]
           │  (Structured JSON Output)
           ▼
[Client Response (Instant Allergen Verdict)]
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  ⚡ Key Engineering Challenges &amp;amp; Solutions
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. Image Preprocessing &amp;amp; Payload Optimization
&lt;/h3&gt;

&lt;p&gt;Sending 4K raw photos from an iPhone camera directly to an AI endpoint kills responsiveness and inflates bandwidth costs. &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Solution:&lt;/strong&gt; On the client side, images are compressed and downscaled before transmission. Balancing OCR legibility with payload size was crucial; compressing down to ~800KB maintained over 95% text extraction accuracy while reducing network roundtrip latency by ~60%.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  2. Structured JSON Output Reliability
&lt;/h3&gt;

&lt;p&gt;Raw LLM text outputs often vary in format, which easily breaks mobile parsing logic.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Solution:&lt;/strong&gt; In FastAPI, I enforced strict schema validation using &lt;strong&gt;Pydantic&lt;/strong&gt; models. By supplying explicit JSON schemas and few-shot formatting constraints in the system prompts, the model consistently returns deterministic, type-safe responses:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;pydantic&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;BaseModel&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;typing&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;List&lt;/span&gt;

&lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;AllergenAnalysis&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;BaseModel&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
    &lt;span class="n"&gt;is_safe&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;bool&lt;/span&gt;
    &lt;span class="n"&gt;detected_allergens&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;List&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
    &lt;span class="n"&gt;confidence_score&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;float&lt;/span&gt;
    &lt;span class="n"&gt;summary&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  3. Surviving App Store Review Guidelines
&lt;/h3&gt;

&lt;p&gt;Publishing an AI-driven health/food application comes with rigorous scrutiny:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Clear disclaimers stating that the AI is an assistant, not medical advice.&lt;/li&gt;
&lt;li&gt;Robust fallback handling when the model confidence is below threshold.&lt;/li&gt;
&lt;li&gt;Clear Terms of Use and Privacy Policy covering image processing.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  📱 Live App &amp;amp; Takeaways
&lt;/h2&gt;

&lt;p&gt;Shipping this project from initial prototype to production taught me that the real challenge of "AI Engineering" isn't calling an API—it's handling edge cases, network latency, and building intuitive user experiences around probabilistic models.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;App Store:&lt;/strong&gt; You can check out &lt;a href="https://apps.apple.com/tr/app/safebite-ai/id6809148412" rel="noopener noreferrer"&gt;SafeBite AI on the App Store&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I’d love to hear your thoughts: How do you handle latency and structured outputs in your mobile AI projects? Let me know in the comments!&lt;/p&gt;

</description>
      <category>ai</category>
      <category>python</category>
      <category>react</category>
      <category>ios</category>
    </item>
  </channel>
</rss>
