Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Document Fix] #85

Merged
merged 5 commits into from
Jul 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ class Net(nn.Module):
## LightRAG Task Pipeline


We will ask the model to respond with ``explaination`` and ``example`` of a concept. And we will build a pipeline to get the structured output as ``QAOutput``.
We will ask the model to respond with ``explanation`` and ``example`` of a concept. And we will build a pipeline to get the structured output as ``QAOutput``.

```python

Expand Down
4 changes: 2 additions & 2 deletions docs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ update_files:
@python $(SOURCEDIR)/insert_labels.py
@echo "Removing unnecessary strings for better formatting"
@python $(SOURCEDIR)/remove_string.py
#@echo "Removing duplicated files"
# @python $(SOURCEDIR)/remove_files.py
@echo "Removing duplicated files"
@python $(SOURCEDIR)/remove_files.py
@echo "Renaming and updating file"
@python $(SOURCEDIR)/change_api_file_name.py

Expand Down
Binary file modified docs/source/_static/images/LightRAG-logo-doc.jpeg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
36 changes: 2 additions & 34 deletions docs/source/remove_files.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,53 +15,21 @@ def remove_file(directory: str):

# remove modules.rst
try:
for filename in os.listdir(directory):
for _ in os.listdir(directory):
module_file = os.path.join(directory, "modules.rst")
os.remove(module_file)
except Exception:
print(f"No modules.rst to remove in {directory}")

# remove components.rst, core.rst, prompt.rst, ...
try:
for filename in os.listdir(directory):
for _ in os.listdir(directory):
name = directory.split("/")[-1] + ".rst"
module_file = os.path.join(directory, name)
os.remove(module_file)
except Exception:
print(f"No {name} to remove in {directory}")

# remove api files to avoid showing duplicated section

target_files = [
"components.model_client.openai_client.rst",
"components.retriever.faiss_retriever.rst",
"components.reasoning.chain_of_thought.rst",
"components.model_client.groq_client.rst",
"components.retriever.bm25_retriever.rst",
"components.model_client.google_client.rst",
"components.model_client.transformers_client.rst",
"components.model_client.utils.rst",
"components.retriever.llm_retriever.rst",
"components.agent.react.rst",
"components.model_client.anthropic_client.rst",
"components.output_parsers.outputs.rst",
"components.model_client.cohere_client.rst",
"components.retriever.reranker_retriever.rst",
"components.data_process.data_components.rst",
"components.data_process.text_splitter.rst",
"components.memory.memory.rst",
# "components.retriever.postgres_retriever.rst",
]
try:
for filename in os.listdir(directory):
if filename in target_files:
filepath = os.path.join(directory, filename)
os.remove(filepath)
print(f"{filepath} is removed")
except Exception:
print(f"No target files to remove in {directory}")


remove_file("./source/apis/components")
remove_file("./source/apis/core")
remove_file("./source/apis/eval")
Expand Down
Loading