Metadata-Version: 2.1
Name: graphfleet
Version: 0.4.0
Summary: Build upon GraphRAG, provide a quick solution setup and is part of the overall Qredence System like AgenticFleet and FleetUI
License: Apache-2.0
Author: Zachary
Author-email: zachary@qredence.ai
Requires-Python: >=3.10,<3.13
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Requires-Dist: aiofiles (>=24.1.0,<25.0.0)
Requires-Dist: aiolimiter (>=1.1.0,<2.0.0)
Requires-Dist: at (>=0.0.3,<0.0.4)
Requires-Dist: azure-cli-core (>=2.62.0,<3.0.0)
Requires-Dist: azure-cosmos (>=4.7.0,<5.0.0)
Requires-Dist: azure-identity (>=1.17.1,<2.0.0)
Requires-Dist: azure-search-documents (>=11.4.0,<12.0.0)
Requires-Dist: azure-storage-blob (>=12.19.0,<13.0.0)
Requires-Dist: build (>=1.2.1,<2.0.0)
Requires-Dist: datashaper (>=0.0.49,<0.0.50)
Requires-Dist: devtools (>=0.12.2,<0.13.0)
Requires-Dist: environs (>=11.0.0,<12.0.0)
Requires-Dist: fastapi (>=0.111.1,<0.112.0)
Requires-Dist: fastparquet (>=2024.2.0,<2025.0.0)
Requires-Dist: graphrag (==0.3.0)
Requires-Dist: graspologic (>=3.4.1,<4.0.0)
Requires-Dist: jq (>=1.7.0,<2.0.0)
Requires-Dist: jupyter (>=1.0.0,<2.0.0)
Requires-Dist: jupyter-contrib-nbextensions (>=0.7.0,<0.8.0)
Requires-Dist: lancedb (>=0.11.0,<0.12.0)
Requires-Dist: microsoft-bing-websearch (>=1.0.0,<2.0.0)
Requires-Dist: nest-asyncio (>=1.6.0,<2.0.0) ; platform_system == "Windows"
Requires-Dist: networkx (>=3,<4)
Requires-Dist: nltk (==3.8.1)
Requires-Dist: numba (==0.60.0)
Requires-Dist: numpy (>=1.25.2,<2.0.0)
Requires-Dist: openai (>=1.35.7,<2.0.0)
Requires-Dist: packaging (>=24.1,<25.0)
Requires-Dist: pdfreader (>=0.1.15,<0.2.0)
Requires-Dist: promptflow (>=1.14.0,<2.0.0)
Requires-Dist: promptflow-tools (>=1.4.0,<2.0.0)
Requires-Dist: pyaml-env (>=1.2.1,<2.0.0)
Requires-Dist: pydantic (>=2,<3)
Requires-Dist: pypdf2 (>=3.0.1,<4.0.0)
Requires-Dist: python-dotenv (>=1.0.0,<2.0.0)
Requires-Dist: pyyaml (>=6.0.1,<7.0.0)
Requires-Dist: rich (>=13.6.0,<14.0.0)
Requires-Dist: scipy (==1.12.0)
Requires-Dist: swifter (>=1.4.0,<2.0.0)
Requires-Dist: tenacity (>=9.0.0,<10.0.0)
Requires-Dist: textual (>=0.74.0,<0.75.0)
Requires-Dist: tiktoken (>=0.7.0,<0.8.0)
Requires-Dist: typing-extensions (>=4.12.2,<5.0.0)
Requires-Dist: uvicorn (>=0.30.6,<0.31.0)
Requires-Dist: uvloop (>=0.19.0,<0.20.0) ; platform_system != "Windows"
Requires-Dist: yfiles-jupyter-graphs (>=1.7.3,<2.0.0)
Requires-Dist: yq (>=3.4.3,<4.0.0)
Description-Content-Type: text/markdown

# Overview

![image](https://github.com/user-attachments/assets/c3ca5ec8-1bbf-4a9c-988e-e7f5100ea5d5)

GraphFleet is an advanced implementation of [GraphRAG from Microsoft](https://github.com/microsoft/graphrag), designed to enhance large language models' ability to reason about complex information and private datasets. It builds upon GraphRAG (Retrieval Augmented Generation using Graph structures) and will gradually adopt its own path to fulfill our roadmap at Qredence.

## GraphFleet

GraphFleet uses knowledge graphs to provide substantial improvements in question-and-answer performance when reasoning about complex information. It addresses limitations of traditional RAG approaches:
<<<<<<< HEAD

## Roadmap
=======
>>>>>>> origin/main

- [ ] Provide a FleetUI Design Kit and a quicker way of starting GraphFleet locally.
- [ ] Provide a Toddle interface ready to use for GraphFleet
- [ ] Add integrations of Composio
- [ ] Add integrations of LangSmith
- [ ] Add few selfhosting  one click deploy solutions.
- [ ] Access GraphFleet through a secure and enterprise-ready Azure Cloud hosting version.
- [ ] And way more... 👀

## Key Features

- Structured, hierarchical approach to Retrieval Augmented Generation.
- Knowledge graph extraction from raw text.
- Community hierarchy building.
- Hierarchical summarization.
- Enhanced reasoning capabilities for LLMs on private datasets.

## Contribute

- Leave us a star ♥
- Fork and contribute to the project
- [![Join the discord](https://api.star-history.com/svg?repos=Qredence/GraphFleet&type=Date)](https://star-history.com/#Qredence/GraphFleet&Date)

## Getting Started

### Prerequisites

<<<<<<< HEAD
- Python 3.10
- Poetry
- Make sure to have a virtual environment manager such as `virtualenv` installed
=======
- Python 3.11 
- Make sure to have a virtual environment manager such as `virtualenv` installed 
>>>>>>> origin/main

### Installation

1. Clone the repository:
<<<<<<< HEAD
=======

``` bash
   git clone https://github.com/Qredence/GraphFleet.git
   cd GraphFleet
```
>>>>>>> origin/main

   ``` bash
   git clone https://github.com/Qredence/GraphFleet.git
   cd GraphFleet
   ```

<<<<<<< HEAD
2. Simply run these in your terminal:

   ``` bash
   poetry shell
   poetry install
   ```

=======
2. Create a virtual environment and activate it:

``` bash
python3.11 -m venv gfleetenv
source gfleetenv/bin/activate
```

3. Install dependencies:

```
pip install -r requirements.txt
```
>>>>>>> origin/main

### Usage

1. Configuration:
Environment Variables: Set up your environment variables in a .env file (refer to the .env.example file for available options). Key variables include:
<<<<<<< HEAD

   ```sh
   export GRAPHRAG_API_KEY="<apikey>"
   export GRAPHRAG_API_BASE="custom base api url"
   export GRAPHRAG_API_VERSION="version (if not OpenAI)"
   export GRAPHRAG_LLM_MODEL="model name"
   export GRAPHRAG_DEPLOYMENT_NAME="model name"
   export GRAPHRAG_EMBEDDING_MODEL="embedding model"
   ```

   settings.yaml: Customize GraphFleet's behavior further by modifying the settings.yaml file within the graphfleet directory.

1. Data Indexing:
Jupyter Notebook Guide: Follow the instructions provided in the get-started-graphfleet.ipynb notebook to learn how to index your data with GraphFleet. This notebook provides a hands-on experience for setting up your knowledge base.

1. Interacting with GraphFleet:
Jupyter Notebooks: Explore GraphFleet's capabilities with the provided notebooks:

   get-started-graphfleet.ipynb: A comprehensive guide to indexing your data and running basic queries.

   Local Search Notebook.ipynb: Demonstrates local search techniques.

   app.py (FastAPI Application): Run a Streamlit-powered web interface to interact with GraphFleet using a user-friendly chat-like interface.

### Start the application

```
streamlit run app.py
```

Access the interface in your web browser at the provided URL (usually <http://localhost:8080>).

=======

```
GRAPHRAG_API_KEY
GRAPHRAG_API_BASE (for Azure OpenAI)
GRAPHRAG_API_VERSION (for Azure OpenAI)
Other settings related to your LLM and embedding models.
settings.yaml: Customize GraphFleet's behavior further by modifying the settings.yaml file within the graphfleet directory.
```

2. Data Indexing:

Jupyter Notebook Guide: Follow the instructions provided in the get-started-graphfleet.ipynb notebook to learn how to index your data with GraphFleet. This notebook provides a hands-on experience for setting up your knowledge base.

3. Interacting with GraphFleet:
Jupyter Notebooks: Explore GraphFleet's capabilities with the provided notebooks:

get-started-graphfleet.ipynb: A comprehensive guide to indexing your data and running basic queries.
Local Search Notebook.ipynb: Demonstrates local search techniques.
[Add descriptions of other notebooks and their purpose here]
app.py (FastAPI Application): Run a Streamlit-powered web interface to interact with GraphFleet using a user-friendly chat-like interface:

### Start the application: 

```
streamlit run app.py
```
Access the interface in your web browser at the provided URL (usually http://localhost:8080).

>>>>>>> origin/main
``` bash
python -m graphrag.query --root ./graphfleet --method local "What are the key features of GraphRAG ??"
```

For Global query mode :

``` bash
python -m graphrag.query --root ./graphfleet --method global "What are the top main features of GraphRAG"
```
<<<<<<< HEAD

=======
>>>>>>> origin/main
### Running the API only

To run the API, save the code in a file named api.py and execute the following command in your terminal:

``` bash
uvicorn api:app --reload --port 8001
```

## Security

[Security](SECURITY.md)

## License

[text](LICENSE)

## Star History

<<<<<<< HEAD
[![Star History Chart](https://api.star-history.com/svg?repos=Qredence/GraphFleet&type=Date)](https://star-history.com/#Qredence/GraphFleet&Date)
=======
[![Star History Chart](https://api.star-history.com/svg?repos=Qredence/GraphFleet&type=Date)](https://star-history.com/#Qredence/GraphFleet&Date)
>>>>>>> origin/main

