Skip to content

hassanRagabb/CivicFlow

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

⚙ CivicFlow

AI-powered business registration assistant with a human-in-the-loop approval step.

CivicFlow automates the tedious parts of business registration — researching regulations, filling forms, validating data — while keeping a human in control before anything gets submitted.


Example Agent Requests

Use one of these as the request text for the agent (in your app input):

  • I want to register a food truck business in my city. Please research required permits, estimate fees, and prepare the application draft.
  • Help me register a small general retail business. Find required documents, licensing steps, and create the form draft for approval.
  • I am starting a home bakery business. Check regulations, list permits and costs, then draft the business registration form.

How it works

User Request → [Orchestrator] → [Researcher] → [Form Filler] → [Validator] → ⏸ Human Approval → [Submit]
  1. Orchestrator — Plans the registration steps using a local LLM (via Ollama)
  2. Researcher — Looks up relevant regulations and fees
  3. Form Filler — Drafts the application automatically
  4. Validator — Checks the form is complete
  5. ⏸ Human Approval — You review the form in the browser before anything is filed
  6. Submission — Submits and returns a reference ID

Stack

Layer Tech
Backend FastAPI + Uvicorn
AI Agent LangGraph + LangChain
LLM Ollama (qwen2.5:0.5b, local)
Frontend Vanilla HTML/CSS/JS

No databases. No Docker needed. No cloud dependencies.


Prerequisites

  • Python 3.11+
  • Ollama running locally
# Pull the model used by the backend
ollama pull qwen2.5:0.5b

Setup

# Clone
git clone https://github.com/yourname/civicflow.git
cd civicflow

# Install dependencies
pip install -r requirements.txt

# Run
cd backend
uvicorn main:app --reload

Open http://localhost:8000


Run Locally (Exact Terminals + Commands)

Use 2 terminals.

Terminal 1 — Ollama

ollama serve

If this is your first run, in the same terminal (or a new one) pull model once:

ollama pull qwen2.5:0.5b

Terminal 2 — Backend + Frontend

From project root:

cd D:\challengeAccepted\agentic\projects\CivicFlow
python -m venv .venv
.\.venv\Scripts\Activate.ps1
python -m pip install -r requirements.txt
cd backend
python -m uvicorn main:app --reload

Then open:

Notes:

  • Frontend is served by FastAPI on the same URL (no separate frontend server).
  • Keep both terminals running while using the app.

Project Structure

civicflow/
├── backend/
│   ├── main.py       # FastAPI routes
│   └── agent.py      # LangGraph agent + session helpers
├── frontend/
│   └── index.html    # Single-file UI
├── requirements.txt
└── README.md

License

MIT

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors