# We Scored Oracle's Database Skill Live: 95% Isn't Enough

## Executive summary

The video demonstrates how Oracle's database team utilized AI 'skills'—encapsulated in a repository like `oracle/skills`—to guide AI agents in writing secure and best-practice compliant SQL. The process involved running an automated review (using Tessl) on a skill designed to improve database code generation, which initially scored 95%. Through iterative refinement and applying changes via a 'run, review, fix' cycle, the skill was successfully upgraded to a 100% success rate, showcasing a robust mechanism for encoding complex domain knowledge into AI workflows.

## Key takeaways

- Purpose of Database Skills: The primary function of the skill is to help agents write better SQL and database code by making them knowledgeable about the database's capabilities (e.g., property graphs, vector data). It helps discover what the database can do, rather than relying solely on general agent knowledge.
- Skill Review Process: The skill was subjected to an automated review comparing it against best practices. The process involves running a 'run, review, fix' cycle, which applies changes and re-runs the validation in an agile style approach.
- Achieving 100% Compliance: After making specific developer-suggested changes (e.g., adding a recommended sequence task), the skill's review score reached 100%, demonstrating continuous improvement and validation of domain knowledge.

## Technical details

- AI Skill Architecture: Skills are designed to supplement an agent’s knowledge, particularly for niche syntax or complex interactions (like property graphs), reducing the chance of hallucination compared to general documentation lookups. The skill is housed in a structure like `oracle/skills`.
- Development Workflow: The skills can be paired with a database MCP server for local development, allowing the skills to interact directly with the database using tools like calling activism.
- Security and Best Practices: Skills are used to encode best practices beyond just 'how' to do something, focusing on how to do it securely (e.g., preventing SQL injections) and scalably.

## Practical implications

- Automating the enforcement of complex domain best practices (like secure SQL patterns) within AI agent workflows.
- Using structured skills to guide agents through multi-step processes, mimicking a controlled Software Development Lifecycle (SDLC).
- Implementing iterative validation loops ('run, review, fix') to ensure high reliability and compliance in generated code/queries.

## Topics

AI Agents, Database Engineering, SQL Best Practices, Skill Automation, DevOps, Tessl, Oracle Skills GitHub repo

Source: https://www.youtube.com/watch?v=Jwz0k8ZK9TE
