Skip to content

GML-2029 Remove the impractical embedding for Entity and other types#27

Open
chengbiao-jin wants to merge 1 commit intomainfrom
GML-2029-Embedding
Open

GML-2029 Remove the impractical embedding for Entity and other types#27
chengbiao-jin wants to merge 1 commit intomainfrom
GML-2029-Embedding

Conversation

@chengbiao-jin
Copy link
Collaborator

@chengbiao-jin chengbiao-jin commented Feb 28, 2026

PR Type

Enhancement, Bug fix, Documentation


Description

  • Remove entity/relationship embeddings; simplify schema.

    • Rename Relationship to RelationshipType.
    • Drop ResolvedEntity, resolution workflow.
    • Keep vectors on DocumentChunk, Community.
  • Safer vector upserts with schema discovery.

    • Cache vector attributes per vertex type.
    • Per-item vector_attribute support.
  • Better multimodal defaults and providers.

    • Add Bedrock; sensible default vision models.
  • Agent history contextualization and routing.

    • Merge KG results with conversation history.

Diagram Walkthrough

flowchart LR
  EMB["EmbeddingStore: vector attr cache + checks"]
  UPSERT["add_embeddings uses per-vertex attr"]
  SCHEMA["Schema: drop ResolvedEntity; use RelationshipType"]
  GSQL["GSQL queries updated accordingly"]
  AGENT["Agent: contextualize history, merge KG"]
  UI["UI/routers: clearer states and errors"]

  EMB -- "discover attrs via ls" --> UPSERT
  SCHEMA -- "affects" --> GSQL
  UPSERT -- "skip if attr missing" --> GSQL
  AGENT -- "history -> supportai -> merge" --> GSQL
  UI -- "status, selection, messages" --> AGENT
Loading

File Walkthrough

Relevant files
Enhancement
17 files
tigergraph_embedding_store.py
Add vector-attribute cache and safe upserts                           
+137/-17
config.py
Validate configs; multimodal defaults; Bedrock support     
+45/-18 
graph_rag.py
Remove entity resolution; streamline communities                 
+7/-116 
agent_graph.py
Contextualize history and merge KG results                             
+100/-9 
supportai_ingest.py
Stop embedding entities; use RelationshipType                       
+9/-79   
workers.py
Drop embed channel; no entity embeddings                                 
+4/-102 
util.py
Robust query installation with polling; concurrency           
+44/-29 
util.py
Verify query install; poll until ready                                     
+40/-16 
image_data_extractor.py
Cache multimodal client; simpler error texts                         
+11/-4   
base_llm.py
Add prompt for question contextualization                               
+15/-1   
SupportAI_Schema.gsql
Remove ResolvedEntity/Concept; add RelationshipType           
+6/-16   
SupportAI_Schema_Native_Vector.gsql
Rename vector job; keep chunk/community vectors                   
+2/-9     
graphrag_louvain_init.gsql
Run louvain directly on Entity vertices                                   
+14/-14 
GraphRAG_Hybrid_Search.gsql
Adjust types; support RelationshipType context                     
+2/-2     
get_community_children.gsql
Fetch children via Entity IN_COMMUNITY                                     
+1/-1     
Setup.tsx
Track processing state; robust rebuild status                       
+54/-29 
Bot.tsx
Validate selected graph; empty-state handling                       
+25/-10 
Bug fix
3 files
eventual_consistency_checker.py
Update upserts to RelationshipType; remove Concept links 
+5/-25   
inquiryai.py
Clearer error messages for missing graphs                               
+14/-6   
text_extractors.py
Sanitize alt text; lowercase image IDs; cleanup                   
+12/-4   
Documentation
1 files
answer_question.py
Update indices to chunks and communities                                 
+1/-1     
Additional files
54 files
LICENSE +1/-1     
html_chunker.py +1/-1     
markdown_chunker.py +1/-1     
recursive_chunker.py +1/-1     
semantic_chunker.py +1/-1     
connections.py +1/-1     
LLMEntityRelationshipExtractor.py +1/-1     
Build_Community_Concepts.gsql +0/-47   
Build_Concept_Tree.gsql +0/-34   
Build_Entity_Concepts.gsql +0/-28   
Build_Relationship_Concepts.gsql +0/-25   
getEntityRelationshipConceptCooccurrence.gsql +0/-140 
ResolveRelationships.gsql +0/-26   
StreamDocIds.gsql +0/-16   
entities_have_resolution.gsql +0/-10   
modularity.gsql +3/-3     
Scan_For_Updates.gsql +1/-5     
Selected_Set_Display.gsql +1/-1     
SupportAI_IndexCreation.gsql +0/-3     
SupportAI_Schema_Images.gsql +1/-1     
Chunk_Sibling_Search.gsql +1/-1     
Chunk_Sibling_Vector_Search.gsql +1/-1     
Content_Similarity_Search.gsql +2/-2     
Content_Similarity_Vector_Search.gsql +2/-2     
Entity_Relationship_Retrieval.gsql +2/-2     
GraphRAG_Community_Search.gsql +3/-3     
GraphRAG_Community_Search_Display.gsql +3/-3     
GraphRAG_Community_Vector_Search.gsql +4/-4     
GraphRAG_Hybrid_Search_Display.gsql +2/-2     
GraphRAG_Hybrid_Vector_Search.gsql +2/-2     
Keyword_Search.gsql +1/-1     
aws_bedrock_service.py +1/-1     
google_genai_service.py +1/-1     
openai_service.py +1/-1     
schemas.py +1/-1     
tool_io_schemas.py +1/-1     
token_calculator.py +1/-1     
community_summarizer.py +1/-1     
main.py +2/-2     
supportai_init.py +2/-2     
workers.py +7/-14   
agent.py +1/-1     
agent_generation.py +1/-1     
agent_router.py +1/-1     
main.py +1/-1     
supportai.py +1/-24   
ui.py +7/-3     
create_concepts.py +0/-103 
supportai.py +2/-2     
generate_cypher.py +1/-1     
generate_function.py +1/-1     
generate_gsql.py +1/-1     
map_question_to_schema.py +1/-1     
test_supportai.py +0/-6     

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant