close

Agentic AI

Agentic AIArticlesArtificial IntelligenceFeatured

Bringing Order to Content Chaos: How Gemini CLI Elevates Your Command Line Productivity

The command line is the backbone of productivity for many developers, data professionals, and content creators. Yet with growing volumes of files, drafts, and project assets, even the most organized users face content chaos — duplicate files, forgotten revisions, and manual cleanup that eats into creative time.

Enter Gemini CLI: an open-source AI agent that brings Google Gemini’s natural language intelligence right to your terminal. Gemini CLI isn’t just about coding — it’s a smarter way to search, summarize, compare, organize, and automate file and content workflows using plain English.

What Makes Gemini CLI Stand Out?

  •  Direct Access to Gemini 2.5 Pro:
     Instant, lightweight access to a powerful AI model with a generous token context window — ideal for large files and lengthy content.
  •  Natural Language Commands:
     Forget obscure flags or complex scripts. Just ask in everyday language, and Gemini CLI understands your intent.
  •  Productivity Beyond Coding:
     Whether you’re sorting research notes, summarizing docs, or managing creative assets, Gemini CLI adapts to your workflow.

Practical Ways Gemini CLI Boosts Productivity

Here are real-world scenarios where Gemini CLI shines:

  • 🔍 Find and Remove Duplicate Files:
     gemini "Scan this folder for duplicate PDFs and list them"
     gemini "Find images with similar names and flag potential duplicates"
  • 📝 Summarize Key Content:
     gemini "Summarize the main points from all meeting notes in this directory"
     gemini "Extract key differences between Draft_v1.docx and Draft_v2.docx"
  • 🗂️ Organize and Rename Files:
     gemini "Organize all documents by project and year"
     gemini "Batch rename files in this folder using a consistent naming scheme"
  • 🔎 Search by Natural Language:
     gemini "Show all presentations from 2024 with more than 10 slides"
     gemini "List files modified in the last 7 days containing the word ‘proposal’"
  • ⚙️ Automate Repetitive Actions:
     gemini "Move all .txt files older than 6 months to the archive folder"
     gemini "Delete temporary files with 'backup' in their names after review"
  • 🛠️ Content Generation and Debugging:
     gemini "Draft a README.md based on the contents of this project folder"
     gemini "Review this Python script and suggest improvements"

My Experiment: Gemini CLI in Action

To see Gemini CLI in action, I pointed it at one of my project folders — a mix of presentations, reports, and working drafts. With just a few natural language commands, Gemini CLI quickly analyzed the folder, flagged duplicate files, outlined unique documents, and delivered a clear, actionable summary. What would have taken much longer to sort manually was resolved in minutes.

I also tried a creative utility: asking Gemini CLI to take a screenshot of my screen and convert it to JPG. The tool prompted me for the necessary permissions and guided me to grant Terminal access on my Mac. Once enabled, Gemini CLI handled the task seamlessly — showcasing how agent-powered CLI can integrate real-world utility features right into your workflow.

Download the Gemini CLI at – https://blog.google/technology/developers/introducing-gemini-cli-open-source-ai-agent/

Important Caveats and Best Practices

  • File Access and Permissions:
     Gemini CLI can access and modify your files. Always check which folders you’re targeting, especially with move or delete commands.
  • Accidental Deletion:
     AI-powered deletion is fast but irreversible. Add confirmation prompts or use a “dry run” before destructive commands.
  • Sensitive Content:
     Avoid processing sensitive files unless you’re clear on how data is handled locally vs. in the cloud (refer to documentation).
  • Versioning and Auditability:
     For important assets, enable file versioning or keep a changelog to track changes made via Gemini CLI.
  • AI Limitations:
    Review AI suggestions, especially for bulk operations. Natural language is powerful — but not perfect.

Final Thoughts: The Future Is Agentic

Gemini CLI brings much-needed order and intelligence to content management in the terminal. By combining natural language with robust AI, it transforms how we interact with files, automate tasks, and create content. For developers, creators, and knowledge workers, it’s a way to reclaim time and reduce manual overhead — when used thoughtfully.

💡 This is just one example of how an integrated agent CLI can make a difference. Looking ahead, it’s clear that future operating systems will be powered by smart agents — completely changing how we interact with files, applications, and information across our digital lives.

read more
Agentic AIArticlesArtificial IntelligenceBooksFeaturedGenerative AI

The New AI Engineering Mindset—Navigating Uncertainty and Opportunity in the Age of Intelligent Machines

We are living through the most transformative era in engineering history. Artificial intelligence—once the domain of research labs and specialized applications—now sits at the core of how systems, products, and organizations are built and operated. For engineers, this brings both exhilaration and deep uncertainty. As intelligent machines automate everything from code review to decision-making, the very foundations of engineering practice are being redefined.

It is natural to feel anxiety or fear as new technologies challenge traditional roles and skills. But focusing only on what may be lost risks overlooking a far greater opportunity: to redefine what it means to engineer in the age of intelligent machines. This is not just about surviving disruption, but about thriving—by developing new ways of thinking, learning, and leading.

This book is your guide to navigating and shaping this new landscape. You’ll discover practical frameworks for thriving amid uncertainty, strategies for rapid learning and upskilling, and a modern mindset for collaborating with AI without losing your edge. You’ll learn how to move beyond basic automation and become an orchestrator—integrating technology, context, and purpose to solve problems that truly matter.

At the heart of this new approach is the concept of the Human Stack—a layered model capturing where engineers create enduring value in the AI era. 

From context engineering and system integration, to oversight, ethics, and vision, the Human Stack highlights the roles where judgment, creativity, and leadership remain irreplaceable. In this book, you’ll see how mastering these layers is essential not just for your relevance, but for the positive impact you can have on your teams, organizations, and the world.

What will you find inside?

  • Step-by-step strategies for adapting to AI-driven change and building future-proof skills
  • Deep dives into the mindset, habits, and collaborative models that define the new engineer
  • Actionable frameworks for orchestrating complex workflows, including the principles of prompt engineering, multi-agent collaboration, and continuous learning
  • A full-length, real-world case study: transforming the Software Development Lifecycle (SDLC) using Agentic AI, including the design and governance of advanced orchestration, integration of protocols like the Model Context Protocol (MCP), and best practices for scaling responsible automation in production
  • Insight into emerging roles, ethical standards, and the opportunities that come with being a technical leader and orchestrator in the AI era

This book goes beyond theory, providing actionable playbooks, architectures, and checklists that you can apply immediately—whether you’re a hands-on engineer, a technical leader, or a strategist guiding your organization’s AI journey.

This is the engineer’s moment of truth. Those who cling to old certainties will watch the future pass them by. But those who embrace uncertainty, see opportunity where others see risk, and learn to orchestrate rather than just automate, will define the next era of progress.

The age of intelligent machines is not a threat—it is the greatest opportunity ever handed to engineers. The path ahead may be uncertain, but it is within this uncertainty that invention—and true leadership—are born.

Having gone through various waves of technology transformation over the past two decades—from my first project on mainframe modernization, where decades-old business logic was translated into new architectures, to now embracing the opportunities and challenges of Gen AI—I’ve witnessed firsthand both the excitement and uncertainty that each new era brings. I see a lot of confusion and anxiety across the engineering community about which skills to develop, what roles to pursue, and how to stay relevant as technology evolves. If I can help clarify this path, provide a practical roadmap, and instill a sense of purpose and confidence, then this book will have achieved its mission.

This book distills those lessons and provides the strategies, mindsets, and examples that will empower you to make your mark—no matter where you are in your journey.

Welcome to your new mindset.

Get your copy of the book at – https://amzn.to/43CnItq

read more
Agentic AIArticlesArtificial IntelligenceFeatured

Autonomous Portfolio Analysis with Google ADK, Zerodha MCP, and LLMs

Modern financial analysis is rapidly moving toward automation and agentic workflows. Integrating large language models (LLMs) with real-time financial data unlocks not just powerful insights but also entirely new ways of interacting with portfolio data.

This post walks through a practical, autonomous solution using Google ADK, Zerodha’s Kite MCP protocol, and an LLM for actionable portfolio analytics. The full workflow and code are available on GitHub.


Why This Stack?

  • Google ADK: Enables LLM agents to interact with live tools, APIs, and event streams in a repeatable, testable way.
  • Zerodha MCP (Model Control Protocol): Provides a secure, real-time API to portfolio holdings using Server-Sent Events (SSE).
  • LLMs (Gemini/GPT-4o): Analyze portfolio data, highlight concentration risk, and offer actionable recommendations.

Architecture Overview

The workflow has three main steps:

  1. User authenticates with Zerodha using an OAuth browser flow.
  2. The agent retrieves live holdings via the MCP get_holdings tool.
  3. The LLM agent analyzes the raw data for risk and performance insights.

All API keys and connection details are managed through environment variables for security and reproducibility.


Key Code Snippets

1. Environment and Dependency Setup

import os
from dotenv import load_dotenv

# Load API keys and config from .env
load_dotenv('.env')
os.environ["GOOGLE_API_KEY"] = os.environ["GOOGLE_API_KEY"]
os.environ["GOOGLE_GENAI_USE_VERTEXAI"] = "False"

2. ADK Agent and Toolset Initialization

from google.adk.agents.llm_agent import LlmAgent
from google.adk.tools.mcp_tool.mcp_toolset import MCPToolset, SseServerParams

MCP_SSE_URL = os.environ.get("MCP_SSE_URL", "https://mcp.kite.trade/sse")

toolset = MCPToolset(
    connection_params=SseServerParams(url=MCP_SSE_URL, headers={})
)

root_agent = LlmAgent(
    model='gemini-2.0-flash',
    name='zerodha_portfolio_assistant',
    instruction=(
        "You are an expert Zerodha portfolio assistant. "
        "Use the 'login' tool to authenticate, and the 'get_holdings' tool to fetch stock holdings. "
        "When given portfolio data, analyze for concentration risk and best/worst performers."
    ),
    tools=[toolset]
)

3. Orchestrating the Workflow

from google.adk.sessions import InMemorySessionService
from google.adk.artifacts.in_memory_artifact_service import InMemoryArtifactService
from google.adk.runners import Runner
from google.genai import types

import asyncio

async def run_workflow():
    session_service = InMemorySessionService()
    artifacts_service = InMemoryArtifactService()
    session = await session_service.create_session(
        state={}, app_name='zerodha_portfolio_app', user_id='user1'
    )

    runner = Runner(
        app_name='zerodha_portfolio_app',
        agent=root_agent,
        artifact_service=artifacts_service,
        session_service=session_service,
    )

    # 1. Login Step
    login_query = "Authenticate and provide the login URL for Zerodha."
    content = types.Content(role='user', parts=[types.Part(text=login_query)])
    login_url = None
    async for event in runner.run_async(session_id=session.id, user_id=session.user_id, new_message=content):
        if event.is_final_response():
            import re
            match = re.search(r'(https?://[^\s)]+)', getattr(event.content.parts[0], "text", ""))
            if match:
                login_url = match.group(1)
    if not login_url:
        print("No login URL found. Exiting.")
        return
    print(f"Open this URL in your browser to authenticate:\n{login_url}")
    import webbrowser; webbrowser.open(login_url)
    input("Press Enter after completing login...")

    # 2. Fetch Holdings
    holdings_query = "Show my current stock holdings."
    content = types.Content(role='user', parts=[types.Part(text=holdings_query)])
    holdings_raw = None
    async for event in runner.run_async(session_id=session.id, user_id=session.user_id, new_message=content):
        if event.is_final_response():
            holdings_raw = getattr(event.content.parts[0], "text", None)
    if not holdings_raw:
        print("No holdings data found.")
        return

    # 3. Analysis
    analysis_prompt = f"""
You are a senior portfolio analyst.

Given only the raw stock holdings listed below, do not invent or assume any other holdings.

1. **Concentration Risk**: Identify if a significant percentage of the total portfolio is allocated to a single stock or sector. Quantify the largest exposures, explain why this matters, and suggest specific diversification improvements.

2. **Performance Standouts**: Clearly identify the best and worst performing stocks in the portfolio (by absolute and percentage P&L), and give actionable recommendations.

Raw holdings:

{holdings_raw}

Use only the provided data.
"""
    content = types.Content(role='user', parts=[types.Part(text=analysis_prompt)])
    async for event in runner.run_async(session_id=session.id, user_id=session.user_id, new_message=content):
        if event.is_final_response():
            print("\n=== Portfolio Analysis Report ===\n")
            print(getattr(event.content.parts[0], "text", ""))

asyncio.run(run_workflow())

Security and Environment Configuration

All API keys and MCP endpoints are managed via environment variables or a .env file.
Never hardcode sensitive information in code.

Example .env file:

GOOGLE_API_KEY=your_google_gemini_api_key
MCP_SSE_URL=https://mcp.kite.trade/sse

What This Enables

  • Reproducible automation: Agents can authenticate, retrieve, and analyze portfolios with minimal human input.
  • Extensibility: Easily add more tools (orders, margins, etc.) or more advanced analytic prompts.
  • Separation of concerns: Business logic, security, and agent workflow are all clearly separated.

Repository

Full working code and documentation:
https://github.com/navveenb/agentic-ai-worfklows/tree/main/google-adk-zerodha


This workflow is for educational and portfolio analysis purposes only. Not investment advice.

read more
Agentic AIArtificial IntelligenceFeaturedUncategorized

Comparative Analysis of AI Agentic Frameworks

AI agentic frameworks provide the infrastructure for building autonomous AI agents that can perceive, reason, and act to achieve goals. With the rapid growth of large language models (LLMs), these frameworks extend LLMs with orchestration, planning, memory, and tool-use capabilities​. This blog compares prominent frameworks from a 2025 perspective – including LangChain, Microsoft AutoGen, Semantic Kernel, CrewAI, LlamaIndex AgentWorkflows, Haystack Agents, SmolAgents, PydanticAI, and AgentVerse – across their internal execution models, agent coordination mechanisms, scalability, memory architecture, tool use abstraction, and LLM interoperability. I will also cover emerging frameworks in my next blog (e.g. Atomic Agents, LangGraph, OpenDevin, Flowise, CAMEL) and analyze their design principles, strengths, and limitations relative to existing solutions.

Comparison of Established Agentic Frameworks (2025)

The table below summarizes core characteristics of each major framework.

Table 1. Key Features of Prominent AI Agent Frameworks (2025)

FrameworkExecution ModelAgent CoordinationScalability StrategiesMemory ArchitectureTool Use & PluginsLLM Interoperability
LangChainChain-of-thought sequences (ReAct loops) using prompts. Chains modularly compose LLM calls, memory, and actions.Primarily single-agent, but supports multi-agent interactions via custom chains. No built-in agent-to-agent messaging.Designed for integration rather than distributed compute. Concurrency handled externally.Pluggable Memory modules (short-term context, long-term via vector stores).Abstraction for Tools as functions. Implements ReAct and OpenAI function calling. Rich API/DB connectors.Model-agnostic: supports OpenAI, Azure, HuggingFace, etc.
AutoGen (Microsoft)Event-driven asynchronous agent loop. Agents converse via messages, generating code or actions executed asynchronously.Multi-agent conversation built-in – e.g., AssistantAgent and UserProxyAgent chat to solve tasks.Scalable by design: async messaging for non-blocking execution. Supports distributed networks.Relies on message history for context. Can integrate external memory if needed.Tools and code execution via messages. Easy integration with Python tools and custom functions.Multi-LLM support (OpenAI, Azure, etc.), optimized for Microsoft’s stack.
Semantic KernelPlan-and-execute model using skills (functions) and planners. High-level SDK for embedding AI into apps.Concurrent agents supported via planner/orchestrator. Multi-agent collaboration via shared context.Enterprise-grade scalability: async and parallel calls, integration with cloud infrastructure.Robust Memory system: supports volatile and non-volatile memory stores. Vector memory supported.Plugins (Skills) as first-class tools. Secure function calling for C#/Python functions.Model-flexible: OpenAI, Azure OpenAI, HuggingFace. Multi-language support.
CrewAIRole-based workflow execution. Pre-defined agent roles run in sequence or parallel. Built atop LangChain.Multi-agent teams (“crews”) with structured coordination. Sequential, hierarchical, and parallel pipelines supported.Focuses on orchestrating multiple agents. Enterprise version integrates with cloud for production deployment.Inherits LangChain memory. Context passed through crew steps. Conflict resolution supported.Flexible tool integration per agent role. Open-source version integrates LangChain tools.Any LLM via LangChain: OpenAI, Anthropic, local models supported.
LlamaIndex AgentWorkflowsWorkflow graph execution. Agents (nodes) execute in a graph, handing off state via shared Context.Built for both single and multi-agent orchestration. Supports cyclic workflows and human-in-the-loop.Parallelizable workflows. Checkpointing for intermediate results. Scales to large data volumes.Shared memory context via WorkflowContext. Integration with vector stores.Tools integrated as functions or pre-built tools. Strong retrieval-generation combination.Model-agnostic via LlamaIndex: OpenAI, HF, local LLMs.
Haystack AgentsTool-driven ReAct agents. LLM planner selects tools iteratively until task completion.Primarily single-agent. Can be extended to multi-agent via connected pipelines.Designed for production Q&A. Scalability via batching and pipeline parallelism.Emphasis on retrieval-augmented memory. Uses embedding stores and indexes.Abstracts services as Tools. Modular pipeline design for swapping components.Pluggable LLMs via PromptNode: OpenAI, Azure, Cohere, etc.
SmolAgents (HF)Minimalist ReAct implementation. Agents write/execute code or call structured tools.Single-agent, multi-step. Can run multiple agents in parallel if needed.Lightweight for rapid prototyping. Can embed in larger systems. No built-in distribution.No built-in long-term memory. External vector DBs can be integrated manually.Direct code execution with secure sandbox options. Minimal abstractions.Highly model-flexible: OpenAI, HuggingFace, Anthropic, local models.
PydanticAIStructured agent loop with output validation. Supports async execution. Pythonic control flow.Single-agent by default. Supports multi-agent via delegation and composition.Async & scalable: handles concurrent API calls or tools. Production-grade error handling.Structured state passed via Pydantic models. External stores can be integrated.Tools as Python functions with Pydantic I/O models. Dependency injection supported.Model-agnostic: OpenAI, Anthropic, Cohere, Azure, Vertex AI, etc.
AgentVerse (Fetch.ai)Modular multi-agent environment simulation. Agents register in a decentralized registry.Multi-agent by design. Agents discover each other and collaborate dynamically.Supports large agent populations. Agent Explorer UI for monitoring. Distributed deployment supported.Environment state as shared memory. Agents may also have private memory/state.Tools as environment-specific actions. Emphasizes communication protocols.Model-agnostic. LLM-based agents supported via wrappers.
read more
Agentic AIArticlesArtificial IntelligenceBooksFeatured

Agentic AI: From Strategy to Purposeful Implementation

As we welcome 2025, I’m thrilled to introduce my latest book, which reflects my vision for the future of AI—where systems go beyond automation to adapt dynamically, make informed decisions, and align with purpose and sustainability.

This book address a critical gap: the lack of a structured framework for Agentic AI. In this book, I’ve modeled a framework inspired by human cognition, offering a clear pathway for designing impactful, sustainable, and purpose-driven Agentic AI systems.

What’s Inside?
– Cognitive Frameworks: The 7 foundational layers of Agentic AI.
– Purposeful Strategy: Practical ways to embed ethics and sustainability.
– Practical Implementation: Step-by-step guidance and tools for domain-specific agents.
– 10+ Agentic AI Patterns: Explore reusable patterns for building adaptable, intelligent systems.
– Leadership in AI: Navigate challenges and seize opportunities in intelligent systems.
– Observability and Governance: Ensure transparency, accountability, and continuous improvement.

This book bridges the gap between vision and implementation, equipping leaders, technologists, and policymakers with the tools to create Agentic AI systems that make a meaningful impact.

📚 Now available on Amazon https://amzn.to/420TXC3

Wishing you all a successful and inspiring 2025! 🌟

read more