<?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: Kevin</title>
    <description>The latest articles on DEV Community by Kevin (@kevinhui98).</description>
    <link>https://dev.to/kevinhui98</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.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3051444%2Feab093c1-9f92-4829-b6af-6f62aed951fd.png</url>
      <title>DEV Community: Kevin</title>
      <link>https://dev.to/kevinhui98</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/kevinhui98"/>
    <language>en</language>
    <item>
      <title>How I Built a Travel Assistant Chat App Using GPT and Jetpack Compose</title>
      <dc:creator>Kevin</dc:creator>
      <pubDate>Tue, 15 Apr 2025 02:47:26 +0000</pubDate>
      <link>https://dev.to/kevinhui98/how-i-built-a-travel-assistant-chat-app-using-gpt-and-jetpack-compose-o7c</link>
      <guid>https://dev.to/kevinhui98/how-i-built-a-travel-assistant-chat-app-using-gpt-and-jetpack-compose-o7c</guid>
      <description>&lt;h1&gt;
  
  
  How I Built a Travel Assistant Chat App Using GPT and Jetpack Compose
&lt;/h1&gt;

&lt;p&gt;In a world where AI is changing the way we plan and explore, I wanted to create something fun and practical — a mobile travel assistant powered by an LLM that helps you plan your next trip through natural conversation.&lt;/p&gt;

&lt;p&gt;This is how I built &lt;strong&gt;Travel Guide Chat&lt;/strong&gt;, a Jetpack Compose Android app that lets users chat with an LLM about travel plans, save conversations, and revisit them later.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Why I Built It
&lt;/h2&gt;

&lt;p&gt;I’m passionate about combining &lt;strong&gt;AI&lt;/strong&gt;, &lt;strong&gt;mobile UX&lt;/strong&gt;, and &lt;strong&gt;real-world use cases&lt;/strong&gt;. Travel Guide Chat is my attempt to blend these into one product:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A sleek, real-time &lt;strong&gt;chat interface&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;OpenRouter-powered LLM&lt;/strong&gt; for smart responses&lt;/li&gt;
&lt;li&gt;Persistent chat &lt;strong&gt;session history&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Auto-generated chat &lt;strong&gt;titles based on content&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Markdown rendering for clean, readable answers&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🔧 The Tech Stack
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Layer&lt;/th&gt;
&lt;th&gt;Stack&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;UI&lt;/td&gt;
&lt;td&gt;Jetpack Compose&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;State Mgmt&lt;/td&gt;
&lt;td&gt;ViewModel + StateFlow&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;API&lt;/td&gt;
&lt;td&gt;OpenRouter (ChatGPT-compatible)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Networking&lt;/td&gt;
&lt;td&gt;Ktor&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Storage&lt;/td&gt;
&lt;td&gt;JSON File (simple local persistence)&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Jetpack Compose gave me the flexibility to rapidly build a clean UI, while OpenRouter’s LLM API gave me access to powerful GPT-style responses.&lt;/p&gt;




&lt;h2&gt;
  
  
  💬 Key Features
&lt;/h2&gt;

&lt;h3&gt;
  
  
  ✈️ Chat with an AI Travel Assistant
&lt;/h3&gt;

&lt;p&gt;Users can ask about destinations, get itinerary suggestions, or plan a day trip — all via natural conversation.&lt;/p&gt;

&lt;h3&gt;
  
  
  📚 Chat History
&lt;/h3&gt;

&lt;p&gt;Each session is stored locally with an auto-generated title (like “Weekend in Tokyo”) and can be reloaded later.&lt;/p&gt;

&lt;h3&gt;
  
  
  🔁 Rename, Re-engage, Repeat
&lt;/h3&gt;

&lt;p&gt;Long press to rename chats, tap to resume any past session, and continue where you left off.&lt;/p&gt;

&lt;h3&gt;
  
  
  📝 Markdown Rendering
&lt;/h3&gt;

&lt;p&gt;LLM responses are rendered in Markdown for clean formatting — helpful for lists, bolded places, etc.&lt;/p&gt;




&lt;h2&gt;
  
  
  💡 Challenges &amp;amp; Solutions
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. Persisting Chat State
&lt;/h3&gt;

&lt;p&gt;I needed a lightweight solution, so I used &lt;strong&gt;JSON file storage&lt;/strong&gt; rather than Room DB. This kept things fast and simple.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Auto-Titling
&lt;/h3&gt;

&lt;p&gt;Instead of hardcoding titles, I generated them using the &lt;strong&gt;first user message&lt;/strong&gt; and &lt;strong&gt;LLM response&lt;/strong&gt; heuristics — giving each session a meaningful identity.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Compose UI Bugs
&lt;/h3&gt;

&lt;p&gt;Some scroll issues popped up in the chat window, but were solved with &lt;strong&gt;&lt;code&gt;LazyColumn&lt;/code&gt; + &lt;code&gt;LaunchedEffect(scrollState)&lt;/code&gt;&lt;/strong&gt; to keep the view anchored at the bottom.&lt;/p&gt;




&lt;h2&gt;
  
  
  📸 Screenshots
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fi.imgur.com%2FDo8q2Nv.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fi.imgur.com%2FDo8q2Nv.gif" alt="Travel Guide Chat Walkthrough" width="372" height="854"&gt;&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  🧪 What’s Next
&lt;/h2&gt;

&lt;p&gt;I plan to extend this with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;RAG (Retrieval-Augmented Generation)&lt;/strong&gt; using Pinecone&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Searchable conversations&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Cloud sync&lt;/strong&gt; so chats persist across devices&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;UI improvements&lt;/strong&gt; like avatars, emojis, etc.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  ✍️ Final Thoughts
&lt;/h2&gt;

&lt;p&gt;This project helped me level up my Compose skills, explore LLM integration, and think more deeply about UX in AI apps. I built something I’d actually use — and that’s what makes coding exciting.&lt;/p&gt;

&lt;p&gt;You can check out the repo here:&lt;br&gt;&lt;br&gt;
👉 &lt;a href="https://github.com/kevinhui98/travel-guide-chat" rel="noopener noreferrer"&gt;github.com/kevinhui98/travel-guide-chat&lt;/a&gt;&lt;/p&gt;




&lt;p&gt;Follow me for more projects on &lt;a href="https://github.com/kevinhui98" rel="noopener noreferrer"&gt;GitHub&lt;/a&gt;!&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
