Skip to content

Commit

Permalink
Update runtime_tools.md (#562)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeadie authored Oct 25, 2024
1 parent 145025d commit 0cc4aeb
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions spiceaidocs/docs/features/ai-gateway/runtime_tools.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,22 @@ models:
spice_tools: auto # Use all available tools
```
### Tool Recursion Limit
When a model requests to call a runtime tool, Spice runs the tool internally and feeds it back to the model. The `tool_recursion_limit` parameter limits the depth of internal recursion Spice will undertake. By default, Spice can infinitely recurse if the model requests to do so.

```yaml
models:
- name: my-model
from: openai
params:
tool_recursion_limit: 3
```

## Available tools
- `list_datasets`: List all available datasets in the runtime.
- `sql`: Execute SQL queries on the runtime.
- `table_schema`: Get the schema of a specific SQL table.
- `document_similarity`: For datasets with an embedding column, retrieve documents based on an input query. It is equivalent to [/v1/search](/api/http/search).
- `sample_distinct_columns`: For a dataset, generate a synthetic sample of data whereby each column has at least a number of distinct values.
- `random_sample`: Sample random rows from a table.
- `top_n_sample`: Sample the top N rows from a table based on a specified ordering.

0 comments on commit 0cc4aeb

Please sign in to comment.