Context
How to supply your agent with additional context
Prompt injection with context
Any additional context you’d like to provide to your LLM can be added in adding
the context
section to your .agent.yml
file, as shown below:
This means that SQL files can be added to your oxy repository as plain .sql
files, then supplied to the agent using the context
object.
You can then reference these within the system_instructions
using Jinja, as follows:
where queries
references the name
given in the context
field.
Best practices for SQL
For SQL queries, in particular, at the top of these files, you should generally add a comment that describes what the query does (we call this “front matter” internally).
The accepted format of this front matter will likely change in the future.
Retrieval configuration
To configure data instead for retrieval, see the agents section.