{"id":22381043,"url":"https://github.com/shxntanu/lesa","last_synced_at":"2025-10-15T11:30:34.551Z","repository":{"id":266522938,"uuid":"897790841","full_name":"shxntanu/lesa","owner":"shxntanu","description":"📚 Turn your terminal into a File Interpreter","archived":false,"fork":false,"pushed_at":"2025-01-05T15:35:35.000Z","size":1800,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-08T02:06:39.678Z","etag":null,"topics":["document-chat","ollama","python"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/lesa/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/shxntanu.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-12-03T08:46:37.000Z","updated_at":"2025-01-03T07:29:43.000Z","dependencies_parsed_at":null,"dependency_job_id":"1582abb1-78b1-4663-a53d-3c1fba19de42","html_url":"https://github.com/shxntanu/lesa","commit_stats":null,"previous_names":["shxntanu/lesa"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shxntanu%2Flesa","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shxntanu%2Flesa/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shxntanu%2Flesa/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shxntanu%2Flesa/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/shxntanu","download_url":"https://codeload.github.com/shxntanu/lesa/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":236607255,"owners_count":19176301,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["document-chat","ollama","python"],"created_at":"2024-12-05T00:07:08.772Z","updated_at":"2025-10-15T11:30:34.064Z","avatar_url":"https://github.com/shxntanu.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"![Banner](https://github.com/shxntanu/lesa/raw/master/assets/banner-v3.png)\n\n\u003cdiv align=\"center\"\u003e\n\n[![Python](https://img.shields.io/badge/python-3.10%2B-blue)](https://www.python.org/downloads/)\n![PyPI - Version](https://img.shields.io/pypi/v/lesa)\n![PyPI Downloads](https://static.pepy.tech/badge/lesa)\n\n\u003c/div\u003e\n\n\u003cdiv align=\"center\"\u003e\n\n**_lesa_**\n`[lee - saa]` • **Old Norse** \u003cbr/\u003e\n(v.) to read, to study, to learn\n\n\u003c!-- \u003cdiv align=\"center\"\u003e\n  \u003csub\u003ePrepared by \u003ca href=\"https://github.com/shxntanu\"\u003eShantanu Wable\u003c/a\u003e and \u003ca href=\"https://github.com/omkargwagholikar\"\u003eOmkar Wagholikar\u003c/a\u003e \u003c/sub\u003e\n\u003c/div\u003e --\u003e\n\n\u003c/div\u003e\n\n`lesa` is a CLI tool built in Python that allows you to converse with your documents from the terminal, completely offline and on-device using **Ollama**. Open the terminal in the directory of your choice and start a conversation with any document!\n\n## Usage\n\nTo start a conversation with a document (`.pdf` and `.docx` for now), simply run:\n\n```bash\nlesa read path/to/your/document --page \u003cpage_number\u003e (optional)\n```\n\nOr start a conversation with an already-embedded directory, run:\n\n```bash\nlesa chat\n```\n\n### Embed\n\nTo embed all files from your current working directory, run:\n\n```bash\nlesa embed\n```\n\nThis creates a `.lesa` config folder in your current working directory that stores the embeddings of all the documents in the directory.\n\n\u003c!-- ## Features\n\n-   🖥️ **Completely On-Device**: Uses Ollama under the hood to interface with LLMs, so you can be sure your data is not leaving your device.\n-   📚 **Converse with (almost) all documents**: Supports PDF, DOCX and Text files.\n-   🤖 **Wide Range of LLMs**: Choose the Large Language Model of your choice. Whether you want to keep it quick and concise, or want to go all in with a huge context window, the choice is yours. --\u003e\n\n## Setup\n\n`lesa` uses [Ollama](https://ollama.com/) under the hood to utilize the power of large language models.\nTo install and setup Ollama, run the setup script [`setup-ollama.sh`](scripts/setup-ollama.sh).\n\n```bash\ncurl -fsSL https://raw.githubusercontent.com/shxntanu/lesa/master/scripts/setup-ollama.sh | bash\n```\n\nThis script automatically installs the Ollama CLI and pulls the default model (llama3.1:latest) for you. Then install the package using pip.\n\n## Installation\n\nSimply install the package using pip:\n\n```bash\npip install lesa\n```\n\nTo upgrade to the latest version, run:\n\n```bash\npip install -U lesa\n```\n\n## Contribute\n\nWe welcome contributions! If you'd like to improve `lesa` or have any feedback, feel free to open an issue or submit a pull request.\n\n## Credits\n\n1. [Typer](https://typer.tiangolo.com/) and [Rich](https://github.com/Textualize/rich): CLI library and terminal formatting.\n2. [Ollama](https://ollama.com/): On-device language model inference.\n3. [Langchain](https://langchain.com/): Pipeline for language model inference.\n4. [FAISS](https://github.com/facebookresearch/faiss): Similarity Search and Vector Store library from Meta AI.\n\n## License\n\nApache-2.0\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshxntanu%2Flesa","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshxntanu%2Flesa","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshxntanu%2Flesa/lists"}