วันศุกร์ที่ 28 สิงหาคม พ.ศ. 2569

MVP vs MVC

 The primary difference between MVP and MVC is how the View interacts with the Model and Middle Layer. In MVC, the View can observe the Model directly to update itself, whereas in MVP, the View is completely passive and can only communicate with the Model through the Presenter.


🏛️ Architecture and Data Flow
Model-View-Controller (MVC)
  • The Flow: The User interacts with the View → View triggers the Controller → Controller updates the Model → Model notifies the View directly to change the screen.
  • Coupling: The View and the Model are aware of each other, creating tighter coupling.
  • Relationship: One Controller can manage multiple different Views.
Model-View-Presenter (MVP)
  • The Flow: The User interacts with the View → View passes the event to the Presenter → Presenter updates the Model → Model returns data to the Presenter → Presenter formats data and manually updates the View.
  • Coupling: Isolated. The View and Model never talk to each other.
  • Relationship: Typically a strict 1:1 mapping between a View and its Presenter.

📊 Side-by-Side Comparison
FeatureModel-View-Controller (MVC)Model-View-Presenter (MVP)
View Passive or Active?Active: Directly listens to data changes from the Model.Passive: Strictly waits for instructions from the Presenter.
Middle Layer KnowledgeController selects the View but doesn't manage its UI components closely.Presenter commands the View directly via a predefined interface.
Testing UI LogicDifficult: Highly tied to the platform UI lifecycles and components.Easy: Presenter logic can be tested entirely with mock interfaces.
Component CouplingHigh (View and Model are connected).Low (View and Model are completely separated).
Primary Use CasesTraditional web frameworks (e.g., ASP.NET Core, Ruby on Rails).Legacy or highly modular Android/iOS apps, complex desktop UIs.

🎭 An Everyday Analogy: The Restaurant
  • The MVC Restaurant: You (User) give an order to the Waiter (Controller). The Waiter gives it to the Kitchen (Model). When the food is ready, the Kitchen staff calls out your name directly or slides the plate to your table (Model updates View directly).
  • The MVP Restaurant: You (User) tell the Waiter (Presenter). The Waiter talks to the Kitchen (Model). The Kitchen hands the raw plate back to the Waiter. The Waiter garnishes it, ensures it looks exactly right for your specific table layout, and places it down in front of you (Presenter manually forces View updates).

AI coding agent platforms

Leading AI coding agent platforms are categorized below based on their primary operating environment. They are categorized into Command-Line Interface (CLI) Tools, Dedicated Integrated Development Environments (IDEs), and Cloud Platforms.

1. Command-Line Interface (CLI) & Terminal Agents
These tools operate directly inside your terminal, using an agentic reasoning loop to edit files, execute commands, and fix bugs locally.
  • OpenAI Codex: A highly-ranked CLI-first agent that executes autonomous, multi-step tasks inside secure cloud sandboxes. It features native parallel delegation, letting developers run multiple background agent tasks concurrently.
  • Claude Code: Anthropic's terminal-based agent powered natively by Claude. It is highly regarded for complex repository-wide reasoning, managing large context windows, and executing recursive subagent workflows.
  • OpenCode: A popular, vendor-agnostic, open-source terminal agent. It supports local or private models, uses dual build/plan agents, and features deep Language Server Protocol (LSP) integrations.
  • Aider: A widely utilized open-source CLI coding assistant that lets you edit code in your local git repository using a wide range of LLMs.

2. Dedicated IDEs & Desktop Platforms
These platforms serve as your entire workspace or integrate deep visual wrappers to control autonomous agents.
  • Google Antigravity: An agentic desktop platform designed around a unique "agent-first" architecture. It provides an Agent Manager view to run multiple asynchronous subagents in parallel, a built-in automated Chrome browser for visual UI testing, and structured "Artifacts" (checklists, mockups, and recordings) to verify code safety(Completely free for use)
  • Cursor: A popular custom fork of VS Code. It provides context-aware workspace indexing, custom "Composer" agent modes to refactor multiple files simultaneously, and a Cloud Handoff feature for long-running asynchronous processes.
  • Windsurf: A powerful dedicated IDE that mirrors Cursor's core primitives. It provides developers with flexible execution environments alongside dedicated code, plan, and ask modes.
  • Nimbalyst: A comprehensive visual workspace featuring an MIT-licensed desktop interface. It utilizes Kanban boards, specialized worktrees, and mobile companions to organize parallel multi-agent sessions. (Completely free for use)

3. Cloud-Based & Autonomous Platforms
These platforms (i.e., Cloud coding agent) operate almost entirely in the cloud, abstracting away the local machine to handle broad, end-to-end software engineering requirements.
  • Devin: An autonomous cloud-hosted AI software engineer. It acts on long-form GitHub issues by autonomously generating code, executing terminal commands, fixing its own bugs, and verifying work inside a closed sandbox.
  • OpenHands (formerly OpenDevin): A powerful open-source alternative to Devin. It allows teams to deploy an autonomous agent workspace over Docker containers using customizable model keys.
  • Genie: A specialized cloud engineering platform engineered by Cosine, built to resolve complex bugs and implement expansive features across large-scale codebases natively. 


วันพฤหัสบดีที่ 27 สิงหาคม พ.ศ. 2569

Industry 5.0








 



https://www.linkedin.com/pulse/industry-50-next-industrial-revolution-around-corner-shirish-kulkarni/

วันอาทิตย์ที่ 23 สิงหาคม พ.ศ. 2569

Cloud native vs Cloud agnostic

Cloud agnostic means designing software and systems so they can run on any cloud platform, like AWSAzure, or Google Cloud Platform, without relying on features from only one provider. It helps teams avoid vendor lock-in and move workloads easily.

Tools for cloud agnostic include:

  • Containerization: Use Docker so applications run consistently everywhere.
  • Orchestration: Use Kubernetes, which is supported by all major cloud providers.
  • Open-source databases: Use PostgreSQL or MySQL instead of cloud-specific databases when portability is important.
  • Infrastructure as Code (IaC): Use tools like Terraform to provision infrastructure across multiple clouds.
  • Standard APIs and protocols: Avoid relying heavily on proprietary cloud services.
Trade-offs

Cloud agnostic apps come with costs over cloud native apps :

  • Giving up some advanced cloud-native features.
  • More engineering effort to maintain portability.
  • Potentially higher operational complexity.
  • Sometimes lower performance than using provider-specific managed services.