<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Meet Limbachiya on Medium]]></title>
        <description><![CDATA[Stories by Meet Limbachiya on Medium]]></description>
        <link>https://medium.com/@meetlimbachiya2005?source=rss-b0d1f6c7ab98------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*cNw90a46hBR0SZHpYuixnA.jpeg</url>
            <title>Stories by Meet Limbachiya on Medium</title>
            <link>https://medium.com/@meetlimbachiya2005?source=rss-b0d1f6c7ab98------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 05 Dec 2026 22:05:02 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@meetlimbachiya2005/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Building Arthtantra: From Financial Intelligence Idea to Working Product]]></title>
            <link>https://medium.com/@meetlimbachiya2005/building-arthtantra-from-financial-intelligence-idea-to-working-product-18ec8f2513fa?source=rss-b0d1f6c7ab98------2</link>
            <guid isPermaLink="false">https://medium.com/p/18ec8f2513fa</guid>
            <dc:creator><![CDATA[Meet Limbachiya]]></dc:creator>
            <pubDate>Mon, 10 Aug 2026 10:18:48 GMT</pubDate>
            <atom:updated>2026-08-10T10:18:48.237Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>Introduction</strong></p><p>Arthtantra began with a simple question: what would a financial research workspace look like if evidence, uncertainty, and explainability were first-class product features?</p><p>Most market products are very good at showing information and much less good at explaining the path from information to conclusion. A price appears, a chart moves, a score changes, and the user is expected to infer the rest. Arthtantra was designed around a different promise:</p><p><strong>Never predict without evidence.</strong></p><p>That principle shaped the product, the architecture, the data model, the provider integrations, and even the error states. A missing quote should be visible as missing. A fallback should be identified as a fallback. A research section should be able to say that its source was unavailable rather than filling the gap with confident fiction.</p><p>The result is a full-stack financial intelligence workspace built through several intense days and nights of architecture, implementation, screenshots, production debugging, and deployment iteration.</p><p><strong>1. The problem we were solving</strong></p><p>Financial information is abundant but fragmented. A researcher may need to combine:</p><p>- market prices and historical returns;</p><p>- company profiles and financial metrics;</p><p>- technical signals;</p><p>- macroeconomic conditions;</p><p>- institutional and industry context;</p><p>- recent news and filings;</p><p>- crypto or alternative-asset data;</p><p>- portfolio exposure and risk;</p><p>- and a clear explanation of what is known versus uncertain.</p><p>These sources do not share one schema, one symbol system, one update schedule, or one definition of “live.” A provider may identify Google as `GOOGL`, another may return a regional suffix, and a third may not cover the instrument at all. An index can be available for a quote but unavailable for historical data. A mutual fund may have an AMFI or scheme identifier instead of an exchange ticker.</p><p>Arthtantra treats the research problem as a pipeline rather than a single API call:</p><p>User query</p><p>↓</p><p>Asset resolution</p><p>↓</p><p>Provider selection</p><p>↓</p><p>Response normalization</p><p>↓</p><p>Research dimensions</p><p>↓</p><p>Validation and confidence</p><p>↓</p><p>Evidence-backed presentation</p><p>This makes the system more complex than a simple quote dashboard, but it also creates room for better explanations and safer failure behavior.</p><p><strong>2. Product direction and user experience</strong></p><p>The frontend is designed as a financial workspace rather than a list of API responses. The main surfaces are:</p><p><strong>Dashboard</strong></p><p>The dashboard brings together a market pulse, watchlist, market top performers, index selection, timeframe controls, portfolio-oriented cards, and a historical trend view. The index selector includes NIFTY 50, SENSEX, NASDAQ, S&amp;P 500, Dow Jones, FTSE, DAX, Nikkei, Hang Seng, and ASX 200.</p><p>The chart became an important product lesson. The first version used attractive static SVG paths. It looked good, but it did not represent the selected index. The final direction is data-driven: the backend returns historical close points and the frontend calculates an independent path for the selected index and range.</p><p><strong>Research beds</strong></p><p>Research is organized into sections instead of one large block of prose. A session can contain asset overview, market snapshot, latest developments, company ecosystem, financial health, technical signals, industry context, macro context, institutional activity, historical context, risk assessment, opportunity assessment, evidence, and timeline information.</p><p>This structure makes partial availability possible. If a provider fails for one section, the UI can show that section as temporarily unavailable while preserving the rest of the research run.</p><p><strong>Garden and portfolio workflows</strong></p><p>The portfolio area is presented as a “Garden,” a product metaphor for cultivating and monitoring holdings. It supports holdings-oriented views, allocation context, watchlists, and portfolio health surfaces. The underlying model still uses conventional financial concepts: assets, holdings, quantities, prices, market values, and risk context.</p><p><strong>Public and authenticated product surfaces</strong></p><p>The application separates public landing and product pages from authenticated workflows. Authentication includes registration, email verification, login, user context, and Google sign-in integration points. Research sessions and user-owned portfolio actions are protected by the backend.</p><p><strong>3. Frontend architecture</strong></p><p>The frontend lives in `Frontend` and uses Next.js, React, TypeScript, Tailwind CSS, Framer Motion, Zustand, TanStack Query, and Lucide icons.</p><p>The broad responsibilities are:</p><p>src/app/ route-level pages and layouts</p><p>src/components/ reusable interface components</p><p>src/services/ API clients, stores, hooks, and domain data</p><p>src/lib/ utilities and shared helpers</p><p>The frontend does not receive provider credentials. It receives a backend URL through `NEXT_PUBLIC_ASTERION_API_URL` and calls the Django API.</p><p>A simplified API client boundary looks like this:</p><p>const apiBaseUrl = (</p><p>process.env.NEXT_PUBLIC_ASTERION_API_URL ?? “http://localhost:8000&quot;</p><p>).replace(/\/$/, “”);</p><p>export async function request&lt;T&gt;(path: string, init?: RequestInit): Promise&lt;T&gt; {</p><p>const response = await fetch(`${apiBaseUrl}${path}`, {</p><p>…init,</p><p>headers: {</p><p>“Content-Type”: “application/json”,</p><p>…(init?.headers ?? {}),</p><p>},</p><p>});</p><p>if (!response.ok) {</p><p>throw new Error(`API request failed: ${response.status}`);</p><p>}</p><p>return response.json() as Promise&lt;T&gt;;</p><p>}</p><p>The exact implementation evolves, but the boundary matters: components should consume typed application data, not know how CoinMarketCap or FMP formats their raw responses.</p><p>The dashboard chart follows the same principle. The backend returns points such as:</p><p>{</p><p>“date”: “2026–08–07”,</p><p>“close”: 24263.30</p><p>}</p><p>The frontend maps those values into chart coordinates based on the selected dataset. It does not reuse a universal decorative curve for every index.</p><p><strong>4. Backend architecture</strong></p><p>The backend lives in `Backend/platform` and uses Django and Django REST Framework. Its domain modules include:</p><p>apps/accounts authentication, users, OTP, Google login</p><p>apps/asset assets, exchanges, price bars</p><p>apps/market workspace, quotes, indexes, gainers</p><p>apps/research research sessions and research requests</p><p>apps/portfolio portfolios, holdings, transactions</p><p>apps/news news models and repositories</p><p>apps/ingestion provider adapters and normalized contracts</p><p>apps/intelligence signal engines and structured research output</p><p>apps/risk risk contracts and risk-oriented logic</p><p>apps/audit audit records</p><p>apps/operations health, jobs, rate limits, operations</p><p>apps/runtime context, cache, confidence, explainability</p><p>The backend is intentionally more than a collection of view functions. Views receive requests and return responses. Domain services resolve assets and build research sessions. Provider adapters communicate with external systems. Contracts and normalization functions define the shape that the rest of the application can trust.</p><p>A simplified provider interface looks like this:</p><p>class MarketProvider(ABC):</p><p>name = “provider”</p><p>@abstractmethod</p><p>def fetch_prices(self, *, symbol, start, end):</p><p>“””Return normalized price observations.”””</p><p>The provider registry can select candidates by capability and priority. That creates a path toward resilient provider fusion rather than hard-coding the entire product to one vendor.</p><p><strong>5. Database design</strong></p><p>The relational database is the system of record for user and product state. PostgreSQL is the production target, while SQLite is available for local development.</p><p><strong>Core entities</strong></p><p><strong>Users and authentication</strong></p><p>Users, credentials, verification state, refresh/access-token workflows, and Google identity integration support protected product actions.</p><p><strong>Assets and exchanges</strong></p><p>An `Asset` represents the instrument concept. An `Exchange` represents a trading venue. An asset can have a symbol, type, currency, sector, industry, metadata, active status, and optional exchange relationship.</p><p>Supported type values include stock, ETF, mutual fund, bond, crypto, forex, commodity, and index. This distinction prevents the system from treating every searchable thing as a common stock.</p><p><strong>Price observations</strong></p><p>`PriceBar` stores open, high, low, close, volume, timestamp, timeframe, source, and quality score. Keeping `source` on the observation is essential for comparing provider behavior and explaining where a number came from.</p><p>Conceptually:</p><p>class PriceBar(models.Model):</p><p>asset = models.ForeignKey(Asset, on_delete=models.CASCADE)</p><p>timeframe = models.CharField(max_length=16, default=”1d”)</p><p>timestamp = models.DateTimeField()</p><p>open = models.DecimalField(max_digits=24, decimal_places=8)</p><p>high = models.DecimalField(max_digits=24, decimal_places=8)</p><p>low = models.DecimalField(max_digits=24, decimal_places=8)</p><p>close = models.DecimalField(max_digits=24, decimal_places=8)</p><p>volume = models.DecimalField(max_digits=30, decimal_places=8, null=True)</p><p>source = models.CharField(max_length=80)</p><p><strong>Research state</strong></p><p>Research sessions, sections, requests, reports, changes, timestamps, and status transitions allow the UI to show a structured run rather than a single opaque response.</p><p><strong>Portfolio and audit state</strong></p><p>Portfolio holdings, transactions, alerts, and audit records give the platform a durable product foundation beyond read-only market data.</p><p><strong>6. Provider architecture and API responsibilities</strong></p><p>No provider is treated as universal truth. Each provider has strengths, coverage boundaries, rate limits, symbol conventions, and failure modes.</p><p>| Provider/API | Role in Arthtantra |</p><p>| CoinMarketCap | Crypto discovery, quotes, and historical crypto prices |</p><p>| Finnhub | Equity search, quotes, profiles, fundamentals, and metrics |</p><p>| Financial Modeling Prep | Stock/index prices, historical data, gainers, symbol search, ETF/fund paths, and fallbacks |</p><p>| Twelve Data | Price series, historical data, technical-indicator route, and regional index fallback |</p><p>| Polygon | Market prices and historical price provider path |</p><p>| Alpha Vantage | Price/history and macro-oriented fallback path |</p><p>| Google News RSS | Latest developments and research evidence links |</p><p>| SEC EDGAR | Company facts and filing-oriented evidence |</p><p>| FRED | Macroeconomic data integration point |</p><p>| Brevo | Signup verification and transactional email |</p><p>| Google Identity | Optional authentication integration |</p><p>| OpenAI | Optional analyst/orchestrator integration point |</p><p>Provider keys are backend-only:</p><p>```env</p><p>FMP_API_KEY=server-side-only</p><p>COINMARKETCAP_API_KEY=server-side-only</p><p>FINNHUB_API_KEY=server-side-only</p><p>```</p><p>They must not be prefixed with `NEXT_PUBLIC_`, committed to git, or exposed to browser code.</p><p><strong>Why normalization matters</strong></p><p>One provider may return `price`, another `close`, another `c`, and another may wrap the result in `data`, `results`, or `historical`. The ingestion layer translates those variations into application contracts.</p><p>return PriceObservation(</p><p>symbol=symbol.upper(),</p><p>timestamp=timestamp,</p><p>open=row.get(“open”, row.get(“o”)),</p><p>high=row.get(“high”, row.get(“h”)),</p><p>low=row.get(“low”, row.get(“l”)),</p><p>close=row.get(“close”, row.get(“c”)),</p><p>volume=row.get(“volume”, row.get(“v”)),</p><p>source=self.name,</p><p>)</p><p>Without this boundary, every frontend card and research engine would need provider-specific logic.</p><p><strong>7. Asset resolution: the deceptively hard problem</strong></p><p>The user types a name. The market needs a canonical instrument. That translation is not trivial.</p><p>The resolver follows a layered approach:</p><p>```text</p><p>Exact local symbol/name</p><p>↓</p><p>Known aliases and canonical mappings</p><p>↓</p><p>Crypto lookup through CoinMarketCap</p><p>↓</p><p>FMP name search</p><p>↓</p><p>Finnhub equity search</p><p>↓</p><p>Explicit unavailable response</p><p>Examples that forced this design:</p><p>```text</p><p>Google → GOOGL</p><p>Mahindra &amp; Mahindra → M&amp;M.NS</p><p>Artificial Superintelligence Alliance → crypto symbol through CMC</p><p>Sensex / BSENI / BSEI → ^BSESN</p><p>NIFTY / NIFTY 50 → ^NSEI</p><p>```</p><p>The dangerous version is unrestricted fuzzy matching. A query such as `BSENI` can return an unrelated listing if the provider considers “close enough” to be good enough. The resolver now prefers exact and known canonical matches before remote fuzzy search.</p><p>This is a broader engineering lesson: search is not identity. Search suggests candidates; resolution must establish which asset the user actually meant.</p><p><strong>8. Research-session pipeline</strong></p><p>When a user starts research, the backend validates the input, resolves an active asset, creates or updates a session, and executes defined research sections.</p><p>```text</p><p>POST /api/research/sessions/</p><p>↓</p><p>Validate query</p><p>↓</p><p>Resolve Asset</p><p>↓</p><p>Create ResearchSession</p><p>↓</p><p>Initialize section records</p><p>↓</p><p>Run provider-backed section functions</p><p>↓</p><p>Persist package, changes, status, timestamps</p><p>↓</p><p>Return structured session to frontend</p><p>```</p><p>Each section is intentionally shaped as data. The frontend knows how to render a market snapshot, evidence list, timeline, or risk block without needing to understand how the external provider was called.</p><p>A simplified section definition looks like:</p><p>```python</p><p>SECTION_DEFINITIONS = (</p><p>(“asset_overview”, “Asset Overview”),</p><p>(“market_snapshot”, “Market Snapshot”),</p><p>(“latest_developments”, “Latest Developments”),</p><p>(“technical_signals”, “Technical Signals”),</p><p>(“macro_context”, “Macroeconomic Context”),</p><p>(“risk_assessment”, “Risk Assessment”),</p><p>(“opportunity_assessment”, “Opportunity Assessment”),</p><p>(“evidence”, “Evidence”),</p><p>)</p><p>```</p><p>The service records failures by section. This is important because a market-data provider outage should not erase an otherwise useful asset overview or evidence timeline.</p><p><strong>9. The chart incident and real historical data</strong></p><p>The first dashboard trend chart used hard-coded SVG geometry. It was visually polished but semantically wrong. Every index and timeframe could inherit the same shape.</p><p>The corrected flow is:</p><p>```text</p><p>Dashboard selects index + range</p><p>↓</p><p>GET /market/indexes?index=NIFTY50&amp;range=6M</p><p>↓</p><p>Backend asks provider(s) for historical prices</p><p>↓</p><p>Response returns date/close points</p><p>↓</p><p>Frontend independently scales the selected points</p><p>↓</p><p>Chart refreshes periodically</p><p>```</p><p>The frontend converts the data into coordinates:</p><p>```ts</p><p>const min = Math.min(…values);</p><p>const max = Math.max(…values);</p><p>const spread = max — min || Math.max(Math.abs(max) * 0.01, 1);</p><p>const y = (value: number) =&gt;</p><p>180 — ((value — min) / spread) * 160;</p><p>```</p><p>This does not make a provider omniscient. It does make the visualization faithful to the points returned for that index and range.</p><p>For regional index coverage, the backend attempts explicit symbol handling and fallback routes. The UI should communicate unavailable data rather than silently substitute an unrelated market.</p><p><strong>10. Authentication and security boundaries</strong></p><p>Arthtantra separates public pages from authenticated research and portfolio actions. Authentication includes registration, email verification, login, user context, and Google sign-in integration points.</p><p>Security decisions include:</p><p>- provider secrets remain server-side;</p><p>- API URLs are configured by environment;</p><p>- user-owned records are scoped to the authenticated user;</p><p>- backend permissions guard protected views;</p><p>- email verification is handled through a transactional sender;</p><p>- audit models provide a foundation for recording critical actions;</p><p>- legal and risk disclosure documents live in the repository.</p><p>The financial domain also requires product honesty. A market-data result is not automatically a recommendation. A forecast is not a guarantee. Arthtantra presents research and decision support, not certainty or personalized financial advice.</p><p><strong>11. Deployment architecture</strong></p><p>The current documented deployment model is:</p><p>```text</p><p>Vercel</p><p>└── Next.js frontend</p><p>│</p><p>▼ NEXT_PUBLIC_ASTERION_API_URL</p><p>Render</p><p>└── Django + Gunicorn backend</p><p>│</p><p>├── Render PostgreSQL</p><p>└── Optional managed Redis</p><p>```</p><p>The deployment boundary created several real bugs. A backend provider key in a local `.env` does not configure Render. A Vercel environment variable does not configure Django. Updating an environment variable requires a new deployment before the built frontend or backend sees it.</p><p>The deployment checklist became:</p><p>```text</p><p>1. Confirm backend environment variables</p><p>2. Confirm frontend API URL</p><p>3. Confirm production CORS origin</p><p>4. Run migrations</p><p>5. Start Gunicorn on the platform port</p><p>6. Verify backend endpoint directly</p><p>7. Verify frontend request in the browser</p><p>8. Refresh after redeploy</p><p>9. Check that live/unavailable status is truthful</p><p>```</p><p>The last step matters most. A green dashboard badge is not a substitute for valid points.</p><p><strong>12. Testing and validation</strong></p><p>The project uses proportional validation while the system continues to grow. Useful checks include:</p><p>```bash</p><p>cd Frontend</p><p>npx tsc — noEmit</p><p>cd ../Backend/platform</p><p>python3 -m py_compile apps/market/views.py apps/research/views.py</p><p>python3 manage.py check</p><p>```</p><p>The most valuable testing scenarios are not only happy paths. They include:</p><p>- a known stock by ticker;</p><p>- a company by name;</p><p>- a crypto by name, symbol, and slug;</p><p>- an Indian index by alias;</p><p>- an ETF or mutual fund;</p><p>- a provider returning an empty response;</p><p>- a missing provider credential;</p><p>- a stale frontend deployment;</p><p>- a null quote or missing numeric field;</p><p>- an authenticated user requesting another user’s data.</p><p>The production screenshots became an informal test suite. Each screenshot exposed a real contract failure: missing data, wrong resolution, stale deployment, fake chart geometry, or frontend null handling.</p><p><strong>13. The nights and iteration</strong></p><p>The current `main` line contains <strong>**66 commits**</strong>, with the most concentrated work running from <strong>**August 6–10, 2026**</strong>. The commit history records live market wiring, research rendering, authentication refinements, dashboard changes, crypto and fund resolution, graph sorting, null-safety fixes, and deployment corrections.</p><p>The first production screenshot often became the next implementation task. That is the real rhythm of product engineering: architecture creates the boundaries, users reveal the edge cases, and iteration closes the gap.</p><p>There were no clean “frontend days” and “backend days.” A chart issue could lead to an API change. An asset resolver bug could reveal a database modeling problem. A deployment issue could expose a configuration boundary. The work moved across the stack because the product experience is the sum of all those boundaries.</p><p><strong>14. What exists today</strong></p><p>Arthtantra currently has:</p><p>- a responsive Next.js product interface;</p><p>- authenticated research sessions;</p><p>- Django REST market and research endpoints;</p><p>- asset, exchange, price, portfolio, news, audit, and research models;</p><p>- provider adapters and normalized data contracts;</p><p>- crypto discovery through CoinMarketCap;</p><p>- equity discovery through Finnhub and FMP paths;</p><p>- dashboard index selection and historical chart data paths;</p><p>- watchlists, Garden/portfolio surfaces, alerts, settings, and public product pages;</p><p>- deployment documentation for Vercel and Render;</p><p>- legal and risk disclosure documentation.</p><p>It is a real foundation, not the final form. The platform is intentionally honest about provider coverage and keeps deeper breadth and reliability work for V2.</p><p><strong>15. V2 roadmap</strong></p><p>V2 is reserved for the next level of reliability and breadth:</p><p>1. Broader global ETF, mutual-fund, commodity, index, and exchange coverage.</p><p>2. Provider-health dashboards with latency, error, freshness, and coverage metrics.</p><p>3. Stronger historical validation and cross-provider reconciliation.</p><p>4. More complete live-market guarantees with clear exchange-session semantics.</p><p>5. Asynchronous research execution and better progress reporting.</p><p>6. Richer portfolio analytics, scenarios, drawdown analysis, and allocation tools.</p><p>7. Reproducible research snapshots with data lineage and source timestamps.</p><p>8. More extensive automated tests around resolution, permissions, fallbacks, and null data.</p><p>The central promise remains unchanged:</p><p>&gt; Never predict without evidence, and never hide uncertainty behind a pretty interface.</p><p><strong>Closing thought</strong></p><p>Arthtantra was built through a mixture of architecture, design, debugging, deployment, screenshots, and persistence. The interface is the visible part. Underneath it is an attempt to make financial intelligence more structured, more explainable, and more useful to the person trying to understand a noisy market.</p><p>The market is volatile. The APIs are inconsistent. The browser cache has opinions. The chart still has to be accurate.</p><p>That is the work.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=18ec8f2513fa" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[From a Random Idea to a Deployed Digital Banking Platform: Building Underseas Bank with FastAPI and…]]></title>
            <link>https://medium.com/@meetlimbachiya2005/from-a-random-idea-to-a-deployed-digital-banking-platform-building-underseas-bank-with-fastapi-and-b1c3e00cfd97?source=rss-b0d1f6c7ab98------2</link>
            <guid isPermaLink="false">https://medium.com/p/b1c3e00cfd97</guid>
            <category><![CDATA[developed-an-fintech]]></category>
            <dc:creator><![CDATA[Meet Limbachiya]]></dc:creator>
            <pubDate>Fri, 10 Jul 2026 18:52:40 GMT</pubDate>
            <atom:updated>2026-07-10T18:53:44.211Z</atom:updated>
            <content:encoded><![CDATA[<h3>From a Random Idea to a Deployed Digital Banking Platform: Building Underseas Bank with FastAPI and React</h3><p>“Every full-stack project starts with an idea. Mine started with a question — ‘Can I build a modern digital banking platform from scratch while learning along the way?’”</p><h3><strong>Introduction</strong></h3><p>About three months ago, I decided to build something bigger than another CRUD application.I wanted a project that would push me to understand how modern full-stack applications are actually designed.Instead of creating a simple to-do app or notes application, I challenged myself to build a <strong>digital banking platform</strong>.Not because banking is easy.But because banking systems combine almost every concept a software engineer needs to understand:</p><ul><li>Authentication</li><li>Database relationships</li><li>Transactions</li><li>Business logic</li><li>Security</li><li>APIs</li><li>Frontend architecture</li><li>Deployment</li><li>Cloud services</li></ul><p>That project eventually became <strong>Underseas Bank</strong>. Today, it’s live. This article isn’t just about the final product. It’s about <strong>why each technology was chosen</strong>, <strong>what problems it solved</strong>, and <strong>what I learned during the journey</strong>.</p><h3>Why a Banking Platform?</h3><p>Banking software isn’t simply about moving money from one account to another.</p><p>It involves:</p><ul><li>User identity</li><li>Authentication</li><li>Secure APIs</li><li>Financial records</li><li>Transaction history</li><li>Balance consistency</li><li>Different financial products</li><li>Analytics</li><li>Scalability</li></ul><p>A banking application naturally combines backend engineering, frontend development, database design, and cloud deployment into one project. It forces you to think like an engineer rather than simply writing code.</p><h3>The Goal</h3><p>I wanted users to be able to:</p><ul><li>Register securely</li><li>Log in using MPIN authentication</li><li>Create multiple bank accounts</li><li>Deposit money</li><li>Withdraw money</li><li>Transfer funds</li><li>Track transaction history</li><li>Apply for loans</li><li>Create Fixed Deposits</li><li>Manage Credit Cards</li><li>View financial analytics</li></ul><p>Each feature introduced a different engineering challenge.</p><h3>Choosing the Tech Stack</h3><h4>One of the biggest lessons I learned was that technologies should be selected based on <strong>the problems they solve</strong>, not because they’re popular.</h4><h3>Backend — FastAPI</h3><p>Why FastAPI?</p><p>FastAPI is one of the fastest modern Python frameworks.</p><p>It automatically provides:</p><ul><li>request validation</li><li>type checking</li><li>OpenAPI documentation</li><li>asynchronous support</li><li>high performance</li></ul><p>Unlike traditional frameworks, FastAPI encourages writing clean, structured APIs with minimal boilerplate. Another reason I selected FastAPI was its excellent developer experience. The automatic Swagger documentation significantly reduced the effort required to test endpoints.</p><h3>Why PostgreSQL?</h3><p>A banking application stores structured financial information. Relationships are extremely important. One user owns multiple accounts. Each account contains many transactions. Loans belong to users. Fixed Deposits belong to users. Credit Cards belong to users. A relational database is naturally suited for this. PostgreSQL provides:</p><ul><li>ACID transactions</li><li>Foreign Keys</li><li>Reliability</li><li>Strong consistency</li></ul><p>Exactly what a banking application requires.</p><h3>Why SQLAlchemy?</h3><p>Writing raw SQL for every operation quickly becomes difficult to maintain.</p><p>SQLAlchemy allows Python classes to represent database tables.</p><p>Instead of writing SQL manually, I could write:</p><pre>user = db.query(User).filter(User.email == email).first()</pre><p>This improves readability while still generating efficient SQL queries.</p><h3>Why JWT Authentication?</h3><p>After a successful login, users shouldn’t repeatedly enter credentials for every request. JWT (JSON Web Tokens) solves this problem. The backend generates a signed token containing the user’s identity. Subsequent requests include that token inside the Authorization header. The server validates the token before allowing access to protected endpoints. This makes authentication:</p><ul><li>Stateless</li><li>Secure</li><li>Scalable</li></ul><h3>Why Redis?</h3><p>Although PostgreSQL stores permanent data, some information doesn’t need permanent storage. Redis is an in-memory database optimized for speed. It is commonly used for:</p><ul><li>caching</li><li>OTP storage</li><li>session data</li><li>rate limiting</li></ul><p>In my project, Redis was introduced to improve performance and prepare the application for features requiring temporary data.</p><h3>Why Celery?</h3><p>Some tasks shouldn’t block the user interface.</p><p>For example:</p><p>Sending an email shouldn’t force users to wait.</p><p>Celery allows such tasks to execute asynchronously.</p><p>Instead of:</p><pre>User waits<br>↓</pre><pre>Email sends<br>↓</pre><pre>Response</pre><p>The flow becomes:</p><pre>User requests action<br>↓</pre><pre>Task added to queue<br>↓</pre><pre>Immediate response<br>↓</pre><pre>Email sent in background</pre><p>This greatly improves responsiveness.</p><h3>Why Brevo?</h3><p>Users expect transactional emails. Instead of building an email server, I integrated Brevo.</p><p>It provides reliable email delivery through SMTP for:</p><ul><li>OTP verification</li><li>Notifications</li><li>Password recovery (future)</li></ul><h3>Why React?</h3><p>The backend manages data. The frontend manages experience. React allowed me to build reusable UI components.</p><p>Examples include:</p><ul><li>Sidebar</li><li>Dashboard Cards</li><li>Transaction Tables</li><li>Loan Components</li><li>Analytics Charts</li></ul><p>Each component is isolated, reusable, and easier to maintain.</p><h3>Why Vite?</h3><p>Traditional React setups can become slow as projects grow.</p><p>Vite provides:</p><ul><li>instant startup</li><li>faster builds</li><li>excellent development experience</li></ul><p>This significantly reduced development time.</p><h3>Why Recharts?</h3><p>Financial information becomes much easier to understand visually.</p><p>Instead of listing numbers, I added:</p><ul><li>expense charts</li><li>spending analytics</li><li>financial overview</li></ul><p>Charts communicate patterns better than tables.</p><h3>Why Figma?</h3><p>Before writing frontend code, I designed layouts. This reduced unnecessary redesigns later. Planning visually first made development faster.</p><h3>Why Antigravity?</h3><p>UI inspiration. Good design is rarely created in isolation. Antigravity helped explore modern dashboard layouts and interaction ideas that influenced the application’s visual direction.</p><h3>Why Render?</h3><p>A project isn’t complete until it’s deployed.</p><p>Render provided:</p><ul><li>FastAPI hosting</li><li>Environment variable management</li><li>Automatic deployments</li><li>HTTPS</li><li>Production infrastructure</li></ul><p>Deployment introduced completely new challenges compared to local development.</p><h3>Why Vercel?</h3><p>React applications deploy exceptionally well on Vercel.</p><p>Advantages:</p><ul><li>automatic deployments</li><li>CDN</li><li>excellent React support</li><li>GitHub integration</li></ul><p>Every Git push automatically updates the live frontend.</p><h3>Why NeonDB?</h3><p>Instead of running PostgreSQL locally forever, I experimented with cloud-hosted databases. Neon provides managed PostgreSQL without maintaining infrastructure manually.</p><h3>What I Learned:</h3><p>The biggest lesson wasn’t FastAPI.</p><p>It wasn’t React.</p><p>It wasn’t PostgreSQL.</p><p>It was debugging.</p><p>Every production deployment exposed problems that never appeared locally.</p><p>I learned about:</p><ul><li>CORS</li><li>Environment Variables</li><li>Authentication flows</li><li>Cloud deployments</li><li>API debugging</li><li>Database migrations</li></ul><p>Many of these concepts only truly make sense after experiencing them firsthand.</p><h3>Biggest Challenges</h3><p>Some memorable moments included:</p><ul><li>APIs working locally but failing in production</li><li>JWT authentication errors</li><li>Database connection problems</li><li>Deployment failures</li><li>Missing environment variables</li><li>CORS restrictions</li><li>Email configuration</li></ul><p>Every problem forced me to understand the underlying system rather than simply copying code.</p><h3>Looking Back</h3><p>When I started this project, I didn’t know everything required to build it. That’s exactly why I started. Instead of waiting until I felt “ready,” I learned one feature at a time. The result isn’t just a deployed banking platform. It’s a collection of lessons earned through months of building, breaking, debugging, and improving.</p><h3>Final Thoughts</h3><p>One sentence summarizes this entire journey:</p><blockquote><strong><em>I took a lot of questionable decisions while building this project. Looking back, I appreciate every single one of them because each one taught me something valuable.</em></strong></blockquote><p>Underseas Bank is more than a portfolio project.</p><p>It’s a milestone in my learning journey as a software engineer.</p><p>Regards,</p><p>Meet Limbachiya</p><p>AI/ML FULL STACK ENGINEER</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*YAGBAYNFjE-YCV4d6RK_YA.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b1c3e00cfd97" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Building a Banking System API with FastAPI and PostgreSQL]]></title>
            <link>https://medium.com/@meetlimbachiya2005/building-a-banking-system-api-with-fastapi-and-postgresql-e45833d1200c?source=rss-b0d1f6c7ab98------2</link>
            <guid isPermaLink="false">https://medium.com/p/e45833d1200c</guid>
            <dc:creator><![CDATA[Meet Limbachiya]]></dc:creator>
            <pubDate>Tue, 10 Mar 2026 17:52:07 GMT</pubDate>
            <atom:updated>2026-03-10T17:52:07.334Z</atom:updated>
            <content:encoded><![CDATA[<h3>Modern backend systems must handle authentication, data integrity, and secure transactions. A banking system is a good example because it combines multiple backend concepts: authentication, account management, and financial transactions.</h3><p>This article explains the design and implementation of a banking system API built with FastAPI and PostgreSQL.</p><h3>Project Objective</h3><p>The goal is to build a backend service that simulates basic banking operations:</p><ul><li>User registration</li><li>User authentication</li><li>Account creation</li><li>Balance management</li><li>Money transfer between accounts</li><li>Transaction recording</li></ul><p>The system focuses on backend architecture, database design, and API development.</p><h3>Technology Stack</h3><p>FastAPI provides a high performance framework for building APIs in Python. It includes automatic request validation and interactive API documentation.</p><ul><li>PostgreSQL stores application data and ensures reliability for financial records.</li><li>SQLAlchemy handles object relational mapping between Python models and database tables.</li><li>Pydantic validates request and response data.</li><li>JWT tokens secure protected endpoints.</li><li>Uvicorn runs the FastAPI application.</li></ul><h3>System Architecture</h3><p>The project follows a modular backend structure that separates responsibilities across components.</p><ul><li>Models represent database tables.</li><li>Schemas validate API request and response data.</li><li>Routes define API endpoints.</li><li>Services contain business logic.</li><li>Middleware handles authentication.</li><li>Utilities provide helpers such as JWT token generation.</li></ul><p>This separation improves maintainability and scalability.</p><h3>Database Design</h3><p>The core entities in the system are Users, Accounts, and Transactions.</p><p>Users store identity information and authentication data.</p><p>Accounts represent bank accounts linked to users. Each account contains an account number and balance.</p><p>Transactions record money transfers between accounts.</p><p>Example structure:</p><p>Users<br>id<br>name<br>email<br>phone_number<br>mpin_hash</p><p>Accounts<br>id<br>account_number<br>user_id<br>balance</p><p>Transactions<br>id<br>sender_account<br>receiver_account<br>amount<br>created_at</p><p>This structure ensures every financial operation is recorded.</p><h3>User Authentication</h3><ul><li>Authentication uses phone number and MPIN.</li><li>During registration the MPIN is hashed before storage.</li><li>During login the system verifies the hashed value and generates a JWT token.</li><li>The token is used to access protected endpoints.</li></ul><p>Protected routes require authentication middleware which extracts and validates the token before processing the request.</p><h3>Account Creation</h3><ul><li>After authentication a user can create a bank account.</li><li>The system generates a unique account number and links it to the user.</li><li>Each account starts with a balance of zero.</li></ul><p>Account creation allows the system to manage multiple accounts per user if needed.</p><h3>Money Transfer Logic</h3><ul><li>Money transfer is the core feature.</li><li>The process follows several steps.</li><li>1) the sender account is retrieved.</li><li>2) the receiver account is validated.</li><li>3) the sender balance is checked to ensure sufficient funds.</li><li>4) the sender balance decreases and the receiver balance increases.</li><li>Finally a transaction record is stored.</li></ul><p>Example transfer request:</p><p>POST /transactions/transfer</p><p>Request body</p><p>receiver_account<br>amount</p><p>After completion the database reflects updated balances and a transaction history entry.</p><h3>Transaction Recording</h3><p>Every transfer creates a transaction record.</p><p>This record includes sender account number, receiver account number, amount, and timestamp.</p><p>Transaction history enables auditing and debugging of financial operations.</p><h3>API Testing</h3><p>Testing uses FastAPI documentation interface.</p><p>The common workflow is:</p><p>Register a user<br>Login to receive a token<br>Authorize the token<br>Create a bank account<br>Transfer money to another account</p><p>Testing should also include invalid scenarios such as insufficient balance or invalid receiver accounts.</p><h3>Key Backend Concepts Demonstrated</h3><p>The project demonstrates several important backend engineering concepts.</p><ul><li>Secure authentication with JWT</li><li>Database relationships between users and accounts</li><li>Business logic separation through service layers</li><li>Transaction recording for financial operations</li><li>Validation of input data before execution</li></ul><p>These concepts appear frequently in production backend systems.</p><h3>Possible Improvements</h3><p>Future enhancements could include transaction history endpoints, beneficiary management, loan modules, credit card systems, and rate limiting.</p><p>Additional improvements could include database migrations, containerized deployment, and automated testing.</p><h3>Conclusion</h3><p>A banking system backend provides an excellent environment for learning backend development concepts. It requires careful handling of authentication, database consistency, and transaction logic.</p><p>FastAPI and PostgreSQL provide a reliable foundation for building such systems. By structuring the project into models, routes, services, and middleware, the system becomes easier to maintain and extend.</p><p>This project demonstrates how modern backend tools can be combined to implement core banking functionality in a structured and scalable way.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e45833d1200c" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Predicting Car Price Depreciation with Machine Learning ]]></title>
            <link>https://medium.com/@meetlimbachiya2005/predicting-car-price-depreciation-with-machine-learning-c2458ba65056?source=rss-b0d1f6c7ab98------2</link>
            <guid isPermaLink="false">https://medium.com/p/c2458ba65056</guid>
            <dc:creator><![CDATA[Meet Limbachiya]]></dc:creator>
            <pubDate>Fri, 29 Aug 2025 08:59:07 GMT</pubDate>
            <atom:updated>2025-08-29T08:59:07.107Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*C7r-FNltZWpYg-6YFwwIYw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*C7r-FNltZWpYg-6YFwwIYw.png" /></figure><p>Buying a car is exciting, but figuring out how much it will be worth after a few years? Not so much. Cars lose value every year due to <strong>depreciation</strong>, and predicting this accurately can help both buyers and sellers make smarter decisions.</p><p>In this project, I built a <strong>Car Price Depreciation Prediction Model</strong> using <strong>Python, Pandas, Scikit-learn, and Random Forest Regressor</strong>.</p><h3>🔧 Tech Stack</h3><ul><li><strong>Python</strong> 🐍</li><li><strong>Pandas, NumPy</strong> → data cleaning &amp; preprocessing</li><li><strong>Matplotlib, Seaborn</strong> → data visualization</li><li><strong>Scikit-learn</strong> → machine learning</li><li><strong>Streamlit</strong> → interactive app</li></ul><h3>📊 Data Preprocessing</h3><h3>1. Load Dataset</h3><pre>import pandas as pd  </pre><pre>df = pd.read_csv(&quot;Car Sell Dataset.csv&quot;, low_memory=False)<br>print(df.head())</pre><p>👉 Used low_memory=False to avoid DtypeWarning since some columns had mixed data types.</p><h3>2. Create Depreciated Price Column</h3><pre>df[&quot;Depreciated Price&quot;] = df[&quot;New Car Price&quot;] * 0.7</pre><p>👉 Assumed <strong>30% depreciation</strong> for simplification. This creates a target column for training.</p><h3>3. Encode Categorical Variables</h3><pre>from sklearn.preprocessing import LabelEncoder</pre><pre>label_encoders = {}<br>for col in [&quot;Brand&quot;, &quot;Model Name&quot;, &quot;Car Type&quot;, &quot;Transmission&quot;, &quot;Fuel Type&quot;, &quot;Owner&quot;, &quot;State&quot;, &quot;Accidental&quot;]:<br>    le = LabelEncoder()<br>    df[col] = le.fit_transform(df[col].astype(str))<br>    label_encoders[col] = le</pre><p>👉 Machine learning models need <strong>numeric input</strong>.<br> 👉 Used LabelEncoder since categorical features like <strong>Brand</strong> or <strong>Fuel Type</strong> are <strong>non-ordinal</strong>.</p><h3>🚀 Model Training</h3><h3>4. Train-Test Split</h3><pre>from sklearn.model_selection import train_test_split</pre><pre>X = df.drop(columns=[&quot;Depreciated Price&quot;])<br>y = df[&quot;Depreciated Price&quot;]</pre><pre>X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.2, random_state=42)</pre><p>👉 Splitting ensures <strong>fair evaluation</strong> (20% test data is unseen during training).</p><h3>5. Random Forest Model</h3><pre>from sklearn.ensemble import RandomForestRegressor</pre><pre>model = RandomForestRegressor(n_estimators=200, random_state=42)<br>model.fit(X_train, y_train)</pre><p>👉 Chose <strong>Random Forest</strong> because:</p><ul><li>It captures <strong>non-linear relationships</strong>.</li><li>Handles <strong>categorical + numerical features</strong> well.</li><li>More robust than Linear Regression for real-world noisy data.</li></ul><h3>📈 Model Evaluation</h3><pre>from sklearn.metrics import mean_absolute_error, r2_score</pre><pre>y_pred = model.predict(X_test)<br>print(&quot;MAE:&quot;, mean_absolute_error(y_test, y_pred))<br>print(&quot;R²:&quot;, r2_score(y_test, y_pred))</pre><p>👉 MAE tells us the <strong>average prediction error</strong>.<br> 👉 R² shows how well the model explains the variance in data.</p><h3>📊 Visualizations</h3><h3>Scatter Plot — Actual vs Predicted</h3><pre>import matplotlib.pyplot as plt  </pre><pre>plt.scatter(y_test, y_pred, alpha=0.5)<br>plt.xlabel(&quot;Actual Price&quot;)<br>plt.ylabel(&quot;Predicted Price&quot;)<br>plt.title(&quot;Actual vs Predicted Depreciated Car Price&quot;)<br>plt.show()</pre><p>👉 This helps visualize how close predictions are to the actual values.</p><h3>Pie Chart — Brand Distribution</h3><pre>brand_counts = df[&quot;Brand&quot;].value_counts()</pre><pre>plt.pie(brand_counts, labels=brand_counts.index, autopct=&#39;%1.1f%%&#39;, startangle=140)<br>plt.title(&quot;Car Brand Distribution&quot;)<br>plt.show()</pre><p>👉 A quick <strong>exploratory analysis</strong> to see brand dominance in the dataset.</p><h3>🎯 Key Insights</h3><ul><li><strong>Brand &amp; Model</strong> play the biggest role in depreciation.</li><li><strong>Transmission type</strong> impacts resale value (automatic vs manual).</li><li><strong>Insurance price</strong> correlated more strongly than expected.</li></ul><h3>🔮 Next Steps</h3><ul><li>Deploy app with <strong>Streamlit Cloud/Heroku</strong>.</li><li>Improve dataset with <strong>service history, accident details</strong>.</li><li>Add <strong>real-time scraping</strong> from OLX/CarDekho for live predictions.</li></ul><p>👉 This project was an exciting journey into <strong>applied machine learning</strong> with real-world impact. Cars lose value fast, but with data, we can predict exactly how fast. 🚗💨</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*C7r-FNltZWpYg-6YFwwIYw.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c2458ba65056" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Customer Churn Prediction in Telecom — A Data Science Approach]]></title>
            <link>https://medium.com/@meetlimbachiya2005/customer-churn-prediction-in-telecom-a-data-science-approach-f05155af27c0?source=rss-b0d1f6c7ab98------2</link>
            <guid isPermaLink="false">https://medium.com/p/f05155af27c0</guid>
            <dc:creator><![CDATA[Meet Limbachiya]]></dc:creator>
            <pubDate>Mon, 11 Aug 2025 08:28:12 GMT</pubDate>
            <atom:updated>2025-08-11T08:28:12.068Z</atom:updated>
            <content:encoded><![CDATA[<h3>Customer Churn Prediction in Telecom — A Data Science Approach</h3><p>Customer churn the phenomenon where customers stop doing business with a company is a critical challenge for telecom companies. Predicting churn helps businesses take proactive steps to retain valuable customers, ultimately saving both revenue and reputation.</p><p>In this project, we used <strong>machine learning algorithms</strong> to predict telecom customer churn with a structured data-driven pipeline. You can check out the complete code here:</p><p>🔗 <strong>GitHub Repository:</strong> <a href="https://github.com/Meet2206/CUSTOMER-CHURN-PREDICTION.git">CUSTOMER-CHURN-PREDICTION</a></p><h3>1. Understanding the Objective</h3><p>The primary goal of this project was to analyze telecom customer data, preprocess it, and apply various machine learning algorithms to predict whether a customer would churn or not.</p><h3>2. The Dataset</h3><p>We worked with a telecom dataset containing features like:</p><ul><li><strong>Customer demographics</strong> (gender, senior citizen, partner, dependents)</li><li><strong>Account details</strong> (tenure, contract type, payment method)</li><li><strong>Service usage</strong> (internet service type, phone service, tech support)</li><li><strong>Target variable:</strong> Churn (Yes/No)</li></ul><h3>3. Project Workflow</h3><h3>Step 1 : Importing Required Libraries</h3><pre>import pandas as pd<br>import numpy as np<br>import matplotlib.pyplot as plt<br>import seaborn as sns</pre><pre>from sklearn.model_selection import train_test_split<br>from sklearn.preprocessing import StandardScaler, LabelEncoder<br>from sklearn.linear_model import LogisticRegression<br>from sklearn.ensemble import RandomForestClassifier<br>from xgboost import XGBClassifier<br>from sklearn.metrics import accuracy_score, classification_report, confusion_matrix</pre><p><strong>Why these imports?</strong></p><ul><li><strong>pandas, numpy</strong> → Data manipulation and analysis.</li><li><strong>matplotlib, seaborn</strong> → Data visualization.</li><li><strong>train_test_split</strong> → Split dataset into training and testing sets.</li><li><strong>StandardScaler</strong> → Standardize numerical features for better model performance.</li><li><strong>LabelEncoder</strong> → Convert categorical variables into numerical form.</li><li><strong>LogisticRegression, RandomForestClassifier, XGBClassifier</strong> → Machine learning algorithms used for churn prediction.</li><li><strong>accuracy_score, classification_report, confusion_matrix</strong> → Model performance evaluation.</li></ul><h3>Step 2 : Loading and Exploring the Data</h3><pre>df = pd.read_csv(&quot;Telco-Customer-Churn.csv&quot;)<br>df.head()</pre><ul><li>Loaded dataset into a pandas DataFrame.</li><li>Checked the first few rows to understand structure.</li></ul><h3>Step 3 : Data Preprocessing</h3><ul><li>Handled missing values.</li><li>Converted categorical features using <strong>Label Encoding</strong>.</li><li>Standardized numerical features for algorithms sensitive to feature scales.</li></ul><h3>Step 4 : Train-Test Split</h3><pre>X = df.drop(&quot;Churn&quot;, axis=1)<br>y = df[&quot;Churn&quot;]</pre><pre>X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.2, random_state=42)</pre><ul><li><strong>80%</strong> of data for training, <strong>20%</strong> for testing.</li></ul><h3>Step 5 : Feature Scaling</h3><pre>scaler = StandardScaler()<br>X_train_scaled = scaler.fit_transform(X_train)<br>X_test_scaled = scaler.transform(X_test)</pre><ul><li>Scaling ensures better convergence for algorithms like Logistic Regression.</li></ul><h3>Step 6 : Model Training &amp; Evaluation</h3><p>We trained three models:</p><h4>1. Logistic Regression</h4><pre>log_reg = LogisticRegression(max_iter=2000)<br>log_reg.fit(X_train_scaled, y_train)</pre><ul><li>Best for quick baseline results and interpretability.</li></ul><h4>2. Random Forest Classifier</h4><pre>rf_clf = RandomForestClassifier(random_state=42)<br>rf_clf.fit(X_train, y_train)</pre><ul><li>Handles both categorical and numerical data well, robust to outliers.</li></ul><h4>3. XGBoost Classifier</h4><pre>xgb_clf = XGBClassifier(eval_metric=&#39;logloss&#39;)<br>xgb_clf.fit(X_train, y_train)</pre><ul><li>Gradient boosting model known for high accuracy in classification problems.</li></ul><h3>Step 7 : Model Performance</h3><p>We used <strong>Accuracy Score</strong>, <strong>Classification Report</strong>, and <strong>Confusion Matrix</strong> to evaluate models.</p><p>Example: Logistic Regression Accuracy</p><pre>y_pred_lr = log_reg.predict(X_test_scaled)<br>print(&quot;Accuracy:&quot;, accuracy_score(y_test, y_pred_lr))</pre><h3>4. Key Results</h3><ul><li><strong>Random Forest</strong> and <strong>XGBoost</strong> performed better than Logistic Regression.</li><li>Scaling improved Logistic Regression’s convergence.</li><li>The models provided valuable insights into features contributing most to churn.</li></ul><h3>5. Future Enhancements</h3><ul><li>Use <strong>hyperparameter tuning</strong> for better accuracy.</li><li>Implement <strong>deep learning models</strong> for complex feature interactions.</li><li>Add <strong>SHAP values</strong> for feature interpretability.</li></ul><h3>Conclusion</h3><p>Predicting customer churn helps telecom companies focus retention strategies on high-risk customers. Our ML-based approach achieved strong results, showing that predictive analytics can significantly reduce customer loss.</p><p>You can explore the full project and code here:<br> 🔗 <strong>GitHub Repository:</strong> <a href="https://github.com/Meet2206/CUSTOMER-CHURN-PREDICTION.git">CUSTOMER-CHURN-PREDICTION</a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*tP-WJYDsquf-eXcmq0QOSg.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f05155af27c0" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[House Price Prediction with a Self-Generated Dataset: A Comprehensive Walkthrough]]></title>
            <link>https://medium.com/@meetlimbachiya2005/house-price-prediction-with-a-self-generated-dataset-a-comprehensive-walkthrough-d29c6f9fd92a?source=rss-b0d1f6c7ab98------2</link>
            <guid isPermaLink="false">https://medium.com/p/d29c6f9fd92a</guid>
            <dc:creator><![CDATA[Meet Limbachiya]]></dc:creator>
            <pubDate>Sat, 26 Jul 2025 11:42:29 GMT</pubDate>
            <atom:updated>2025-07-26T11:42:29.062Z</atom:updated>
            <content:encoded><![CDATA[<p>In this blog post, we’ll dive deep into the process of building a machine learning pipeline to predict house prices. What makes this project particularly interesting is that <strong>the dataset is entirely self-generated</strong> — we simulate realistic housing data with features like location, size, and house type. This end-to-end guide will cover:</p><p>Outline:</p><ol><li><strong>Why synthetic data?</strong></li><li><strong>Dataset generation</strong></li><li><strong>Exploratory Data Analysis (EDA)</strong></li><li><strong>Feature engineering &amp; preprocessing</strong></li><li><strong>Train–test splitting</strong></li><li><strong>Model selection and training</strong></li><li><strong>Evaluation metrics</strong></li><li><strong>Visualisation of results</strong></li><li><strong>Conclusions and next steps</strong></li></ol><h3><strong>1. Why synthetic data?</strong></h3><ul><li><strong>Control over complexity</strong>: We decide exactly which factors drive price, adding noise to mimic real-world variability.</li><li><strong>Privacy &amp; availability</strong>: No need to hunt down proprietary real estate datasets.</li><li><strong>Learning exercise</strong>: Generating your own data reinforces understanding of feature impact.</li></ul><h3>2. Generating the Dataset</h3><p>We simulate 50 housing records, each with:</p><ul><li><strong>Size</strong> (sqft): Random integer between 600 and 5,000</li><li><strong>HouseType</strong>: One of Flat, Bungalow, Duplex, Triplex, Tenement</li><li><strong>City</strong>: One of Vadodara, Ankleshwar, Surat</li><li><strong>Area</strong>: Neighborhoods tied to each city</li><li><strong>Rooms</strong>: 1–7</li><li><strong>Age</strong> (years): 0–30</li><li><strong>Price</strong> (target): Computed via</li><li>price = (size × city_multiplier × type_multiplier) + (rooms × 10,000) - (age × 1,500) + random_noise</li><li><strong>Multipliers</strong>:</li><li>city_multiplier = {&#39;Vadodara&#39;:350, &#39;Ankleshwar&#39;:250, &#39;Surat&#39;:400} type_multiplier = { &#39;Flat&#39;:1.0, &#39;Bungalow&#39;:1.5, &#39;Duplex&#39;:1.3, &#39;Triplex&#39;:1.7, &#39;Tenement&#39;:0.9 }</li><li>This formula gives us control: for instance, a bigger city multiplier or luxurious house type directly inflates price, while age subtracts value.</li></ul><pre># Simplified snippet of the price calculation<br>base_price = size * city_multiplier[city]<br>price = base_price * type_multiplier[house_type]<br>price += rooms * 10000<br>price -= age * 1500<br>price += np.random.randint(-50000, 50000)</pre><p>We save the resulting DataFrame to synthetic_house_prices.csv for reproducibility.</p><h3>3. Exploratory Data Analysis (EDA)</h3><p>Before modeling, we must <strong>understand</strong> our data:</p><ol><li><strong>Data Info &amp; Summary</strong></li><li>df.info() # Data types &amp; missing values df.describe() # Distribution of numeric features</li></ol><ul><li><strong>Price Distribution</strong></li></ul><ol><li>A histogram with a kernel density estimate helps us see skewness or multimodality.</li></ol><ul><li>If highly skewed, we might consider a log-transform for linear models.</li><li>sns.histplot(df[&#39;Price&#39;], kde=True) plt.title(&#39;Price Distribution&#39;)</li><li><strong>Correlation Heatmap</strong></li></ul><ol><li>Shows which numeric features correlate with price:</li></ol><ul><li><strong>Size</strong> should correlate strongly (bigger house, higher price).</li><li><strong>Rooms</strong> correlates positively, <strong>Age</strong> negatively.</li><li>sns.heatmap(df.corr(numeric_only=True), annot=True, cmap=&#39;coolwarm&#39;) plt.title(&#39;Correlation Heatmap&#39;)</li><li><strong>Categorical Insights</strong> (optional enhancements)</li></ul><ol><li>Boxplots of Price vs. HouseType or City reveal distribution differences across categories.</li></ol><ul><li>A pairplot (sns.pairplot) combining numeric and categorical hues can further illustrate relationships.</li></ul><h3>4. Feature Engineering &amp; Preprocessing</h3><p>Machine learning algorithms require numeric input, so we transform features:</p><ul><li><strong>Numerical features</strong>: Size, Rooms, Age</li><li><strong>StandardScaler</strong>: Centers to zero mean and unit variance. Especially important for models (like Linear Regression) sensitive to feature scales.</li><li><strong>Categorical features</strong>: HouseType, City, Area</li><li><strong>OneHotEncoder(drop=’first’)</strong>: Converts each category into binary columns, dropping the first to avoid multicollinearity in linear models.</li><li>We bundle these into a <strong>ColumnTransformer</strong>, then embed in a <strong>Pipeline</strong>:</li></ul><pre>from sklearn.compose import ColumnTransformer<br>from sklearn.preprocessing import StandardScaler, OneHotEncoder</pre><pre>preprocessor = ColumnTransformer(transformers=[<br>    (&#39;num&#39;, StandardScaler(), [&#39;Size&#39;,&#39;Rooms&#39;,&#39;Age&#39;]),<br>    (&#39;cat&#39;, OneHotEncoder(drop=&#39;first&#39;, handle_unknown=&#39;ignore&#39;),<br>            [&#39;HouseType&#39;,&#39;City&#39;,&#39;Area&#39;])<br>])</pre><p>This modular approach ensures that <strong>any new data</strong> passed through the pipeline undergoes identical transformations.</p><h3>5. Splitting Data: Train vs. Test</h3><p>We split our 50 records into:</p><ul><li><strong>Training set</strong>: 80% (40 houses)</li><li><strong>Test set</strong>: 20% (10 houses)</li><li>from sklearn.model_selection import train_test_split</li></ul><pre>X_train, X_test, y_train, y_test = train_test_split(<br>    X, y, test_size=0.2, random_state=42<br>)</pre><p>Using a fixed random_state makes our experiments <strong>reproducible</strong>.</p><h3>6. Model Selection &amp; Training</h3><p>We compare two models:</p><ol><li><strong>Linear Regression</strong></li><li>A <strong>baseline</strong>. Fast, interpretable coefficients.</li></ol><ul><li>Assumes linear relationship between features and target.</li><li><strong>Random Forest Regressor</strong></li></ul><ol><li>An <strong>ensemble of decision trees</strong>.</li></ol><ul><li>Captures non-linearities, interactions, and is robust to outliers.</li><li>We build <strong>two pipelines</strong>, each combining the shared preprocessor with its respective regressor:</li></ul><pre>from sklearn.pipeline import Pipeline<br>from sklearn.linear_model import LinearRegression<br>from sklearn.ensemble import RandomForestRegressor</pre><pre>lr_pipeline = Pipeline([<br>    (&#39;preprocessor&#39;, preprocessor),<br>    (&#39;regressor&#39;, LinearRegression())<br>])<br>rf_pipeline = Pipeline([<br>    (&#39;preprocessor&#39;, preprocessor),<br>    (&#39;regressor&#39;, RandomForestRegressor(<br>        n_estimators=100, random_state=42))<br>])</pre><p>Training both on X_train ensures a fair head‑to‑head comparison.</p><h3>7. Evaluation Metrics</h3><p>After fitting, we predict on X_test and compute:</p><ul><li><strong>Mean Squared Error (MSE)</strong>: Average squared difference between actual &amp; predicted prices.</li><li><strong>R² Score</strong>: Proportion of variance explained by the model (1.0 is perfect).</li></ul><pre>from sklearn.metrics import mean_squared_error, r2_score</pre><pre>def evaluate_model(name, y_true, y_pred):<br>    mse = mean_squared_error(y_true, y_pred)<br>    r2  = r2_score(y_true, y_pred)<br>    print(f&quot;{name} ➔ MSE: {mse:.2f}, R²: {r2:.2f}&quot;)</pre><h3>8. Visualizing Predictions</h3><p>A scatter plot of <strong>Actual vs. Predicted</strong> reveals:</p><ul><li><strong>Points on the 45° line</strong> indicate perfect predictions.</li><li><strong>Spread</strong> shows error magnitude.</li></ul><pre>plt.scatter(y_test, y_pred_lr, label=&#39;Linear&#39;, alpha=0.7)<br>plt.scatter(y_test, y_pred_rf, label=&#39;Random Forest&#39;, alpha=0.7)<br>plt.plot([min,y],[min,y],&#39;k--&#39;)<br>plt.xlabel(&#39;Actual Price&#39;); plt.ylabel(&#39;Predicted Price&#39;)<br>plt.legend(); plt.title(&#39;Actual vs. Predicted Prices&#39;)<br>plt.show()</pre><p>Additional plots to consider:</p><ul><li><strong>Residual plot</strong> (predicted - actual vs. actual) to spot heteroscedasticity or bias.</li><li><strong>Feature importances</strong> from Random Forest to identify top drivers of price.</li></ul><h3>9. Conclusions &amp; Next Steps</h3><h4>Key Takeaways</h4><ul><li><strong>Synthetic data</strong> gave full control and taught data‑generation concepts.</li><li><strong>Pipelines</strong> ensure your preprocessing is inseparable from modeling — crucial for deployment.</li><li><strong>Model comparison</strong> highlighted trade-offs: interpretability vs. nonlinearity capture.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*BckeLsaypPSDglalwMVzKA.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d29c6f9fd92a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Titanic Survival Prediction: My AI/ML Internship Journey at OutriX]]></title>
            <link>https://medium.com/@meetlimbachiya2005/titanic-survival-prediction-my-ai-ml-internship-journey-at-outrix-f161d8418d66?source=rss-b0d1f6c7ab98------2</link>
            <guid isPermaLink="false">https://medium.com/p/f161d8418d66</guid>
            <dc:creator><![CDATA[Meet Limbachiya]]></dc:creator>
            <pubDate>Tue, 22 Jul 2025 04:35:00 GMT</pubDate>
            <atom:updated>2025-07-22T04:35:00.111Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>Introduction</strong></p><p>I’m excited to share about my first project during my AI/ML internship at OutriX: Predicting who survived the Titanic disaster. The Titanic data is a classic beginner dataset for machine learning. The goal was to analyse passenger data (like class, gender, age, etc.) and train a model to guess whether each person survived (Survived = 1) or not (0). Working on this project helped me learn the end-to-end ML workflow: from understanding the data to cleaning, feature engineering, model building, and evaluation. It was a great way to apply and learn new concepts with its applications.</p><p><strong>Dataset Overview</strong></p><p>The Titanic dataset has one row per passenger and many columns. The <strong>Survived</strong> column is our target (1 if the passenger lived, 0 if not). Other important columns include:</p><ul><li><strong>Pclass (Passenger Class)</strong> — The ticket class (1st, 2nd, 3rd). This serves as a proxy for socio-economic status: first-class passengers were wealthier and generally had better survival chances.</li><li><strong>Sex</strong> — The passenger’s gender (male or female). Historical accounts suggest women had priority on lifeboats.</li><li><strong>Age</strong> — The passenger’s age in years. Children and younger people might have been more likely to survive. (This column has missing values in the data, which we will need to handle.)</li><li><strong>SibSp</strong> — Number of siblings or spouses aboard.</li><li><strong>Parch</strong> — Number of parents or children aboard. (SibSp and Parch together hint at family size.)</li><li><strong>Fare</strong> — The ticket fare paid by the passenger. Higher fares usually mean higher class.</li><li><strong>Embarked</strong> — Port of embarkation (C = Cherbourg, Q = Queenstown, S = Southampton). This can sometimes correlate with survival due to demographic factors.</li><li>Columns we dropped include <strong>Name</strong>, <strong>Ticket</strong>, <strong>Cabin</strong>, and <strong>PassengerId</strong>. These are either unique identifiers (like Name or PassengerId) or have too many missing/irrelevant values (like Cabin), so they wouldn’t help the model.</li></ul><p><strong>Data Cleaning</strong></p><p>Before modeling, it was critical to clean the data. For example, the <strong>Age</strong>, <strong>Cabin</strong>, and <strong>Embarked</strong> columns have missing values. Most machine learning algorithms cannot handle missing data directly. So I either filled these gaps or dropped the columns/rows if there was alot of missing information. I also removed columns like Name, Ticket, and PassengerId because they don’t contain generalizable information, they’re basically labels or unique IDs that wouldn’t help in predicting survival. Handling missing data and dropping irrelevant columns is essential; if you feed “NaN” values to a model, it will throw errors or give poor results, and useless features only add noise. Cleaning the data ensured the models received a solid, reliable dataset to learn from.</p><p><strong>Feature Engineering</strong></p><p>Once the data was cleaned, I focused on preparing features for the models. This involved <strong>encoding categorical data</strong> and <strong>scaling numeric data</strong>. For example, the <strong>Sex</strong> and <strong>Embarked</strong> columns are text (like “male”/“female” or “S”/“C”/“Q”). Machine learning models need numbers, so I converted these to numeric form — a process called encoding. I used one-hot encoding to turn each category into a separate binary column. Encoding is essential because it transforms textual labels into numeric features that the model can interpret.</p><p>I also scaled some numerical features like <strong>Age</strong> and <strong>Fare</strong> (standardizing them to a similar range) so that no one feature would dominate purely due to its scale. Additionally, I created a new feature called <strong>FamilySize</strong> by combining SibSp and Parch (since a large family might affect survival chances). These engineered features can capture more complex patterns for instance, FamilySize might reveal that solo travelers had different odds than those with many relatives. In summary, encoding and scaling made the data model-ready, and creating features like FamilySize or age groups helped the model pick up useful signals.</p><p><strong>Model Building</strong></p><p>With the features ready, I trained two simple models: <strong>Logistic Regression</strong> and a <strong>Decision Tree</strong>. I chose these because they are beginner-friendly and easy to interpret. Logistic regression is a classic algorithm for binary outcomes. It is fast, widely understood, and its coefficients can be interpreted (telling us how each feature influences the log-odds of survival). In fact, “Logistic Regression is often the first stepping stone for aspiring data scientists” since it’s interpretable and effective for problems like this. Decision trees, on the other hand, are intuitive — they split the data on feature values like a flowchart. Trees clearly show which questions (e.g., “is the passenger female?” or “is Pclass=1?”) lead to survival predictions. They are “one of the most intuitive and interpretable algorithms” in machine learning. By using both models, I could compare results and also learn how each model “thinks.”</p><p><strong>Evaluation</strong></p><p>To judge how well the models performed, I looked at <strong>accuracy</strong> and the <strong>confusion matrix</strong>. Accuracy is simply the ratio of correct predictions out of all predictions. It’s the most straightforward metric: if 80% of the time our model’s guess matches reality, we say accuracy is 80%. However, accuracy alone can be misleading (for example, if very few passengers survived, you could get high accuracy by guessing “died” for everyone). So we also examined the confusion matrix. A confusion matrix is a table that shows the counts of true positives, false positives, true negatives, and false negatives. In our case, it broke down how many survivors the model correctly identified (true positives) versus how many it missed or wrongly predicted. This detailed view helps us see if the model is confusing one class for another — for instance, if it’s predicting too many survivors that aren’t actually. Together, accuracy and the confusion matrix give a fuller picture of model performance.</p><p><strong>Visual Insights</strong></p><p>Before trusting the models, I looked at some visualizations to understand the data trends. One clear pattern was <strong>gender and survival</strong>: roughly 74% of the female passengers survived, compared to only about 19% of the males. In other words, being a woman dramatically improved survival odds, which matches the “women and children first” account of the disaster. Another strong trend was <strong>passenger class</strong>: first-class travelers had much higher survival rates than those in second or third class. In the scatter plots and bar charts, many blue points (survivors) clustered in the first-class group, suggesting they had a better chance. This makes historical sense, as the wealthier passengers (first class) were given priority boarding on lifeboats. I also noticed that passengers paying higher fares (usually first-class) tended to survive more, reinforcing that class effect. (We also saw smaller patterns, like passengers alone or with small families surviving slightly more, but the sex and class differences were the most striking observations.) These visual insights confirmed that our feature choices (Sex and Pclass, for example) were indeed meaningful.</p><p><strong>Key Learnings</strong></p><ul><li><strong>Data Cleaning Matters:</strong> Handling missing values and irrelevant columns was crucial. I learned that even a small fraction of bad data can confuse a model, so cleaning (imputation or removal) really pays off.</li><li><strong>Feature Engineering Is Powerful:</strong> Transforming data into the right format (encoding categories, scaling numbers, creating new features) gave the model better signals. For example, combining family members into one feature helped capture survival trends more easily.</li><li><strong>Interpretable Models Help Learning:</strong> Using logistic regression and decision trees taught me how to interpret model output. For logistic regression, I could look at coefficients to see which features increase survival odds. For decision trees, I could trace the decision rules directly. This reinforced understanding of <em>why</em> the models were making certain predictions.</li><li><strong>Evaluation Goes Beyond Accuracy:</strong> I saw that accuracy is simple but sometimes hides errors. The confusion matrix especially helped me understand mistakes (like how many survivors were missed). Learning to read these metrics ensured I didn’t get fooled by a high accuracy number alone.</li><li><strong>Storytelling with Data:</strong> Seeing patterns in the plots (like “women survived more”) underlined the importance of exploratory analysis. It was a reminder that data analysis is not just numbers — it’s about uncovering the real stories behind the data.</li><li><strong>Conclusion</strong></li></ul><p>Overall, this Titanic project was a fantastic first assignment at OutriX. I got hands-on experience with the full ML pipeline and improved my understanding of core concepts. It was fun to apply algorithms and immediately see how classic history (women and first-class saved first) came out of the numbers. Most importantly, I built confidence in cleaning data, engineering features, and choosing simple, interpretable models. I’m proud of this achievement and excited to dive into the next projects at OutriX, where I’ll continue learning and growing my AI/ML skills.</p><p><strong>Sources:</strong> The column definitions and dataset details are based on the Titanic dataset description. Statistics on survival by gender and class come from exploratory analysis of that data. General points about missing data, encoding, and model interpretability are drawn from standard ML references.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zJVkiyUwMTJuXL1ZY_FhBg.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f161d8418d66" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>