Skip to content

Commit 7b76699

Browse files
committed
chore (docs): some fixes and enhancements
1 parent 8ae9e22 commit 7b76699

File tree

7 files changed

+20
-18
lines changed

7 files changed

+20
-18
lines changed

docs/docs/02-examples/01-cli.md

+6-6
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ Agents: k8s-agent, github-agent
157157
Context: shared-context
158158
Chat: true
159159
160-
Help the user acomplish their tasks using the tools you have. When the user starts this chat, just say hello and ask what you can help with. You donlt need to start off by guiding them.
160+
Help the user acomplish their tasks using the tools you have. When the user starts this chat, just say hello and ask what you can help with. You don't need to start off by guiding them.
161161
```
162162

163163
By being at the top of the file, this tool will serve as the script's entrypoint. Here are the parts of this tool that are worth additional explanation:
@@ -201,14 +201,14 @@ Context: shared-context
201201
Agents: k8s-agent, github-agent
202202
Chat: true
203203
204-
Help the user acomplish their tasks using the tools you have. When the user starts this chat, just say hello and ask what you can help with. You donlt need to start off by guiding them.
204+
Help the user acomplish their tasks using the tools you have. When the user starts this chat, just say hello and ask what you can help with. You don't need to start off by guiding them.
205205
206206
---
207207
Name: k8s-agent
208208
Description: An agent that can help you with your Kubernetes cluster by executing kubectl commands
209209
Context: shared-context
210210
Tools: sys.exec
211-
Parameter: task: The kubectl releated task to accomplish
211+
Parameter: task: The kubectl related task to accomplish
212212
Chat: true
213213
214214
You have the kubectl cli available to you. Use it to accomplish the tasks that the user asks of you.
@@ -268,15 +268,15 @@ By now you should notice a simple pattern emerging that you can follow to add yo
268268
```
269269
Name: {your cli}-agent
270270
Description: An agent to help you with {your taks} related tasks using the gh cli
271-
Context: {here's your biggest decsion to make}, shared-context
271+
Context: {here's your biggest decision to make}, shared-context
272272
Tools: sys.exec
273-
Parameter: task: The {your task}The GitHub task to accomplish
273+
Parameter: task: The {your task} to accomplish
274274
Chat: true
275275
276276
You have the {your cli} cli available to you. Use it to accomplish the tasks that the user asks of you.
277277
```
278278

279-
You can drop in your task and CLI and have a fairly functional CLI-based chat agent. The biggest decision you'll need to make is what and how much context to give your agent. For well-known for CLIs/technologies like kubectl and Kubernetes, you probably won't need a custom context. For custom CLIs, you'll definitely need to help the LLM out. The best approach is to experiment and see what works best.
279+
You can drop in your task and CLI and have a fairly functional CLI-based chat agent. The biggest decision you'll need to make is what and how much context to give your agent. For well-known CLIs/technologies like kubectl and Kubernetes, you probably won't need a custom context. For custom CLIs, you'll definitely need to help the LLM out. The best approach is to experiment and see what works best.
280280

281281
## Next steps
282282

docs/docs/02-examples/04-local-files.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -45,11 +45,11 @@ This is actually the entirety of the script. We're packing a lot of power into j
4545

4646
The **Tools: ...** stanza pulls two useful tools into this assistant.
4747

48-
The [structured-data-querier](https://github.com/gptscript-ai/structured-data-querier) makes it possible to query csv, xlsx, and json files as though they SQL databases (using an application called [DuckDB](https://duckdb.org/)). This is extremely powerful when combined with the power of LLMs because it let's you ask natural language questions that the LLM can then translate to SQL.
48+
The [structured-data-querier](https://github.com/gptscript-ai/structured-data-querier) makes it possible to query csv, xlsx, and json files as though they were SQL databases (using an application called [DuckDB](https://duckdb.org/)). This is extremely powerful when combined with the power of LLMs because it let's you ask natural language questions that the LLM can then translate to SQL.
4949

5050
The [pdf-reader](https://github.com/gptscript-ai/pdf-reader) isn't quite as exciting, but still useful. It parses and reads PDFs and returns the contents to the LLM. This will put the entire contents in your chat context, so it's not appropriate for extremely large PDFs, but it's handy for smaller ones.
5151

52-
**Context: github.com/gptscript-ai/context/workspace** introduces a context tool makes this assistant "workspace" aware. It's description reads:
52+
**Context: github.com/gptscript-ai/context/workspace** introduces a context tool that makes this assistant "workspace" aware. It's description reads:
5353
> Adds the workspace and tools needed to access the workspace to the current context
5454
5555
That translates to telling the LLM what the workspace directory is and instructing it to use that directory for reading and writing files. As we saw above, you can specify a workspace like this:

docs/docs/03-tools/03-openapi.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# OpenAPI Tools
22

3-
GPTScript can treat OpenAPI v3 definition files as though they were tool files.
3+
GPTScript can treat OpenAPI v2 and v3 definition files as though they were tool files.
44
Each operation (a path and HTTP method) in the file will become a simple tool that makes an HTTP request.
55
GPTScript will automatically and internally generate the necessary code to make the request and parse the response.
66

@@ -44,6 +44,7 @@ Will be resolved as `https://api.example.com/v1`.
4444
:::warning
4545
All authentication options will be completely ignored if the server uses HTTP and not HTTPS.
4646
This is to protect users from accidentally sending credentials in plain text.
47+
HTTP is only OK, if it's on localhost/127.0.0.1.
4748
:::
4849

4950
### 1. Security Schemes

docs/docs/03-tools/05-context.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ Here is a simple example of a context provider tool that provides additional con
4545

4646
```yaml
4747
# my-search-context-tool.gpt
48-
export: sys.http.html2text?
48+
share tools: sys.http.html2text?
4949

5050
#!/bin/bash
5151
echo You are an expert web researcher with access to the Search tool.If the search tool fails to return any information stop execution of the script with message "Sorry! Search did not return any results". Feel free to get the contents of the returned URLs in order to get more information. Provide as much detail as you can. Also return the source of the search results.
@@ -71,7 +71,7 @@ Here is an example of a context provider tool that uses args to decide which sea
7171

7272
```yaml
7373
# context_with_arg.gpt
74-
export: github.com/gptscript-ai/search/duckduckgo, github.com/gptscript-ai/search/brave, sys.http.html2text?
74+
share tools: github.com/gptscript-ai/search/duckduckgo, github.com/gptscript-ai/search/brave, sys.http.html2text?
7575
args: search_tool: tool to search with
7676

7777
#!/bin/bash
@@ -84,7 +84,7 @@ Continuing with the above example, this is how you can use it in a script:
8484
```yaml
8585
# my_context_with_arg.gpt
8686
context: ./context_with_arg.gpt with ${search} as search_tool
87-
Args: search: Search tool to use
87+
args: search: Search tool to use
8888

8989
What are some of the most popular tourist destinations in Scotland, and how many people visit them each year?
9090

docs/docs/03-tools/06-how-it-works.md

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
# How it works
22

3-
**_GPTScript is composed of tools._** Each tool performs a series of actions similar to a function. Tools have available
4-
to them other tools that can be invoked similar to a function call. While similar to a function, the tools are
3+
**_GPTScript is composed of tools._** Each tool performs a series of actions similar to a function. Tools have other tools available to them that can be invoked similar to a function call. While similar to a function, the tools are
54
primarily implemented with a natural language prompt. **_The interaction of the tools is determined by the AI model_**,
65
the model determines if the tool needs to be invoked and what arguments to pass. Tools are intended to be implemented
76
with a natural language prompt but can also be implemented with a command or HTTP call.

docs/docs/03-tools/07-gpt-file-reference.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,8 @@ Tool parameters are key-value pairs defined at the beginning of a tool block, be
6060
| `Credential` | Credential tool to call to set credentials as environment variables before doing anything else. One per line. |
6161
| `Agents` | A comma-separated list of agents that are available to the tool. |
6262
| `Share Tools` | A comma-separated list of tools that are shared by the tool. |
63-
| `Context` | A comma-separated list of context tools available to the tool |
64-
63+
| `Context` | A comma-separated list of context tools available to the tool. |
64+
| `Share Context` | A comma-separated list of context tools shared by this tool with any tool including this tool in its context. |
6565

6666

6767

docs/docs/05-alternative-model-providers.md

+4-2
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,11 @@ model: mistral-large-latest from https://api.mistral.ai/v1
1212
Say hello world
1313
```
1414

15-
#### Note
16-
Mistral's La Plateforme has an OpenAI compatible API, but the model does not behave identically to gpt-4. For that reason, we also have a provider for it that might get better results in some cases.
15+
:::note
1716

17+
Mistral's La Plateforme has an OpenAI compatible API, but the model does not behave identically to gpt-4. For that reason, we also have a provider for it that might get better results in some cases.
18+
19+
:::
1820

1921
### Using a model that requires a provider
2022
```gptscript

0 commit comments

Comments
 (0)