`-r/--reuse` mode
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 12.5k
- Forks
- 998
- Avg merge
- 3d 13h
- Merged PRs (30d)
- 10
Description
When using this on the command-line it would be useful if you could opt to get a previous response for the same prompt/system/model/options - if one exists:
cat file.py | llm "explain this file" --reuse
That way you could safely run loops against larger amounts of data while avoiding paying for the same prompt twice.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the command-line entry point for llm and trace how the prompt, system, model, and options are handled. Work out how the --reuse invocation should identify a matching previous response, then exercise the shown cat file.py | llm "explain this file" --reuse workflow and verify that repeated runs avoid paying for the same prompt twice.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100