Skip to content

Commit

Permalink
improve the message about what is lightrag
Browse files Browse the repository at this point in the history
  • Loading branch information
liyin2015 committed Jul 8, 2024
1 parent e5a96a9 commit dff36b0
Showing 1 changed file with 27 additions and 52 deletions.
79 changes: 27 additions & 52 deletions docs/source/index.rst
Original file line number Diff line number Diff line change
@@ -1,47 +1,11 @@
.. =======================
.. Introduction
.. =======================

.. image:: https://raw.githubusercontent.com/SylphAI-Inc/LightRAG/main/docs/source/_static/images/LightRAG-logo-doc.jpeg
:width: 100%
:alt: LightRAG Logo


.. .. |GitHub| image:: https://img.shields.io/github/stars/SylphAI-Inc/LightRAG?style=flat-square
.. :target: https://github.com/SylphAI-Inc/LightRAG


.. .. |PyPI Version| image:: https://img.shields.io/pypi/v/lightRAG?style=flat-square
.. :target: https://pypi.org/project/lightRAG/
.. .. |Discord| image:: https://dcbadge.vercel.app/api/server/zt2mTPcu?compact=true&style=flat
.. :target: https://discord.gg/zt2mTPcu
.. .. |License| image:: https://img.shields.io/github/license/SylphAI-Inc/LightRAG
.. :target: https://opensource.org/license/MIT
.. .. |PyPI Downloads| image:: https://img.shields.io/pypi/dm/lightRAG?style=flat-square
.. :target: https://pypistats.org/packages/lightRAG
.. .. |GitHub Stars| image:: https://img.shields.io/github/stars/SylphAI-Inc/LightRAG?style=flat-square
.. :target: https://star-history.com/#SylphAI-Inc/LightRAG
.. .. raw:: html
.. <div style="text-align: center; margin-bottom: 20px;">
.. <a href="https://github.com/SylphAI-Inc/LightRAG"><img src="https://img.shields.io/github/repo-size/SylphAI-Inc/LightRAG?style=flat-square" alt="GitHub Repo"></a>
.. <a href="https://pypi.org/project/lightRAG/"><img src="https://img.shields.io/pypi/v/lightRAG?style=flat-square" alt="PyPI Version"></a>
.. <a href="https://star-history.com/#SylphAI-Inc/LightRAG"><img src="https://img.shields.io/github/stars/SylphAI-Inc/LightRAG?style=flat-square" alt="GitHub Stars"></a>
.. <a href="https://discord.gg/zt2mTPcu"><img src="https://dcbadge.vercel.app/api/server/zt2mTPcu?compact=true&style=flat" alt="Discord"></a>
.. <a href="https://opensource.org/license/MIT"><img src="https://img.shields.io/github/license/SylphAI-Inc/LightRAG" alt="License"></a>
.. </div>
.. raw:: html

<div style="text-align: center; margin-bottom: 20px;">
Expand All @@ -67,8 +31,6 @@
</p>
</div>

.. *LightRAG* helps developers with both building and optimizing *Retriever-Agent-Generator (RAG)* pipelines.
.. It is *light*, *modular*, and *robust*.



Expand Down Expand Up @@ -139,15 +101,15 @@
.. and Customizability
Maxium Customizability & Composability
Light
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
We provide developers with fundamental building blocks of *100% clarity and simplicity*.

Developers who are building real-world Large Language Model (LLM) applications are the real heroes.
As a library, we provide them with the fundamental building blocks with 100% clarity and simplicity.
- Only two fundamental but powerful base classes: `Component` for the pipeline and `DataClass` for data interaction with LLMs.
- A highly readable codebase and less than two levels of class inheritance. :doc:`developer_notes/class_hierarchy`.
- We maximize the library's tooling and prompting capabilities to minimize the reliance on LLM API features such as tools and JSON format.
- The result is a library with bare minimum abstraction, providing developers with *maximum customizability*.

- Two fundamental and powerful base classes: `Component` for the pipeline and `DataClass` for data interaction with LLMs.
- We end up with less than two levels of class inheritance. :doc:`developer_notes/class_hierarchy`.
- The result is a library with bare minimum abstraction, providing developers with *maximum customizability and composability*.

.. - We use 10X less code than other libraries to achieve 10X more robustness and flexibility.
Expand All @@ -156,7 +118,19 @@ As a library, we provide them with the fundamental building blocks with 100% cla
.. Each developer has unique data needs to build their own models/components, experiment with In-context Learning (ICL) or model finetuning, and deploy the LLM applications to production. This means the library must provide fundamental lower-level building blocks and strive for clarity and simplicity:
Similar to the `PyTorch` module, our ``Component`` provides excellent visualization of the pipeline structure.
Modular
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

LightRAG resembles PyTorch in the way that we provide a modular and composable structure for developers to build and to optimize their LLM applications.

- `Component` and `DataClass` are to LightRAG for LLM Applications what `module` and `Tensor` are to PyTorch for deep learning modeling.
- `ModelClient` to bridge the gap between the LLM API and the LightRAG pipeline.
- `Orchestrator` components like `Retriever`, `Embedder`, `Generator`, and `Agent` are all model-agnostic (you can use the component on different models from different providers).


Similar to the PyTorch `module`, our `Component` provides excellent visualization of the pipeline structure.

.. code-block::
Expand All @@ -178,12 +152,12 @@ Similar to the `PyTorch` module, our ``Component`` provides excellent visualizat
.. and Robustness
Maximum Control and Robustness
Robust
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Our simplicity did not come from doing less.
On the contrary, we have to do more and go deeper and wider on any topic to offer developers *maximum control and robustness*.

- LLMs are sensitive to the prompt. We allow developers full control over their prompts without relying on API features such as tools and JSON format with components like ``Prompt``, ``OutputParser``, ``FunctionTool``, and ``ToolManager``.
- LLMs are sensitive to the prompt. We allow developers full control over their prompts without relying on LLM API features such as tools and JSON format with components like ``Prompt``, ``OutputParser``, ``FunctionTool``, and ``ToolManager``.
- Our goal is not to optimize for integration, but to provide a robust abstraction with representative examples. See this in ``ModelClient`` and ``Retriever``.
- All integrations, such as different API SDKs, are formed as optional packages but all within the same library. You can easily switch to any models from different providers that we officially support.

Expand All @@ -197,13 +171,14 @@ On the contrary, we have to do more and go deeper and wider on any topic to offe
.. It is the future of LLM applications
Unites both Research and Production
Unites Research and Production
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Our team has experience in both AI research and production.
We are building a library that unites the two worlds, forming a healthy LLM application ecosystem.

On top of the easiness to use, we in particular optimize the configurability of components for researchers to build their solutions and to benchmark existing solutions.
Like how PyTorch has united both researchers and production teams, it enables smooth transition from research to production.
With researchers building on LightRAG, production engineers can easily take over the method and test and iterate on their production data.
Researchers will want their code to be adapted into more products too.
- To resemble the PyTorch library makes it easier for LLM researchers to use the library.
- Researchers building on LightRAG enable production engineers to easily adopt, test, and iterate on their production data.
- Our 100% control and clarity of the source code further make it easy for product teams to build on and for researchers to extend their new methods.


.. toctree::
Expand Down

0 comments on commit dff36b0

Please sign in to comment.