Giter Site home page Giter Site logo

shell-ai's Introduction

Hi, I'm Ilan! ๐Ÿ™‹๐Ÿฝโ€โ™‚๏ธ

I'm a builder and reader based in New York doing my best to figure out what I care about in life. ๐ŸŒณ

Hours of scripting can save you minutes of manual labor...

...but hundreds of hours for everyone else.

I mean, that's not why I do it. It's just fun. But it's a great way to justify it :)

shell-ai's People

Contributors

ibigio avatar joecummings avatar mayd524 avatar tpai avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

shell-ai's Issues

Add support for input box line wrapping

Context

Currently when a user enters more text than the width of the screen, it allows you to keep entering text but it is off-screen (so you can't see what it is).

Task

Make it so a user entering text will overflow / wrap to the next line.

Feature Request - Cache the previous command for context

Hey @ibigio. Might be pretty useful if ShellAI takes in the previous command as context for the next response. I'd love to contribute so if this sounds good I can start writing the feature.

Quick example:
This:

$ docker tag myImage myAcr.azurecr.io/myImage
$ q push the above image

    docker push <image_name>

Would turn into this:

$ docker tag myImage myAcr.azurecr.io/myImage
$ q push the above image

    docker push myAcr.azurecr.io/myImage

Let me know what you think!

Make install script more robust

Context

The install script only works sometimes, and is troublesome on managed machines with multiple users.

Task

Update script to work consistently and intuitively on more Linux distros / setups, based on other existing install.sh examples.

Fix buggy output on narrow terminals

Context

On a narrow terminal window where rendered output wraps to the line below, sometimes output jumps around and creates "sticky" artifacts that end up in the terminal output.

Screen.Recording.2023-06-25.at.6.52.03.PM.mov

Given that this only occurs on narrows terminal windows where lines wrap around I'm guessing this might be an issue how BubbleTea handles rapid updates to the rendered markdown output. Also going to try validating that there's no rogue tea.Print or actual prints messing things up.

Task

Find root cause of jumpy output and fix, so it is stable and leaves no artifacts.

Investigate slow first request on some networks

Context

Noticed while traveling to Mexico that while using the tool from some networks the response to the first prompt consistently took > 15 seconds, even though subsequent followups were still returning in ~1-3 seconds. My hunch is that something is slowing down the initial http client setup / first request, and then reusing the http client for followups makes it quicker. Ideally this tool should work quickly from any network.

Task

Investigate why first request is so slow, propose potential solutions, discuss and implement.

Some ideas:

  • Use a daemon to maximize http client reuse.
  • Cache some intermediate connection state on disk and load it at runtime(?)
  • Take the L.

It broke!

I set up a new computer today, and set my OPENAI_API_KEY in my ~/.zprofile and q does not work:

> q hello

  Error: Failed to connect to OpenAI.

  API request failed: 404 Not Found

I went back to my old computer (which was working great with shell-ai) and did a brew upgrade shell-ai, and now it does the same thing.

Add support for -4 flag for GPT4

Context

Currently to use GPT4 instead of 3.5 you have to set OPENAI_MODEL_OVERRIDE to gpt-4, but this feels clumsy especially when you just want shell-ai to be smarter for just a sec.

Task

Add support for passing the -4 or -gpt4 flag to cause the model to use the gpt-4 model. (This is a quality of life improvement.)

Unable to connect to OpenAI

Context

It does not seem possible to connect to OpenAI, even with a newly generated API key.
Installed via brew.

image

Fix occasional infinite loading state

Context

Sometimes I'll make a request or followup and the spinner will go forever. Not sure if this a state-machine bug in cli.go or a network issue.

Task

Investigate why this happens, and if it's a real issue fix it.

SEO is impossibly hard for this project :)

I LOVE this tool and keep trying to tell people about it. But I forget the name. So I run

> q --help
A command line interface for natural language queries

Usage:
  q [request] [flags]

Flags:
  -h, --help   help for q

Which doesn't tell me the name or the link to this project. So then I do ls -la $(which q) and see that I got it from Homebrew and it's called shell-ai. So then I google shell-ai and I get a bunch of things that aren't this project (including similarly named projects and Shell the oil company).

I've done this a couple times now when trying to tell people about this.

Probably would be good to at least add a link to this GitHub in the --help!

Fix stream / final response content discrepancy (MISSING)

Context

I noticed with the prompt print first 20 prime numbers (on version v0.3.0) that the streaming response looks ok, but when it gets tea.Printfed it suddenyl has a (MISSING) in the text that didn't used to be there. Weird. Might have to do with the rendering in tea.Printf the final response vs the stream string returned in View()...

Screen.Recording.2023-06-11.at.10.13.51.PM.mov

Task

Investigate and fix it.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.