Neurosymbolic verification for your CI/CD pipeline
QWED combines Neural Networks (LLMs) with Symbolic Reasoning (SymPy, Z3) to provide deterministic verification of AI outputs.
Use cases:
- ✅ Verify mathematical calculations in PRs
- ✅ Check logical reasoning in documentation
- ✅ Detect unsafe code patterns
- ✅ Validate LLM outputs before deployment
Add this to your .github/workflows/verify.yml:
name: Verify with QWED
on: [push, pull_request]
jobs:
verify:
runs-on: ubuntu-latest
steps:
- name: Verify Calculation
uses: QWED-AI/qwed-verification@v2.2.0
with:
query: "What is the derivative of x^2?"
provider: "openai"
api-key: ${{ secrets.OPENAI_API_KEY }}| Input | Description | Required | Default |
|---|---|---|---|
query |
Question or statement to verify | ✅ Yes | - |
provider |
LLM provider (openai, anthropic, gemini) |
No | openai |
api-key |
API key for LLM provider | No | - |
model |
Model name (e.g., gpt-4o-mini) |
No | gpt-4o-mini |
mask-pii |
Enable PII masking (true/false) |
No | false |
verification-type |
Type: auto, math, logic, code |
No | auto |
| Output | Description |
|---|---|
verified |
Verification result (true/false) |
value |
Verified value or result |
confidence |
Confidence score (0.0-1.0) |
evidence |
JSON evidence of verification |
- name: Check Math
uses: QWED-AI/qwed-verification@v2.2.0
with:
query: "What is 2^10?"
provider: "openai"
api-key: ${{ secrets.OPENAI_API_KEY }}- name: Check Logic
uses: QWED-AI/qwed-verification@v2.2.0
with:
query: "Is (A AND NOT A) satisfiable?"
provider: "anthropic"
api-key: ${{ secrets.ANTHROPIC_API_KEY }}- name: Security Check
uses: QWED-AI/qwed-verification@v2.2.0
with:
query: |
Is this code safe?
```python
eval(user_input)
```
verification-type: "code"- name: Secure Verification
uses: QWED-AI/qwed-verification@v2.2.0
with:
query: "User email: john@example.com, calculate 2+2"
mask-pii: "true"
provider: "openai"
api-key: ${{ secrets.OPENAI_API_KEY }}- 🔒 PII Masking: Automatically mask sensitive data (emails, SSNs, credit cards)
- 🏠 Local Option: Use local LLMs (Ollama) for zero cloud exposure
- 🔐 API Keys: Use GitHub Secrets for secure credential management
- ✅ Open Source: Full transparency, no black boxes
Your Query
↓
LLM Response (GPT-4, Claude, etc.)
↓
Symbolic Verification (SymPy, Z3, AST)
↓
✅ Deterministic Proof or ❌ Verification Failure
Example:
- Query: "What is the derivative of x^2?"
- LLM says: "2x"
- SymPy computes:
diff(x**2, x) = 2*x - QWED: ✅ MATCH! Verified with 100% confidence
API Keys (choose one):
- OpenAI:
OPENAI_API_KEY - Anthropic:
ANTHROPIC_API_KEY - Google:
GOOGLE_API_KEY
Or use local LLMs (Ollama) for free!
- Issues: GitHub Issues
- PyPI: qwed
- Twitter: @rahuldass29
Apache 2.0 - See LICENSE
Made with 💜 by QWED-AI