https://github.com/roy-pstr/python-pilot
A python terminal with a coding copilot
https://github.com/roy-pstr/python-pilot
agent copilot llm openai python python-terminal
Last synced: 9 months ago
JSON representation
A python terminal with a coding copilot
- Host: GitHub
- URL: https://github.com/roy-pstr/python-pilot
- Owner: roy-pstr
- License: mit
- Created: 2024-03-13T13:28:04.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-03-25T09:45:51.000Z (almost 2 years ago)
- Last Synced: 2024-04-25T12:21:26.876Z (over 1 year ago)
- Topics: agent, copilot, llm, openai, python, python-terminal
- Language: Python
- Homepage:
- Size: 13.2 MB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# PyPilot
A python terminal with a coding copilot inside.
This is a regular python terminal, only that your comments are used as requests queries for the copilot.
Don't forget to set the API KEY (supports only OPENAI for now).
## Demo

## Features
- Code generation inside the python terminal.
- Your comments are used to communicate with the copilot.
- The copilot is aware of the terminal history and locals.
- Both code and chat responses are supported.
- Supports system commands from within the terminal (e.g. !pip install ).
- Supports all OpenAI models.
## Installation
```bash
$ pip install python-pilot
```
## Usage
```bash
$ pypilot --api-key sk-....
```
or
```bash
$ export OPENAI_API_KEY=sk-...
$ pypilot
```
# TODO
- Add a way to use history only with headers of functions...
- Docker containers
- Add a selector step that decide what context the next llm prompt should have:
- history: code executed (w/wo expressions), errors, llm requests
- locals: vars, functions, modules
(full terminal history, locals only) and if the output should be code or chat
- Add support in llm config file