Skip to content

Commit

Permalink
fix refresh bug
Browse files Browse the repository at this point in the history
  • Loading branch information
MrJs133 committed Dec 27, 2024
1 parent fddc8e0 commit 58eb9f5
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion hugegraph-llm/src/hugegraph_llm/demo/rag_demo/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ def init_rag_ui() -> gr.Interface:
textbox_array_graph_config = create_configs_block()

with gr.Tab(label="1. Build RAG Index 💡"):
textbox_input_text, textbox_input_schema, textbox_info_extract_template = create_vector_graph_block()
textbox_input_text, textbox_input_schema, textbox_info_extract_template = create_vector_graph_block()
with gr.Tab(label="2. (Graph)RAG & User Functions 📖"):
(
textbox_inp,
Expand Down
6 changes: 5 additions & 1 deletion hugegraph-llm/src/hugegraph_llm/utils/graph_index_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,11 @@ def extract_graph(input_file, input_text, schema, example_prompt) -> str:
if not context["vertices"] and not context["edges"]:
log.info("Please check the schema.(The schema may not match the Doc)")
return json.dumps(
{"vertices": context["vertices"], "edges": context["edges"], "warning": "The schema may not match the Doc"},
{
"vertices": context["vertices"],
"edges": context["edges"],
"warning": "The schema may not match the Doc"
},
ensure_ascii=False,
indent=2
)
Expand Down

0 comments on commit 58eb9f5

Please sign in to comment.