Skip to content

Commit

Permalink
Merge pull request #38 from docker/cm/da-big-1
Browse files Browse the repository at this point in the history
Start refactor to use new prompts system
  • Loading branch information
ColinMcNeil authored Sep 12, 2024
2 parents 0dd4aa9 + eae40e7 commit f046fe3
Show file tree
Hide file tree
Showing 20 changed files with 5,258 additions and 635 deletions.
32 changes: 32 additions & 0 deletions .github/workflows/build-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Build extension on release

on:
release:
types: [published]

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: "Checkout code"
uses: actions/checkout@v4

- name: "Set up Node.js"
uses: actions/setup-node@v2
with:
node-version: "20"

- name: "Install dependencies"
run: npm install
- name: "Build extension"
run: npm run package

- name: upload vsix
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ github.token }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: *.vsix
asset_name: ${{ github.event.release.tag_name }}.vsix
asset_content_type: application/vsix
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Change Log

All notable changes to the "make-runbook" extension will be documented in this file.
All notable changes to the "labs-ai-tools-vscode" extension will be documented in this file.

Check [Keep a Changelog](http://keepachangelog.com/) for recommendations on how to structure this file.

Expand Down
2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Visual Studio Code Extension for Docker Runbooks
Visual Studio Code Extension for Docker Prompts

Copyright (c) Docker Inc

Expand Down
35 changes: 10 additions & 25 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,45 +1,30 @@
# Docker Runbook Generator
# Docker AI Prompts

The Docker Runbook Generator is a standalone VSCode extension to add additional runbook features on top of the experimental [Docker-VScode](https://github.com/docker/docker-vscode/) extension.

## What is this project?

"Make Runbook" uses generative AI and project analysis to generate a Docker specific runbook-style `README.md` to your project.

See the following for an example:
## What is this project?

![runbook demo video](./screenshots/demo.gif)

## Getting started
Docker Desktop must be installed, and running with an active Docker Hub account.
Docker internal users: You must be opted-out of mandatory sign-in.

1. Install latest VSIX file https://github.com/docker/labs-make-runbook/releases
1. Install latest VSIX file https://github.com/docker/labs-ai-tools-vscode/releases
2. Open your workspace
3. Execute command `>Set OpenAI API key...` and enter your OpenAI secret key. Alternatively, configure Ollama in settings `docker.make-runbook`
4. Execute command `>Generate a runbook for this project`
3. Execute command `>Set OpenAI API key...` and enter your OpenAI secret key.
4. Execute command `>save-prompt` and enter your prompt URL/ref.
Example prompt: `https://github.com/docker/labs-ai-tools-for-devs/tree/main/prompts/poem`
5. Execute command `>run-prompt`

This project is a research prototype. It is ready to try and will give results for any project you try it on.

We are still actively working on the prompt engineering.

## Development

### Ollama support
We use the OpenAI Typescript client, meaning all OpenAI compatible models can be used.

Configure the model and endpoint using settings
`docker.make-runbook.openai-base` and `docker.make-runbook.openai-model`

![ollama config screenshot](./screenshots/ollama.png)

### Changing prompts
See [prompts README](./prompts/README.md).

### Local developement

```sh
# docker:command=build-and-install
yarn run compile
yarn run package
code --install-extension make-runbook-0.0.9.vsix
# Outputs vsix file
code --install-extension your-file.vsix
```
Loading

0 comments on commit f046fe3

Please sign in to comment.