-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
5410cd5
commit c5e5155
Showing
17 changed files
with
363 additions
and
131 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
- `revo` for graphql/rag and fine-grained data access | ||
- bismuth | ||
- ratatui rust cli | ||
- paige | ||
- agents building infrastructure was super interesting | ||
- > if you ask a really concise question, you'll get many fewer questions for clarification | ||
- tinfoil | ||
- attestations | ||
- nvidia gpus now shipping with gpms | ||
- confidentiality | ||
- enclaves | ||
- aws nitro hypervisors | ||
- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
- [[br]] |
89 changes: 89 additions & 0 deletions
89
graphs/prompts/logseq/bak/journals/2024_09_03/2024-11-11T15_55_25.389Z.Desktop.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
- Run some prompts checked in to GitHub against a project in the current working directory. | ||
id:: 66d779c7-c1b7-40c6-a635-fa712da492de | ||
```sh | ||
docker run | ||
--rm -it \ | ||
--pull=always \ | ||
-v /var/run/docker.sock:/var/run/docker.sock \ | ||
-v /run/host-services/backend.sock:/host-services/docker-desktop-backend.sock \ | ||
-e "DOCKER_DESKTOP_SOCKET_PATH=/host-services/docker-desktop-backend.sock" \ | ||
--mount type=volume,source=docker-prompts,target=/prompts \ | ||
-e "OPENAI_API_KEY_LOCATION=/root" \ | ||
--mount type=bind,source=$HOME/.openai-api-key,target=/root/.openai-api-key \ | ||
vonwig/prompts:latest \ | ||
run \ | ||
--host-dir $PWD \ | ||
--platform $(uname -o) \ | ||
--prompts "github:docker/labs-make-runbook?ref=main&path=prompts/lazy_docker" | ||
``` | ||
- Most of this is boiler plate except: | ||
- the `--user` option in line 10 requires a valid DOCKER_HUB user name | ||
- the `--prompts` option in line 12 requires a valid [github reference]([[GitHub Refs]]) to some markdown prompts | ||
- if the project is located somewhere other than $PWD then the `--host-dir` will need to be updated. | ||
- Run a local prompt markdown file against a project in the current working directory. In this example, the prompts are not pulled from GitHub. Instead, our prompts are being developed in a directory called `$PROMPTS_DIR`. In this example, the local prompt file is `$PROMPTS_DIR/myprompts.md`. | ||
id:: 66d77f1b-1684-480d-ad7b-5e9f53292fe4 | ||
```sh | ||
docker run | ||
--rm -it \ | ||
--pull=always \ | ||
-v /var/run/docker.sock:/var/run/docker.sock \ | ||
-v /run/host-services/backend.sock:/host-services/docker-desktop-backend.sock \ | ||
-e "DOCKER_DESKTOP_SOCKET_PATH=/host-services/docker-desktop-backend.sock" \ | ||
--mount type=volume,source=docker-prompts,target=/prompts \ | ||
-e "OPENAI_API_KEY_LOCATION=/root" \ | ||
--mount type=bind,source=$HOME/.openai-api-key,target=/root/.openai-api-key \ | ||
--mount type=bind,source=$PROMPTS_DIR,target=/app/workdir \ | ||
--workdir /app/workdir \ | ||
vonwig/prompts:latest \ | ||
run \ | ||
--host-dir $PWD \ | ||
--platform $(uname -o) \ | ||
--prompts-file myprompts.md | ||
``` | ||
- Most of this is boiler plate except: | ||
- the `--user` option in line 12 requires a valid DOCKER_HUB user name | ||
- the `--prompts-file` option in line 14 is a relative path to a prompts file (relative to $PROMPTS_DIR) | ||
- if the project being analyzed is located somewhere other than $PWD then the `--host-dir` will need to be updated. | ||
- [[Running the Prompt Engine]] | ||
- [[Authoring Prompts]] | ||
- id:: 66d7f3ff-8769-40b3-b6b5-fc4fceea879e | ||
``` | ||
--- | ||
extractors: | ||
- name: linguist | ||
image: vonwig/go-linguist:latest | ||
command: | ||
- -json | ||
output-handler: linguist | ||
tools: | ||
- name: findutils-by-name | ||
description: find files in a project by name | ||
parameters: | ||
type: object | ||
properties: | ||
glob: | ||
type: string | ||
description: the glob pattern for files that should be found | ||
container: | ||
image: vonwig/findutils:latest | ||
command: | ||
- find | ||
- . | ||
- -name | ||
model: llama3.1 | ||
url: http://localhost/v1/chat/completions | ||
stream: false | ||
--- | ||
# Prompt system | ||
You are an expert on analyzing project content. | ||
# Prompt user | ||
{{#linguist}} | ||
This project contains {{language}} code. | ||
{{/linguist}} | ||
Can you find any language specific project files and list them? | ||
``` |
87 changes: 87 additions & 0 deletions
87
graphs/prompts/logseq/bak/journals/2024_09_03/2024-11-11T15_55_34.983Z.Desktop.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
- Run some prompts checked in to GitHub against a project in the current working directory. | ||
id:: 66d779c7-c1b7-40c6-a635-fa712da492de | ||
```sh | ||
docker run | ||
--rm -it \ | ||
--pull=always \ | ||
-v /var/run/docker.sock:/var/run/docker.sock \ | ||
-v /run/host-services/backend.sock:/host-services/docker-desktop-backend.sock \ | ||
-e "DOCKER_DESKTOP_SOCKET_PATH=/host-services/docker-desktop-backend.sock" \ | ||
--mount type=volume,source=docker-prompts,target=/prompts \ | ||
-e "OPENAI_API_KEY_LOCATION=/root" \ | ||
--mount type=bind,source=$HOME/.openai-api-key,target=/root/.openai-api-key \ | ||
vonwig/prompts:latest \ | ||
run \ | ||
--host-dir $PWD \ | ||
--platform $(uname -o) \ | ||
--prompts "github:docker/labs-make-runbook?ref=main&path=prompts/lazy_docker" | ||
``` | ||
- Most of this is boiler plate except: | ||
- the `--user` option in line 10 requires a valid DOCKER_HUB user name | ||
- the `--prompts` option in line 12 requires a valid [github reference]([[GitHub Refs]]) to some markdown prompts | ||
- if the project is located somewhere other than $PWD then the `--host-dir` will need to be updated. | ||
- Run a local prompt markdown file against a project in the current working directory. In this example, the prompts are not pulled from GitHub. Instead, our prompts are being developed in a directory called `$PROMPTS_DIR`. In this example, the local prompt file is `$PROMPTS_DIR/myprompts.md`. | ||
id:: 66d77f1b-1684-480d-ad7b-5e9f53292fe4 | ||
```sh | ||
docker run | ||
--rm -it \ | ||
--pull=always \ | ||
-v /var/run/docker.sock:/var/run/docker.sock \ | ||
-v /run/host-services/backend.sock:/host-services/docker-desktop-backend.sock \ | ||
-e "DOCKER_DESKTOP_SOCKET_PATH=/host-services/docker-desktop-backend.sock" \ | ||
--mount type=volume,source=docker-prompts,target=/prompts \ | ||
-e "OPENAI_API_KEY_LOCATION=/root" \ | ||
--mount type=bind,source=$HOME/.openai-api-key,target=/root/.openai-api-key \ | ||
--mount type=bind,source=$PROMPTS_DIR,target=/app/workdir \ | ||
--workdir /app/workdir \ | ||
vonwig/prompts:latest \ | ||
run \ | ||
--host-dir $PWD \ | ||
--platform $(uname -o) \ | ||
--prompts-file myprompts.md | ||
``` | ||
- Most of this is boiler plate except: | ||
- the `--user` option in line 12 requires a valid DOCKER_HUB user name | ||
- the `--prompts-file` option in line 14 is a relative path to a prompts file (relative to $PROMPTS_DIR) | ||
- if the project being analyzed is located somewhere other than $PWD then the `--host-dir` will need to be updated. | ||
- [[Running the Prompt Engine]] | ||
- [[Authoring Prompts]] | ||
- --- | ||
id:: 66d7f3ff-8769-40b3-b6b5-fc4fceea879e | ||
extractors: | ||
- name: linguist | ||
image: vonwig/go-linguist:latest | ||
command: | ||
- -json | ||
output-handler: linguist | ||
tools: | ||
- name: findutils-by-name | ||
description: find files in a project by name | ||
parameters: | ||
type: object | ||
properties: | ||
glob: | ||
type: string | ||
description: the glob pattern for files that should be found | ||
container: | ||
image: vonwig/findutils:latest | ||
command: | ||
- find | ||
- . | ||
- -name | ||
model: llama3.1 | ||
url: http://localhost/v1/chat/completions | ||
stream: false | ||
--- | ||
|
||
# Prompt system | ||
|
||
You are an expert on analyzing project content. | ||
|
||
# Prompt user | ||
|
||
{{#linguist}} | ||
This project contains {{language}} code. | ||
{{/linguist}} | ||
|
||
Can you find any language specific project files and list them? |
9 changes: 9 additions & 0 deletions
9
.../prompts/logseq/bak/pages/Authoring Prompts/2024-11-11T15_55_25.397Z.Desktop.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# Prompt files | ||
The simplest prompt file is just markdown content. We use `h1` headers to delineate the blocks containing prompts and the name of the header to determine the prompt role. | ||
A prompt file can also contain metadata about how to generate and run the prompt. | ||
{{embed ((66d7f3ff-8769-40b3-b6b5-fc4fceea879e)) }} | ||
The example above defines a lot of metadata. A prompt file might also be very simple. | ||
{{embed ((66d8a396-9268-4917-882f-da4c52b7b5dd)) }} | ||
Use the [prompt engine]([[Running the Prompt Engine]]) to run this prompt file against an LLM. | ||
- ## Prompt Metadata | ||
- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
- Volumes are managed by the top-level container. In other words, we construct them as we need them. | ||
- the `--thread-id` allows the user of the prompt engine to control the names of the volume | ||
- by default, tool containers will be started with at least one volume mounted at `/thread` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# Summary | ||
|
||
This prompt defines no tools. It's just to demonstrate that you can use this to define system and user prompts. | ||
|
||
# prompt system | ||
|
||
You try to start every sentence with the letter 'a'. | ||
|
||
# prompt user | ||
|
||
Can you give me a quick summary of the NASA space program? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# Summary | ||
|
||
There are no prompts or tools in this file. The engine should complain. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.