aboutsummaryrefslogtreecommitdiffstats
path: root/agents/demo
diff options
context:
space:
mode:
Diffstat (limited to 'agents/demo')
-rw-r--r--agents/demo/README.md31
-rw-r--r--agents/demo/index.yaml4
2 files changed, 19 insertions, 16 deletions
diff --git a/agents/demo/README.md b/agents/demo/README.md
index ab9831d..856c7ff 100644
--- a/agents/demo/README.md
+++ b/agents/demo/README.md
@@ -21,21 +21,26 @@ variables:
When use define variables, please avoid these built-in variables:
-| name | description | example |
-| :------------ | :-------------------------------------------- | :----------------------- |
-| __os__ | Operating system name | linux |
-| __os_family__ | Operating system family | unix |
-| __arch__ | System architecture | x86_64 |
-| __shell__ | Current user's default shell | bash |
-| __locale__ | User's preferred language and region settings | en-US |
-| __now__ | Current timestamp in ISO 8601 format | 2024-07-29T08:11:24.367Z |
-| __cwd__ | Current working directory | /tmp |
-
-Variables should be used in the `instructions` field.
+| name | description | example |
+| :-------------- | :-------------------------------------------- | :----------------------- |
+| `__os__` | Operating system name | linux |
+| `__os_family__` | Operating system family | unix |
+| `__arch__` | System architecture | x86_64 |
+| `__shell__` | Current user's default shell | bash |
+| `__locale__` | User's preferred language and region settings | en-US |
+| `__now__` | Current timestamp in ISO 8601 format | 2024-07-29T08:11:24.367Z |
+| `__cwd__` | Current working directory | /tmp |
+| `__tools__` | List of agent tools | |
+
+Variables can be used in the `instructions` and tools script.
```yaml
instructions: |
- The instructions can inline user defined variables: {{foo}}, {{bar}} and builtin variables {{__shell__}}.
+ The instructions can access variables {{foo}} and {{bar}}.
+```
+
+```sh
+echo "The tools script can access environment variables $LLM_AGENT_VAR_FOO and $LLM_AGENT_VAR_BAR"
```
### documents
@@ -53,8 +58,6 @@ documents:
The tool script implements agent-specific tools.
-> You only need one of the `tools.sh`, `tools.js`, or `tools.py`.
-
## tools.txt
The `tools.txt` file enables tool reuse from the `/tools` folder in this project.
diff --git a/agents/demo/index.yaml b/agents/demo/index.yaml
index 18116b6..5b718be 100644
--- a/agents/demo/index.yaml
+++ b/agents/demo/index.yaml
@@ -2,10 +2,10 @@ name: Demo
description: This is demo agent.
version: 0.1.0
instructions: |
- You are a AI agent designed to demonstrate agent capabilities.
+ You are a AI agent designed to demonstrate agent capabilities.
<tools>
- __TOOLS__
+ {{__tools__}}
</tools>
<system>