<?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: Anil Kumar</title>
    <description>The latest articles on DEV Community by Anil Kumar (@anil_kumar_a1acc61500053c).</description>
    <link>https://dev.to/anil_kumar_a1acc61500053c</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%2F4208599%2F966444cd-e895-4653-bb95-d6b7eecdf063.png</url>
      <title>DEV Community: Anil Kumar</title>
      <link>https://dev.to/anil_kumar_a1acc61500053c</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/anil_kumar_a1acc61500053c"/>
    <language>en</language>
    <item>
      <title>Designing an Emotion-Aware Chat Backend: Patterns from Building Mendle</title>
      <dc:creator>Anil Kumar</dc:creator>
      <pubDate>Mon, 16 Nov 2026 09:58:06 +0000</pubDate>
      <link>https://dev.to/anil_kumar_a1acc61500053c/designing-an-emotion-aware-chat-backend-patterns-from-building-mendle-42gj</link>
      <guid>https://dev.to/anil_kumar_a1acc61500053c/designing-an-emotion-aware-chat-backend-patterns-from-building-mendle-42gj</guid>
      <description>&lt;p&gt;Most chat products treat every message as a standalone prompt. For an emotional wellness product, that's the wrong unit. The same sentence means different things depending on mood, history and who else is in the room.&lt;/p&gt;

&lt;p&gt;This post walks through the design problems we worked through while building Mendle, an AI emotional wellness platform for individuals, teams and communities. It is written at the pattern level. &lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Detect emotion, intent and context separately&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Emotion alone isn't enough. "I'm fine" after a long silence and "I'm fine" in a cheerful thread are different inputs. We treated three signals as separate:&lt;/p&gt;

&lt;p&gt;Emotion (what the person seems to feel)&lt;br&gt;
Intent (what they want from this message: vent, ask, plan)&lt;br&gt;
Context (recent conversation and longer-term mood history)&lt;/p&gt;

&lt;p&gt;Keeping them separate makes each one testable. The platform reports 90% emotion detection accuracy, which is the number that tells you the first layer is working before you tune anything downstream.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Let tone adapt, not just content&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Once you have an emotion estimate, the generation layer can change its register: shorter and calmer for distress, more exploratory for curiosity. The risk is overfitting to the label. We'd recommend keeping tone adaptation soft, so a wrong classification degrades the reply slightly instead of derailing it.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Build memory as a product feature&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The Emotional Memory Engine (EME) turns conversations into patterns: mood shifts, engagement trends and recurring themes. This does two jobs. It personalizes the wellness journey, and it gives users insight into their own patterns. Treat stored emotional data as sensitive by default. That drives most of the privacy decisions below.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Group chat needs its own signal&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Individual sentiment doesn't roll up cleanly into group health. We added community-level sentiment analysis so moderators and administrators can see trends and potential concerns early. The platform reports real-time risk detection and 70% higher group engagement.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Privacy is architecture, not a settings page&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;For sensitive emotional data, we designed around encryption, access controls and a compliance-ready structure from the start. Retrofitting these later usually means migrating data you've already collected.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Latency is part of the experience&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The reported 60% faster AI response time matters more here than in a typical chatbot, because a delayed reply in an emotional moment reads as indifference.&lt;/p&gt;

&lt;p&gt;Trade-offs worth naming&lt;br&gt;
More memory means more sensitive data to protect.&lt;br&gt;
Emotion labels are probabilistic. Never present them to users as facts about their feelings.&lt;br&gt;
Group analytics must be aggregated carefully so individuals aren't exposed.&lt;/p&gt;

&lt;p&gt;The product screens and full service breakdown are in the &lt;a href="https://www.solulab.com/case-study/mendle/" rel="noopener noreferrer"&gt;Mendle case study&lt;/a&gt;. If you're building something similar, we also publish on &lt;a href="https://www.solulab.com/ai-integration-services/" rel="noopener noreferrer"&gt;AI integration services&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>productivity</category>
      <category>nlp</category>
      <category>architecture</category>
    </item>
    <item>
      <title>Adding a Chatbot and Voice AI Agent to a Banking App</title>
      <dc:creator>Anil Kumar</dc:creator>
      <pubDate>Fri, 13 Nov 2026 11:28:53 +0000</pubDate>
      <link>https://dev.to/anil_kumar_a1acc61500053c/adding-a-chatbot-and-voice-ai-agent-to-a-banking-app-1e4</link>
      <guid>https://dev.to/anil_kumar_a1acc61500053c/adding-a-chatbot-and-voice-ai-agent-to-a-banking-app-1e4</guid>
      <description>&lt;p&gt;Adding AI to a banking app is mostly an integration problem, not a model problem. The model understands what the customer wants. Everything that touches money has to go through the bank’s existing systems, with clear rules about what the AI may and may not do.&lt;/p&gt;

&lt;p&gt;Here’s how that played out in a real project: an AI chatbot and voice agent for Aman Bank in Libya, which serves around 750,000 customers.&lt;/p&gt;

&lt;p&gt;The stack&lt;br&gt;
Layer   Technology&lt;br&gt;
Mobile apps Native Android (Kotlin) and iOS (Swift)&lt;br&gt;
Chatbot Python with a GPT-based language model&lt;br&gt;
Voice   Google Speech-to-Text, Text-to-Speech, NLP&lt;br&gt;
ML  TensorFlow&lt;br&gt;
Data / real time    MongoDB, WebSocket&lt;br&gt;
Infra / delivery    AWS, Jenkins, Git, Jira&lt;br&gt;
How a request flows&lt;br&gt;
The customer types or speaks in the app.&lt;br&gt;
Voice input goes through speech-to-text.&lt;br&gt;
The language model works out the intent (check balance, transfer, pay bill, request statement) and extracts details such as the amount and payee.&lt;br&gt;
The backend calls the right banking API. The model never computes a balance or decides whether a transfer is allowed.&lt;br&gt;
The response is phrased in plain language and, for voice users, turned back into speech.&lt;br&gt;
WebSocket keeps the conversation and alerts real time, for example low balance or suspicious activity.&lt;br&gt;
Rule 1: the LLM classifies, the core system answers&lt;/p&gt;

&lt;p&gt;The safest pattern is to treat the language model as a router. Here’s an illustrative sketch of the idea (not the production code):&lt;/p&gt;

&lt;p&gt;python&lt;br&gt;
INTENT_HANDLERS = {&lt;br&gt;
    "check_balance": banking_api.get_balance,&lt;br&gt;
    "recent_transactions": banking_api.get_transactions,&lt;br&gt;
    "pay_bill": banking_api.pay_registered_biller,&lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;def handle(message, customer):&lt;br&gt;
    intent, slots = llm.classify(message)         # model only labels intent and extracts fields&lt;br&gt;
    if intent not in INTENT_HANDLERS:&lt;br&gt;
        return escalate_to_agent(customer, message)&lt;br&gt;
    if requires_confirmation(intent):&lt;br&gt;
        return ask_customer_to_confirm(intent, slots)&lt;br&gt;
    data = INTENT_HANDLERS&lt;a href="//customer.id,%20**slots"&gt;intent&lt;/a&gt;   # source of truth&lt;br&gt;
    return llm.phrase(intent, data)                # model only phrases the result&lt;/p&gt;

&lt;p&gt;The model never invents a balance, and anything outside known intents goes to a person.&lt;/p&gt;

&lt;p&gt;Rule 2: confirm before money moves&lt;/p&gt;

&lt;p&gt;Transfers and payments need an explicit confirmation step: amount, payee and account read back to the customer, plus the bank’s normal authentication. Voice makes this more important, because speech-to-text can mishear numbers.&lt;/p&gt;

&lt;p&gt;Rule 3: voice needs its own testing&lt;/p&gt;

&lt;p&gt;Speech recognition accuracy varies by language, dialect, accent and background noise. Test with real customer recordings, not clean samples. Keep spoken responses short. Long answers are hard to follow by ear.&lt;/p&gt;

&lt;p&gt;Rule 4: design for low-end devices&lt;/p&gt;

&lt;p&gt;Many customers used feature phones or had limited data. Native apps help, as does keeping heavy AI work server-side.&lt;/p&gt;

&lt;p&gt;Results the bank reported&lt;br&gt;
60% faster onboarding (with OCR-based digital KYC)&lt;br&gt;
50% less workload for human support agents&lt;br&gt;
40% faster average response time&lt;/p&gt;

&lt;p&gt;Full case study: Aman Bank generative AI mobile banking platform. If you’re building something similar, this kind of work sits at the intersection of &lt;a href="https://www.solulab.com/ai-development-company/" rel="noopener noreferrer"&gt;AI software development&lt;/a&gt; and native mobile engineering.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>mobile</category>
      <category>fintech</category>
    </item>
    <item>
      <title>How an AI-Agent Analytics Layer Works: Notes on Cookie.fun's Data Approach" published</title>
      <dc:creator>Anil Kumar</dc:creator>
      <pubDate>Mon, 26 Oct 2026 11:43:22 +0000</pubDate>
      <link>https://dev.to/anil_kumar_a1acc61500053c/how-an-ai-agent-analytics-layer-works-notes-on-cookiefuns-data-approachpublished-2j7p</link>
      <guid>https://dev.to/anil_kumar_a1acc61500053c/how-an-ai-agent-analytics-layer-works-notes-on-cookiefuns-data-approachpublished-2j7p</guid>
      <description>&lt;p&gt;If you wanted to rank AI agents in crypto, where would the data come from, and how would you stop people gaming it? Cookie DAO's Cookie.fun is a useful real-world example: it indexes 1,400+ agents by merging off-chain chatter with on-chain behavior.&lt;/p&gt;

&lt;p&gt;Here is the architecture at a conceptual level, based on SoluLab's published case study.&lt;/p&gt;

&lt;p&gt;The key design choice is bridging off-chain sentiment with on-chain behavior in one signal dashboard. Social data alone is easy to inflate. On-chain data alone misses attention.&lt;/p&gt;

&lt;p&gt;*&lt;em&gt;Mindshare as a ranking primitive&lt;br&gt;
*&lt;/em&gt;&lt;br&gt;
Mindshare ranks agents by attention-weighted activity. The weighting details are not public in the case study, so treat this as a concept rather than a formula. For builders, the useful lesson is that a ranking needs both an activity signal and an attention signal.&lt;/p&gt;

&lt;p&gt;*&lt;em&gt;Where developers plug in&lt;br&gt;
*&lt;/em&gt;&lt;br&gt;
In the third rollout phase, Cookie released APIs so third-party AI tools could consume its data. That turned a dashboard into infrastructure, alongside two primitives:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Snaps:&lt;/strong&gt; tokenized actions that campaigns can reward&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;InfoFi:&lt;/strong&gt; attention and signal intelligence&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;*&lt;em&gt;Practical lessons&lt;br&gt;
*&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Combine at least two independent signal types before ranking anything.&lt;/li&gt;
&lt;li&gt;Expose an API early. Distribution through other tools beat a standalone UI.&lt;/li&gt;
&lt;li&gt;Reward verified actions, not impressions.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Full case study with results and the four-phase rollout: &lt;a href="https://www.solulab.com/case-study/marketingfi-and-ai-driven-mindshare/" rel="noopener noreferrer"&gt;SoluLab: Cookie DAO and MarketingFi&lt;/a&gt;&lt;/p&gt;

</description>
      <category>agents</category>
      <category>ai</category>
      <category>analytics</category>
      <category>web3</category>
    </item>
  </channel>
</rss>
