Skip to content

yilinxia/DecViz

Repository files navigation

DecViz Logo

DecViz

Overview

DecViz is a free, open-source web application that transforms domain knowledge into interactive graph visualizations through declarative programming.

Getting Started

Local Installation

Prerequisites

  • Node.js (v16+)
  • Python 3.11+
  • Logica
  1. Clone and setup:
git clone https://github.com/yilinxia/DecViz.git
cd DecViz
conda env create -f environment.yml
conda activate decviz
npm install
  1. Start backend server (Python FastAPI):
pip install -r requirements.txt
uvicorn api.logica_backend:app --reload --port 8000
  1. Start frontend development server:
NEXT_PUBLIC_LOGICA_BACKEND_URL=http://localhost:8000 npm run dev

Note

For future use, you can use ./start.sh to start both backend and frontend in development mode.

Run with Docker

For easier development with Docker:

# Start both frontend and backend in development mode
docker build -t decviz .
docker run -p 8000:8000 -p 3000:3000 decviz

How It Works

DecViz uses a two-language approach:

  1. Domain Language: Define facts and relationships using Logica
  2. Visual Language: Configure visualization using Logica predicates

Example:

# Domain Language
Argument("a"); Argument("b");
Attacks("a", "b");

# Visual Language  
Node(node_id: x, label: x, shape: "circle") :- Argument(x);
Edge(source_id: source, target_id: target) :- Attacks(source, target);

License

The software is available under Apache 2.0 License.

Contact

For any queries, please open an issue on GitHub or contact Yilin Xia.

About

Transforms domain knowledge into graph visualizations via declarative programming

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published