orchard-litchi


Nameorchard-litchi JSON
Version 0.1.2 PyPI version JSON
download
home_pagehttps://github.com/OrchardUniverse/litchi
SummaryLitchi is yet another coding assistant powered by LLM.
upload_time2024-09-09 10:57:11
maintainerNone
docs_urlNone
authorOrchard Universe
requires_python>=3.6
licenseNone
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Litchi

## Introduction

`Litchi` is yet another coding assistant powered by LLM.

Unlike other programming assistants, `litchi` supports global indexing across all source files in projects and code-based retrieval augmented generation. It makes features like chat-to-code and code-generation more effective and practical.

## Features

`Litchi` has more features than other coding assistants or copilot plugins because it is integrated with indexes which can be used as standalone tools.

* Support indexing source code files for the whole project.
* Manager any code index by creating, updating, showing, and searching.
* Retrieval augmented generation with source code for user's query.
* Addoc chat to code which will retrieval related source files to query LLM.
* Generate code based on user's query and related source files.
* One step to filter the source files which can be customed for different projects.
* Compatible with all large language models like ChatGPT and others.
* Compatible with public and private MaaS which can be deployed in local.

## Use Cases

* Normal chat: chat with LLM without indexes which is useful for general purposes.
* Chat with file: use LLM to read and understand a local file.
* Chat with files: collect file names in index file and chat with all files.
* Generate code for user's query:
  * Quickly generate python script like port detecting to execute.
* Generate code for user's query and source files:
  * Rewrite the source code in different programming languages.
  * Generate unit test cases for the source code.
* Run commands: generate the script and execute immediately
* Write requirements instead of coding: Edit local requirement file and automatically generating code
* Optimize code for user's query and source file:
  * Add annotation for original source code.
  * Format, refactor or optmize the source code with specified style.
  * Inplace or ask permission to update the source code with optimized code.
  * Implement the TODO functions in the source code.

  

## Install

Install the `litchi` command from [PyPI](https://pypi.org/project/orchard-litchi/).

```
pip install orchard-litchi
```

You can install from source by cloning the repository.

```
git clone https://github.com/OrchardUniverse/litchi.git
cd ./litchi/
python ./setup.py develop
```

## Usage

Initialize the project and generate directory `.litchi/`. You can input the language as "Chinese" so that it will create index and query in Chinese.

```
cd $PROJECT_PATH

litchi init .

litchi init --language Chinese ,
```

Go to the project directory and create source file `.litchi/source_files.yaml`. You can edit `.litchi/ignore_rules.yaml` to choose the expected source files.

```
litchi source create
```

Create the index for single file or all source files in project.

```
litchi index create $FILE_PATH

litchi index create --all
```

Show the detail of the index of single file or all indexes.

```
litchi index show $FILE_PATH

litchi index show --all
```

You can input a query and get the related indexes.

```
litchi index query $QUERY
```

If you want to read the source code with index, use the following commands which will copy the readable index file next to the source file.

```
litchi index copy-to-source

litchi index delete-from-source
```


            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/OrchardUniverse/litchi",
    "name": "orchard-litchi",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.6",
    "maintainer_email": null,
    "keywords": null,
    "author": "Orchard Universe",
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/5d/f8/f7c32a1f68a4c6bf7d61c8ac30b703ccc069fd96b95fbb1d14fe6bd95405/orchard_litchi-0.1.2.tar.gz",
    "platform": null,
    "description": "# Litchi\n\n## Introduction\n\n`Litchi` is yet another coding assistant powered by LLM.\n\nUnlike other programming assistants, `litchi` supports global indexing across all source files in projects and code-based retrieval augmented generation. It makes features like chat-to-code and code-generation more effective and practical.\n\n## Features\n\n`Litchi` has more features than other coding assistants or copilot plugins because it is integrated with indexes which can be used as standalone tools.\n\n* Support indexing source code files for the whole project.\n* Manager any code index by creating, updating, showing, and searching.\n* Retrieval augmented generation with source code for user's query.\n* Addoc chat to code which will retrieval related source files to query LLM.\n* Generate code based on user's query and related source files.\n* One step to filter the source files which can be customed for different projects.\n* Compatible with all large language models like ChatGPT and others.\n* Compatible with public and private MaaS which can be deployed in local.\n\n## Use Cases\n\n* Normal chat: chat with LLM without indexes which is useful for general purposes.\n* Chat with file: use LLM to read and understand a local file.\n* Chat with files: collect file names in index file and chat with all files.\n* Generate code for user's query:\n  * Quickly generate python script like port detecting to execute.\n* Generate code for user's query and source files:\n  * Rewrite the source code in different programming languages.\n  * Generate unit test cases for the source code.\n* Run commands: generate the script and execute immediately\n* Write requirements instead of coding: Edit local requirement file and automatically generating code\n* Optimize code for user's query and source file:\n  * Add annotation for original source code.\n  * Format, refactor or optmize the source code with specified style.\n  * Inplace or ask permission to update the source code with optimized code.\n  * Implement the TODO functions in the source code.\n\n  \n\n## Install\n\nInstall the `litchi` command from [PyPI](https://pypi.org/project/orchard-litchi/).\n\n```\npip install orchard-litchi\n```\n\nYou can install from source by cloning the repository.\n\n```\ngit clone https://github.com/OrchardUniverse/litchi.git\ncd ./litchi/\npython ./setup.py develop\n```\n\n## Usage\n\nInitialize the project and generate directory `.litchi/`. You can input the language as \"Chinese\" so that it will create index and query in Chinese.\n\n```\ncd $PROJECT_PATH\n\nlitchi init .\n\nlitchi init --language Chinese ,\n```\n\nGo to the project directory and create source file `.litchi/source_files.yaml`. You can edit `.litchi/ignore_rules.yaml` to choose the expected source files.\n\n```\nlitchi source create\n```\n\nCreate the index for single file or all source files in project.\n\n```\nlitchi index create $FILE_PATH\n\nlitchi index create --all\n```\n\nShow the detail of the index of single file or all indexes.\n\n```\nlitchi index show $FILE_PATH\n\nlitchi index show --all\n```\n\nYou can input a query and get the related indexes.\n\n```\nlitchi index query $QUERY\n```\n\nIf you want to read the source code with index, use the following commands which will copy the readable index file next to the source file.\n\n```\nlitchi index copy-to-source\n\nlitchi index delete-from-source\n```\n\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "Litchi is yet another coding assistant powered by LLM.",
    "version": "0.1.2",
    "project_urls": {
        "Homepage": "https://github.com/OrchardUniverse/litchi"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "a64570b00b65a4bfe062664a90a863bfaad012731e310b4191465d05831c2592",
                "md5": "0ffe5b6bf5f1105abafb95b81df0c6a6",
                "sha256": "2db31f6fcee082b447576cb4564c1412dc73588dc6fd6c7c67ca48c5cd453568"
            },
            "downloads": -1,
            "filename": "orchard_litchi-0.1.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "0ffe5b6bf5f1105abafb95b81df0c6a6",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.6",
            "size": 33674,
            "upload_time": "2024-09-09T10:57:07",
            "upload_time_iso_8601": "2024-09-09T10:57:07.988914Z",
            "url": "https://files.pythonhosted.org/packages/a6/45/70b00b65a4bfe062664a90a863bfaad012731e310b4191465d05831c2592/orchard_litchi-0.1.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "5df8f7c32a1f68a4c6bf7d61c8ac30b703ccc069fd96b95fbb1d14fe6bd95405",
                "md5": "8f62e6f1b3847663b8b41ebfbe9d7880",
                "sha256": "44d6115eb5e0a075790acc665dd4b0e9260e451c48038bc2aabd1f97c8f29998"
            },
            "downloads": -1,
            "filename": "orchard_litchi-0.1.2.tar.gz",
            "has_sig": false,
            "md5_digest": "8f62e6f1b3847663b8b41ebfbe9d7880",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.6",
            "size": 25519,
            "upload_time": "2024-09-09T10:57:11",
            "upload_time_iso_8601": "2024-09-09T10:57:11.502351Z",
            "url": "https://files.pythonhosted.org/packages/5d/f8/f7c32a1f68a4c6bf7d61c8ac30b703ccc069fd96b95fbb1d14fe6bd95405/orchard_litchi-0.1.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-09-09 10:57:11",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "OrchardUniverse",
    "github_project": "litchi",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "requirements": [],
    "lcname": "orchard-litchi"
}
        
Elapsed time: 0.38795s