-
Notifications
You must be signed in to change notification settings - Fork 0
/
Config.py
36 lines (30 loc) · 834 Bytes
/
Config.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
import sys
import os
import pandas as pd # Import pandas
from tqdm import tqdm # Import tqdm for progress bar
import pymupdf4llm as plm
from concurrent.futures import ProcessPoolExecutor
from ReadPDF import process_pdf
from toc import extract_toc
from graphio import save_gml, read_gml
from typing import Tuple
import pickle
import ollama
import networkx as nx
import numpy as np
import matplotlib.pyplot as plt
import concurrent.futures
import re
from tqdm import tqdm
import time
import json
import dspy
from typing import List, Union, Optional
from nltk.tokenize import sent_tokenize, word_tokenize
from nltk.corpus import stopwords
from rake_nltk import Rake
# Ensure you have the necessary NLTK resources
import nltk
nltk.download('punkt')
nltk.download('stopwords')
#os.environ["NETWORKX_AUTOMATIC_BACKENDS"] = "cugraph"