{"id":14964749,"url":"https://github.com/p-e-w/arrows","last_synced_at":"2025-10-05T09:30:31.738Z","repository":{"id":245582188,"uuid":"815882646","full_name":"p-e-w/arrows","owner":"p-e-w","description":"A frontend for creative writing with LLMs","archived":false,"fork":false,"pushed_at":"2024-07-15T10:44:51.000Z","size":31,"stargazers_count":115,"open_issues_count":3,"forks_count":8,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-23T04:12:46.338Z","etag":null,"topics":["ai-writing","creative-writing","frontend","llamacpp","openai-api"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/p-e-w.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-06-16T12:16:55.000Z","updated_at":"2025-01-18T02:23:09.000Z","dependencies_parsed_at":"2024-09-13T22:42:17.607Z","dependency_job_id":"07259457-dc29-4aa4-8a9f-be6932d41ba4","html_url":"https://github.com/p-e-w/arrows","commit_stats":{"total_commits":2,"total_committers":1,"mean_commits":2.0,"dds":0.0,"last_synced_commit":"ca4c3dac1eaffa51d7454c3f4b1779d709b58bb8"},"previous_names":["p-e-w/arrows"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/p-e-w%2Farrows","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/p-e-w%2Farrows/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/p-e-w%2Farrows/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/p-e-w%2Farrows/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/p-e-w","download_url":"https://codeload.github.com/p-e-w/arrows/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":235378950,"owners_count":18980492,"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":["ai-writing","creative-writing","frontend","llamacpp","openai-api"],"created_at":"2024-09-24T13:33:43.541Z","updated_at":"2025-10-05T09:30:31.434Z","avatar_url":"https://github.com/p-e-w.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Arrows\n\nArrows is an experimental frontend for creative writing with large language models (LLMs).\n\nhttps://github.com/p-e-w/arrows/assets/2702526/a3f21e54-9dbd-43a1-9b2a-ea8873e9d5ec\n\nIt is designed around three principles:\n\n1. **Generate whole paragraphs:** Paragraphs are the natural semantic units of prose.\n   Instead of generating a fixed number of tokens like some other AI writing tools,\n   Arrows stops requesting more tokens at the end of the paragraph,\n   presenting a piece of text to the user that makes sense on its own.\n2. **Give the user two options to choose from:** Arrows generates two versions\n   of the next paragraph, and presents them to the user as two possible\n   continuations. With a correctly configured backend (see llama.cpp arguments\n   below), this can be done as a batched operation, which is essentially free,\n   *doubling the effective generation speed!*\n3. **Zero UI:** Arrows has no buttons, labels, or menus. Its user interface\n   consists of the text you are working on, and nothing else. All LLM operations\n   are performed using only six intuitive keyboard shortcuts (see below).\n\nArrows supports any backend that exposes an OpenAI-compatible text completion API.\nThis includes [text-generation-webui](https://github.com/oobabooga/text-generation-webui),\nthe [llama.cpp](https://github.com/ggerganov/llama.cpp) server, and of course\nthe OpenAI API itself.\n\nNote that Arrows is intended for a completion-based writing workflow like the one\nI described in [this Reddit post](https://www.reddit.com/r/LocalLLaMA/comments/18zqy4s/).\nIf you want an *instruction*-based workflow where you explicitly tell the AI\nwhat to write next, then this is not the frontend you are looking for.\n\n\n## Keyboard shortcuts\n\nArrows is a browser-based text editor and supports all standard text editing\nshortcuts. In addition, the following shortcuts are provided to use the LLM\nwriting features:\n\n**\u003ckbd\u003eCtrl\u003c/kbd\u003e+\u003ckbd\u003eEnter\u003c/kbd\u003e (on Windows/Linux)** or **\u003ckbd\u003e⌘\u003c/kbd\u003e+\u003ckbd\u003eEnter\u003c/kbd\u003e (on macOS):**\nGenerate two options for the paragraph following the current cursor position.\n\n**\u003ckbd\u003e← Left Arrow\u003c/kbd\u003e:**\nChoose left option and continue generating from there.\n\n**\u003ckbd\u003e→ Right Arrow\u003c/kbd\u003e:**\nChoose right option and continue generating from there.\n\n**\u003ckbd\u003e↓ Down Arrow\u003c/kbd\u003e:**\nGenerate new options.\n\n**\u003ckbd\u003e↑ Up Arrow\u003c/kbd\u003e:**\nUndo last insertion and generate from there.\n\n**\u003ckbd\u003eEscape\u003c/kbd\u003e:**\nReturn to normal editing.\n\n\n## Installation\n\nIf you have Git and Node.js installed, installing Arrows is straightforward:\n\n```\ngit clone https://github.com/p-e-w/arrows.git\ncd arrows\nnpm install\n```\n\n\n## Running\n\nThe easiest way to use Arrows locally is to just run\n\n```\nnpm run dev\n```\n\nfrom the installation directory and then open the displayed URL in the browser.\nYou can also use\n\n```\nnpm run build\n```\n\nto build a minified production version, and then serve the `dist` directory\nusing the web server of your choice.\n\n\n## Configuration\n\nTo set the base URL, API key, and generation parameters, simply edit the file\n[`src/config.ts`](src/config.ts).\n\n\n## Enabling parallel generation\n\nArrows has a fully asynchronous architecture and is capable of streaming\ntwo completion options in parallel, as demonstrated in the video above.\nThis can save valuable user and GPU time.\n\nHowever, in order for parallel generation to work, the backend server\nhas to support concurrent requests, ideally with automatic batching.\nAs of June 2024, text-generation-webui\n[does not support](https://github.com/oobabooga/text-generation-webui/issues/3767)\nconcurrent request handling. When used as a backend for Arrows, the left/right\nchoices will be generated sequentially rather than in parallel.\n\nA backend that *does* support concurrent requests is the\n[llama.cpp server](https://github.com/ggerganov/llama.cpp/tree/master/examples/server).\nTo enable this feature, simply run the server with the arguments\n\n```\n--parallel 2 --cont-batching\n```\n\n\n## License\n\nCopyright \u0026copy; 2024  Philipp Emanuel Weidmann (\u003cpew@worldwidemann.com\u003e)\n\nThis program is free software: you can redistribute it and/or modify\nit under the terms of the GNU Affero General Public License as published by\nthe Free Software Foundation, either version 3 of the License, or\n(at your option) any later version.\n\nThis program is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\nGNU Affero General Public License for more details.\n\nYou should have received a copy of the GNU Affero General Public License\nalong with this program.  If not, see \u003chttps://www.gnu.org/licenses/\u003e.\n\n**By contributing to this project, you agree to release your\ncontributions under the same license.**\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fp-e-w%2Farrows","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fp-e-w%2Farrows","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fp-e-w%2Farrows/lists"}