Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HCP Copilot — AI-First CRM Interaction Management System

HCP Copilot is a modern, AI-first Customer Relationship Management (CRM) platform built specifically for pharmaceutical field representatives. It reimagines the traditional CRM experience by replacing manual data entry with an intelligent AI Agent. Users simply converse with the AI in natural language, and the agent dynamically logs interactions, extracts key entities, generates meeting summaries, and recommends prioritized follow-up actions.

✨ Key Features

  • Conversational UI: Log meetings and interactions through a natural chat interface.
  • AI-Driven Orchestration: Powered by LangGraph, the AI agent dynamically selects the right tools to execute tasks without hardcoded logic.
  • Live State Synchronization: The CRM interface updates in real-time as the AI agent processes the conversation and modifies database records.
  • Smart Summarization: Automatically synthesizes complex clinical discussions into clean, professional summaries.
  • Intelligent Follow-ups: Evaluates meeting sentiment and outcomes to automatically suggest prioritized next steps and follow-up dates.
  • Manual Override Mode: Seamlessly switch between AI-assisted logging and traditional manual form editing, with full tracking of whether a field was modified by a human or AI.

🛠️ Technology Stack

  • Backend: Python 3, FastAPI, SQLAlchemy 2.0 (SQLite/PostgreSQL)
  • AI/LLM: LangGraph (ReAct Agent Workflow), LangChain, Groq API (Llama 3.1 8B)
  • Frontend: React 18, TypeScript, Vite, Redux Toolkit, Tailwind CSS v3

🚀 Getting Started

Prerequisites

1. Backend Setup

  1. Navigate to the backend directory:
    cd backend
  2. Create and activate a Python virtual environment:
    python -m venv .venv
    
    # On Windows:
    .\.venv\Scripts\activate
    # On macOS/Linux:
    source .venv/bin/activate
  3. Install dependencies:
    pip install -r requirements.txt
  4. Set up environment variables: Copy .env.example to .env and add your Groq API key:
    cp .env.example .env
  5. Run the database migrations (creates local SQLite DB):
    alembic upgrade head

2. Frontend Setup

  1. Open a new terminal and navigate to the frontend directory:
    cd frontend
  2. Install Node dependencies:
    npm install
  3. Copy the environment variables:
    cp .env.example .env

3. Running the Application

You can start both the frontend and backend servers concurrently from the project root directory using a single command:

# In the root directory (HCF/)
npm run dev

Alternatively, you can run them separately:

  • Backend: cd backend && uvicorn app.main:app --reload --port 8000
  • Frontend: cd frontend && npm run dev

4. Access the App

Open your browser and navigate to:

🧪 How to use

  1. Open the Web UI and look at the right-hand AI Assistant Panel.
  2. Click one of the Quick Prompts (e.g., "Log CardioX Visit"), or type a summary of a recent HCP meeting.
  3. Watch the AI Activity Timeline update in real-time as the agent parses intent, selects tools, and updates the CRM.
  4. See the Left CRM Interaction State populate instantly with the extracted data.
  5. Click "Generate Meeting Summary" to generate a final report.

About

An AI-first Healthcare CRM prototype that enables pharmaceutical representatives to log, edit, validate, and manage HCP interactions through natural language. Built with React, FastAPI, LangGraph, Groq LLM, PostgreSQL, and Redux Toolkit, showcasing conversational CRM workflows and AI-driven CRUD operations.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages