bumpy-florist-37019
12/07/2025, 11:40 PMtall-airline-16756
12/07/2025, 11:40 PMtall-airline-16756
12/07/2025, 11:41 PMbumpy-florist-37019
12/07/2025, 11:42 PMtall-airline-16756
12/07/2025, 11:42 PMbumpy-florist-37019
12/07/2025, 11:45 PMtall-airline-16756
12/07/2025, 11:45 PMplugins:
- name: groq-llm
type: llm
provider: groq
api_key: ${GROQ_API_KEY}
model: groq-llama-xx
- name: groq-llama-guard
type: llm
provider: groq
api_key: ${GROQ_API_KEY}
endpoint: https://api.groq.com/llama-guard # match the notebook endpoint
Example Agent flow (conceptual):
1. Agent calls groq-llm to generate response text.
2. Agent sends generated text to groq-llama-guard plugin (or direct guard endpoint).
3. If guard verdict = allow → return response. If redact/block → redact or return alternate reply.
Minimal code snippet (pseudo-JS) showing post‑processing:
const resp = await agent.callPlugin('groq-llm', { prompt });
const text = resp.output;
const guard = await agent.callPlugin('groq-llama-guard', { input: text });
// or call guard endpoint directly with same payload as notebook
if (guard.verdict === 'allow') {
return text;
} else if (guard.verdict === 'redact') {
return redactText(text, guard.redactions);
} else {
return "I can't help with that.";
}
Next steps
• I can produce a concrete plugin YAML/JSON and an Agent code example that follows the exact request/response shape from the Groq notebook you linked. Would you like that? If so, tell me whether you prefer a full Agent example in JavaScript, Python, or YAML-first configuration.