Demosthene-OR commited on
Commit
652068d
·
1 Parent(s): 1d1a8c7
Files changed (3) hide show
  1. knowledge_graph.html +3 -3
  2. requirements.txt +5 -5
  3. requirements_v1.txt +16 -0
knowledge_graph.html CHANGED
@@ -230,7 +230,7 @@ function highlightFilter(filter) {
230
 
231
  #mynetwork {
232
  width: 100%;
233
- height: 1200px;
234
  background-color: #222222;
235
  border: 1px solid lightgray;
236
  position: relative;
@@ -453,8 +453,8 @@ function highlightFilter(filter) {
453
 
454
 
455
  // parsing and collecting nodes and edges from the python
456
- nodes = new vis.DataSet([{"font": {"color": "white"}, "group": "Fictional organization", "id": "Night\u0027S Watch", "label": "Night\u0027S Watch", "shape": "dot", "title": "Fictional organization"}, {"font": {"color": "white"}, "group": "Person", "id": "David Benioff", "label": "David Benioff", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Award", "id": "Primetime Emmy Awards", "label": "Primetime Emmy Awards", "shape": "dot", "title": "Award"}, {"font": {"color": "white"}, "group": "Award", "id": "Hugo Awards", "label": "Hugo Awards", "shape": "dot", "title": "Award"}, {"font": {"color": "white"}, "group": "Person", "id": "D. B. Weiss", "label": "D. B. Weiss", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Fictional continent", "id": "Essos", "label": "Essos", "shape": "dot", "title": "Fictional continent"}, {"font": {"color": "white"}, "group": "Organization", "id": "Hbo", "label": "Hbo", "shape": "dot", "title": "Organization"}, {"font": {"color": "white"}, "group": "Person", "id": "George R. R. Martin", "label": "George R. R. Martin", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Television series", "id": "A Knight Of The Seven Kingdoms", "label": "A Knight Of The Seven Kingdoms", "shape": "dot", "title": "Television series"}, {"font": {"color": "white"}, "group": "Book series", "id": "A Song Of Ice And Fire", "label": "A Song Of Ice And Fire", "shape": "dot", "title": "Book series"}, {"font": {"color": "white"}, "group": "Award", "id": "Golden Globe Award For Best Television Series \u2013 Drama", "label": "Golden Globe Award For Best Television Series \u2013 Drama", "shape": "dot", "title": "Award"}, {"font": {"color": "white"}, "group": "Book", "id": "A Game Of Thrones", "label": "A Game Of Thrones", "shape": "dot", "title": "Book"}, {"font": {"color": "white"}, "group": "Television series", "id": "Game Of Thrones", "label": "Game Of Thrones", "shape": "dot", "title": "Television series"}, {"font": {"color": "white"}, "group": "Fictional object", "id": "Iron Throne", "label": "Iron Throne", "shape": "dot", "title": "Fictional object"}, {"font": {"color": "white"}, "group": "Fictional place", "id": "Seven Kingdoms", "label": "Seven Kingdoms", "shape": "dot", "title": "Fictional place"}, {"font": {"color": "white"}, "group": "Television series", "id": "House Of The Dragon", "label": "House Of The Dragon", "shape": "dot", "title": "Television series"}, {"font": {"color": "white"}, "group": "Award", "id": "Peabody Award", "label": "Peabody Award", "shape": "dot", "title": "Award"}, {"font": {"color": "white"}, "group": "Fictional continent", "id": "Westeros", "label": "Westeros", "shape": "dot", "title": "Fictional continent"}]);
457
- edges = new vis.DataSet([{"arrows": "to", "from": "Game Of Thrones", "label": "creator", "to": "David Benioff"}, {"arrows": "to", "from": "Game Of Thrones", "label": "creator", "to": "D. B. Weiss"}, {"arrows": "to", "from": "Game Of Thrones", "label": "network", "to": "Hbo"}, {"arrows": "to", "from": "Game Of Thrones", "label": "adaptation", "to": "A Song Of Ice And Fire"}, {"arrows": "to", "from": "A Song Of Ice And Fire", "label": "author", "to": "George R. R. Martin"}, {"arrows": "to", "from": "A Song Of Ice And Fire", "label": "first_book", "to": "A Game Of Thrones"}, {"arrows": "to", "from": "Game Of Thrones", "label": "setting", "to": "Westeros"}, {"arrows": "to", "from": "Game Of Thrones", "label": "setting", "to": "Essos"}, {"arrows": "to", "from": "Game Of Thrones", "label": "focus", "to": "Iron Throne"}, {"arrows": "to", "from": "Game Of Thrones", "label": "focus", "to": "Seven Kingdoms"}, {"arrows": "to", "from": "Game Of Thrones", "label": "focus", "to": "Night\u0027S Watch"}, {"arrows": "to", "from": "Game Of Thrones", "label": "award", "to": "Primetime Emmy Awards"}, {"arrows": "to", "from": "Game Of Thrones", "label": "award", "to": "Hugo Awards"}, {"arrows": "to", "from": "Game Of Thrones", "label": "award", "to": "Peabody Award"}, {"arrows": "to", "from": "Game Of Thrones", "label": "nomination", "to": "Golden Globe Award For Best Television Series \u2013 Drama"}, {"arrows": "to", "from": "House Of The Dragon", "label": "network", "to": "Hbo"}, {"arrows": "to", "from": "A Knight Of The Seven Kingdoms", "label": "network", "to": "Hbo"}]);
458
 
459
  nodeColors = {};
460
  allNodes = nodes.get({ returnType: "Object" });
 
230
 
231
  #mynetwork {
232
  width: 100%;
233
+ height: 600px;
234
  background-color: #222222;
235
  border: 1px solid lightgray;
236
  position: relative;
 
453
 
454
 
455
  // parsing and collecting nodes and edges from the python
456
+ nodes = new vis.DataSet([{"font": {"color": "white"}, "group": "Person", "id": "Stannis_Baratheon", "label": "Stannis_Baratheon", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Bran_Stark", "label": "Bran_Stark", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Jaime_Lannister", "label": "Jaime_Lannister", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Organization", "id": "Night\u0027S_Watch", "label": "Night\u0027S_Watch", "shape": "dot", "title": "Organization"}, {"font": {"color": "white"}, "group": "Organization", "id": "White_Walkers", "label": "White_Walkers", "shape": "dot", "title": "Organization"}, {"font": {"color": "white"}, "group": "Person", "id": "Joffrey_Baratheon", "label": "Joffrey_Baratheon", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Petyr_Baelish", "label": "Petyr_Baelish", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Yara_Greyjoy", "label": "Yara_Greyjoy", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Lysa_Arryn", "label": "Lysa_Arryn", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Ellaria_Sand", "label": "Ellaria_Sand", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Margaery_Tyrell", "label": "Margaery_Tyrell", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Mance_Rayder", "label": "Mance_Rayder", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Sandor_Clegane", "label": "Sandor_Clegane", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Euron_Greyjoy", "label": "Euron_Greyjoy", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Sansa_Stark", "label": "Sansa_Stark", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Viserys_Targaryen", "label": "Viserys_Targaryen", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Robb_Stark", "label": "Robb_Stark", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Theon_Greyjoy", "label": "Theon_Greyjoy", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Olenna_Tyrell", "label": "Olenna_Tyrell", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Jon_Snow", "label": "Jon_Snow", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Daenerys_Targaryen", "label": "Daenerys_Targaryen", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Samwell_Tarly", "label": "Samwell_Tarly", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Balon_Greyjoy", "label": "Balon_Greyjoy", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Missandei", "label": "Missandei", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Organization", "id": "Second_Sons", "label": "Second_Sons", "shape": "dot", "title": "Organization"}, {"font": {"color": "white"}, "group": "Person", "id": "Cersei_Lannister", "label": "Cersei_Lannister", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Tommen_Baratheon", "label": "Tommen_Baratheon", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Ned_Stark", "label": "Ned_Stark", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Catelyn_Stark", "label": "Catelyn_Stark", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Arya_Stark", "label": "Arya_Stark", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Tywin_Lannister", "label": "Tywin_Lannister", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Tyrion_Lannister", "label": "Tyrion_Lannister", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Organization", "id": "Sparrows", "label": "Sparrows", "shape": "dot", "title": "Organization"}, {"font": {"color": "white"}, "group": "Person", "id": "Three-Eyed_Raven", "label": "Three-Eyed_Raven", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Aegon_Targaryen", "label": "Aegon_Targaryen", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Khal_Drogo", "label": "Khal_Drogo", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Robert_Baratheon", "label": "Robert_Baratheon", "shape": "dot", "title": "Person"}, {"font": {"color": "white"}, "group": "Person", "id": "Brienne_Of_Tarth", "label": "Brienne_Of_Tarth", "shape": "dot", "title": "Person"}]);
457
+ edges = new vis.DataSet([{"arrows": "to", "from": "Ned_Stark", "label": "hand_of_the_king", "to": "Robert_Baratheon"}, {"arrows": "to", "from": "Ned_Stark", "label": "parent", "to": "Sansa_Stark"}, {"arrows": "to", "from": "Ned_Stark", "label": "parent", "to": "Arya_Stark"}, {"arrows": "to", "from": "Ned_Stark", "label": "parent", "to": "Bran_Stark"}, {"arrows": "to", "from": "Cersei_Lannister", "label": "sibling", "to": "Jaime_Lannister"}, {"arrows": "to", "from": "Cersei_Lannister", "label": "parent", "to": "Joffrey_Baratheon"}, {"arrows": "to", "from": "Jaime_Lannister", "label": "parent", "to": "Joffrey_Baratheon"}, {"arrows": "to", "from": "Jon_Snow", "label": "member", "to": "Night\u0027S_Watch"}, {"arrows": "to", "from": "Viserys_Targaryen", "label": "sibling", "to": "Daenerys_Targaryen"}, {"arrows": "to", "from": "Daenerys_Targaryen", "label": "spouse", "to": "Khal_Drogo"}, {"arrows": "to", "from": "Robb_Stark", "label": "parent", "to": "Catelyn_Stark"}, {"arrows": "to", "from": "Catelyn_Stark", "label": "ally", "to": "Brienne_Of_Tarth"}, {"arrows": "to", "from": "Tyrion_Lannister", "label": "enemy", "to": "Stannis_Baratheon"}, {"arrows": "to", "from": "Arya_Stark", "label": "servant", "to": "Tywin_Lannister"}, {"arrows": "to", "from": "Theon_Greyjoy", "label": "betrayal", "to": "Robb_Stark"}, {"arrows": "to", "from": "Jon_Snow", "label": "captured_by", "to": "Mance_Rayder"}, {"arrows": "to", "from": "Samwell_Tarly", "label": "encounter", "to": "White_Walkers"}, {"arrows": "to", "from": "Daenerys_Targaryen", "label": "ally", "to": "Missandei"}, {"arrows": "to", "from": "Daenerys_Targaryen", "label": "ally", "to": "Second_Sons"}, {"arrows": "to", "from": "Olenna_Tyrell", "label": "parent", "to": "Margaery_Tyrell"}, {"arrows": "to", "from": "Petyr_Baelish", "label": "spouse", "to": "Lysa_Arryn"}, {"arrows": "to", "from": "Arya_Stark", "label": "enemy", "to": "Sandor_Clegane"}, {"arrows": "to", "from": "Bran_Stark", "label": "mentor", "to": "Three-Eyed_Raven"}, {"arrows": "to", "from": "Tommen_Baratheon", "label": "spouse", "to": "Margaery_Tyrell"}, {"arrows": "to", "from": "Sparrows", "label": "enemy", "to": "Cersei_Lannister"}, {"arrows": "to", "from": "Ellaria_Sand", "label": "enemy", "to": "Balon_Greyjoy"}, {"arrows": "to", "from": "Euron_Greyjoy", "label": "kill", "to": "Balon_Greyjoy"}, {"arrows": "to", "from": "Euron_Greyjoy", "label": "kidnap", "to": "Yara_Greyjoy"}, {"arrows": "to", "from": "Jon_Snow", "label": "identity", "to": "Aegon_Targaryen"}]);
458
 
459
  nodeColors = {};
460
  allNodes = nodes.get({ returnType: "Object" });
requirements.txt CHANGED
@@ -1,13 +1,13 @@
1
  # Core LLM and LangChain packages
2
- langchain>=0.1.0
3
- langchain-experimental>=0.0.45
4
- langchain-openai>=0.1.0
5
 
6
  # Environment variable support
7
- python-dotenv>=1.0.0
8
 
9
  # Graph visualization
10
- pyvis>=0.3.2
11
 
12
  # Web UI
13
  streamlit>=1.32.0
 
1
  # Core LLM and LangChain packages
2
+ langchain==0.3.7
3
+ langchain-experimental==0.3.4
4
+ langchain-openai==0..2.3
5
 
6
  # Environment variable support
7
+ python-dotenv==1.2.1
8
 
9
  # Graph visualization
10
+ pyvis==0.3.2
11
 
12
  # Web UI
13
  streamlit>=1.32.0
requirements_v1.txt ADDED
@@ -0,0 +1,16 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Core LLM and LangChain packages
2
+ langchain>=0.1.0
3
+ langchain-experimental>=0.0.45
4
+ langchain-openai>=0.1.0
5
+
6
+ # Environment variable support
7
+ python-dotenv>=1.0.0
8
+
9
+ # Graph visualization
10
+ pyvis>=0.3.2
11
+
12
+ # Web UI
13
+ streamlit>=1.32.0
14
+
15
+ faiss-cpu
16
+ tiktoken